.patenttechol.js 1.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061
  1. module.exports = {
  2. create: {
  3. requestBody: [
  4. "order_num",
  5. "describe",
  6. "urgent",
  7. "contact",
  8. "phone",
  9. "email",
  10. "requirement",
  11. "status",
  12. ],
  13. },
  14. destroy: {
  15. params: ["!id"],
  16. service: "delete",
  17. },
  18. update: {
  19. params: ["!id"],
  20. requestBody: [
  21. "order_num",
  22. "describe",
  23. "urgent",
  24. "contact",
  25. "phone",
  26. "email",
  27. "requirement",
  28. "status",
  29. ],
  30. },
  31. show: {
  32. parameters: {
  33. params: ["!id"],
  34. },
  35. service: "fetch",
  36. },
  37. index: {
  38. parameters: {
  39. query: {
  40. order_num: "order_num",
  41. urgent: "%urgent%",
  42. contact: "%contact%",
  43. phone: "%phone%",
  44. email: "%email%",
  45. status: "%status%",
  46. "sell_money@start": "sell_money@start",
  47. "sell_money@end": "sell_money@end",
  48. },
  49. // options: {
  50. // "meta.state": 0 // 默认条件
  51. // },
  52. },
  53. service: "query",
  54. options: {
  55. query: ["skip", "limit"],
  56. sort: ["meta.createdAt"],
  57. desc: true,
  58. count: true,
  59. },
  60. },
  61. };