.card.js 2.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109
  1. module.exports = {
  2. create: {
  3. requestBody: [
  4. "!mobile",
  5. "!password",
  6. "!province",
  7. "!city",
  8. "!set",
  9. "pay_type",
  10. "!name",
  11. "id_card",
  12. "level",
  13. "points",
  14. "recommend",
  15. "r_mobile",
  16. "wxaccount",
  17. "create_time",
  18. ],
  19. },
  20. destroy: {
  21. params: ["!id"],
  22. service: "delete",
  23. },
  24. update: {
  25. params: ["!id"],
  26. requestBody: [
  27. "!mobile",
  28. "!password",
  29. "!province",
  30. "!city",
  31. "!set",
  32. "pay_type",
  33. "!name",
  34. "id_card",
  35. "level",
  36. "points",
  37. "recommend",
  38. "r_mobile",
  39. "wxaccount",
  40. "create_time",
  41. ],
  42. },
  43. show: {
  44. parameters: {
  45. params: ["!id"],
  46. },
  47. service: "fetch",
  48. },
  49. index: {
  50. parameters: {
  51. query: {
  52. mobile: "mobile",
  53. province: "province",
  54. city: "city",
  55. pay_type: "pay_type",
  56. name: "name",
  57. id_card: "id_card",
  58. level: "level",
  59. recommend: "%recommend%",
  60. r_mobile: "r_mobile",
  61. car_show: "car_show",
  62. stockholder: "stockholder",
  63. wxaccount: "%wxaccount%",
  64. set: "set",
  65. status: "status",
  66. "create_time@start": "create_time@start",
  67. "create_time@end": "create_time@end",
  68. },
  69. },
  70. service: "query",
  71. options: {
  72. query: ["skip", "limit"],
  73. sort: ["meta.createdAt"],
  74. desc: true,
  75. count: true,
  76. },
  77. },
  78. // 修改密码
  79. passwd: {
  80. params: ["!id"],
  81. requestBody: ["!password"],
  82. service: "passwd",
  83. },
  84. group: {
  85. parameters: {
  86. query: {
  87. r_mobile: "r_mobile",
  88. province: "province",
  89. set: "set",
  90. "create_time@start": "create_time@start",
  91. "create_time@end": "create_time@end",
  92. },
  93. },
  94. service: "group",
  95. options: {
  96. query: ["skip", "limit"],
  97. sort: ["meta.createdAt"],
  98. desc: true,
  99. // count: true,
  100. },
  101. },
  102. // 用户审核
  103. check: {
  104. params: ["!id"],
  105. requestBody: ["!status"],
  106. service: "check",
  107. },
  108. };