feat:完善项目
This commit is contained in:
@ -93,7 +93,8 @@ func (this *workLaunchMaterialForm) SupplierInfo() uint64 {
|
||||
* @apiHeader {string} x-token token
|
||||
* @apiHeader {string} Content-Type=application/json 传输方式
|
||||
*
|
||||
* @apiParam {String} [material_id=0] 装备ID
|
||||
* @apiParam {String} [equipment_code="''"] 装备编码
|
||||
* @apiParam {String} [equipment_title="''"] 装备名称
|
||||
* @apiParam {String} [kind=0] 工单类型
|
||||
* @apiParam {Number} current 当前页
|
||||
* @apiParam {Number} page_size 页展示数
|
||||
@ -135,15 +136,16 @@ func (this *workLaunchMaterialForm) SupplierInfo() uint64 {
|
||||
*/
|
||||
func (*Work) Instance(c *gin.Context) {
|
||||
form := &struct {
|
||||
MaterialID uint64 `json:"material_id" form:"material_id"`
|
||||
Kind int `json:"kind" form:"kind"`
|
||||
EquipmentCode string `json:"equipment_code" form:"equipment_code"`
|
||||
EquipmentTitle string `json:"equipment_title" form:"equipment_title"`
|
||||
Kind int `json:"kind" form:"kind"`
|
||||
PageForm
|
||||
}{}
|
||||
if err := bind(form)(c); err != nil {
|
||||
APIFailure(err.(error))(c)
|
||||
return
|
||||
}
|
||||
data, err := work.NewInstance()(getSession()(c).(*service.Session)).List(form.MaterialID, form.Kind, form.Page, form.PageSize)
|
||||
data, err := work.NewInstance()(getSession()(c).(*service.Session)).List(form.EquipmentCode, form.EquipmentTitle, form.Kind, form.Page, form.PageSize)
|
||||
APIResponse(err, data)(c)
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user