sys_post.go 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. // ==========================================================================
  2. // This is auto-generated by gf cli tool. Fill this file as you wish.
  3. // ==========================================================================
  4. package model
  5. import (
  6. "dashoo.cn/micro/app/model/internal"
  7. "dashoo.cn/opms_libary/request"
  8. )
  9. // SysPost is the golang structure for table sys_post.
  10. type SysPost internal.SysPost
  11. // Fill with you ideas below.
  12. // SysPostSearchParams 搜索参数
  13. type SysPostSearchParams struct {
  14. PostCode string `p:"postCode"` //岗位编码
  15. PostName string `p:"postName"` //岗位名称
  16. Status string `p:"status"` //状态
  17. request.PageReq
  18. }
  19. // SysPostReq 添加岗位参数
  20. type SysPostReq struct {
  21. PostCode string `p:"postCode" v:"required#岗位编码不能为空"`
  22. PostName string `p:"postName" v:"required#岗位名称不能为空"`
  23. Sort int `p:"sort" v:"required#岗位排序不能为空"`
  24. Status string `p:"status" v:"required|in:10,20#状态不能为空|状态只能为10或20"`
  25. RoleIds []int `p:"roleIds"`
  26. Remark string `p:"remark"`
  27. }
  28. // UpdateSysPostReq 修改岗位参数
  29. type UpdateSysPostReq struct {
  30. Id int64 `p:"id" v:"required#id必须"`
  31. SysPostReq
  32. }
  33. // SysPostRes 岗位详情
  34. type SysPostRes struct {
  35. SysPost
  36. RoleIds []int `json:"roleIds"`
  37. }