bill.js 2.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102
  1. import request from '@/utils/request'
  2. // 查询往来账款列表
  3. export function listBill(query) {
  4. return request({
  5. url: '/sc-service-du/ownBill/billList',
  6. method: 'get',
  7. params: query
  8. })
  9. }
  10. // 获取往来账款明细
  11. export function getBill(zbiId) {
  12. return request({
  13. url: '/sc-service-du/ownBill/'+ zbiId,
  14. method: 'get',
  15. })
  16. }
  17. // 获取往来账款发票
  18. export function getInvoice(zbiId) {
  19. return request({
  20. url: '/sc-service-du/ownBill/getInvoice/'+ zbiId,
  21. method: 'get',
  22. })
  23. }
  24. // 初始化往来账款信息
  25. export function addBill(data) {
  26. return request({
  27. url: '/sc-service-du/ownBill/add',
  28. method: 'post',
  29. data: data
  30. })
  31. }
  32. // 发票识别
  33. export function getInvoiceText(data) {
  34. return request({
  35. url: '/sc-service-du/ownBill/getInvoiceText',
  36. method: 'post',
  37. data: data
  38. })
  39. }
  40. // 发票验真
  41. export function invoiceVerification(data) {
  42. return request({
  43. url: '/sc-service-du/ownBill/invoiceVerification',
  44. method: 'post',
  45. data: data
  46. })
  47. }
  48. // 删除发票
  49. export function delInvoice(ziiIds) {
  50. return request({
  51. url: '/sc-service-du/ownBill/' + ziiIds,
  52. method: 'delete'
  53. })
  54. }
  55. // 上传账款附件
  56. export function uploadBillFile(data) {
  57. return request({
  58. url: '/sc-service-du/ownBill/uploadBillFile',
  59. method: 'post',
  60. data: data
  61. })
  62. }
  63. // 获取往来账款附件
  64. export function getFile(type, zbiId) {
  65. return request({
  66. url: '/sc-service-du/ownBill/getFile/'+ type + '/' + zbiId,
  67. method: 'get',
  68. })
  69. }
  70. // 删除发票
  71. export function delFile(ids) {
  72. return request({
  73. url: '/sc-service-du/ownBill/delFile/' + ids,
  74. method: 'delete'
  75. })
  76. }
  77. // 提交往来账款信息
  78. export function commitBill(zbiId) {
  79. return request({
  80. url: '/sc-service-du/ownBill/commitBill/' + zbiId,
  81. method: 'post'
  82. })
  83. }
  84. // 删除往来账款
  85. export function deleteBill(zbiIds) {
  86. return request({
  87. url: '/sc-service-du/ownBill/deleteBill/' + zbiIds,
  88. method: 'delete'
  89. })
  90. }