From 849b89cde3bf2ac26bdcf33e3940f9a1a00d1e85 Mon Sep 17 00:00:00 2001 From: zhangqian <zhangqian@123.com> Date: 星期四, 29 二月 2024 16:30:21 +0800 Subject: [PATCH] 纤度登记列表和删除接口 --- docs/docs.go | 339 +++++++++++++++++++++++++++++++++++++++++++------------ 1 files changed, 263 insertions(+), 76 deletions(-) diff --git a/docs/docs.go b/docs/docs.go index 491292f..c309a2a 100644 --- a/docs/docs.go +++ b/docs/docs.go @@ -16,15 +16,15 @@ "host": "{{.Host}}", "basePath": "{{.BasePath}}", "paths": { - "/api-s/v1/organize/department": { + "/api-jl/v1/fineness/register": { "get": { "produces": [ "application/json" ], "tags": [ - "閮ㄩ棬淇℃伅" + "绾ゅ害鐧昏" ], - "summary": "鏌ヨ閮ㄩ棬淇℃伅鍒楄〃", + "summary": "绾ゅ害鐧昏鍒楄〃", "parameters": [ { "type": "integer", @@ -53,7 +53,107 @@ "data": { "type": "array", "items": { - "$ref": "#/definitions/models.Department" + "$ref": "#/definitions/models.FinenessRegister" + } + } + } + } + ] + } + } + } + } + }, + "/api-jl/v1/fineness/register/{id}": { + "delete": { + "produces": [ + "application/json" + ], + "tags": [ + "绾ゅ害鐧昏" + ], + "summary": "绾ゅ害鐧昏鍒犻櫎", + "parameters": [ + { + "type": "string", + "description": "瀛楀吀淇℃伅", + "name": "id", + "in": "path", + "required": true + } + ], + "responses": { + "200": { + "description": "鎴愬姛", + "schema": { + "$ref": "#/definitions/util.Response" + } + } + } + } + }, + "/api-jl/v1/system/dict": { + "get": { + "produces": [ + "application/json" + ], + "tags": [ + "绯荤粺璁剧疆/瀛楀吀" + ], + "summary": "鏌ヨ瀛楀吀鍒楄〃", + "parameters": [ + { + "enum": [ + 0, + 1, + 2, + 3 + ], + "type": "integer", + "x-enum-comments": { + "DictTypeColor": "棰滆壊", + "DictTypeMarket": "搴勫彛", + "DictTypeSpec": "瑙勬牸", + "DictTypeWorkshop": "杞﹂棿" + }, + "x-enum-varnames": [ + "DictTypeMarket", + "DictTypeWorkshop", + "DictTypeColor", + "DictTypeSpec" + ], + "description": "瀛楀吀绫诲瀷", + "name": "dictType", + "in": "query" + }, + { + "type": "integer", + "description": "椤电爜", + "name": "page", + "in": "query" + }, + { + "type": "integer", + "description": "姣忛〉澶у皬", + "name": "pageSize", + "in": "query" + } + ], + "responses": { + "200": { + "description": "鎴愬姛", + "schema": { + "allOf": [ + { + "$ref": "#/definitions/util.ResponseList" + }, + { + "type": "object", + "properties": { + "data": { + "type": "array", + "items": { + "$ref": "#/definitions/models.Dict" } } } @@ -63,22 +163,50 @@ } } }, + "put": { + "produces": [ + "application/json" + ], + "tags": [ + "绯荤粺璁剧疆/瀛楀吀" + ], + "summary": "缂栬緫瀛楀吀", + "parameters": [ + { + "description": "瀛楀吀淇℃伅", + "name": "object", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/request.UpdateDict" + } + } + ], + "responses": { + "200": { + "description": "鎴愬姛", + "schema": { + "$ref": "#/definitions/util.Response" + } + } + } + }, "post": { "produces": [ "application/json" ], "tags": [ - "閮ㄩ棬淇℃伅" + "绯荤粺璁剧疆/瀛楀吀" ], - "summary": "娣诲姞閮ㄩ棬淇℃伅", + "summary": "娣诲姞瀛楀吀", "parameters": [ { - "description": "閮ㄩ棬淇℃伅淇℃伅", + "description": "瀛楀吀淇℃伅", "name": "object", "in": "body", "required": true, "schema": { - "$ref": "#/definitions/request.AddDepartment" + "$ref": "#/definitions/request.AddDict" } } ], @@ -92,52 +220,22 @@ } } }, - "/api-s/v1/organize/department/{id}": { - "put": { - "produces": [ - "application/json" - ], - "tags": [ - "閮ㄩ棬淇℃伅" - ], - "summary": "缂栬緫閮ㄩ棬淇℃伅", - "parameters": [ - { - "description": "閮ㄩ棬淇℃伅淇℃伅", - "name": "object", - "in": "body", - "required": true, - "schema": { - "$ref": "#/definitions/request.UpdateDepartment" - } - } - ], - "responses": { - "200": { - "description": "鎴愬姛", - "schema": { - "$ref": "#/definitions/util.Response" - } - } - } - }, + "/api-jl/v1/system/dict/{id}": { "delete": { "produces": [ "application/json" ], "tags": [ - "閮ㄩ棬淇℃伅" + "绯荤粺璁剧疆/瀛楀吀" ], - "summary": "缂栬緫閮ㄩ棬淇℃伅", + "summary": "鍒犻櫎瀛楀吀", "parameters": [ { - "description": "閮ㄩ棬淇℃伅淇℃伅", - "name": "object", - "in": "body", - "required": true, - "schema": { - "$ref": "#/definitions/request.UpdateDepartment" - } + "type": "string", + "description": "瀛楀吀淇℃伅", + "name": "id", + "in": "path", + "required": true } ], "responses": { @@ -152,58 +250,143 @@ } }, "definitions": { - "models.Department": { + "constvar.DictType": { + "type": "integer", + "enum": [ + 0, + 1, + 2, + 3 + ], + "x-enum-comments": { + "DictTypeColor": "棰滆壊", + "DictTypeMarket": "搴勫彛", + "DictTypeSpec": "瑙勬牸", + "DictTypeWorkshop": "杞﹂棿" + }, + "x-enum-varnames": [ + "DictTypeMarket", + "DictTypeWorkshop", + "DictTypeColor", + "DictTypeSpec" + ] + }, + "gorm.DeletedAt": { "type": "object", "properties": { - "children": { - "type": "array", - "items": { - "$ref": "#/definitions/models.Department" - } - }, - "head": { - "description": "閮ㄩ棬璐熻矗浜�", + "time": { "type": "string" + }, + "valid": { + "description": "Valid is true if Time is not NULL", + "type": "boolean" + } + } + }, + "models.Dict": { + "type": "object", + "properties": { + "createdAt": { + "type": "string" + }, + "deletedAt": { + "$ref": "#/definitions/gorm.DeletedAt" + }, + "dictType": { + "description": "瀛楀吀绫诲瀷", + "allOf": [ + { + "$ref": "#/definitions/constvar.DictType" + } + ] }, "id": { "type": "integer" }, "name": { - "description": "閮ㄩ棬鍚嶇О", + "description": "鍚嶇О", "type": "string" }, "number": { - "description": "閮ㄩ棬缂栧彿", + "description": "缂栧彿", "type": "string" - }, - "parentId": { - "description": "涓婄骇閮ㄩ棬ID", - "type": "integer" }, "remark": { "description": "澶囨敞", "type": "string" }, - "sort": { - "description": "鎺掑簭", - "type": "integer" + "updatedAt": { + "type": "string" } } }, - "request.AddDepartment": { + "models.FinenessRegister": { "type": "object", "properties": { + "createdAt": { + "type": "string" + }, + "deletedAt": { + "$ref": "#/definitions/gorm.DeletedAt" + }, + "endCircle": { + "description": "缁撴潫鍥炴暟", + "type": "integer" + }, + "finishDate": { + "description": "钀戒笣鏃堕棿", + "type": "string" + }, + "id": { + "type": "integer" + }, + "market": { + "description": "搴勫彛", + "type": "string" + }, "name": { - "description": "閮ㄩ棬鍚嶇О", + "description": "杞﹂棿", "type": "string" }, "number": { - "description": "閮ㄩ棬缂栧彿", + "description": "缂栧彿", "type": "string" }, - "parentId": { - "description": "涓婄骇閮ㄩ棬ID 涓�绾ч儴闂ㄤ紶0", + "spec": { + "description": "瑙勬牸", + "type": "string" + }, + "startCircle": { + "description": "寮�濮嬪洖鏁�", "type": "integer" + }, + "updatedAt": { + "type": "string" + }, + "workshopGroup": { + "description": "杞︾粍", + "type": "string" + } + } + }, + "request.AddDict": { + "type": "object", + "properties": { + "dictType": { + "description": "瀛楀吀绫诲瀷", + "allOf": [ + { + "$ref": "#/definitions/constvar.DictType" + } + ] + }, + "name": { + "description": "鍚嶇О", + "type": "string" + }, + "number": { + "description": "缂栫爜", + "type": "string" }, "remark": { "description": "澶囨敞", @@ -211,23 +394,27 @@ } } }, - "request.UpdateDepartment": { + "request.UpdateDict": { "type": "object", "properties": { + "dictType": { + "description": "瀛楀吀绫诲瀷", + "allOf": [ + { + "$ref": "#/definitions/constvar.DictType" + } + ] + }, "id": { "type": "integer" }, "name": { - "description": "閮ㄩ棬鍚嶇О", + "description": "鍚嶇О", "type": "string" }, "number": { - "description": "閮ㄩ棬缂栧彿", + "description": "缂栫爜", "type": "string" - }, - "parentId": { - "description": "涓婄骇閮ㄩ棬ID 涓�绾ч儴闂ㄤ紶0", - "type": "integer" }, "remark": { "description": "澶囨敞", -- Gitblit v1.8.0