http_response.go 1.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960
  1. package model
  2. import uuid "github.com/satori/go.uuid"
  3. /****************************** common start ****************************************************/
  4. // 分页公用入参结构体
  5. type PageInfo struct {
  6. Page int `json:"page"`
  7. PageSize int `json:"pageSize"`
  8. }
  9. //根据id查询结构体
  10. type GetById struct {
  11. Id float64 `json:"id"`
  12. }
  13. /****************************** common end ****************************************************/
  14. /****************************** api start ****************************************************/
  15. //api分页条件查询及排序结构体
  16. type SearchApiParams struct {
  17. SysApi
  18. PageInfo
  19. OrderKey string `json:"orderKey"`
  20. Desc bool `json:"desc"`
  21. }
  22. /****************************** api end ****************************************************/
  23. /****************************** Authority start ****************************************************/
  24. // 添加角色和menu关系
  25. type AddMenuAuthorityInfo struct {
  26. Menus []SysBaseMenu
  27. AuthorityId string
  28. }
  29. // 根据角色id获取角色
  30. type AuthorityIdInfo struct {
  31. AuthorityId string
  32. }
  33. /****************************** Authority end ****************************************************/
  34. /****************************** user start ****************************************************/
  35. // 修改密码结构体
  36. type ChangePasswordStutrc struct {
  37. Username string `json:"username"`
  38. Password string `json:"password"`
  39. NewPassword string `json:"newPassword"`
  40. }
  41. // 设置用户权限
  42. type SetUserAuth struct {
  43. UUID uuid.UUID `json:"uuid"`
  44. AuthorityId string `json:"authorityId"`
  45. }
  46. /****************************** user end ****************************************************/