From cacf363f222e354cad6db18c4a00fb1097d35c2c Mon Sep 17 00:00:00 2001 From: zhangqian <zhangqian@123.com> Date: 星期四, 09 十一月 2023 14:30:58 +0800 Subject: [PATCH] fix --- docs/docs.go | 219 ++++++++++++++++++++++++++++++++++++++++++++++++++---- 1 files changed, 201 insertions(+), 18 deletions(-) diff --git a/docs/docs.go b/docs/docs.go index 0961c49..35c052f 100644 --- a/docs/docs.go +++ b/docs/docs.go @@ -152,13 +152,43 @@ } } }, + "/v1/device/config": { + "post": { + "produces": [ + "application/json" + ], + "tags": [ + "璁惧" + ], + "summary": "璁剧疆璁惧涓�浜涢厤缃�", + "parameters": [ + { + "description": "鏌ヨ鍙傛暟", + "name": "object", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/request.DeviceConfig" + } + } + ], + "responses": { + "200": { + "description": "鎴愬姛", + "schema": { + "$ref": "#/definitions/contextx.Response" + } + } + } + } + }, "/v1/device/list": { "get": { "produces": [ "application/json" ], "tags": [ - "Device" + "璁惧" ], "summary": "鑾峰彇褰撳墠闈㈡澘缁戝畾鐨勮澶囧垪琛�", "responses": { @@ -229,7 +259,7 @@ "in": "body", "required": true, "schema": { - "$ref": "#/definitions/request.SendProcessParams" + "$ref": "#/definitions/request.GetProductProgress" } } ], @@ -407,13 +437,6 @@ "summary": "鑾峰彇宸ヨ壓妯″瀷鍒楄〃", "parameters": [ { - "type": "string", - "description": "褰撳墠姝e湪浣跨敤鐨勫伐鑹哄弬鏁扮紪鍙�", - "name": "number", - "in": "query", - "required": true - }, - { "type": "integer", "description": "椤电爜", "name": "page", @@ -448,6 +471,40 @@ "type": "array", "items": { "$ref": "#/definitions/model.ProcessModel" + } + } + } + } + ] + } + } + } + } + }, + "/v1/system/problemList": { + "get": { + "produces": [ + "application/json" + ], + "tags": [ + "绯荤粺" + ], + "summary": "闂璇婃柇/闂鍒楄〃", + "responses": { + "200": { + "description": "鎴愬姛", + "schema": { + "allOf": [ + { + "$ref": "#/definitions/contextx.Response" + }, + { + "type": "object", + "properties": { + "data": { + "type": "array", + "items": { + "$ref": "#/definitions/problem.CheckResult" } } } @@ -527,11 +584,6 @@ ], "summary": "鑾峰彇浠诲姟", "parameters": [ - { - "type": "string", - "name": "deviceID", - "in": "query" - }, { "type": "integer", "description": "椤电爜", @@ -926,11 +978,55 @@ "type": "string", "enum": [ "string", - "int" + "int16", + "int32" ], "x-enum-varnames": [ "PlcStartAddressValueTypeString", - "PlcStartAddressValueTypeInt" + "PlcStartAddressValueTypeInt16", + "PlcStartAddressValueTypeInt32" + ] + }, + "constvar.ProblemCode": { + "type": "string", + "enum": [ + "service", + "network", + "db", + "serf", + "cloud", + "device", + "process_model", + "plc_config", + "plc_address_list", + "plc_process_model_address_list", + "plc_connect" + ], + "x-enum-comments": { + "ProblemCodeCloud": "鏈繛鎺ヤ簯绔�", + "ProblemCodeDB": "鏁版嵁搴撹繛鎺ラ敊璇�", + "ProblemCodeDevice": "鏈粦瀹氳澶�", + "ProblemCodeNetwork": "缃戠粶閿欒", + "ProblemCodePlcAddressList": "plc鍦板潃琛ㄧ己澶�", + "ProblemCodePlcConfig": "plc閰嶇疆缂哄け", + "ProblemCodePlcConnect": "plc杩炴帴澶辫触", + "ProblemCodePlcProcessModelAddressList": "plc鍦板潃琛ㄧ己澶�", + "ProblemCodeProcessModel": "宸ヨ壓鍙傛暟缂哄け", + "ProblemCodeSerf": "鏈姞鍏erf闆嗙兢", + "ProblemCodeService": "鏈嶅姟涓嶅彲鐢�" + }, + "x-enum-varnames": [ + "ProblemCodeService", + "ProblemCodeNetwork", + "ProblemCodeDB", + "ProblemCodeSerf", + "ProblemCodeCloud", + "ProblemCodeDevice", + "ProblemCodeProcessModel", + "ProblemCodePlcConfig", + "ProblemCodePlcAddressList", + "ProblemCodePlcProcessModelAddressList", + "ProblemCodePlcConnect" ] }, "constvar.TaskMode": { @@ -1338,6 +1434,20 @@ } } }, + "problem.CheckResult": { + "type": "object", + "properties": { + "checkResult": { + "type": "boolean" + }, + "itemCode": { + "$ref": "#/definitions/constvar.ProblemCode" + }, + "itemName": { + "type": "string" + } + } + }, "request.AddPlcBrand": { "type": "object", "properties": { @@ -1355,6 +1465,23 @@ }, "updatedAt": { "type": "string" + } + } + }, + "request.DeviceConfig": { + "type": "object", + "properties": { + "needSetProcessParams": { + "description": "鏄惁闇�瑕佽缃伐鑹哄弬鏁�", + "type": "boolean" + } + } + }, + "request.GetProductProgress": { + "type": "object", + "properties": { + "channel": { + "type": "integer" } } }, @@ -1479,23 +1606,58 @@ } } }, + "response.Device": { + "type": "object", + "properties": { + "deviceID": { + "type": "string" + }, + "deviceName": { + "type": "string" + }, + "needSetProcessParams": { + "description": "鏄惁闇�瑕佽缃伐鑹哄弬鏁�", + "type": "boolean" + } + } + }, "response.DeviceListResponse": { "type": "object", "properties": { + "clusterNodeQuantity": { + "description": "闆嗙兢鑺傜偣鏁伴噺", + "type": "integer" + }, + "clusterStatus": { + "description": "闆嗙兢鐘舵��", + "type": "string" + }, "currentDeviceID": { "description": "褰撳墠閫夊畾鐨勭敓浜ц澶�", "type": "string" }, - "deviceIDList": { + "deviceList": { "description": "鐢熶骇璁惧id鍒楄〃", "type": "array", "items": { - "type": "string" + "$ref": "#/definitions/response.Device" } }, "systemDeviceID": { "description": "宸ユ帶鏈鸿澶嘔D", "type": "string" + }, + "systemDeviceRunSince": { + "description": "绯荤粺杩愯寮�濮嬫椂闂存埑", + "type": "integer" + }, + "systemDeviceStatus": { + "description": "璁惧鐘舵��", + "allOf": [ + { + "$ref": "#/definitions/response.SystemDeviceStatus" + } + ] } } }, @@ -1540,6 +1702,12 @@ "response.ProductProgress": { "type": "object", "properties": { + "RealEndTime": { + "type": "integer" + }, + "RealStartTime": { + "type": "integer" + }, "finishNumber": { "type": "integer" }, @@ -1551,6 +1719,21 @@ } } }, + "response.SystemDeviceStatus": { + "type": "integer", + "enum": [ + 1, + 2 + ], + "x-enum-comments": { + "SystemDeviceStatusNormal": "姝e父", + "SystemDeviceStatusUnNormal": "寮傚父" + }, + "x-enum-varnames": [ + "SystemDeviceStatusNormal", + "SystemDeviceStatusUnNormal" + ] + }, "response.TaskCountdown": { "type": "object", "properties": { -- Gitblit v1.8.0