{ "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": "用户名", "DataValidationInfo": { "IgnoreBlank": false }, "TestData": "Administrator" }, { "Name": "仓库ID", "DataValidationInfo": { "IgnoreBlank": false }, "TestData": "33487312" } ], "InvokeTriggerTestData": { "UserName": "Administrator" } } ], "Commands": [ { "$type": "Forguncy.Model.Commands.SetParameterCommand, ServerDesignerCommon", "ParameterName": "当前用户", "TableValue": { "TableName": "用户信息视图", "TableValueType": 1, "BindingInfos": [ { "GUID": "63aa6b40-aefd-41c2-91ff-ffdbe5ca9065", "BindingInfo": { "TableName": "用户信息视图", "ColumnName": "GIT用户名", "GUID": "662b2f45-2280-460c-8779-47a746e6319e" }, "ColumnName": "GIT用户名" }, { "GUID": "fef0405d-1cf9-43ea-ba28-ed59a8b1688a", "BindingInfo": { "TableName": "用户信息视图", "ColumnName": "GIT密码", "GUID": "339ee5aa-23f4-47b8-96ff-d0e5c766e1a1" }, "ColumnName": "GIT密码" } ], "SqlCondition": { "$type": "ForguncyDataAccess.GeneralCESqlCondition, ForguncyDataAccess", "ColumnBindingInfo": { "TableName": "用户信息视图", "ColumnName": "用户名", "GUID": "d2703b93-a7e5-4967-abd0-75f2906e28d4" }, "Value": { "$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon", "SerializeProperty": "=用户名" } }, "NullFormulaValueQueryPolicy": 0, "TopCount": "1" }, "ID": "d86d5faca9b240dab3c1709b42211323" }, { "$type": "Forguncy.Model.RequestServerCommand, ServerDesignerCommon", "ServerCommandName": "请求令牌", "Parameters": [ { "$type": "Forguncy.Model.RequestServerCommandObjectParam, ServerDesignerCommon", "ParamName": "用户名", "Value": { "$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon", "SerializeProperty": "=用户名" } }, { "$type": "Forguncy.Model.RequestServerCommandObjectParam, ServerDesignerCommon", "ParamName": "强制刷新", "Value": "0" } ], "ResultErrorCodeTo": { "SerializeProperty": "code" }, "ResultMessageTo": { "SerializeProperty": "msg" }, "ReturnPropertiesTo": [ { "ResultPropertyName": "最新令牌", "ResultTo": { "SerializeProperty": "TOKEN" } } ], "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.Commands.SetParameterCommand, ServerDesignerCommon", "ParameterName": "仓库", "TableValue": { "TableName": "Git仓库表", "TableValueType": 1, "BindingInfos": [ { "GUID": "60acd7bb-f3ce-4aaf-8cf6-29c4e06adc31", "BindingInfo": { "TableName": "Git仓库表", "ColumnName": "空间路径名", "GUID": "6263c854-542e-4df0-a3ea-6ea5c9fb9100" }, "ColumnName": "空间路径名" }, { "GUID": "47ede713-1c30-4c70-878e-6cc82f79b222", "BindingInfo": { "TableName": "Git仓库表", "ColumnName": "仓库路径名", "GUID": "fe8b4447-00d9-4f7f-94f9-1bbcc801da38" }, "ColumnName": "仓库路径名" } ], "SqlCondition": { "$type": "ForguncyDataAccess.GeneralCESqlCondition, ForguncyDataAccess", "ColumnBindingInfo": { "TableName": "Git仓库表", "ColumnName": "仓库ID", "GUID": "f68e8430-3956-4143-9408-0e92899d4516" }, "Value": { "$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon", "SerializeProperty": "=仓库ID" } }, "TopCount": "1" }, "ID": "61efaba6b39a44c3a33a0d251eb70ae6" }, { "$type": "Forguncy.Model.Commands.SetParameterCommand, ServerDesignerCommon", "ParameterName": "url", "ParameterValue": { "$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon", "SerializeProperty": "=\"https://gitee.com/api/v5/repos/\"&仓库.空间路径名&\"/\"&仓库.仓库路径名&\"/branches\"" }, "ID": "0a8b384cb5ed47bebbcfabf787647380" }, { "$type": "Forguncy.Model.CatchExceptionCommand, ServerDesignerCommon", "TryCommandPart": { "CommandList": [ { "$type": "CollectionOperationKit.ServerSideArrayOp, CollectionOperationKit", "OutParamaterName": "分支列表" }, { "$type": "PostDataToWebApi.PostDataCommand, PostDataToWebApi", "PostData": { "DataItemType": 1, "Data": { "$type": "PostDataToWebApi.ObjectData, PostDataToWebApi", "Data": [ { "Name": "access_token", "DataItemType": 0, "Data": { "$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon", "SerializeProperty": "=TOKEN" } }, { "Name": "sort", "DataItemType": 0, "Data": "updated" }, { "Name": "direction", "DataItemType": 0, "Data": "desc" }, { "Name": "page", "DataItemType": 0, "Data": 1 }, { "Name": "per_page", "DataItemType": 0, "Data": 100 } ] } }, "JsonString": "", "WebUrl": { "$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon", "SerializeProperty": "=url" }, "Method": "GET", "SuccessCallback": "// 请求成功返回的数据存储在“result”变量中\r\n// 请使用“result”变量来完成请求成功的回调 \r\n//console.log(result);", "ErrorCallback": "// 请求中发生的错误存储在“error”变量中\r\n// 请使用“error”变量来处理异常情况 \r\nconsole.error(error);", "NewParameter": "result", "Header": [], "Timeout": 100.0 }, { "$type": "Forguncy.Model.LoopCommand, ServerDesignerCommon", "LoopInfo": { "$type": "Forguncy.Model.CountLoopInfo, ServerDesignerCommon", "LoopCount": { "$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon", "SerializeProperty": "=result" }, "LoopItemParamName": "Item" }, "CommandList": [ { "$type": "CollectionOperationKit.ServerSideObjectOp, CollectionOperationKit", "OperationParamaterPairs": [ { "Name": "分支名称", "Value": { "$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon", "SerializeProperty": "=Item.name" } }, { "Name": "最后更新时间", "Value": { "$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon", "SerializeProperty": "=TEXT(Item.commit.commit.committer.date,\"yyyy-mm-dd hh:mm:ss\")" } }, { "Name": "最后更新人", "Value": { "$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon", "SerializeProperty": "=Item.commit.commit.committer.name" } } ], "OutParamaterName": "分支信息" }, { "$type": "CollectionOperationKit.ServerSideArrayOp, CollectionOperationKit", "InParamater": { "$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon", "SerializeProperty": "=分支列表" }, "Operation": 4, "OperationParamaterAName": { "$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon", "SerializeProperty": "=分支信息" }, "OutParamaterName": "分支列表" } ] }, { "$type": "Forguncy.Model.ReturnCommand, ServerDesignerCommon", "ErrorCode": "0", "Message": "获取成功", "CustomReturns": [ { "ReturnPropertyName": "分支列表", "Value": { "$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon", "SerializeProperty": "=分支列表" }, "Remark": "[\r\n{\"分支名称\":\"\",\"最后更新时间\":\"\",\"最后更新人\":\"\"}\r\n]" } ] } ] }, "CatchCommandPart": { "CommandList": [ { "$type": "Forguncy.Model.ReturnCommand, ServerDesignerCommon", "ErrorCode": "400", "Message": { "$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon", "SerializeProperty": "=result.message" }, "CustomReturns": [ { "ReturnPropertyName": "分支列表", "Remark": "[\r\n{\"分支名称\":\"\",\"最后更新时间\":\"\",\"最后更新人\":\"\"}\r\n]" } ] } ] } } ], "ID": "dc853222-924d-49d1-a1b5-42ec24712061" }, { "CommandList": [ { "$type": "Forguncy.Model.ReturnCommand, ServerDesignerCommon", "ErrorCode": { "$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon", "SerializeProperty": "=code" }, "Message": { "$type": "Forguncy.Model.FormulaReferObject, ServerDesignerCommon", "SerializeProperty": "=msg" }, "CustomReturns": [ { "ReturnPropertyName": "分支列表", "Remark": "[\r\n{\"分支名称\":\"\",\"最后更新时间\":\"\",\"最后更新人\":\"\"}\r\n]" } ] } ], "ID": "a2d5b142-9601-4f20-9d42-facbea586b03" } ] } ], "ReturnProperties": [ { "Name": "分支列表", "Remark": "[\r\n{\"分支名称\":\"\",\"最后更新时间\":\"\",\"最后更新人\":\"\"}\r\n]" } ] }