import http from "@/api";
const url = "/alienLawyer";

/**
 * @name 律师管理模块
 */
//////////////////////////// 律所信息管理 ////////////////////////////
// 律所列表
export const getLawFirmPage = (params: any) => {
  return http.get(url + `/lawyer/firm/getPaymentPageWithFirm`, params);
};
// 新增律所
export const addLawFirm = (params: any) => {
  return http.post(url + `/lawyer/firm/addLawFirm`, params);
};
// 删除律所
export const deleteLawFirm = (params: any) => {
  return http.delete(url + `/lawyer/firm/deleteLawFirm`, params);
};
// 编辑律所
export const editLawFirm = (params: any) => {
  return http.post(url + `/lawyer/firm/editLawFirm`, params);
};
//////////////////////////// 律师信息管理 ////////////////////////////
// 律师列表
export const getLawyerPage = (params: any) => {
  return http.get(url + `/lawyer/user/getLawyerList`, params);
};
// 新增律师
export const addLawyerUser = (params: any) => {
  return http.post(url + `/lawyer/user/addLawyerUser`, params);
};
// 删除律师
export const deleteLawyerUser = (params: any) => {
  return http.delete(url + `/lawyer/user/deleteLawyerUser`, params);
};
// 编辑律师
export const editLawyerUser = (params: any) => {
  return http.post(url + `/lawyer/user/editLawyerUser`, params);
};
// 推荐律师
export const recommendLawyer = (params: any) => {
  return http.post(url + `/lawyer/user/isRecommended`, params);
};
// 导出律师列表
export const exportLawyerList = (params: any) => {
  return http.get(url + `/lawyer/user/exportLawyerList`, params, { responseType: "blob" });
};
//////////////////////////// 法律场景管理 ////////////////////////////
// 法律问题场景 列表查询
export const getScenePage = (params: any) => {
  return http.get(url + `/lawyer/legalProblemScenar/getPage`, params);
};
// 新增法律问题场景
export const addScene = (params: any) => {
  return http.post(url + `/lawyer/legalProblemScenar/addLawyerLegalProblemScenar`, params);
};
//  删除法律问题场景
export const deleteScene = (params: any) => {
  return http.delete(url + `/lawyer/legalProblemScenar/deleteLawyerLegalProblemScenar`, params);
};
// 编辑法律问题场景
export const editScene = (params: any) => {
  return http.post(url + `/lawyer/legalProblemScenar/editLawyerLegalProblemScenar`, params);
};
// 设置法律问题场景状态
export const setSceneStatus = (params: any) => {
  return http.post(url + `/lawyer/legalProblemScenar/setStatus`, params);
};
//////////////////////////// 专业领域管理 ////////////////////////////
// 专业领域 列表查询
export const getExpertiseAreaPage = (params: any) => {
  return http.get(url + `/lawyer/expertiseArea/getPage`, params);
};
// 新增专业领域
export const addExpertiseArea = (params: any) => {
  return http.post(url + `/lawyer/expertiseArea/addExpertiseArea`, params);
};
// 删除专业领域
export const deleteExpertiseArea = (params: any) => {
  return http.delete(url + `/lawyer/expertiseArea/deleteExpertiseArea`, params);
};
// 编辑专业领域
export const editExpertiseArea = (params: any) => {
  return http.post(url + `/lawyer/expertiseArea/editExpertiseArea`, params);
};
//////////////////////////// 对账总览 ////////////////////////////

//  全部律所账单列表
export const getAllLawFirmList = (params: any) => {
  return http.get(url + `/lawyer/firm/reconciliation/getAllLawFirmList`, params);
};
//  单个律师账单列表
export const getLawyerList = (params: any) => {
  return http.get(url + `/lawyer/firm/reconciliation/getLawyerListWithName`, params);
};
//  账单详情
export const getLawyerDetails = (params: any) => {
  return http.get(url + `/lawyer/firm/reconciliation/getLawyerOrderList`, params);
};
//  数据总览
export const getOverview = (params: any) => {
  return http.get(url + `/lawyer/firm/reconciliation/getOverview`, params);
};

// 导出律所对账总览
export const exportAllLawFirmList = (params?: any) => {
  return http.get(url + `/lawyer/firm/reconciliation/exportAllLawFirmList`, params, { responseType: "blob" });
};
// 导出单个律所对账总览
export const exportLawyerListWithName = (params?: any) => {
  return http.get(url + `/lawyer/firm/reconciliation/exportLawyerListWithName`, params, { responseType: "blob" });
};

//////////////////////////// 举报审核 ////////////////////////////
export const getViolationPage = (params?: any) => {
  return http.get(url + `/lawyer/user-violation/page`, params);
};
export const violationApprove = (params?: any) => {
  return http.get(url + `/lawyer/user-violation/approve`, params);
};

//////////////////////////// 申诉审核 ////////////////////////////
export const getAppealPage = (params?: any) => {
  return http.get(url + `/commentAppeal/getPage`, params);
};
export const appealApprove = (params?: any) => {
  return http.post(url + `/commentAppeal/audit`, params);
};

//////////////////////////// 导入导出 ////////////////////////////
//  导入律所数据
export const importData = (params: any) => {
  return http.post(url + `/lawyer/firm/import`, params);
};
// 导入模板
export const downloadLawFirmTemplate = (params?: any) => {
  return http.get(url + `/lawyer/firm/downloadTemplate`, params, { responseType: "blob" });
};
// 导出律所数据
export const exportLawFirm = (params?: any) => {
  return http.get(url + `/lawyer/firm/export`, params, { responseType: "blob" });
};
// 导出律所对账数据
export const exportLawFirmReconciliation = (params?: any) => {
  return http.get(url + `/lawyer/firm/reconciliation/export`, params, { responseType: "blob" });
};
//////////////////////////// 律所 查询 收款账号的接口 ////////////////////////////
export const getSelectList = (params?: any) => {
  return http.get(url + `/lawyer/firm/getList`, params);
};
