import request from "@/utils/request";

//获取机具类型列表
export function getListByMaType(query) {
  return request({
    url: "/material-mall/type/getListByMaType",
    method: "get",
    params: query,
  });
}
//机具类型管理
export function getMaTypeList(query) {
  return request({
    url: "/material-mall/type/getMaTypeList",
    method: "get",
    params: query,
  });
}

//机具类型-详情
export function getMaType(typeId) {
  return request({
    url: "/material-mall/type/" + typeId,
    method: "get",
  });
}

//机具类型--新增
export function addMaType(data) {
  return request({
    url: "/material-mall/type",
    method: "post",
    data: data,
  });
}
// 机具类型--修改
export function updateMaType(data) {
  return request({
    url: "/material-mall/type",
    method: "put",
    data: data,
  });
}
//供应商管理--删除
export function delMaType(typeId) {
  return request({
    url: "/material-mall/type/" + typeId,
    method: "delete",
  });
}
export function updateLeasePriceApi(data) {
  return request({
    url: "/material-mall/type/updateLeasePrice",
    method: "post",
    data,
  });
}
