sys_post.go 1.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061
  1. /*
  2. * @desc:岗位相关参数
  3. * @company:云南奇讯科技有限公司
  4. * @Author: yixiaohu
  5. * @Date: 2022/4/7 23:09
  6. */
  7. package system
  8. import (
  9. "github.com/gogf/gf/v2/frame/g"
  10. commonApi "github.com/tiger1103/gfast/v3/api/v1/common"
  11. "github.com/tiger1103/gfast/v3/internal/app/system/model/entity"
  12. )
  13. type PostSearchReq struct {
  14. g.Meta `path:"/post/list" tags:"岗位管理" method:"get" summary:"岗位列表"`
  15. PostCode string `p:"postCode"` //岗位编码
  16. PostName string `p:"postName"` //岗位名称
  17. Status string `p:"status"` //状态
  18. commonApi.PageReq
  19. }
  20. type PostSearchRes struct {
  21. g.Meta `mime:"application/json"`
  22. commonApi.ListRes
  23. PostList []*entity.SysPost `json:"postList"`
  24. }
  25. type PostAddReq struct {
  26. g.Meta `path:"/post/add" tags:"岗位管理" method:"post" summary:"添加岗位"`
  27. PostCode string `p:"postCode" v:"required#岗位编码不能为空"`
  28. PostName string `p:"postName" v:"required#岗位名称不能为空"`
  29. PostSort int `p:"postSort" v:"required#岗位排序不能为空"`
  30. Status uint `p:"status" v:"required#状态不能为空"`
  31. Remark string `p:"remark"`
  32. }
  33. type PostAddRes struct {
  34. }
  35. type PostEditReq struct {
  36. g.Meta `path:"/post/edit" tags:"岗位管理" method:"put" summary:"修改岗位"`
  37. PostId int64 `p:"postId" v:"required#id必须"`
  38. PostCode string `p:"postCode" v:"required#岗位编码不能为空"`
  39. PostName string `p:"postName" v:"required#岗位名称不能为空"`
  40. PostSort int `p:"postSort" v:"required#岗位排序不能为空"`
  41. Status uint `p:"status" v:"required#状态不能为空"`
  42. Remark string `p:"remark"`
  43. }
  44. type PostEditRes struct {
  45. }
  46. type PostDeleteReq struct {
  47. g.Meta `path:"/post/delete" tags:"岗位管理" method:"delete" summary:"删除岗位"`
  48. Ids []int `p:"ids"`
  49. }
  50. type PostDeleteRes struct {
  51. }