import request from "../../common/request"
import { PSI_MANAGEMANT as prefix } from "@/api/AppPath";

export default class LossService {
  list(params) {
    return request({
      url: prefix + "/psi/loss/list",
      method: "get",
      params: params,
    });
  }

  save(data) {
    return request({
      url: prefix + "/psi/loss/save",
      method: "post",
      data: data,
    });
  }

  findById(id) {
    return request({
      url: prefix + "/psi/loss/findById",
      method: "get",
      params: { id: id },
    });
  }

  updateStatusById(data) {
    return request({
      url: prefix + "/psi/loss/updateStatusById",
      method: "post",
      data: data,
    });
  }

  remove(id) {
    return request({
      url: prefix + "/psi/loss/remove",
      method: "get",
      params: { id: id },
    });
  }

  getLossByTradeName(params) {
    return request({
      url: prefix + "/psi/loss/getLossByTradeName",
      method: "get",
      params: params,
    });
  }
}
