2023-06-30 17:35:46 +08:00

33 lines
1.1 KiB
Go
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

package requests
type PostRequest struct {
GetPostPage // 获取岗位列表-分页
AddPost // 新增岗位
DeletePost // 删除岗位-批量
PutPost // 修改岗位
}
// AddPost 新增岗位
type AddPost struct {
PostName string `json:"dept_name" form:"dept_name" validate:"required" label:"岗位名称"`
PostStatus int `json:"dept_status" form:"dept_status" validate:"required,oneof=1 2" label:"岗位状态"` // 1:正常 2:删除)
}
// GetPostPage 获取岗位列表-分页
type GetPostPage struct {
DeptName string `json:"dept_name" form:"dept_name" label:"api名称"`
Page int `json:"page" form:"page" label:"页码"`
PageSize int `json:"page_size" form:"page_size" label:"每页个数"`
}
// DeletePost 删除岗位-批量
type DeletePost struct {
PostIds []string `json:"post_ids" form:"post_ids" validate:"required" label:"岗位id"`
}
// PutPost 修改岗位
type PutPost struct {
PostName string `json:"post_name" form:"post_name" validate:"required" label:"岗位名称"`
PostStatus int `json:"post_status" form:"post_status" validate:"required,oneof=1 2" label:"岗位状态"` // 1:正常 2:删除)
}