Files
clue/ServerCommands/Gitee/同步一个仓库到表.json

542 lines
21 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
}
},
{
"Name": "空间路径名",
"DataValidationInfo": {}
},
{
"Name": "空间名称",
"DataValidationInfo": {}
},
{
"Name": "仓库路径名",
"DataValidationInfo": {}
},
{
"Name": "仓库名称",
"DataValidationInfo": {}
},
{
"Name": "仓库地址",
"DataValidationInfo": {}
},
{
"Name": "仓库描述",
"DataValidationInfo": {}
},
{
"Name": "仓库成员",
"DataValidationInfo": {}
},
{
"Name": "创建人",
"DataValidationInfo": {}
},
{
"Name": "创建人头像",
"DataValidationInfo": {}
},
{
"Name": "api_url",
"DataValidationInfo": {}
}
]
}
],
"Commands": [
{
"$type": "JsonUtilityCommand.JsonDeserializeCommand, JsonUtilityCommand",
"JsonString": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=全局_Gitee"
},
"SampleJson": "{\"client_id\":\"c7d05fcbaf78ad728fcc0267d081ae6c50dc667667758a0933525d4cbe09ed90\",\"client_secret\":\"b4d40db2155ca530e5771b37a2fb67161d4106c64df28f32504b4e3bcfb81313\",\"回调地址\":\"https://develop.gridfriend.cn/pms/ServerCommand/GitCallback\"}",
"ToParameter": "Gitee配置"
},
{
"$type": "Forguncy.Model.Commands.SetParameterCommand, ServerDesignerCommon",
"ParameterName": "当前用户",
"ParameterValue": "%CurrentUser%",
"ID": "54d3c5b327f8449babca7b5f296cea3a"
},
{
"$type": "Forguncy.Model.Commands.SetParameterCommand, ServerDesignerCommon",
"ParameterName": "查找仓库",
"TableValue": {
"TableName": "Git仓库表",
"TableValueType": 1,
"BindingInfos": [
{
"GUID": "0e7da4a8-d338-4585-b6f4-6ae272aea45f",
"BindingInfo": {
"TableName": "Git仓库表",
"ColumnName": "订阅成功",
"GUID": "917e816f-695c-4b75-af4d-bb404ea81fb2"
},
"ColumnName": "绑定成功"
}
],
"SqlCondition": {
"$type": "ForguncyDataAccess.GeneralCESqlCondition, ForguncyDataAccess",
"ColumnBindingInfo": {
"TableName": "Git仓库表",
"ColumnName": "仓库ID",
"GUID": "cb3e1ea6-5719-447f-9e75-84923cffaf89"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=仓库ID"
}
},
"NullFormulaValueQueryPolicy": 0,
"TopCount": "1"
},
"ID": "20e643f89e194c438087b618ea1c338d"
},
{
"$type": "Forguncy.Model.ServerTransactionCommand, ServerDesignerCommon",
"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": "%Null%"
},
"CommandList": [
{
"$type": "Forguncy.Model.UpdateDataTableCommand, ServerDesignerCommon",
"TableName": "Git仓库表",
"UpdateType": "add",
"ShowConfirm": false,
"UpdateBindingValues": [
{
"BindingInfo": {
"TableName": "Git仓库表",
"ColumnName": "仓库ID",
"GUID": "f278f2b3-b446-4dae-8aef-0201ead82b16"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=仓库ID"
}
},
{
"BindingInfo": {
"TableName": "Git仓库表",
"ColumnName": "空间路径名",
"GUID": "8ad70fdd-f628-4030-9a80-bc9b2e911329"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=空间路径名"
}
},
{
"BindingInfo": {
"TableName": "Git仓库表",
"ColumnName": "空间名称",
"GUID": "d2d34e3b-f666-4a7e-ad09-1d9a1fd0f6a8"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=空间名称"
}
},
{
"BindingInfo": {
"TableName": "Git仓库表",
"ColumnName": "仓库路径名",
"GUID": "4bf7ed6b-2f33-492d-94ea-ac19ab5dc207"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=仓库路径名"
}
},
{
"BindingInfo": {
"TableName": "Git仓库表",
"ColumnName": "仓库名称",
"GUID": "8c5a8472-cbd9-4a38-afae-1d6ef8da5d55"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=仓库名称"
}
},
{
"BindingInfo": {
"TableName": "Git仓库表",
"ColumnName": "仓库地址",
"GUID": "e4a356de-ea3d-4a10-8161-60c670b4dcea"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=仓库地址"
}
},
{
"BindingInfo": {
"TableName": "Git仓库表",
"ColumnName": "仓库描述",
"GUID": "77c1c3f2-00b3-4835-b033-053fc6b582f5"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=仓库描述"
}
},
{
"BindingInfo": {
"TableName": "Git仓库表",
"ColumnName": "仓库成员",
"GUID": "929f6163-3e04-4ba3-a7d8-37edea5eaf44"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=仓库成员"
}
},
{
"BindingInfo": {
"TableName": "Git仓库表",
"ColumnName": "创建人",
"GUID": "cfd7fd47-c234-452a-9db4-23be15c5044c"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=创建人"
}
},
{
"BindingInfo": {
"TableName": "Git仓库表",
"ColumnName": "创建人头像",
"GUID": "8e758f6d-51fb-48ce-bd4c-210c3fe6f7e6"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=创建人头像"
}
},
{
"BindingInfo": {
"TableName": "Git仓库表",
"ColumnName": "Callback_url",
"GUID": "bbe9ea3b-e2a0-4f87-a2ca-70e7e12c1969"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=Gitee配置.回调地址"
}
},
{
"BindingInfo": {
"TableName": "Git仓库表",
"ColumnName": "hook_api_url",
"GUID": "82935348-3056-4b67-9e5b-c42913b609d8"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=api_url"
}
},
{
"BindingInfo": {
"TableName": "Git仓库表",
"ColumnName": "订阅成功",
"GUID": "202213a3-5f8f-41ac-a09b-8092bec46042"
},
"Value": "0"
}
]
}
],
"ID": "e1c14211-bea3-40a2-8209-c05ac6641717"
},
{
"CommandList": [
{
"$type": "Forguncy.Model.UpdateDataTableCommand, ServerDesignerCommon",
"TableName": "Git仓库表",
"ShowConfirm": false,
"RowsToUpdate": 1,
"RowsToUpdateCondition": {
"$type": "ForguncyDataAccess.GeneralCESqlCondition, ForguncyDataAccess",
"ColumnBindingInfo": {
"TableName": "Git仓库表",
"ColumnName": "仓库ID",
"GUID": "0cb22c5e-6428-421d-b601-e71f8fe673bd"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=仓库ID"
}
},
"UpdateBindingValues": [
{
"BindingInfo": {
"TableName": "Git仓库表",
"ColumnName": "空间路径名",
"GUID": "852038c2-f6f6-4b56-9ba7-d305743e8aaa"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=空间路径名"
}
},
{
"BindingInfo": {
"TableName": "Git仓库表",
"ColumnName": "空间名称",
"GUID": "32994d59-895e-4a91-84b5-11004ba09778"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=空间名称"
}
},
{
"BindingInfo": {
"TableName": "Git仓库表",
"ColumnName": "仓库路径名",
"GUID": "aeb5e23f-ba60-4482-96c0-6776d18d1bb5"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=仓库路径名"
}
},
{
"BindingInfo": {
"TableName": "Git仓库表",
"ColumnName": "仓库名称",
"GUID": "2fa19715-8877-47d7-9960-05d233f18f9c"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=仓库名称"
}
},
{
"BindingInfo": {
"TableName": "Git仓库表",
"ColumnName": "仓库地址",
"GUID": "08d3b064-5361-4f0c-911e-d8fa7fe2ef8d"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=仓库地址"
}
},
{
"BindingInfo": {
"TableName": "Git仓库表",
"ColumnName": "仓库描述",
"GUID": "bbeba002-5222-40f2-8497-09101ba4e5d8"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=仓库描述"
}
},
{
"BindingInfo": {
"TableName": "Git仓库表",
"ColumnName": "仓库成员",
"GUID": "6866c39a-6ce2-4eea-809b-7498fb3f8b56"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=仓库成员"
}
},
{
"BindingInfo": {
"TableName": "Git仓库表",
"ColumnName": "创建人",
"GUID": "4ae75e1b-a21e-465d-ab2b-e0678f8fe835"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=创建人"
}
},
{
"BindingInfo": {
"TableName": "Git仓库表",
"ColumnName": "创建人头像",
"GUID": "59760498-30b8-4d54-a0cf-b4b8095bfb79"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=创建人头像"
}
},
{
"BindingInfo": {
"TableName": "Git仓库表",
"ColumnName": "hook_api_url",
"GUID": "17d7407b-7b1e-42c1-91df-db0dfaa22717"
},
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=api_url"
}
}
]
}
],
"ID": "51e42604-f5c1-4cf3-949e-0b42df31b38d"
}
]
}
]
},
{
"$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": "=Gitee配置.回调地址"
}
},
"value": "%Null%",
"compareType": 1
},
"CommandList": [
{
"$type": "Forguncy.Model.RequestServerCommand, ServerDesignerCommon",
"ServerCommandName": "创建一个仓库WebHook",
"Parameters": [
{
"$type": "Forguncy.Model.RequestServerCommandObjectParam, ServerDesignerCommon",
"ParamName": "仓库ID",
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=仓库ID"
}
},
{
"$type": "Forguncy.Model.RequestServerCommandObjectParam, ServerDesignerCommon",
"ParamName": "用户名",
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=当前用户"
}
},
{
"$type": "Forguncy.Model.RequestServerCommandObjectParam, ServerDesignerCommon",
"ParamName": "回调地址",
"Value": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=Gitee配置.回调地址"
}
}
],
"ResultErrorCodeTo": {
"SerializeProperty": "code"
},
"ResultMessageTo": {
"SerializeProperty": "msg"
},
"RefreshAfterFinish": true,
"CheckDataValidation": true
},
{
"$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": "=code"
}
},
"value": "0"
},
"CommandList": [
{
"$type": "Forguncy.Model.ReturnCommand, ServerDesignerCommon",
"ErrorCode": "0",
"Message": "仓库创建并订阅成功!"
}
],
"ID": "b1a21ca4-fcba-4dd3-8b59-04b34652ed03"
},
{
"CommandList": [
{
"$type": "Forguncy.Model.ReturnCommand, ServerDesignerCommon",
"ErrorCode": "0",
"Message": {
"$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon",
"SerializeProperty": "=\"仓库创建成功,但未能订阅:\"&msg"
}
}
],
"ID": "cb1079c2-3bc9-41fd-9ec1-b68eb25ec4aa"
}
]
}
],
"ID": "b2af65ed-7f3e-4128-8ae9-113cba32e899"
},
{
"CommandList": [
{
"$type": "Forguncy.Model.ReturnCommand, ServerDesignerCommon",
"ErrorCode": "0",
"Message": "仓库创建成功!"
}
],
"ID": "bb33de37-3a08-4b5e-af09-01bd14a2b97d"
}
]
}
]
}