Files
clue/ServerCommands/工时/分配任务工时.json
超哥 43974fddb7 {"Message":"完成请款流程","MessageType":2,"Modules":[{"State":1,"Type":7,"Name":"Table/任务工时表"},{"State":1,"Type":7,"Name":"Table/收益变动记录表"},{"State":1,"Type":7,"Name":"Table/收款账户信息表"},{"State":1,"Type":7,"Name":"Table/收益请款单表"},{"State":1,"Type":7,"Name":"Table/付款凭证表"},{"State":1,"Type":1,"Name":"PCPage/项目列表"},{"State":1,"Type":1,"Name":"PCPage/项目首页"},{"State":1,"Type":1,"Name":"PCPage/项目标题"},{"State":1,"Type":1,"Name":"PCPage/项目信息"},{"State":1,"Type":1,"Name":"PCPage/任务-子任务列表"},{"State":1,"Type":1,"Name":"PCPage/工时详情"},{"State":1,"Type":1,"Name":"PCPage/修改报工"},{"State":1,"Type":1,"Name":"PCPage/个人中心-收款账户"},{"State":1,"Type":1,"Name":"PCPage/收益中心"},{"State":1,"Type":1,"Name":"PCPage/收益中心-收益请款记录"},{"State":1,"Type":1,"Name":"PCPage/收益中心-变动记录"},{"State":1,"Type":1,"Name":"PCPage/收益中心-收益明细"},{"State":2,"Type":1,"Name":"PCPage/提交结算申请单"},{"State":1,"Type":1,"Name":"PCPage/审批结算申请单"},{"State":1,"Type":1,"Name":"PCPage/办理结算审批单"},{"State":1,"Type":15,"Name":"ServerCommand/分配任务工时"},{"State":2,"Type":15,"Name":"ServerCommand/绑定工时与请款单"},{"State":2,"Type":15,"Name":"ServerCommand/绑定结算请款单凭证ID"},{"State":2,"Type":15,"Name":"ServerCommand/记录收益变动"},{"State":1,"Type":28,"Name":"ProcessItem/结算申请"},{"State":1,"Type":12,"Name":"CustomLibrary"},{"State":1,"Type":23,"Name":"TableView/项目平行视图"},{"State":3,"Type":38,"Name":"Image/返回.svg"},{"State":3,"Type":15,"Name":"ServerCommand/删除请款单"},{"State":3,"Type":1,"Name":"PCPage/生成结算申请单"},{"State":3,"Type":15,"Name":"ServerCommand/完成请款单"},{"State":3,"Type":15,"Name":"ServerCommand/生成请款单"}],"Version":"v1"}
2024-06-21 14:39:24 +08:00

1044 lines
67 KiB
JSON

{
"Name": "分配任务工时",
"Enabled": true,
"Triggers": [
{
"$type": "Forguncy.SaveLoad.PostRequestTriggerSaveData, ServerDesignerCommon",
"Permission": {
"PermissionData": {
"$type": "Forguncy.RbacPermission.Core.Impl.ServerCommand.ServerCommandPermissionData, Forguncy.RbacPermission.Core",
"permissionResource": {
"$type": "Forguncy.RbacPermission.Core.Impl.ServerCommand.ServerCommandPermissionResource, Forguncy.RbacPermission.Core"
},
"permissionBindings": [
{
"$type": "Forguncy.RbacPermission.Core.Impl.ServerCommand.ServerCommandPermissionBinding, Forguncy.RbacPermission.Core",
"roleNames": [
"FGC_LoginUser"
]
}
]
}
},
"Parameters": [
{
"Name": "任务ID",
"DataValidationInfo": {
"IgnoreBlank": false
},
"TestData": "2"
},
{
"Name": "开始日期",
"DataValidationInfo": {},
"TestData": "2024-03-01"
},
{
"Name": "结束日期",
"DataValidationInfo": {},
"TestData": "2024-03-10"
},
{
"Name": "执行人",
"DataValidationInfo": {
"IgnoreBlank": false
},
"TestData": "administrator"
},
{
"Name": "工时数",
"DataValidationInfo": {
"IgnoreBlank": false
},
"TestData": "40"
},
{
"Name": "备注",
"DataValidationInfo": {},
"TestData": "测试"
}
],
"InvokeTriggerTestData": {
"UserName": "Administrator"
}
}
],
"Commands": [
{
"$type": "Forguncy.Model.CatchExceptionCommand, ServerDesignerCommon",
"TryCommandPart": {
"CommandList": [
{
"$type": "Forguncy.Model.Commands.SetParameterCommand, ServerDesignerCommon",
"ParameterName": "任务信息",
"TableValue": {
"TableName": "任务平行视图",
"TableValueType": 1,
"BindingInfos": [
{
"GUID": "136684ee-5394-4682-b812-1b29d38b3420",
"BindingInfo": {
"TableName": "任务平行视图",
"ColumnName": "项目ID",
"GUID": "305361b8-995e-48bc-99d6-f008471584ca"
},
"ColumnName": "项目ID"
},
{
"GUID": "be9d4292-cb11-40d5-b3e1-c303ad79c30f",
"BindingInfo": {
"TableName": "任务平行视图",
"ColumnName": "任务名称",
"GUID": "1514429a-cb4c-433a-a448-a452f6e330dd"
},
"ColumnName": "任务名称"
},
{
"GUID": "43c2eef2-5eb0-4255-96df-17ae07a9c3fd",
"BindingInfo": {
"TableName": "任务平行视图",
"ColumnName": "任务状态",
"GUID": "b0c6d3c7-733a-4b63-a511-f4f3299b9e05"
},
"ColumnName": "任务状态"
},
{
"GUID": "dddbffb0-3233-4b2d-96be-cb774747ecc9",
"BindingInfo": {
"TableName": "任务平行视图",
"ColumnName": "任务状态",
"GUID": "4fe7e2d7-474c-4257-9186-51fd7c25b219",
"RelationBinding": {
"RelatedTable": "任务状态",
"RelatedColumn": "状态码",
"DisplayColumn": "任务状态"
}
},
"ColumnName": "任务状态文本"
},
{
"GUID": "a1843f4c-9646-472e-9576-89ddbcf172ab",
"BindingInfo": {
"TableName": "任务平行视图",
"ColumnName": "项目ID",
"GUID": "7ce07b47-d21f-4abe-8a7a-3e0ec69b559d",
"RelationBinding": {
"RelatedTable": "项目平行视图",
"RelatedColumn": "ID",
"DisplayColumn": "严格模式"
}
},
"ColumnName": "严格模式"
},
{
"GUID": "c0244cf1-8b1e-454f-800b-4bb38eadee25",
"BindingInfo": {
"TableName": "任务平行视图",
"ColumnName": "任务类型",
"GUID": "bea8ca1b-c9c4-4681-940b-d701f4944130",
"RelationBinding": {
"RelatedTable": "任务类型",
"RelatedColumn": "ID",
"DisplayColumn": "提成系数"
}
},
"ColumnName": "提成系数"
},
{
"GUID": "9d72b79e-ff35-4351-98e2-12ced45e989a",
"BindingInfo": {
"TableName": "任务平行视图",
"ColumnName": "项目ID",
"GUID": "e76d70e2-a2fe-48eb-bd6e-e28af6b71990",
"RelationBinding": {
"RelatedTable": "项目平行视图",
"RelatedColumn": "ID",
"DisplayColumn": "工时分配方式"
}
},
"ColumnName": "工时分配方式"
},
{
"GUID": "b5130014-cef4-4b45-b66c-95b040c23157",
"BindingInfo": {
"TableName": "任务平行视图",
"ColumnName": "开始时间",
"GUID": "862b87e2-946e-40a0-896e-09a97d96f51c"
},
"ColumnName": "开始时间"
},
{
"GUID": "d85138a4-04d9-425e-9492-5fa12b6c7312",
"BindingInfo": {
"TableName": "任务平行视图",
"ColumnName": "任务负责人",
"GUID": "a2e73ddf-4af8-436f-8a01-997bff966952"
},
"ColumnName": "执行者"
},
{
"GUID": "209b24c9-daff-4dad-a9e1-4fb89f674d09",
"BindingInfo": {
"TableName": "任务平行视图",
"ColumnName": "可分配工时",
"GUID": "6054feca-ba74-4e7f-989e-c9a201859a2e"
},
"ColumnName": "可分配工时"
}
],
"SqlCondition": {
"$type": "ForguncyDataAccess.GeneralCESqlCondition, ForguncyDataAccess",
"ColumnBindingInfo": {
"TableName": "任务平行视图",
"ColumnName": "ID",
"GUID": "565ce7a5-e5aa-434e-aecf-d7e00ac509fd"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=任务ID"
}
},
"NullFormulaValueQueryPolicy": 0,
"TopCount": "1"
},
"ID": "0a5e439272554e37a96d7a61d8f69050"
},
{
"$type": "Forguncy.Model.ConditionCommand, ServerDesignerCommon",
"ConditionAndCommandPairList": [
{
"Condition": {
"$type": "Forguncy.Model.IfCondition, ServerDesignerCommon",
"param": {
"$type": "Forguncy.Model.IfConditionServerSiteParam, ServerDesignerCommon",
"ParamObject": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=任务信息"
}
},
"value": "%Null%",
"compareType": 1
},
"CommandList": [
{
"$type": "Forguncy.Model.ConditionCommand, ServerDesignerCommon",
"ConditionAndCommandPairList": [
{
"Condition": {
"$type": "Forguncy.Model.IfCondition, ServerDesignerCommon",
"param": {
"$type": "Forguncy.Model.IfConditionServerSiteParam, ServerDesignerCommon",
"ParamObject": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=工时数"
}
},
"value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=任务信息.可分配工时"
},
"compareType": 5
},
"CommandList": [
{
"$type": "Forguncy.Model.Commands.SetParameterCommand, ServerDesignerCommon",
"ParameterName": "项目成员",
"TableValue": {
"TableName": "项目成员表",
"TableValueType": 1,
"BindingInfos": [
{
"GUID": "ee221b91-2992-463b-9493-acc5b7663f33",
"BindingInfo": {
"TableName": "项目成员表",
"ColumnName": "ID",
"GUID": "5b0ac4f9-25c2-4d0b-953b-8fc25f915d3b"
},
"ColumnName": "ID"
},
{
"GUID": "c1732deb-776f-49d7-8563-7d9058f5b468",
"BindingInfo": {
"TableName": "项目成员表",
"ColumnName": "项目成员",
"GUID": "5e5071c7-2eb0-4ea8-a5c9-d4a102f25e24"
},
"ColumnName": "项目成员"
},
{
"GUID": "bfa78a83-ddf3-4e65-8bc8-47f34976a30e",
"BindingInfo": {
"TableName": "项目成员表",
"ColumnName": "默认时薪",
"GUID": "d434791e-bf5a-4688-8caa-7777fe811018"
},
"ColumnName": "成员时薪"
},
{
"GUID": "45ac5922-6553-416d-9fa5-456c90450ff7",
"BindingInfo": {
"TableName": "项目成员表",
"ColumnName": "岗位ID",
"GUID": "0742bcd9-236d-4c48-87fb-d1f4a981a3e5",
"RelationBinding": {
"RelatedTable": "项目岗位",
"RelatedColumn": "ID",
"DisplayColumn": "默认时薪"
}
},
"ColumnName": "岗位时薪"
},
{
"GUID": "bf119452-c85b-4e1e-b6bc-8caa94231883",
"BindingInfo": {
"TableName": "项目成员表",
"ColumnName": "项目成员",
"GUID": "653b75d4-3491-4a4c-a330-00b180998295",
"AttachType": {
"$type": "ForguncyDataAccess.UserColumnAttachObj, ForguncyDataAccess",
"UserColumnAttachType": 5,
"AttachTypeTag": "默认时薪"
}
},
"ColumnName": "用户时薪"
},
{
"GUID": "7fcdba55-5874-49c8-af9d-5bba537ebbf5",
"BindingInfo": {
"TableName": "项目成员表",
"ColumnName": "项目成员",
"GUID": "496e2025-1b05-42b2-8858-f75e717c926f",
"AttachType": {
"$type": "ForguncyDataAccess.UserColumnAttachObj, ForguncyDataAccess",
"UserColumnAttachType": 5,
"AttachTypeTag": "负荷"
}
},
"ColumnName": "成员负荷"
}
],
"SqlCondition": {
"$type": "ForguncyDataAccess.RelationSqlCondition, ForguncyDataAccess",
"SubConditions": [
{
"$type": "ForguncyDataAccess.GeneralCESqlCondition, ForguncyDataAccess",
"ColumnBindingInfo": {
"TableName": "项目成员表",
"ColumnName": "项目ID",
"GUID": "363b99f0-817d-4c62-aabd-a1cc3bfc8d6c"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=任务信息.项目ID"
}
},
{
"$type": "ForguncyDataAccess.GeneralCESqlCondition, ForguncyDataAccess",
"ColumnBindingInfo": {
"TableName": "项目成员表",
"ColumnName": "项目成员",
"GUID": "ee74776e-38e4-4133-98c0-520529836bdf"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=执行人"
}
}
]
},
"NullFormulaValueQueryPolicy": 0,
"TopCount": "1"
},
"ID": "2c47908cb40649a4b37a29783b09b61b"
},
{
"$type": "Forguncy.Model.ConditionCommand, ServerDesignerCommon",
"ConditionAndCommandPairList": [
{
"Condition": {
"$type": "Forguncy.Model.IfCondition, ServerDesignerCommon",
"param": {
"$type": "Forguncy.Model.IfConditionServerSiteParam, ServerDesignerCommon",
"ParamObject": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=项目成员"
}
},
"value": "%Null%",
"compareType": 1
},
"CommandList": [
{
"$type": "Forguncy.Model.Commands.SetParameterCommand, ServerDesignerCommon",
"ParameterName": "提成系数",
"ParameterValue": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=任务信息.提成系数"
},
"ID": "cf9f329698f54d8e9b353d2f024fd2de"
},
{
"$type": "Forguncy.Model.Commands.SetParameterCommand, ServerDesignerCommon",
"ParameterName": "任务成员是否存在",
"TableValue": {
"TableName": "任务成员表",
"TableValueType": 3,
"SqlCondition": {
"$type": "ForguncyDataAccess.RelationSqlCondition, ForguncyDataAccess",
"SubConditions": [
{
"$type": "ForguncyDataAccess.GeneralCESqlCondition, ForguncyDataAccess",
"ColumnBindingInfo": {
"TableName": "任务成员表",
"ColumnName": "任务ID",
"GUID": "513afd45-e476-45f0-a858-293abdb3c212"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=任务ID"
}
},
{
"$type": "ForguncyDataAccess.GeneralCESqlCondition, ForguncyDataAccess",
"ColumnBindingInfo": {
"TableName": "任务成员表",
"ColumnName": "任务成员",
"GUID": "40488a39-9df7-4064-80ab-e9f36af4a0e3"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=执行人"
}
}
]
},
"NullFormulaValueQueryPolicy": 0
},
"ID": "94021ae43c984221ba0c00ffdd38ae06"
},
{
"$type": "Forguncy.Model.ConditionCommand, ServerDesignerCommon",
"ConditionAndCommandPairList": [
{
"Condition": {
"$type": "Forguncy.Model.IfCondition, ServerDesignerCommon",
"param": {
"$type": "Forguncy.Model.IfConditionServerSiteParam, ServerDesignerCommon",
"ParamObject": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=任务成员是否存在"
}
},
"value": "0"
},
"CommandList": [
{
"$type": "Forguncy.Model.UpdateDataTableCommand, ServerDesignerCommon",
"TableName": "任务成员表",
"UpdateType": "add",
"ShowConfirm": false,
"UpdateBindingValues": [
{
"BindingInfo": {
"TableName": "任务成员表",
"ColumnName": "项目ID",
"GUID": "907e634d-70aa-4e00-88d9-f79953045dfd"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=任务信息.项目ID"
}
},
{
"BindingInfo": {
"TableName": "任务成员表",
"ColumnName": "任务ID",
"GUID": "abd77ff1-74af-4c64-b709-ba12c09c4449"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=任务ID"
}
},
{
"BindingInfo": {
"TableName": "任务成员表",
"ColumnName": "任务成员",
"GUID": "0cd16274-f487-4f8c-944d-2160958e5a56"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=执行人"
}
}
],
"ParamNameToSaveNewRowValue": ""
}
],
"ID": "57248cd4-2838-4f18-a187-2040ad1ce0b6"
}
]
},
{
"$type": "Forguncy.Model.ConditionCommand, ServerDesignerCommon",
"ConditionAndCommandPairList": [
{
"Condition": {
"$type": "Forguncy.Model.IfCondition, ServerDesignerCommon",
"param": {
"$type": "Forguncy.Model.IfConditionServerSiteParam, ServerDesignerCommon",
"ParamObject": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=任务信息.任务状态"
}
},
"value": "2"
},
"CommandList": [
{
"$type": "Forguncy.Model.ConditionCommand, ServerDesignerCommon",
"ConditionAndCommandPairList": [
{
"Condition": {
"$type": "Forguncy.Model.IfCondition, ServerDesignerCommon",
"param": {
"$type": "Forguncy.Model.IfConditionServerSiteParam, ServerDesignerCommon",
"ParamObject": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=任务信息.工时分配方式"
}
},
"value": "1"
},
"CommandList": [
{
"$type": "Forguncy.Model.Commands.SetParameterCommand, ServerDesignerCommon",
"ParameterName": "计算开始日期",
"ParameterValue": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=TODAY()"
},
"ID": "c784c1c888af40a18ac06d86dd9aa3c1"
},
{
"$type": "Forguncy.Model.Commands.SetParameterCommand, ServerDesignerCommon",
"ParameterName": "计算结束日期",
"ParameterValue": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=TODAY()"
},
"ID": "f1babee3af9a4401b69d66a5728facf3"
}
],
"ID": "d243eecb-bdef-4cb6-8560-9a34f370378e"
},
{
"Condition": {
"$type": "Forguncy.Model.IfCondition, ServerDesignerCommon",
"param": {
"$type": "Forguncy.Model.IfConditionServerSiteParam, ServerDesignerCommon",
"ParamObject": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=任务信息.工时分配方式"
}
},
"value": "2"
},
"CommandList": [
{
"$type": "Forguncy.Model.Commands.SetParameterCommand, ServerDesignerCommon",
"ParameterName": "计算开始日期",
"ParameterValue": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=开始日期"
},
"ID": "f23c325e19c74deaac8b0bd00de7bb0c"
},
{
"$type": "Forguncy.Model.Commands.SetParameterCommand, ServerDesignerCommon",
"ParameterName": "计算结束日期",
"ParameterValue": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=结束日期"
},
"ID": "aaefe8a951624a449e45823a45627c18"
}
],
"ID": "ce8b08de-2dc8-4063-a813-84cff33d9a44"
}
],
"Comments": "如果是按人分配,则把计划工时分到一天中"
},
{
"$type": "Forguncy.Model.Commands.SetParameterCommand, ServerDesignerCommon",
"ParameterName": "待分配工时",
"ParameterValue": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=工时数"
},
"ID": "538fe8a21ecb4b4cb6f8fbf831f03d1d"
},
{
"$type": "Forguncy.Model.Commands.SetParameterCommand, ServerDesignerCommon",
"ParameterName": "分配天数",
"ParameterValue": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=DATEDIF(开始日期,结束日期,\"d\")+1"
},
"ID": "e885f0713e4446d59779d8102dfa7ca5"
},
{
"$type": "Forguncy.Model.ServerTransactionCommand, ServerDesignerCommon",
"CommandList": [
{
"$type": "Forguncy.Model.LoopCommand, ServerDesignerCommon",
"LoopInfo": {
"$type": "Forguncy.Model.CountLoopInfo, ServerDesignerCommon",
"LoopCount": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=分配天数"
},
"LoopIndexParamName": "index",
"LoopItemParamName": "Item"
},
"CommandList": [
{
"$type": "Forguncy.Model.Commands.SetParameterCommand, ServerDesignerCommon",
"ParameterName": "当前日期",
"ParameterValue": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=开始日期+(index-1)"
},
"ID": "89d195a8f1f34d1ba004d79dc714d5ab"
},
{
"$type": "Forguncy.Model.Commands.SetParameterCommand, ServerDesignerCommon",
"ParameterName": "统计工时",
"TableValue": {
"TableName": "任务工时表",
"TableValueType": 1,
"BindingInfos": [
{
"GUID": "4ae72769-fd2f-4b8c-9ca5-cd1bb5f84b30",
"BindingInfo": {
"TableName": "任务工时表",
"ColumnName": "总工时",
"GUID": "a0006a9d-3fba-4cf5-a20a-d2a0909d5175"
},
"ColumnName": "总工时"
}
],
"SqlCondition": {
"$type": "ForguncyDataAccess.RelationSqlCondition, ForguncyDataAccess",
"SubConditions": [
{
"$type": "ForguncyDataAccess.GeneralCESqlCondition, ForguncyDataAccess",
"ColumnBindingInfo": {
"TableName": "任务工时表",
"ColumnName": "工时日期",
"GUID": "98f3f236-67bc-4db2-9af7-407e52bdcd74"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=当前日期"
}
},
{
"$type": "ForguncyDataAccess.GeneralCESqlCondition, ForguncyDataAccess",
"ColumnBindingInfo": {
"TableName": "任务工时表",
"ColumnName": "执行人",
"GUID": "9a1d5408-9353-4ab0-bef4-91af355df584"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=执行人"
}
},
{
"$type": "ForguncyDataAccess.GeneralCESqlCondition, ForguncyDataAccess",
"ColumnBindingInfo": {
"TableName": "任务工时表",
"ColumnName": "工时类型",
"GUID": "6fae6e04-e2b8-4d6c-b594-3bd02c5883d2"
},
"Value": "计划"
}
]
},
"NullFormulaValueQueryPolicy": 0
},
"ID": "7e69c5b18dbc4befa21da00cc4b1487f"
},
{
"$type": "Forguncy.Model.ConditionCommand, ServerDesignerCommon",
"ConditionAndCommandPairList": [
{
"Condition": {
"$type": "Forguncy.Model.IfCondition, ServerDesignerCommon",
"param": {
"$type": "Forguncy.Model.IfConditionServerSiteParam, ServerDesignerCommon",
"ParamObject": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=index"
}
},
"value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=分配天数"
},
"compareType": 4
},
"CommandList": [
{
"$type": "Forguncy.Model.Commands.SetParameterCommand, ServerDesignerCommon",
"ParameterName": "计算本次分配工时",
"ParameterValue": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=ROUNDUP(工时数/分配天数,1)"
},
"ID": "954da7d900d44d068c49c0775cbb66ad"
}
],
"ID": "6c34f9eb-9039-4cdd-8bcd-caeafe3003d5"
},
{
"CommandList": [
{
"$type": "Forguncy.Model.Commands.SetParameterCommand, ServerDesignerCommon",
"ParameterName": "计算本次分配工时",
"ParameterValue": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=ROUNDUP(待分配工时,1)"
},
"ID": "bd03cd955f4449cf9d84c422471b58ac"
}
],
"ID": "fa2e70eb-89ff-442e-b63d-7acc531ba781"
}
]
},
{
"$type": "Forguncy.Model.Commands.SetParameterCommand, ServerDesignerCommon",
"ParameterName": "预计增加后工时",
"ParameterValue": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=IF(统计工时.总工时=\"\",0,统计工时.总工时)+计算本次分配工时"
},
"ID": "cdea7fa17c4a44c5ba0ae697ab76f6e5"
},
{
"$type": "Forguncy.Model.Commands.SetParameterCommand, ServerDesignerCommon",
"ParameterName": "执行人负荷",
"ParameterValue": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=IF(OR(项目成员.成员负荷=\"\",项目成员.成员负荷=0,项目成员.成员负荷>24),24,项目成员.成员负荷)"
},
"ID": "5af95d7b590044bd919ee967c7ce6ae3"
},
{
"$type": "Forguncy.Model.ConditionCommand, ServerDesignerCommon",
"ConditionAndCommandPairList": [
{
"Condition": {
"$type": "ForguncyDataAccess.RelationSqlCondition, ForguncyDataAccess",
"SubConditions": [
{
"$type": "Forguncy.Model.IfCondition, ServerDesignerCommon",
"param": {
"$type": "Forguncy.Model.IfConditionServerSiteParam, ServerDesignerCommon",
"ParamObject": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=任务信息.工时分配方式"
}
},
"value": "1"
},
{
"$type": "Forguncy.Model.IfCondition, ServerDesignerCommon",
"param": {
"$type": "Forguncy.Model.IfConditionServerSiteParam, ServerDesignerCommon",
"ParamObject": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=预计增加后工时"
}
},
"value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=执行人负荷"
},
"compareType": 5
}
],
"RelationType": 1
},
"CommandList": [
{
"$type": "Forguncy.Model.Commands.SetParameterCommand, ServerDesignerCommon",
"ParameterName": "待分配工时",
"ParameterValue": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=ROUNDUP(待分配工时-计算本次分配工时,1)"
},
"ID": "8762d3868c56480ebf590a29716e9f32"
},
{
"$type": "Forguncy.Model.ServerTransactionCommand, ServerDesignerCommon",
"CommandList": [
{
"$type": "Forguncy.Model.UpdateDataTableCommand, ServerDesignerCommon",
"TableName": "任务工时表",
"UpdateType": "add",
"ShowConfirm": false,
"UpdateBindingValues": [
{
"BindingInfo": {
"TableName": "任务工时表",
"ColumnName": "项目ID",
"GUID": "62276f79-9b5c-4d2c-9ee7-1b22def93d88"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=任务信息.项目ID"
}
},
{
"BindingInfo": {
"TableName": "任务工时表",
"ColumnName": "任务ID",
"GUID": "78890980-32ba-437b-b818-5dacd60eaeb6"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=任务ID"
}
},
{
"BindingInfo": {
"TableName": "任务工时表",
"ColumnName": "工时日期",
"GUID": "77dbe469-acdf-4403-92cc-8f4df2d07741"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=当前日期"
}
},
{
"BindingInfo": {
"TableName": "任务工时表",
"ColumnName": "工时类型",
"GUID": "156b1aa9-00d0-4014-88dc-1de5bcdfa094"
},
"Value": "计划"
},
{
"BindingInfo": {
"TableName": "任务工时表",
"ColumnName": "执行人",
"GUID": "531143cf-d38d-4c86-8c93-9f9a97aa2d4e"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=执行人"
}
},
{
"BindingInfo": {
"TableName": "任务工时表",
"ColumnName": "执行内容",
"GUID": "8a60f2dd-d8c3-4de6-b836-f24daa94d0f7"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=备注"
}
},
{
"BindingInfo": {
"TableName": "任务工时表",
"ColumnName": "工时",
"GUID": "c14458b5-3e48-4525-bb12-fa7a103746cf"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=计算本次分配工时"
}
},
{
"BindingInfo": {
"TableName": "任务工时表",
"ColumnName": "时薪单价",
"GUID": "dfa43bea-2db8-4347-81b3-682ffe372a30"
},
"Value": "0"
},
{
"BindingInfo": {
"TableName": "任务工时表",
"ColumnName": "提成系数",
"GUID": "bc4394e7-3142-4cb6-8b31-422223365a39"
},
"Value": "0"
},
{
"BindingInfo": {
"TableName": "任务工时表",
"ColumnName": "时薪来源",
"GUID": "cd8474fe-29cd-4885-9ab9-06b3c1954441"
}
}
]
},
{
"$type": "Forguncy.Model.UpdateDataTableCommand, ServerDesignerCommon",
"TableName": "项目动态",
"UpdateType": "add",
"ShowConfirm": false,
"UpdateBindingValues": [
{
"BindingInfo": {
"TableName": "项目动态",
"ColumnName": "项目ID",
"GUID": "a584d5c3-214e-446e-b71f-e9ddaa1e076a"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=任务信息.项目ID"
}
},
{
"BindingInfo": {
"TableName": "项目动态",
"ColumnName": "项目动态",
"GUID": "99164e45-4b55-4277-ac9d-d27926533639"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=\"任务[\"&任务信息.任务名称&\"]增加计划工时\"&工时数&\"小时\""
}
},
{
"BindingInfo": {
"TableName": "项目动态",
"ColumnName": "执行人",
"GUID": "8dd8cb7f-ae3f-4c44-a488-6001d3c1df29"
},
"Value": "%CurrentUser%"
}
]
}
]
}
],
"Comments": "如果不是按人分配,且分配后的工时超过负荷,则报错",
"ID": "5bcefe86-54b7-42c9-a36d-9937ae264dd7"
},
{
"CommandList": [
{
"$type": "Forguncy.Model.ReturnCommand, ServerDesignerCommon",
"ErrorCode": "400",
"Message": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=TEXT(当前日期,\"yyyy年mm月dd\")&\"的最大工作负荷超出限制的\"&执行人负荷&\"小时,请重新提交!\""
}
}
],
"ID": "5bafb462-cbc7-4fbd-a9f8-e934a1118945"
}
]
}
]
}
]
},
{
"$type": "Forguncy.Model.ReturnCommand, ServerDesignerCommon",
"ErrorCode": "0",
"Message": "分配计划工时成功"
}
],
"ID": "52c76946-b751-42dc-b52d-517bd444faa4"
},
{
"CommandList": [
{
"$type": "Forguncy.Model.ReturnCommand, ServerDesignerCommon",
"ErrorCode": "400",
"Message": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=\"当前任务状态为[\"&任务信息.任务状态文本&\"],无法提交工时!\""
}
}
],
"ID": "bf83c604-28e7-4994-9167-33ff6931935c"
}
]
}
],
"ID": "1f129fa8-f603-46ef-bde1-8ca87368c489"
},
{
"CommandList": [
{
"$type": "Forguncy.Model.ReturnCommand, ServerDesignerCommon",
"ErrorCode": "400",
"Message": "该用户不是项目成员"
}
],
"ID": "79e2ea95-deb1-4260-9805-43f190ef789d"
}
],
"Comments": "如果任务成员中没有,则自动加一个"
}
],
"ID": "8f799997-03ea-43ed-8434-a36d3e109de6"
},
{
"CommandList": [
{
"$type": "Forguncy.Model.ReturnCommand, ServerDesignerCommon",
"ErrorCode": "400",
"Message": "您提交的工时超过任务预算工时,请修改后重新提交"
}
],
"ID": "e5d63a8d-12d3-4288-842a-238ae431f6c0"
}
]
}
],
"ID": "ec92978b-9d8f-49c2-83ce-6b57b0e83a14"
},
{
"CommandList": [
{
"$type": "Forguncy.Model.ReturnCommand, ServerDesignerCommon",
"ErrorCode": "400",
"Message": "任务不存在"
}
],
"ID": "0439b829-1a9b-4b3b-b8c7-caa2a070e7d7"
}
]
}
]
},
"CatchCommandPart": {
"CommandList": [
{
"$type": "Forguncy.Model.ReturnCommand, ServerDesignerCommon",
"ErrorCode": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=ExceptionCode"
},
"Message": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=ExceptionMessage"
}
}
]
}
}
]
}