112 lines
4.3 KiB
Go
112 lines
4.3 KiB
Go
// ==========================================================================
|
||
// GFast自动生成api操作代码。
|
||
// 生成日期:2024-03-28 14:53:05
|
||
// 生成路径: api/v1/system/bus_hse_management.go
|
||
// 生成人:gfast
|
||
// desc:HSE-巡检工单相关参数
|
||
// company:云南奇讯科技有限公司
|
||
// ==========================================================================
|
||
|
||
package system
|
||
|
||
import (
|
||
"github.com/gogf/gf/v2/frame/g"
|
||
"github.com/gogf/gf/v2/net/ghttp"
|
||
commonApi "github.com/tiger1103/gfast/v3/api/v1/common"
|
||
comModel "github.com/tiger1103/gfast/v3/internal/app/common/model"
|
||
"github.com/tiger1103/gfast/v3/internal/app/system/model"
|
||
)
|
||
|
||
// BusHseManagementSearchReq 分页请求参数
|
||
type BusHseManagementSearchReq struct {
|
||
g.Meta `path:"/list" tags:"HSE-巡检工单" method:"get" summary:"HSE-巡检工单列表"`
|
||
ProjectId string `p:"projectId" v:"projectId@integer#项目ID需为整数"`
|
||
StudyType string `p:"studyType" dc:"检查类型"`
|
||
TourType string `p:"tourType" dc:"违章类型"`
|
||
Fill string `p:"fill" dc:"检查人"`
|
||
Abarbeitung string `p:"abarbeitung" dc:"整改人"`
|
||
commonApi.PageReq
|
||
commonApi.Author
|
||
}
|
||
|
||
// BusHseManagementSearchRes 列表返回结果
|
||
type BusHseManagementSearchRes struct {
|
||
g.Meta `mime:"application/json"`
|
||
commonApi.ListRes
|
||
List []*model.BusHseManagementInfoTwoRes `json:"list"`
|
||
}
|
||
|
||
// BusHseManagementAddReq 添加操作请求参数
|
||
type BusHseManagementAddReq struct {
|
||
g.Meta `path:"/add" tags:"HSE-巡检工单" method:"post" summary:"HSE-巡检工单添加"`
|
||
commonApi.Author
|
||
ProjectId int64 `p:"projectId" dc:"项目ID"`
|
||
StudyType string `p:"studyType" dc:"检查类型"`
|
||
TourType string `p:"tourType" dc:"违章类型"`
|
||
InspectionResult string `p:"inspectionResult" dc:"巡检结果"`
|
||
TeamName string `p:"teamName" v:"required#名称(班组/部门)不能为空"`
|
||
Corrector string `p:"corrector" dc:"整改人"`
|
||
ReplyDate string `p:"replyDate" dc:"回复日期"`
|
||
HseManagementAdd int `p:"hseManagementAdd" dc:"0使用file 1使用fileTwo"`
|
||
File []*ghttp.UploadFile `p:"file" dc:"附件"`
|
||
FileTwo []*comModel.UpFile `p:"fileTwo" dc:"附件"`
|
||
}
|
||
|
||
// BusHseManagementAddRes 添加操作返回结果
|
||
type BusHseManagementAddRes struct {
|
||
commonApi.EmptyRes
|
||
}
|
||
|
||
// BusHseManagementEditReq 修改操作请求参数
|
||
type BusHseManagementEditReq struct {
|
||
g.Meta `path:"/edit" tags:"HSE-巡检工单" method:"put" summary:"HSE-巡检工单整改"`
|
||
commonApi.Author
|
||
Id int64 `p:"id" v:"required#主键ID不能为空"`
|
||
File []*ghttp.UploadFile `p:"file" dc:"附件"`
|
||
}
|
||
|
||
// BusHseManagementEditRes 修改操作返回结果
|
||
type BusHseManagementEditRes struct {
|
||
commonApi.EmptyRes
|
||
}
|
||
|
||
// EditReviewReq 修改操作请求参数
|
||
type EditReviewReq struct {
|
||
g.Meta `path:"/editReview" tags:"HSE-巡检工单" method:"put" summary:"HSE-巡检工单复查"`
|
||
commonApi.Author
|
||
Id int64 `p:"id" v:"required#主键ID不能为空"`
|
||
ReviewType string `p:"reviewType" dc:"复查状态(1通过 2未通过)" v:"required#主键ID不能为空"`
|
||
Review string `p:"review" dc:"复查情况" v:"required#复查情况不能为空"`
|
||
//Review string `p:"review" dc:"复查情况" v:"required-if:reviewType,2#状态为未通过,需填写复查"`
|
||
}
|
||
|
||
// EditReviewRes 修改操作返回结果
|
||
type EditReviewRes struct {
|
||
commonApi.EmptyRes
|
||
}
|
||
|
||
// BusHseManagementGetReq 获取一条数据请求
|
||
type BusHseManagementGetReq struct {
|
||
g.Meta `path:"/get" tags:"HSE-巡检工单" method:"get" summary:"获取HSE-巡检工单信息"`
|
||
commonApi.Author
|
||
Id int64 `p:"id" v:"required#主键必须"` // 通过主键获取
|
||
}
|
||
|
||
// BusHseManagementGetRes 获取一条数据结果
|
||
type BusHseManagementGetRes struct {
|
||
g.Meta `mime:"application/json"`
|
||
*model.BusHseManagementDetailsRes
|
||
}
|
||
|
||
// BusHseManagementDeleteReq 删除数据请求
|
||
type BusHseManagementDeleteReq struct {
|
||
g.Meta `path:"/delete" tags:"HSE-巡检工单" method:"delete" summary:"删除HSE-巡检工单"`
|
||
commonApi.Author
|
||
Ids []int64 `p:"ids" v:"required#主键必须"` // 通过主键删除
|
||
}
|
||
|
||
// BusHseManagementDeleteRes 删除数据返回
|
||
type BusHseManagementDeleteRes struct {
|
||
commonApi.EmptyRes
|
||
}
|