/*
 * @Author: chris
 * @Date: 2025-09-05 11:34:53
 * @LastEditors: chris
 * @LastEditTime: 2025-09-05 11:37:30
 */
import request from "@/utils/request";

// 查询果园列表
export function listPest(query) {
  return request({
    url: "/business/pest/list",
    method: "get",
    params: query,
  });
}

// 查询果园详细
export function getPest(id) {
  return request({
    url: "/business/pest/" + id,
    method: "get",
  });
}

// 新增果园
export function addPest(data) {
  return request({
    url: "/business/pest",
    method: "post",
    data: data,
  });
}

// 修改果园
export function updatePest(data) {
  return request({
    url: "/business/pest",
    method: "put",
    data: data,
  });
}

// 删除果园
export function delPest(id) {
  return request({
    url: "/business/pest/" + id,
    method: "delete",
  });
}

// 导出果园数据
export function exportPest(query) {
  return request({
    url: "/business/pest/export",
    method: "get",
    params: query,
    responseType: "blob",
  });
}
