companyCustomer.js 3.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149
  1. import request from '@/utils/request'
  2. // 查询客户列表
  3. export function listCustomer(query) {
  4. return request({
  5. url: '/qw/companyCustomer/list',
  6. method: 'get',
  7. params: query
  8. })
  9. }
  10. // 查询客户详情
  11. export function getCustomer(id) {
  12. return request({
  13. url: '/qw/companyCustomer/' + id,
  14. method: 'get'
  15. })
  16. }
  17. // 新增客户
  18. export function addCustomer(data) {
  19. return request({
  20. url: '/qw/companyCustomer',
  21. method: 'post',
  22. data: data
  23. })
  24. }
  25. // 修改客户
  26. export function updateCustomer(data) {
  27. return request({
  28. url: '/qw/companyCustomer',
  29. method: 'put',
  30. data: data
  31. })
  32. }
  33. // 认领客户
  34. export function claimCustomer(data) {
  35. return request({
  36. url: '/qw/companyCustomer/claimCustomer',
  37. method: 'put',
  38. data: data
  39. })
  40. }
  41. // 删除客户
  42. export function delCustomer(ids) {
  43. return request({
  44. url: '/qw/companyCustomer/' + ids,
  45. method: 'delete'
  46. })
  47. }
  48. // 导出客户
  49. export function exportCustomer(query) {
  50. return request({
  51. url: '/qw/companyCustomer/export',
  52. method: 'post',
  53. params: query,
  54. responseType: 'blob'
  55. })
  56. }
  57. // 获取当前登录销售及绑定医生信息
  58. export function getCompanyUserAndDoctor() {
  59. return request({
  60. url: '/qw/companyCustomer/getCompanyUserAndDoctor',
  61. method: 'get'
  62. })
  63. }
  64. // 根据主键id分页查询处方列表(销售端)
  65. export function getPrescribeListByPhone(data) {
  66. return request({
  67. url: '/qw/companyCustomer/getPrescribeListByPhone',
  68. method: 'post',
  69. data: data
  70. })
  71. }
  72. // 根据主键id分页查询处方列表
  73. export function getPrescribeListByIdAndPhone(data) {
  74. return request({
  75. url: '/qw/companyCustomer/getPrescribeListByIdAndPhone',
  76. method: 'post',
  77. data: data
  78. })
  79. }
  80. // 根据主键id分页查询信息采集列表
  81. export function getCollectionInfoListByPhone(data) {
  82. return request({
  83. url: '/qw/companyCustomer/getCollectionInfoListByPhone',
  84. method: 'post',
  85. data: data
  86. })
  87. }
  88. // 根据主键id分页查询信息采集列表
  89. export function getCollectionInfoListByIdAndPhone(data) {
  90. return request({
  91. url: '/qw/companyCustomer/getCollectionInfoListByIdAndPhone',
  92. method: 'post',
  93. data: data
  94. })
  95. }
  96. // 获取客户认领记录列表
  97. export function getCustomerLogList(query) {
  98. return request({
  99. url: '/qw/customerLog/list',
  100. method: 'get',
  101. params: query
  102. })
  103. }
  104. // 获取销售人员可用的收款记录列表
  105. export function getCanUsePayReceiptList() {
  106. return request({
  107. url: '/pay/receipt/canUsePayReceiptList',
  108. method: 'get'
  109. })
  110. }
  111. // 获取客户订单列表
  112. export function getOrderList(query) {
  113. return request({
  114. url: '/qw/companyCustomer/getOrderList', // 去掉 fs
  115. method: 'get',
  116. params: query
  117. })
  118. }
  119. // 获取订单二维码
  120. export function getQRCode(orderId) {
  121. return request({
  122. url: '/qw/companyCustomer/getQRCode/' + orderId, // 去掉 fs
  123. method: 'get'
  124. })
  125. }
  126. export function getAddress(address) {
  127. return request({
  128. url: '/qw/companyCustomer/getAddress',
  129. method: 'get',
  130. params: { address: address }
  131. })
  132. }