zhangqian
2024-07-02 cdbdde21488beb0cca5527c94b5321f04a915e11
update doc
5个文件已修改
240 ■■■■■ 已修改文件
controllers/report_forms_controller.go 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
docs/docs.go 86 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
docs/swagger.json 86 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
docs/swagger.yaml 62 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
models/warehouse_month_stats.go 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
controllers/report_forms_controller.go
@@ -444,7 +444,7 @@
// @Produce   application/json
// @Param     object  body  request.GetMonthStats true  "查询参数"
// @Param     Authorization    header string true "token"
// @Success   200 {object} util.ResponseList{data=[]models.MonthStats}    "成功"
// @Success   200 {object} util.ResponseList{data=[]models.WarehouseMonthStats}    "成功"
// @Router    /api-wms/v1/forms/warehouseMonthStats [post]
func (slf ReportFormsController) WarehouseMonthStats(c *gin.Context) {
    var params request.GetMonthStats
docs/docs.go
@@ -1334,7 +1334,7 @@
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/definitions/models.MonthStats"
                                                "$ref": "#/definitions/models.WarehouseMonthStats"
                                            }
                                        }
                                    }
@@ -5661,6 +5661,90 @@
                }
            }
        },
        "models.WarehouseMonthStats": {
            "type": "object",
            "properties": {
                "amount": {
                    "description": "期末结余数量",
                    "type": "number"
                },
                "beginAmount": {
                    "description": "期初数量",
                    "type": "number"
                },
                "createTime": {
                    "type": "string"
                },
                "date": {
                    "description": "日期 2024-04",
                    "type": "string"
                },
                "id": {
                    "type": "integer"
                },
                "inputAmount": {
                    "description": "入库数量",
                    "type": "number"
                },
                "inputItems": {
                    "description": "入库明细",
                    "type": "array",
                    "items": {
                        "$ref": "#/definitions/models.WarehouseStatsItems"
                    }
                },
                "outputAmount": {
                    "description": "出库数量",
                    "type": "number"
                },
                "outputItems": {
                    "description": "出库明细",
                    "type": "array",
                    "items": {
                        "$ref": "#/definitions/models.WarehouseStatsItems"
                    }
                },
                "productId": {
                    "description": "产品id",
                    "type": "string"
                },
                "productName": {
                    "description": "产品名称",
                    "type": "string"
                },
                "salePrice": {
                    "description": "销售单价",
                    "type": "number"
                },
                "unit": {
                    "description": "单位",
                    "type": "string"
                },
                "updateTime": {
                    "type": "string"
                },
                "warehouseId": {
                    "description": "仓库ID",
                    "type": "integer"
                }
            }
        },
        "models.WarehouseStatsItems": {
            "type": "object",
            "properties": {
                "amount": {
                    "description": "数量",
                    "type": "number"
                },
                "name": {
                    "description": "入库来源,出库去处",
                    "type": "string"
                },
                "warehouseMonthStatsId": {
                    "type": "integer"
                }
            }
        },
        "request.AddAttribute": {
            "type": "object",
            "properties": {
docs/swagger.json
@@ -1323,7 +1323,7 @@
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/definitions/models.MonthStats"
                                                "$ref": "#/definitions/models.WarehouseMonthStats"
                                            }
                                        }
                                    }
@@ -5650,6 +5650,90 @@
                }
            }
        },
        "models.WarehouseMonthStats": {
            "type": "object",
            "properties": {
                "amount": {
                    "description": "期末结余数量",
                    "type": "number"
                },
                "beginAmount": {
                    "description": "期初数量",
                    "type": "number"
                },
                "createTime": {
                    "type": "string"
                },
                "date": {
                    "description": "日期 2024-04",
                    "type": "string"
                },
                "id": {
                    "type": "integer"
                },
                "inputAmount": {
                    "description": "入库数量",
                    "type": "number"
                },
                "inputItems": {
                    "description": "入库明细",
                    "type": "array",
                    "items": {
                        "$ref": "#/definitions/models.WarehouseStatsItems"
                    }
                },
                "outputAmount": {
                    "description": "出库数量",
                    "type": "number"
                },
                "outputItems": {
                    "description": "出库明细",
                    "type": "array",
                    "items": {
                        "$ref": "#/definitions/models.WarehouseStatsItems"
                    }
                },
                "productId": {
                    "description": "产品id",
                    "type": "string"
                },
                "productName": {
                    "description": "产品名称",
                    "type": "string"
                },
                "salePrice": {
                    "description": "销售单价",
                    "type": "number"
                },
                "unit": {
                    "description": "单位",
                    "type": "string"
                },
                "updateTime": {
                    "type": "string"
                },
                "warehouseId": {
                    "description": "仓库ID",
                    "type": "integer"
                }
            }
        },
        "models.WarehouseStatsItems": {
            "type": "object",
            "properties": {
                "amount": {
                    "description": "数量",
                    "type": "number"
                },
                "name": {
                    "description": "入库来源,出库去处",
                    "type": "string"
                },
                "warehouseMonthStatsId": {
                    "type": "integer"
                }
            }
        },
        "request.AddAttribute": {
            "type": "object",
            "properties": {
docs/swagger.yaml
@@ -1272,6 +1272,66 @@
        description: 库存位置
        type: string
    type: object
  models.WarehouseMonthStats:
    properties:
      amount:
        description: 期末结余数量
        type: number
      beginAmount:
        description: 期初数量
        type: number
      createTime:
        type: string
      date:
        description: 日期 2024-04
        type: string
      id:
        type: integer
      inputAmount:
        description: 入库数量
        type: number
      inputItems:
        description: 入库明细
        items:
          $ref: '#/definitions/models.WarehouseStatsItems'
        type: array
      outputAmount:
        description: 出库数量
        type: number
      outputItems:
        description: 出库明细
        items:
          $ref: '#/definitions/models.WarehouseStatsItems'
        type: array
      productId:
        description: 产品id
        type: string
      productName:
        description: 产品名称
        type: string
      salePrice:
        description: 销售单价
        type: number
      unit:
        description: 单位
        type: string
      updateTime:
        type: string
      warehouseId:
        description: 仓库ID
        type: integer
    type: object
  models.WarehouseStatsItems:
    properties:
      amount:
        description: 数量
        type: number
      name:
        description: 入库来源,出库去处
        type: string
      warehouseMonthStatsId:
        type: integer
    type: object
  request.AddAttribute:
    properties:
      dataType:
@@ -3149,7 +3209,7 @@
            - properties:
                data:
                  items:
                    $ref: '#/definitions/models.MonthStats'
                    $ref: '#/definitions/models.WarehouseMonthStats'
                  type: array
              type: object
      summary: 仓库月度统计库存报表
models/warehouse_month_stats.go
@@ -22,10 +22,10 @@
        EndAmount   decimal.Decimal `json:"amount" gorm:"type:decimal(30,10);not null;comment:数量"`      //期末结余数量
        InputAmount decimal.Decimal        `json:"inputAmount" gorm:"type:decimal(30,10);not null;comment:数量"` //入库数量
        InputItems  []*WarehouseStatsItems `json:"inputMoreUnitsArr"`                                          //入库明细
        InputItems  []*WarehouseStatsItems `json:"inputItems"`                                                 //入库明细
        OutputAmount decimal.Decimal        `json:"outputAmount" gorm:"type:decimal(30,10);not null;comment:数量"` //出库数量
        OutputItems  []*WarehouseStatsItems `json:"outputMoreUnitsArr"`                                          //出库明细
        OutputItems  []*WarehouseStatsItems `json:"outputItems"`                                                 //出库明细
        Date string `json:"date" gorm:"index;type:varchar(255); not null;default ''"` //日期 2024-04
    }