Files
hazardousWaste_web/src/api/worn/material.js
2026-03-12 09:39:16 +08:00

52 lines
890 B
JavaScript

import request from '@/utils/request'
// 查询物料列表
export function listMaterial(query) {
return request({
url: '/worn/material/list',
method: 'get',
params: query
})
}
// 查询物料详细
export function getMaterial(id) {
return request({
url: '/worn/material/' + id,
method: 'get'
})
}
// 新增物料
export function addMaterial(data) {
return request({
url: '/worn/material',
method: 'post',
data: data
})
}
// 修改物料
export function updateMaterial(data) {
return request({
url: '/worn/material',
method: 'put',
data: data
})
}
// 删除物料
export function delMaterial(id) {
return request({
url: '/worn/material/' + id,
method: 'delete'
})
}
// 获取物料类型的树形结构
export function getMaterTypeTree() {
return request({
url: '/worn/type/tree' ,
method: 'get'
})
}