price.js 3.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104
  1. import { get, uget, post, upost, parmasPost, put, deletes } from '@/http/index'
  2. // 查询装备价格详细
  3. export const getEquipmentPrice = async (data) => {
  4. return await uget('/system/equipmentPrice/', data)
  5. }
  6. // 新增装备价格
  7. export const addEquipmentPrice = async (data) => {
  8. return await post('/system/equipmentPrice/', data)
  9. }
  10. // 修改装备价格
  11. export const updateEquipmentPrice = async (data) => {
  12. return await put('/system/equipmentPrice', data)
  13. }
  14. // 删除装备价格
  15. export const delEquipmentPrice = async (data) => {
  16. return await deletes('/system/equipmentPrice/', data)
  17. }
  18. // 导出装备价格
  19. export const exportEquipmentPrice = async (data) => {
  20. return await get('/system/equipmentPrice/export', data)
  21. }
  22. // 根据装备型号ID查询装备价格列表
  23. export const queryEquipmentPricesByEquipmentModelId = async (data) => {
  24. return await parmasPost('/system/equipmentPrice/queryEquipmentPricesByEquipmentModelId', data)
  25. }
  26. // 查询器材价格详细
  27. export const getMaterialtPrice = async (data) => {
  28. return await uget('/system/materialPrice/', data)
  29. }
  30. // 新增器材价格
  31. export const addMaterialtPrice = async (data) => {
  32. return await post('/system/materialPrice', data)
  33. }
  34. // 修改器材价格
  35. export const updateMaterialtPrice = async (data) => {
  36. return await put('/system/materialPrice', data)
  37. }
  38. // 删除器材价格
  39. export const delMaterialtPrice = async (data) => {
  40. return await deletes('/system/materialPrice/', data)
  41. }
  42. // 导出器材价格
  43. export const exporMaterialtPrice = async (data) => {
  44. return await get('/system/materialPrice/export', data)
  45. }
  46. // 根据器材型号ID查询器材价格列表
  47. export const queryMaterialPricesByMaterialModelId = async (data) => {
  48. return await parmasPost('/system/materialPrice/queryMaterialPricesByMaterialModelId/', data)
  49. }
  50. // 查询设备价格详细
  51. export const getDevicePrice = async (data) => {
  52. return await uget('/system/devicePrice/', data)
  53. }
  54. // 新增设备价格
  55. export const addDevicePrice = async (data) => {
  56. return await post('/system/devicePrice', data)
  57. }
  58. // 修改设备价格
  59. export const updateDevicePrice = async (data) => {
  60. return await put('/system/devicePrice', data)
  61. }
  62. // 删除设备价格
  63. export const delDevicePrice = async (data) => {
  64. return await deletes('/system/devicePrice/', data)
  65. }
  66. // 导出设备价格
  67. export const exportDevicePrice = async (data) => {
  68. return await get('/system/devicePrice/export', data)
  69. }
  70. // 根据设备型号ID查询设备价格列表
  71. export const queryDevicePricesByDeviceModelId = async (data) => {
  72. return await parmasPost('/system/devicePrice/queryDevicePricesByDeviceModelId/', data)
  73. }
  74. // 下载装备价格数据模板
  75. export function downLoadEquipmentFile() {
  76. window.open(process.env.VUE_APP_BASE_API + '/system/equipmentPrice/downLoadFile')
  77. }
  78. // 下载器材价格数据模板
  79. export function downLoadMaterialFile() {
  80. window.open(process.env.VUE_APP_BASE_API + '/system/materialPrice/downLoadFile')
  81. }
  82. // 下载设备价格数据模板
  83. export function downLoadDeviceFile() {
  84. window.open(process.env.VUE_APP_BASE_API + '/system/devicePrice/downLoadFile')
  85. }