hailin
2023-07-21 17e62da2a097844b0f6f7a58926e7d0a40598d2c
src/api/standardLibrary.js
@@ -58,3 +58,95 @@
    method: 'get'
  })
}
// 规格详情页接口
// 根据规格id查询所有物料 specificationsId
export function getMaterialList(params) {
  return request({
    url: '/material/list',
    method: 'get',
    params
  })
}
// 根据物料id,获取对应的物料详情
export function getMaterialDetail(params) {
  return request({
    url: '/material/list_id',
    method: 'get',
    params
  })
}
// 添加物料
export function addMaterial(data) {
  return request({
    url: '/material/add',
    method: 'post',
    data
  })
}
// 编辑物料信息
export function updateMaterial(data) {
  return request({
    url: '/material/update',
    method: 'put',
    data
  })
}
// 删除物料信息
export function deleteMaterial(data) {
  return request({
    url: '/material/delete',
    method: 'delete',
    data
  })
}
// 根据物料id查询所有标准分类 specificationsId
export function getProductList(params) {
  return request({
    url: '/product/list',
    method: 'get',
    params
  })
}
// 添加标准分类
export function addProduct(data) {
  return request({
    url: '/product/add',
    method: 'post',
    data
  })
}
// 查询标准分类详情,对应的标准详情
export function getProductProductId(params) {
  return request({
    url: '/product/productId',
    method: 'get',
    params
  })
}
// 编辑子项目信息
export function updateProduct(data) {
  return request({
    url: '/product/update',
    method: 'put',
    data
  })
}
// 删除子项目信息
export function deleteProduct(data) {
  return request({
    url: '/product/delete',
    method: 'delete',
    data
  })
}