index.js 2.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125
  1. import https from "@/plugins/luch-request_0.0.7/request";
  2. export const print = data => {
  3. return https.get("/product/print", data);
  4. };
  5. export const batchChangeAddPrice = data => {
  6. return https.post("/product/batch-change-add-price", data);
  7. };
  8. export const productList = data => {
  9. return https.get("/product/list", data);
  10. };
  11. //获取拼音首字母缩写 shish 20210707
  12. export const py = data => {
  13. return https.get("/product/py", data);
  14. };
  15. export const getGhsProductDetail = data => {
  16. return https.get('/product/ghs-product-detail', data)
  17. }
  18. /** *
  19. * 分类及花材数据(库存预警、库存管理共用这个接口)
  20. * @parmas py 花材拼音
  21. * @parmas type 库存预警时,固定为waring,其他情况不传或者传空
  22. */
  23. export const getProductDataApi = data => {
  24. return https.get("/product/index", data);
  25. };
  26. /** *
  27. * 获取所有分类(包括常用、全部)(暂不用)
  28. * @parmas py 花材拼音
  29. * @parmas type 库存预警时,固定为waring,其他情况不传或者传空
  30. */
  31. export const getAllProductDataApi = data => {
  32. return https.get("/product/list", data);
  33. };
  34. /**
  35. * 自动调价
  36. * productId
  37. */
  38. export const autoPriceByIdApi = data => {
  39. return https.post("/product/auto-price", data);
  40. };
  41. //添加花材
  42. export const addProduct = data => {
  43. return https.post("/product/add", data);
  44. };
  45. //修改花材
  46. export const updateProduct = data => {
  47. return https.post("/product/update", data);
  48. };
  49. export const changePriceByIdApi = data => {
  50. return https.post("/product/change-price", data);
  51. };
  52. /** *
  53. * 培训班开单列表(课程开单)
  54. */
  55. export const getPxClassDataApi = data => {
  56. return https.get("/px-class/list", data);
  57. };
  58. /** *
  59. * 商品开单列表
  60. */
  61. export const getGoodsDataApi = data => {
  62. return https.get("/goods/index", data);
  63. };
  64. /** *
  65. * 培训班详情
  66. */
  67. export const pxClassDetail = data => {
  68. return https.get("/px-class/detail", data);
  69. };
  70. /** *
  71. * 修改培训班
  72. */
  73. export const pxClassUpdate = data => {
  74. return https.get("/px-class/update", data);
  75. };
  76. /** *
  77. * 新增培训班
  78. */
  79. export const pxClassAdd = data => {
  80. return https.get("/px-class/add", data);
  81. };
  82. /** *
  83. * 删除培训班
  84. */
  85. export const pxClassDel = data => {
  86. return https.get("/px-class/del", data);
  87. };
  88. /** *
  89. * 供货商花材列表(进店开单) 【采购开单】
  90. */
  91. export const getGhsProductList = data => {
  92. return https.get('/product/ghs-item', data)
  93. }
  94. export const getGhsProductListV2 = data => {
  95. return https.get('/product/ghs-item-v2', data)
  96. }
  97. export const getProductDetail = data => {
  98. return https.get("/product/detail", data);
  99. };
  100. //批量改价
  101. export const batchChangePrice = data => {
  102. return https.post("/product/batch-change-price", data);
  103. };
  104. //生成价格表 shish 20210922
  105. export const generatePriceTable = data => {
  106. return https.get("/product/generate-price-table", data);
  107. };