order.service.js 3.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113
  1. /**
  2. * 这是与购物有关的业务逻辑的服务
  3. */
  4. export default class OrderService {
  5. constructor(AjaxService) {
  6. Object.assign(this, { AjaxService })
  7. this.name = 'OrderService'
  8. }
  9. /**
  10. *识别收款短信
  11. * @param smsContent 短信内容
  12. * @param openid 微信openid
  13. /**/
  14. orderReceiptReadSms (data = {}) {
  15. return this.AjaxService.post({
  16. url:'/order/receipt/read/sms',
  17. data,
  18. isLoading: true ,
  19. loadText: '识别中...'
  20. })
  21. }
  22. /**
  23. *获取收款类型
  24. /**/
  25. orderReceiptType (data = {}) {
  26. return this.AjaxService.get({
  27. url:'/order/receipt/type',
  28. data,
  29. isLoading: true ,
  30. })
  31. }
  32. /**
  33. *保存收款
  34. * @param smsContent 短信内容
  35. * @param openid 微信openid
  36. * @param payType 付款类型
  37. * @param receiptType 收款类型
  38. * @param receiptAmount 收款金额
  39. * @param handlingFee 手续费
  40. * @param receiptDate 收款时间
  41. /**/
  42. orderReceiptSave(data = {}) {
  43. return this.AjaxService.post({
  44. url:'/order/receipt/save',
  45. data,
  46. isLoading: true ,
  47. loadText: '保存中...'
  48. })
  49. }
  50. /**
  51. *获取收款列表
  52. * @param startDate 筛选开始时间
  53. * @param endDate 筛选结束时间
  54. * @param openid 微信openid
  55. * @param pageNum 页码
  56. * @param pageSize 条数
  57. * @param receiptStatus 收款状态:0全部 1待确认、2已确认(待审核)、3审核通过、4审核未通过、5收款撤销【线上支付成功为审核通过】
  58. * @param receiptType 款项类型:1订单款,2非订单款,3返佣款 4订单款或者非订单款(因财务阶段无法区分订单非订单), 5供应商退款
  59. * @param smsContent 收款短信
  60. /**/
  61. orderReceiptList(data = {}) {
  62. return this.AjaxService.get({
  63. url:'/order/receipt/list',
  64. data,
  65. isLoading: false ,
  66. })
  67. }
  68. /**
  69. *获取收款详情
  70. * @param id 款项Id
  71. * @param openid 微信openid
  72. /**/
  73. orderReceiptDetail(data = {}) {
  74. return this.AjaxService.get({
  75. url:'/order/receipt/detail',
  76. data,
  77. isLoading: true ,
  78. })
  79. }
  80. /**
  81. *操作收款信息(作废,设为返佣-普通-供应商退款-非订单款)
  82. * @param id 款项Id
  83. * @param openid 微信openid
  84. /**/
  85. orderReceiptOperate(data = {}) {
  86. return this.AjaxService.post({
  87. url:'/order/receipt/operate',
  88. data,
  89. isLoading: true ,
  90. loadText: '请稍候...'
  91. })
  92. }
  93. /**
  94. *收款详情-订单列表
  95. * @param id 收款Id
  96. * @param keyword 搜索关键词(客户名称/订单号)
  97. * @param orderReceiptStatus 订单收款状态:1待收款(协销待确认款项的订单),2部分收款(已确认款项的订单),3已收款(已确认款项的订单)
  98. * @param organizeId 组织ID
  99. * @param pageNum 页码
  100. * @param pageSize 条数
  101. * @param type 0商品订单(默认),1订金订单
  102. /**/
  103. orderReceiptOrders(data = {}) {
  104. return this.AjaxService.get({
  105. url:'/order/receipt/detail/orders',
  106. data,
  107. isLoading: true ,
  108. loadText: '请稍候...'
  109. })
  110. }
  111. }