jiangshuai
2023-11-22 0022d062fc8c72061b4d62dc5e192e75588b6979
出入库导入导出修改代码
5个文件已修改
100 ■■■■■ 已修改文件
controllers/operation.go 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
docs/docs.go 36 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
docs/swagger.json 34 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
docs/swagger.yaml 22 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
router/router.go 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
controllers/operation.go
@@ -839,7 +839,7 @@
//    @Param        id    path        int            true    "id"
//    @Success    200    {object}    util.Response    "成功"
//    @Router        /api-wms/v1/operation/outputOperation/{id} [put]
func (slf OperationController) InputSelfmade(c *gin.Context) {
func (slf OperationController) OutputOperation(c *gin.Context) {
    id, err := strconv.Atoi(c.Param("id"))
    if err != nil {
        util.ResponseFormat(c, code.RequestParamError, "错误的id值")
@@ -881,7 +881,7 @@
}
func ExportInputSelfmade(category constvar.FileTemplateCategory, operation *models.Operation) (string, error) {
    template, err := models.NewFileTemplateAttachmentSearch().SetCategory(category).First()
    template, err := models.NewFileTemplateAttachmentSearch().SetPreload(true).SetCategory(category).First()
    if err != nil {
        return "", errors.New("获取模版记录失败:" + err.Error())
    }
@@ -960,7 +960,7 @@
}
func ExportOutputOperation(category constvar.FileTemplateCategory, operation *models.Operation) (string, error) {
    template, err := models.NewFileTemplateAttachmentSearch().SetCategory(category).First()
    template, err := models.NewFileTemplateAttachmentSearch().SetPreload(true).SetCategory(category).First()
    if err != nil {
        return "", errors.New("获取模版记录失败:" + err.Error())
    }
docs/docs.go
@@ -1249,6 +1249,34 @@
                }
            }
        },
        "/api-wms/v1/operation/outputOperation/{id}": {
            "put": {
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "入库/出库"
                ],
                "summary": "打印",
                "parameters": [
                    {
                        "type": "integer",
                        "description": "id",
                        "name": "id",
                        "in": "path",
                        "required": true
                    }
                ],
                "responses": {
                    "200": {
                        "description": "成功",
                        "schema": {
                            "$ref": "#/definitions/util.Response"
                        }
                    }
                }
            }
        },
        "/api-wms/v1/operation/update": {
            "post": {
                "produces": [
@@ -3347,6 +3375,9 @@
                        }
                    ]
                },
                "createTime": {
                    "type": "string"
                },
                "forceRemovalStrategy": {
                    "description": "强制下架策略",
                    "allOf": [
@@ -3380,6 +3411,9 @@
                },
                "routeName": {
                    "description": "公司",
                    "type": "string"
                },
                "updateTime": {
                    "type": "string"
                }
            }
@@ -4652,8 +4686,6 @@
    Description:      "",
    InfoInstanceName: "swagger",
    SwaggerTemplate:  docTemplate,
    LeftDelim:        "{{",
    RightDelim:       "}}",
}
func init() {
docs/swagger.json
@@ -1237,6 +1237,34 @@
                }
            }
        },
        "/api-wms/v1/operation/outputOperation/{id}": {
            "put": {
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "入库/出库"
                ],
                "summary": "打印",
                "parameters": [
                    {
                        "type": "integer",
                        "description": "id",
                        "name": "id",
                        "in": "path",
                        "required": true
                    }
                ],
                "responses": {
                    "200": {
                        "description": "成功",
                        "schema": {
                            "$ref": "#/definitions/util.Response"
                        }
                    }
                }
            }
        },
        "/api-wms/v1/operation/update": {
            "post": {
                "produces": [
@@ -3335,6 +3363,9 @@
                        }
                    ]
                },
                "createTime": {
                    "type": "string"
                },
                "forceRemovalStrategy": {
                    "description": "强制下架策略",
                    "allOf": [
@@ -3369,6 +3400,9 @@
                "routeName": {
                    "description": "公司",
                    "type": "string"
                },
                "updateTime": {
                    "type": "string"
                }
            }
        },
docs/swagger.yaml
@@ -680,6 +680,8 @@
        allOf:
        - $ref: '#/definitions/constvar.CostingMethod'
        description: 成本方法
      createTime:
        type: string
      forceRemovalStrategy:
        allOf:
        - $ref: '#/definitions/constvar.ForceRemovalStrategy'
@@ -701,6 +703,8 @@
        type: integer
      routeName:
        description: 公司
        type: string
      updateTime:
        type: string
    type: object
  models.ReorderRule:
@@ -2331,6 +2335,24 @@
      summary: 删除入库/出库信息
      tags:
      - 入库/出库
  /api-wms/v1/operation/outputOperation/{id}:
    put:
      parameters:
      - description: id
        in: path
        name: id
        required: true
        type: integer
      produces:
      - application/json
      responses:
        "200":
          description: 成功
          schema:
            $ref: '#/definitions/util.Response'
      summary: 打印
      tags:
      - 入库/出库
  /api-wms/v1/operation/update:
    post:
      parameters:
router/router.go
@@ -88,7 +88,7 @@
        operationAPI.POST("listTransfer", operationController.ListTransfer)
        operationAPI.GET("getLogisticCompanyList", operationController.GetLogisticCompanyList)
        operationAPI.PUT("cancel/:id", operationController.Cancel)
        operationAPI.PUT("inputSelfmade/:id", operationController.InputSelfmade)
        operationAPI.PUT("outputOperation/:id", operationController.OutputOperation)
    }