import fetch from "@/utils/fetch";

export default {
  // ----------------------------科室管理--------------------
  getDepartmentManagementList(data) {
    // 获取所有科室管理信息列表
    return fetch({
      url: "/DepartmentManagement/getDepartmentManagementList",
      method: "POST",
      data,
    });
  },

  getDepartmentAndChildren(data) {
    // 获取科室级联格式列表
    return fetch({
      url: "/DepartmentManagement/getDepartmentAndChildren",
      method: "POST",
      data,
    });
  },

  getDepartmentAndChildrenAndUser(data) {
    // 获取科室和科室下专家级联格式列表
    return fetch({
      url: "/DepartmentManagement/getDepartmentAndChildrenAndUser",
      method: "POST",
      data,
    });
  },

  addOrUpdateDepartmentManagement(data) {
    // 增加或者修改科室
    return fetch({
      url: "/DepartmentManagement/addOrUpdateDepartmentManagement",
      method: "POST",
      data,
    });
  },

  getDepartmentManagementById(params) {
    // 查询一条科室信息
    return fetch({
      url: "/DepartmentManagement/getDepartmentManagementById",
      method: "GET",
      params,
    });
  },

  deleteDepartmentManagementById(params) {
    // 删除一条科室信息
    return fetch({
      url: "/DepartmentManagement/deleteDepartmentManagementById",
      method: "GET",
      params,
    });
  },
};
