customer.js 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081
  1. import service from '@/utils/request'
  2. // @Tags SysApi
  3. // @Summary 删除客户
  4. // @Security ApiKeyAuth
  5. // @accept application/json
  6. // @Produce application/json
  7. // @Param data body dbModel.ExaCustomer true "删除客户"
  8. // @Success 200 {string} string "{"success":true,"data":{},"msg":"获取成功"}"
  9. // @Router /customer/customer [post]
  10. export const createExaCustomer = (data) => {
  11. return service({
  12. url: '/customer/customer',
  13. method: 'post',
  14. data
  15. })
  16. }
  17. // @Tags SysApi
  18. // @Summary 更新客户信息
  19. // @Security ApiKeyAuth
  20. // @accept application/json
  21. // @Produce application/json
  22. // @Param data body dbModel.ExaCustomer true "更新客户信息"
  23. // @Success 200 {string} string "{"success":true,"data":{},"msg":"获取成功"}"
  24. // @Router /customer/customer [put]
  25. export const updateExaCustomer = (data) => {
  26. return service({
  27. url: '/customer/customer',
  28. method: 'put',
  29. data
  30. })
  31. }
  32. // @Tags SysApi
  33. // @Summary 创建客户
  34. // @Security ApiKeyAuth
  35. // @accept application/json
  36. // @Produce application/json
  37. // @Param data body dbModel.ExaCustomer true "创建客户"
  38. // @Success 200 {string} string "{"success":true,"data":{},"msg":"获取成功"}"
  39. // @Router /customer/customer [delete]
  40. export const deleteExaCustomer = (data) => {
  41. return service({
  42. url: '/customer/customer',
  43. method: 'delete',
  44. data
  45. })
  46. }
  47. // @Tags SysApi
  48. // @Summary 获取单一客户信息
  49. // @Security ApiKeyAuth
  50. // @accept application/json
  51. // @Produce application/json
  52. // @Param data body dbModel.ExaCustomer true "获取单一客户信息"
  53. // @Success 200 {string} string "{"success":true,"data":{},"msg":"获取成功"}"
  54. // @Router /customer/customer [get]
  55. export const getExaCustomer = (params) => {
  56. return service({
  57. url: '/customer/customer',
  58. method: 'get',
  59. params
  60. })
  61. }
  62. // @Tags SysApi
  63. // @Summary 获取权限客户列表
  64. // @Security ApiKeyAuth
  65. // @accept application/json
  66. // @Produce application/json
  67. // @Param data body modelInterface.PageInfo true "获取权限客户列表"
  68. // @Success 200 {string} string "{"success":true,"data":{},"msg":"获取成功"}"
  69. // @Router /customer/customerList [get]
  70. export const getExaCustomerList = (params) => {
  71. return service({
  72. url: '/customer/customerList',
  73. method: 'get',
  74. params
  75. })
  76. }