{"Message":"增加周报的AI生成功能","MessageType":2,"Modules":[{"State":1,"Type":1,"Name":"PCPage/项目标题"},{"State":1,"Type":1,"Name":"PCPage/汇报详情"},{"State":1,"Type":40,"Name":"Plugin"},{"State":1,"Type":15,"Name":"ServerCommand/AI对话"},{"State":1,"Type":1,"Name":"PCPage/项目周报首页"},{"State":1,"Type":1,"Name":"PCPage/项目周报详情"},{"State":3,"Type":15,"Name":"ServerCommand/AI生成周报"}],"Version":"v1"}

This commit is contained in:
SHAMUSPC\NINGMEI
2024-05-21 11:43:02 +08:00
parent abaf835b76
commit f6f0fa7e3f
13 changed files with 1257 additions and 322 deletions

View File

@@ -0,0 +1,484 @@
{
"Name": "AI生成周报",
"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": "成员",
"DataValidationInfo": {
"IgnoreBlank": false
},
"TestData": "Administrator"
},
{
"Name": "项目ID",
"DataValidationInfo": {
"IgnoreBlank": false
}
},
{
"Name": "生成日期",
"DataValidationInfo": {
"IgnoreBlank": false
},
"TestData": "2024-05-21"
}
],
"InvokeTriggerTestData": {
"UserName": "Administrator"
}
}
],
"Commands": [
{
"$type": "Forguncy.Model.CatchExceptionCommand, ServerDesignerCommon",
"TryCommandPart": {
"CommandList": [
{
"$type": "Forguncy.Model.Commands.SetParameterCommand, ServerDesignerCommon",
"ParameterName": "项目",
"TableValue": {
"TableName": "项目表",
"TableValueType": 1,
"BindingInfos": [
{
"GUID": "918e9258-8319-428c-9b9e-21465d7c4c21",
"BindingInfo": {
"TableName": "项目表",
"ColumnName": "项目名称",
"GUID": "e3ae3770-3818-4a35-8783-8a1cd506c188"
},
"ColumnName": "项目名称"
},
{
"GUID": "f60f492d-e013-4447-985b-a7400086e1f2",
"BindingInfo": {
"TableName": "项目表",
"ColumnName": "项目经理",
"GUID": "7785e73f-e24d-45e4-ae0d-841ad6d99329",
"AttachType": {
"$type": "ForguncyDataAccess.UserColumnAttachObj, ForguncyDataAccess",
"UserColumnAttachType": 1
}
},
"ColumnName": "项目经理_全名"
}
],
"SqlCondition": {
"$type": "ForguncyDataAccess.GeneralCESqlCondition, ForguncyDataAccess",
"ColumnBindingInfo": {
"TableName": "项目表",
"ColumnName": "ID",
"GUID": "de34a6be-921b-46f5-abb6-4bfe6ef9b946"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=项目ID"
}
},
"TopCount": "1"
},
"ID": "7ce3f27f33cc4c438d7d7268f0c11182"
},
{
"$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": "JsonUtilityCommand.JsonSerializeCommand, JsonUtilityCommand",
"SourceObject": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=项目"
},
"ToParameter": "项目信息字符串"
},
{
"$type": "Forguncy.Model.Commands.SetParameterCommand, ServerDesignerCommon",
"ParameterName": "上周起始日期",
"ParameterValue": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=生成日期-WEEKDAY(生成日期,3)-7"
},
"ID": "4115a274972f45bba55e6fb5e8fbfd0c"
},
{
"$type": "Forguncy.Model.Commands.SetParameterCommand, ServerDesignerCommon",
"ParameterName": "上周结束日期",
"ParameterValue": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=生成日期-WEEKDAY(生成日期,3)-1"
},
"ID": "b9fc3400e48043f8bf5ad1b06c5c0864"
},
{
"$type": "Forguncy.Model.Commands.SetParameterCommand, ServerDesignerCommon",
"ParameterName": "本周开始日期",
"ParameterValue": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=生成日期-WEEKDAY(生成日期,3)"
},
"ID": "9c4578b6e5024eb1904bd2332289058e"
},
{
"$type": "Forguncy.Model.Commands.SetParameterCommand, ServerDesignerCommon",
"ParameterName": "本周结束日期",
"ParameterValue": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=生成日期-WEEKDAY(生成日期,3)+6"
},
"ID": "88d0d170d12e4993af02e464ce3c7bcf"
},
{
"$type": "Forguncy.Model.Commands.SetParameterCommand, ServerDesignerCommon",
"ParameterName": "上周工作日报",
"TableValue": {
"TableName": "汇报子表",
"BindingInfos": [
{
"GUID": "5a86d5e9-81a5-4702-9802-ee8703242820",
"BindingInfo": {
"TableName": "汇报子表",
"ColumnName": "汇报ID",
"GUID": "03bafd85-46b6-491f-8d80-cfaa6f064ea3",
"RelationBinding": {
"RelatedTable": "汇报记录表",
"RelatedColumn": "ID",
"DisplayColumn": "汇报日期"
}
},
"ColumnName": "汇报日期"
},
{
"GUID": "983acae3-afea-4289-97da-4e7e6a1b4115",
"BindingInfo": {
"TableName": "汇报子表",
"ColumnName": "关联任务",
"GUID": "f0ea9e3a-3809-4c20-88e4-d9b559823675",
"RelationBinding": {
"RelatedTable": "任务表",
"RelatedColumn": "ID",
"DisplayColumn": "任务名称"
}
},
"ColumnName": "任务名称"
},
{
"GUID": "4ef1c2f9-819e-44b6-838e-ee59bd614947",
"BindingInfo": {
"TableName": "汇报子表",
"ColumnName": "汇报类型",
"GUID": "afd89dec-976c-4ea3-a7ca-9ee6a18f049c"
},
"ColumnName": "汇报类型"
},
{
"GUID": "75f5117f-96ea-401b-ac1c-f656d00274fe",
"BindingInfo": {
"TableName": "汇报子表",
"ColumnName": "汇报内容",
"GUID": "83dc859a-42d2-459b-9264-83540e1ef87c"
},
"ColumnName": "汇报内容"
},
{
"GUID": "b375e278-c5bc-4ba1-b97d-c8d1fefd61a3",
"BindingInfo": {
"TableName": "汇报子表",
"ColumnName": "工时",
"GUID": "c85b16eb-fc2a-4c39-ad41-8cfb9b2921c8"
},
"ColumnName": "工时"
}
],
"SqlCondition": {
"$type": "ForguncyDataAccess.RelationSqlCondition, ForguncyDataAccess",
"SubConditions": [
{
"$type": "ForguncyDataAccess.GeneralCESqlCondition, ForguncyDataAccess",
"ColumnBindingInfo": {
"TableName": "汇报子表",
"ColumnName": "汇报ID",
"GUID": "e83bc92a-a9b1-459f-900a-51ee910af6d9",
"RelationBinding": {
"RelatedTable": "汇报记录表",
"RelatedColumn": "ID",
"DisplayColumn": "汇报人"
}
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=成员"
}
},
{
"$type": "ForguncyDataAccess.GeneralCESqlCondition, ForguncyDataAccess",
"CompareType": 3,
"ColumnBindingInfo": {
"TableName": "汇报子表",
"ColumnName": "汇报ID",
"GUID": "0f825103-4fca-4ad4-819d-7ed1d8cb5200",
"RelationBinding": {
"RelatedTable": "汇报记录表",
"RelatedColumn": "ID",
"DisplayColumn": "汇报日期"
}
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=上周起始日期"
}
},
{
"$type": "ForguncyDataAccess.GeneralCESqlCondition, ForguncyDataAccess",
"CompareType": 5,
"ColumnBindingInfo": {
"TableName": "汇报子表",
"ColumnName": "汇报ID",
"GUID": "976797f8-83c0-46ea-b4a1-3df852eaeb86",
"RelationBinding": {
"RelatedTable": "汇报记录表",
"RelatedColumn": "ID",
"DisplayColumn": "汇报日期"
}
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=上周结束日期"
}
},
{
"$type": "ForguncyDataAccess.GeneralCESqlCondition, ForguncyDataAccess",
"ColumnBindingInfo": {
"TableName": "汇报子表",
"ColumnName": "汇报类型",
"GUID": "b17ef968-65b8-4709-bcc8-d3517e583bb6"
},
"Value": "日报"
},
{
"$type": "ForguncyDataAccess.GeneralCESqlCondition, ForguncyDataAccess",
"ColumnBindingInfo": {
"TableName": "汇报子表",
"ColumnName": "关联项目",
"GUID": "7104cc4b-18cc-4562-8aed-449ac3319774"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=项目ID"
}
}
]
}
},
"ID": "40a01e57ab3444eb9575e658664bbad5"
},
{
"$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": "=上周工作日报.Count"
}
},
"value": "0",
"compareType": 2
},
"CommandList": [
{
"$type": "JsonUtilityCommand.JsonSerializeCommand, JsonUtilityCommand",
"SourceObject": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=上周工作日报"
},
"ToParameter": "上周工作日报字符串"
},
{
"$type": "CollectionOperationKit.ServerSideArrayOp, CollectionOperationKit",
"OutParamaterName": "消息记录"
},
{
"$type": "CollectionOperationKit.ServerSideObjectOp, CollectionOperationKit",
"OperationParamaterPairs": [
{
"Name": "role",
"Value": "user"
},
{
"Name": "content",
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=项目信息字符串"
}
}
],
"OutParamaterName": "项目信息消息对象"
},
{
"$type": "CollectionOperationKit.ServerSideArrayOp, CollectionOperationKit",
"InParamater": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=消息记录"
},
"Operation": 4,
"OperationParamaterAName": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=项目信息消息对象"
},
"OutParamaterName": "消息记录"
},
{
"$type": "CollectionOperationKit.ServerSideObjectOp, CollectionOperationKit",
"OperationParamaterPairs": [
{
"Name": "role",
"Value": "user"
},
{
"Name": "content",
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=上周工作日报字符串"
}
}
],
"OutParamaterName": "日报消息对象"
},
{
"$type": "CollectionOperationKit.ServerSideArrayOp, CollectionOperationKit",
"InParamater": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=消息记录"
},
"Operation": 4,
"OperationParamaterAName": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=日报消息对象"
},
"OutParamaterName": "消息记录"
},
{
"$type": "OPENAIFORGUNCY.Completions, OPENAIFORGUNCY",
"URL": "https://openai.api2d.net",
"APIKEY": "fk211858-C6yKrsealBkvHao04yT9Ypg6GR0NVPyh",
"IsDataSource": "json",
"MessageJSON": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=消息记录"
},
"Parameter": {
"Model": 43,
"Temperature": 1.0,
"TopP": 1.0,
"MaxTokens": 500,
"SystemContent": "我将会发送两个JSON数据第一个为项目的信息第二个为该项目上周的工作日报列表请根据内容为我编写该项目的上周工作总结按照任务进行分类用简短语言描述上周的工作生成内容要求1、请保证返回结果中仅包含报告内容2、不要给周报整体添加标题、说明描述等3、请使用HTML编辑器对段落进行排版4、字数不要超过500字",
"Response_format": "text"
},
"Tools": [],
"ResultTo": "result",
"CommandList": []
},
{
"$type": "Forguncy.Model.ReturnCommand, ServerDesignerCommon",
"ErrorCode": "0",
"Message": "生成完毕",
"CustomReturns": [
{
"ReturnPropertyName": "上周工作",
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=result.content"
}
}
]
}
],
"ID": "8335e543-f850-4648-982c-2b4a4b847747"
},
{
"CommandList": [
{
"$type": "Forguncy.Model.ReturnCommand, ServerDesignerCommon",
"ErrorCode": "400",
"Message": "您上周没有日报,无法为您总结!",
"CustomReturns": [
{
"ReturnPropertyName": "上周工作"
}
]
}
],
"ID": "f78ac38a-7949-452e-a73c-171a2af3be44"
}
]
}
],
"ID": "51703d1d-086c-41db-969c-8149ff8ff24e"
}
]
}
]
},
"CatchCommandPart": {
"CommandList": [
{
"$type": "Forguncy.Model.ReturnCommand, ServerDesignerCommon",
"ErrorCode": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=ExceptionCode"
},
"Message": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=ExceptionMessage"
},
"CustomReturns": [
{
"ReturnPropertyName": "上周工作"
}
]
}
]
}
}
],
"ReturnProperties": [
{
"Name": "上周工作"
}
]
}