.record.js 762 B

1234567891011121314151617181920212223242526272829303132333435363738
  1. module.exports = {
  2. create: {
  3. requestBody: ["mobile", "name", "points", "opera", "remark"],
  4. },
  5. destroy: {
  6. params: ["!id"],
  7. service: "delete",
  8. },
  9. update: {
  10. params: ["!id"],
  11. requestBody: ["mobile", "name", "points", "opera", "remark"],
  12. },
  13. show: {
  14. parameters: {
  15. params: ["!id"],
  16. },
  17. service: "fetch",
  18. },
  19. index: {
  20. parameters: {
  21. query: {
  22. mobile: "mobile",
  23. name: "%name%",
  24. points: "points",
  25. opera: "opera",
  26. "create_time@start": "create_time@start",
  27. "create_time@end": "create_time@end",
  28. },
  29. },
  30. service: "query",
  31. options: {
  32. query: ["skip", "limit"],
  33. sort: ["meta.createdAt"],
  34. desc: true,
  35. count: true,
  36. },
  37. },
  38. };