package.go 1.9 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697
  1. package v1
  2. import (
  3. "property-management-gateway/param/base"
  4. "property-management-gateway/pb/v1"
  5. )
  6. // 套餐相关
  7. type PackageAddBody struct {
  8. Name string `form:"name" json:"name"`
  9. Desc string `form:"desc" json:"desc"`
  10. Price int64 `form:"price" json:"price"`
  11. HouseCount int64 `form:"house_count" json:"house_count"`
  12. }
  13. type PackageAddRequest struct {
  14. base.Header
  15. PackageAddBody
  16. }
  17. type PackageAddResponse struct {
  18. base.Result
  19. }
  20. type PackageUpdateBody struct {
  21. Name string `form:"name" json:"name"`
  22. Desc string `form:"desc" json:"desc"`
  23. Price int64 `form:"price" json:"price"`
  24. HouseCount int64 `form:"house_count" json:"house_count"`
  25. Id int64 `form:"id" json:"id"`
  26. }
  27. type PackageUpdateRequest struct {
  28. base.Header
  29. PackageUpdateBody
  30. }
  31. type PackageUpdateResponse struct {
  32. base.Result
  33. }
  34. type PackageDelQuery struct {
  35. Id int64 `form:"id"`
  36. }
  37. type PackageDelRequest struct {
  38. base.Header
  39. PackageDelQuery
  40. }
  41. type PackageDelResponse struct {
  42. base.Result
  43. }
  44. type PackageListQuery struct {
  45. Page int64 `form:"page" json:"page"`
  46. PageSize int64 `form:"page_size" json:"page_size"`
  47. Enable int32 `form:"enable" json:"enable"`
  48. }
  49. type PackageListRequest struct {
  50. base.Header
  51. PackageListQuery
  52. }
  53. type PackageListResponse struct {
  54. base.Result
  55. Data v1.PackageListReply `json:"data"`
  56. }
  57. type PackageEnableSetBody struct {
  58. Enable bool `form:"enable" json:"enable"`
  59. Id int64 `form:"id" json:"id"`
  60. }
  61. type PackageEnableSetRequest struct {
  62. base.Header
  63. PackageEnableSetBody
  64. }
  65. type PackageEnableSetResponse struct {
  66. base.Result
  67. }
  68. type PackageApplicationSetBody struct {
  69. Id int64 `form:"id" json:"id"`
  70. ApplicationIds []int64 `form:"application_ids" json:"application_ids"`
  71. }
  72. type PackageApplicationSetRequest struct {
  73. base.Header
  74. PackageApplicationSetBody
  75. }
  76. type PackageApplicationSetResponse struct {
  77. base.Result
  78. }