{ "Name": "GitCallback", "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_Anonymous" ] } ] } } } ], "Commands": [ { "$type": "SaveFormData.GetFormDataFiles, SaveFormData", "ResultToReq": "请求信息" }, { "$type": "SaveFormData.fillInJSONProperties, SaveFormData", "FullJsonString": "{\r\n \"ref\": \"refs/heads/版本10\",\r\n \"sign\": \"\",\r\n \"user\": {\r\n \"id\": 13097545,\r\n \"url\": \"https://gitee.com/tyfeikele\",\r\n \"name\": \"tyfeikele\",\r\n \"email\": \"tyfeikele@qq.com\",\r\n \"username\": \"tyfeikele\",\r\n \"user_name\": \"tyfeikele\"\r\n },\r\n \"after\": \"e74df3005e06241146220c1c78b746b1cb903e9d\",\r\n \"before\": \"bce508cc4c7574d8974a6e94a832c639ad07af99\",\r\n \"pusher\": {\r\n \"id\": 13097545,\r\n \"url\": \"https://gitee.com/tyfeikele\",\r\n \"name\": \"tyfeikele\",\r\n \"email\": \"tyfeikele@qq.com\",\r\n \"username\": \"tyfeikele\",\r\n \"user_name\": \"tyfeikele\"\r\n },\r\n \"sender\": {\r\n \"id\": 13097545,\r\n \"url\": \"https://gitee.com/tyfeikele\",\r\n \"name\": \"tyfeikele\",\r\n \"type\": \"User\",\r\n \"email\": \"tyfeikele@qq.com\",\r\n \"login\": \"tyfeikele\",\r\n \"remark\": null,\r\n \"html_url\": \"https://gitee.com/tyfeikele\",\r\n \"username\": \"tyfeikele\",\r\n \"user_name\": \"tyfeikele\",\r\n \"avatar_url\": \"https://foruda.gitee.com/avatar/1687145611305567010/13097545_tyfeikele_1687145611.png\",\r\n \"site_admin\": false\r\n },\r\n \"commits\": [\r\n {\r\n \"id\": \"e74df3005e06241146220c1c78b746b1cb903e9d\",\r\n \"url\": \"https://gitee.com/cuckooent/pms/commit/e74df3005e06241146220c1c78b746b1cb903e9d\",\r\n \"added\": [\r\n \r\n ],\r\n \"author\": {\r\n \"id\": null,\r\n \"url\": null,\r\n \"name\": \"HZG System\",\r\n \"time\": \"2024-06-18T09:38:19+08:00\",\r\n \"user\": null,\r\n \"email\": \"HZG System\",\r\n \"remark\": null,\r\n \"username\": null,\r\n \"user_name\": null\r\n },\r\n \"message\": \"{\\\"Message\\\":\\\"签出模块 : 后端新增项目反馈, 匿名提交项目反馈\\\",\\\"MessageType\\\":1,\\\"Modules\\\":[],\\\"Version\\\":\\\"v1\\\"}\\n\",\r\n \"removed\": [\r\n \r\n ],\r\n \"tree_id\": \"57f89455bbd615902d2a41732205a659beec7dc4\",\r\n \"distinct\": true,\r\n \"modified\": [\r\n \".collaboration\"\r\n ],\r\n \"committer\": {\r\n \"id\": null,\r\n \"url\": null,\r\n \"name\": \"HZG System\",\r\n \"time\": null,\r\n \"user\": null,\r\n \"email\": \"HZG System\",\r\n \"remark\": null,\r\n \"username\": null,\r\n \"user_name\": null\r\n },\r\n \"timestamp\": \"2024-06-18T09:38:19+08:00\",\r\n \"parent_ids\": [\r\n \"bce508cc4c7574d8974a6e94a832c639ad07af99\"\r\n ]\r\n }\r\n ],\r\n \"compare\": \"https://gitee.com/cuckooent/pms/compare/bce508cc4c7574d8974a6e94a832c639ad07af99...e74df3005e06241146220c1c78b746b1cb903e9d\",\r\n \"created\": false,\r\n \"deleted\": false,\r\n \"hook_id\": 1400568,\r\n \"project\": {\r\n \"id\": 33487312,\r\n \"url\": \"https://gitee.com/cuckooent/pms\",\r\n \"fork\": false,\r\n \"name\": \"PMS\",\r\n \"path\": \"pms\",\r\n \"owner\": {\r\n \"id\": 5267986,\r\n \"url\": \"https://gitee.com/cuckooent\",\r\n \"name\": \"超哥\",\r\n \"type\": \"User\",\r\n \"email\": \"phoben@qq.com\",\r\n \"login\": \"cuckooent\",\r\n \"remark\": null,\r\n \"html_url\": \"https://gitee.com/cuckooent\",\r\n \"username\": \"cuckooent\",\r\n \"user_name\": \"cuckooent\",\r\n \"avatar_url\": \"https://foruda.gitee.com/avatar/1677043949039184563/5267986_cuckooent_1646218684.png\",\r\n \"site_admin\": false\r\n },\r\n \"git_url\": \"git://gitee.com/cuckooent/pms.git\",\r\n \"license\": null,\r\n \"private\": true,\r\n \"ssh_url\": \"git@gitee.com:cuckooent/pms.git\",\r\n \"svn_url\": \"svn://gitee.com/cuckooent/pms\",\r\n \"has_wiki\": true,\r\n \"homepage\": null,\r\n \"html_url\": \"https://gitee.com/cuckooent/pms\",\r\n \"language\": \"C#\",\r\n \"clone_url\": \"https://gitee.com/cuckooent/pms.git\",\r\n \"full_name\": \"cuckooent/pms\",\r\n \"has_pages\": false,\r\n \"namespace\": \"cuckooent\",\r\n \"pushed_at\": \"2024-06-18T09:38:20+08:00\",\r\n \"created_at\": \"2024-02-29T22:11:29+08:00\",\r\n \"has_issues\": true,\r\n \"updated_at\": \"2024-06-18T09:38:20+08:00\",\r\n \"description\": \"新的PMS软件开发项目管理系统\",\r\n \"forks_count\": 0,\r\n \"git_ssh_url\": \"git@gitee.com:cuckooent/pms.git\",\r\n \"git_svn_url\": \"svn://gitee.com/cuckooent/pms\",\r\n \"git_http_url\": \"https://gitee.com/cuckooent/pms.git\",\r\n \"default_branch\": \"master\",\r\n \"watchers_count\": 3,\r\n \"stargazers_count\": 0,\r\n \"open_issues_count\": 0,\r\n \"name_with_namespace\": \"超哥/PMS\",\r\n \"path_with_namespace\": \"cuckooent/pms\"\r\n },\r\n \"user_id\": 13097545,\r\n \"hook_url\": \"https://gitee.com/cuckooent/pms/hooks/1400568/edit\",\r\n \"password\": \"6158891\",\r\n \"hook_name\": \"push_hooks\",\r\n \"push_data\": null,\r\n \"timestamp\": \"1718674701049\",\r\n \"user_name\": \"tyfeikele\",\r\n \"enterprise\": null,\r\n \"repository\": {\r\n \"id\": 33487312,\r\n \"url\": \"https://gitee.com/cuckooent/pms\",\r\n \"fork\": false,\r\n \"name\": \"PMS\",\r\n \"path\": \"pms\",\r\n \"owner\": {\r\n \"id\": 5267986,\r\n \"url\": \"https://gitee.com/cuckooent\",\r\n \"name\": \"超哥\",\r\n \"type\": \"User\",\r\n \"email\": \"phoben@qq.com\",\r\n \"login\": \"cuckooent\",\r\n \"remark\": null,\r\n \"html_url\": \"https://gitee.com/cuckooent\",\r\n \"username\": \"cuckooent\",\r\n \"user_name\": \"cuckooent\",\r\n \"avatar_url\": \"https://foruda.gitee.com/avatar/1677043949039184563/5267986_cuckooent_1646218684.png\",\r\n \"site_admin\": false\r\n },\r\n \"git_url\": \"git://gitee.com/cuckooent/pms.git\",\r\n \"license\": null,\r\n \"private\": true,\r\n \"ssh_url\": \"git@gitee.com:cuckooent/pms.git\",\r\n \"svn_url\": \"svn://gitee.com/cuckooent/pms\",\r\n \"has_wiki\": true,\r\n \"homepage\": null,\r\n \"html_url\": \"https://gitee.com/cuckooent/pms\",\r\n \"language\": \"C#\",\r\n \"clone_url\": \"https://gitee.com/cuckooent/pms.git\",\r\n \"full_name\": \"cuckooent/pms\",\r\n \"has_pages\": false,\r\n \"namespace\": \"cuckooent\",\r\n \"pushed_at\": \"2024-06-18T09:38:20+08:00\",\r\n \"created_at\": \"2024-02-29T22:11:29+08:00\",\r\n \"has_issues\": true,\r\n \"updated_at\": \"2024-06-18T09:38:20+08:00\",\r\n \"description\": \"新的PMS软件开发项目管理系统\",\r\n \"forks_count\": 0,\r\n \"git_ssh_url\": \"git@gitee.com:cuckooent/pms.git\",\r\n \"git_svn_url\": \"svn://gitee.com/cuckooent/pms\",\r\n \"git_http_url\": \"https://gitee.com/cuckooent/pms.git\",\r\n \"default_branch\": \"master\",\r\n \"watchers_count\": 3,\r\n \"stargazers_count\": 0,\r\n \"open_issues_count\": 0,\r\n \"name_with_namespace\": \"超哥/PMS\",\r\n \"path_with_namespace\": \"cuckooent/pms\"\r\n },\r\n \"user_email\": \"tyfeikele@qq.com\",\r\n \"head_commit\": {\r\n \"id\": \"e74df3005e06241146220c1c78b746b1cb903e9d\",\r\n \"url\": \"https://gitee.com/cuckooent/pms/commit/e74df3005e06241146220c1c78b746b1cb903e9d\",\r\n \"added\": [\r\n \r\n ],\r\n \"author\": {\r\n \"id\": null,\r\n \"url\": null,\r\n \"name\": \"HZG System\",\r\n \"time\": \"2024-06-18T09:38:19+08:00\",\r\n \"user\": null,\r\n \"email\": \"HZG System\",\r\n \"remark\": null,\r\n \"username\": null,\r\n \"user_name\": null\r\n },\r\n \"message\": \"{\\\"Message\\\":\\\"签出模块 : 后端新增项目反馈, 匿名提交项目反馈\\\",\\\"MessageType\\\":1,\\\"Modules\\\":[],\\\"Version\\\":\\\"v1\\\"}\\n\",\r\n \"removed\": [\r\n \r\n ],\r\n \"tree_id\": \"57f89455bbd615902d2a41732205a659beec7dc4\",\r\n \"distinct\": true,\r\n \"modified\": [\r\n \".collaboration\"\r\n ],\r\n \"committer\": {\r\n \"id\": null,\r\n \"url\": null,\r\n \"name\": \"HZG System\",\r\n \"time\": null,\r\n \"user\": null,\r\n \"email\": \"HZG System\",\r\n \"remark\": null,\r\n \"username\": null,\r\n \"user_name\": null\r\n },\r\n \"timestamp\": \"2024-06-18T09:38:19+08:00\",\r\n \"parent_ids\": [\r\n \"bce508cc4c7574d8974a6e94a832c639ad07af99\"\r\n ]\r\n },\r\n \"total_commits_count\": 1,\r\n \"commits_more_than_ten\": false\r\n }", "SourceJson": { "$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon", "SerializeProperty": "=请求信息.Body" }, "ResultTo": "钩子数据" }, { "$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": "=钩子数据.hook_name" } }, "value": "push_hooks" }, "CommandList": [ { "$type": "Forguncy.Model.CatchExceptionCommand, ServerDesignerCommon", "TryCommandPart": { "CommandList": [ { "$type": "JsonUtilityCommand.JsonDeserializeCommand, JsonUtilityCommand", "JsonString": { "$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon", "SerializeProperty": "=钩子数据.head_commit.message" }, "SampleJson": "{\r\n \"Message\": \"新增WebHook的订阅\",\r\n \"MessageType\": 2,\r\n \"Modules\": [\r\n {\r\n \"State\": 3,\r\n \"Type\": 15,\r\n \"Name\": \"ServerCommand/创建一个仓库WebHook\"\r\n }\r\n ],\r\n \"Version\": \"v1\"\r\n}", "ToParameter": "message" }, { "$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": "=message.MessageType" } }, "value": "2" }, "CommandList": [ { "$type": "CollectionOperationKit.ServerSideArrayOp, CollectionOperationKit", "Operation": 17, "OperationParamaterAName": { "$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon", "SerializeProperty": "=钩子数据.ref" }, "OperationParamaterBName": "/", "OutParamaterName": "ref" }, { "$type": "GETPOST.正则类.正则_校验, GETPOST", "JieShouMsg": { "$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon", "SerializeProperty": "=message.Message" }, "JieShouMsg2": "^(.{0,3}|[^\\u4e00-\\u9fa5]*)$", "FanHuiMsg": "内容有效性" }, { "$type": "Forguncy.Model.Commands.SetParameterCommand, ServerDesignerCommon", "ParameterName": "内容得分", "ParameterValue": { "$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon", "SerializeProperty": "=IF(内容有效性,-1,IF(LEN(message.Message)<4,0,LEN(message.Message)))" }, "ID": "613428f86fac4f55adaeea6a94291b96" }, { "$type": "Forguncy.Model.Commands.SetParameterCommand, ServerDesignerCommon", "ParameterName": "内容得分", "ParameterValue": { "$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon", "SerializeProperty": "=IF(内容得分>100,100,内容得分)" }, "ID": "2ad2df5fcbb54f149af83f3f427a79d4" }, { "$type": "Forguncy.Model.UpdateDataTableCommand, ServerDesignerCommon", "TableName": "Git_事件记录", "UpdateType": "add", "ShowConfirm": false, "UpdateBindingValues": [ { "BindingInfo": { "TableName": "Git_事件记录", "ColumnName": "事件名称", "GUID": "d175cffd-1593-44b1-94d7-996f36a53a26" }, "Value": "签入工程" }, { "BindingInfo": { "TableName": "Git_事件记录", "ColumnName": "hook_id", "GUID": "4fde34c9-8af1-42e9-9474-69950de17aa6" }, "Value": { "$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon", "SerializeProperty": "=钩子数据.hook_id" } }, { "BindingInfo": { "TableName": "Git_事件记录", "ColumnName": "事件内容", "GUID": "b6cb65ca-1c44-4977-b713-816f9415ee8c" }, "Value": { "$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon", "SerializeProperty": "=message.Message" } }, { "BindingInfo": { "TableName": "Git_事件记录", "ColumnName": "空间路径", "GUID": "32a4375c-29c6-4aa5-b0a2-082968cd92f3" }, "Value": { "$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon", "SerializeProperty": "=钩子数据.repository.namespace" } }, { "BindingInfo": { "TableName": "Git_事件记录", "ColumnName": "仓库名称", "GUID": "bab21397-8651-4e95-8fbd-f5a8c5113e82" }, "Value": { "$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon", "SerializeProperty": "=钩子数据.repository.name" } }, { "BindingInfo": { "TableName": "Git_事件记录", "ColumnName": "仓库路径", "GUID": "9a1d7fd4-1fed-4ecc-81a1-172a80068423" }, "Value": { "$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon", "SerializeProperty": "=钩子数据.repository.path" } }, { "BindingInfo": { "TableName": "Git_事件记录", "ColumnName": "url", "GUID": "8c3e6194-355d-4130-b1c5-c40af9504332" }, "Value": { "$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon", "SerializeProperty": "=钩子数据.head_commit.url" } }, { "BindingInfo": { "TableName": "Git_事件记录", "ColumnName": "提交人", "GUID": "dcf401d6-3247-4733-938d-1dd302903fc6" }, "Value": { "$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon", "SerializeProperty": "=钩子数据.pusher.name" } }, { "BindingInfo": { "TableName": "Git_事件记录", "ColumnName": "git用户名", "GUID": "772df5bf-0766-47d8-99f0-0d938d94e687" }, "Value": { "$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon", "SerializeProperty": "=钩子数据.pusher.username" } }, { "BindingInfo": { "TableName": "Git_事件记录", "ColumnName": "仓库ID", "GUID": "4f5a4c02-fd88-42f5-85c9-b6cdd966b214" }, "Value": { "$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon", "SerializeProperty": "=钩子数据.repository.id" } }, { "BindingInfo": { "TableName": "Git_事件记录", "ColumnName": "日期", "GUID": "9ce6c120-a5c6-4f9a-a73c-3b50189eab84" }, "Value": { "$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon", "SerializeProperty": "=钩子数据.head_commit.timestamp" } }, { "BindingInfo": { "TableName": "Git_事件记录", "ColumnName": "内容得分", "GUID": "82e94bff-8b76-4af7-bfef-b829363f96f4" }, "Value": { "$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon", "SerializeProperty": "=内容得分" } }, { "BindingInfo": { "TableName": "Git_事件记录", "ColumnName": "sha", "GUID": "5b3b4e79-66a0-4440-aa47-ca9c646f131d" }, "Value": { "$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon", "SerializeProperty": "=钩子数据.after" } }, { "BindingInfo": { "TableName": "Git_事件记录", "ColumnName": "分支", "GUID": "93935bb9-959b-45a0-af58-5b53e844636f" }, "Value": { "$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon", "SerializeProperty": "=ref.2" } } ] }, { "$type": "Forguncy.Model.Commands.SetParameterCommand, ServerDesignerCommon", "ParameterName": "用户", "TableValue": { "TableName": "用户信息视图", "TableValueType": 1, "BindingInfos": [ { "GUID": "85ebcff8-97d6-41c0-85e8-fffcef940c40", "BindingInfo": { "TableName": "用户信息视图", "ColumnName": "用户名", "GUID": "664ac1a2-90a4-4c4b-bf52-4b363e8b2e56" }, "ColumnName": "用户名" } ], "SqlCondition": { "$type": "ForguncyDataAccess.GeneralCESqlCondition, ForguncyDataAccess", "ColumnBindingInfo": { "TableName": "用户信息视图", "ColumnName": "GIT用户名", "GUID": "198d8a88-c702-41b2-bcd9-c520f2198faf" }, "Value": { "$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon", "SerializeProperty": "=钩子数据.pusher.username" } }, "NullFormulaValueQueryPolicy": 0, "TopCount": "1" }, "ID": "3bce84654ac34772b4c9c89f1d9f5f45" }, { "$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.UpdateDataTableCommand, ServerDesignerCommon", "TableName": "积分记录表", "UpdateType": "add", "ShowConfirm": false, "UpdateBindingValues": [ { "BindingInfo": { "TableName": "积分记录表", "ColumnName": "用户", "GUID": "a66c9c34-e22b-4dee-90cd-d7a287f31e70" }, "Value": { "$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon", "SerializeProperty": "=用户.用户名" } }, { "BindingInfo": { "TableName": "积分记录表", "ColumnName": "类型", "GUID": "d15df832-bbac-4306-b211-bf4233d92ebc" }, "Value": "GitPush" }, { "BindingInfo": { "TableName": "积分记录表", "ColumnName": "分数", "GUID": "2d42ca3e-4b2c-4162-9551-55aff67fe13e" }, "Value": { "$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon", "SerializeProperty": "=内容得分" } }, { "BindingInfo": { "TableName": "积分记录表", "ColumnName": "变动日期", "GUID": "ae60b68b-e01e-43cc-b911-315f71d61185" }, "Value": { "$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon", "SerializeProperty": "=NOW()" } }, { "BindingInfo": { "TableName": "积分记录表", "ColumnName": "备注", "GUID": "05624087-0575-475f-a08d-84d7966645b0" }, "Value": { "$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon", "SerializeProperty": "=\"用户对Git仓库[\"&钩子数据.repository.name&\"]的签入,被系统自动评分\"" } } ] } ], "ID": "7c0ba71f-3010-447b-89fe-d1b1ccf27e0c" } ] }, { "$type": "Forguncy.Model.ReturnCommand, ServerDesignerCommon", "ErrorCode": "0", "Message": "签入已被记录" } ], "ID": "1c211a9f-b7b2-435f-8e6d-64c1e9a2346c" } ] } ] } } ], "ID": "a6f6cb54-5225-4a1e-ac4e-6f53ba014f4a" } ] } ] }