import { WeaTools } from "ecCom";
import { postExportFetch, postFetch } from "../util/request";

//薪酬统计维度下拉列表
export const dimensionGetForm = (params) => {
  return WeaTools.callApi("/api/bs/hrmsalary/report/statistics/dimension/getForm", "GET", params);
};
//获取自定义统计项目表单
export const statisticsItemGetform = (params) => {
  return WeaTools.callApi("/api/bs/hrmsalary/report/statistics/item/getForm", "GET", params);
};
//自定义统计项目列表
export const statisticsItemList = (params) => {
  return WeaTools.callApi("/api/bs/hrmsalary/report/statistics/item/list", "GET", params);
};
// 保存薪酬统计维度
export const dimensionSave = (params) => {
  return postFetch("/api/bs/hrmsalary/report/statistics/dimension/save", params);
};
// 薪酬统计维度列表
export const dimensionList = (params) => {
  return postFetch("/api/bs/hrmsalary/report/statistics/dimension/list", params);
};
// 删除薪酬统计维度
export const dimensionDelete = (params) => {
  return postFetch("/api/bs/hrmsalary/report/statistics/dimension/delete", params);
};

//保存薪酬统计报表
export const reportStatisticsReportList = (params) => {
  return postFetch("/api/bs/hrmsalary/report/statistics/report/list", params);
};
//删除薪酬统计报表
export const reportStatisticsReportDelete = (params) => {
  return postFetch("/api/bs/hrmsalary/report/statistics/report/delete", params);
};
//获取薪酬统计报表数据
export const reportStatisticsReportGetData = (params) => {
  return postFetch("/api/bs/hrmsalary/report/statistics/report/getData", params);
};
//保存自定义统计项目
export const reportStatisticsItemSave = (params) => {
  return postFetch("/api/bs/hrmsalary/report/statistics/item/save", params);
};
//保存数据范围及负责设置
export const reportStatisticsSaveSearchCondition = (params) => {
  return postFetch("/api/bs/hrmsalary/report/statistics/report/saveSearchCondition", params);
};
//删除自定义统计项目
export const reportStatisticsItemDelete = (params) => {
  return postFetch("/api/bs/hrmsalary/report/statistics/item/delete", params);
};
//获取薪酬统计报表查询条件
export const reportStatisticsGetSearchCondition = (params) => {
  return WeaTools.callApi("/api/bs/hrmsalary/report/statistics/report/getSearchCondition", "GET", params);
};
//分析图数据展示范围设置查询
export const queryRangeSetting = (params) => {
  return WeaTools.callApi("/api/bs/hrmsalary/report/statistics/echarts/queryRangeSetting", "GET", params);
};
//分析图数据展示范围设置删除
export const deleteRangeSetting = (params) => {
  return WeaTools.callApi("/api/bs/hrmsalary/report/statistics/echarts/deleteRangeSetting", "GET", params);
};
//分析图数据展示范围设置保存
export const saveRangeSetting = (params) => {
  return postFetch("/api/bs/hrmsalary/report/statistics/echarts/saveRangeSetting", params);
};
//员工列表
export const statisticsEmployeeList = (params) => {
  return postFetch("/api/bs/hrmsalary/report/statistics/employee/list", params);
};
//员工详情列表
export const statisticsEmployeeDetailList = (params) => {
  return postFetch("/api/bs/hrmsalary/report/statistics/employee/detailList", params);
};
//数据透视-列表查询
export const getDataPerspective = (params) => {
  return postFetch("/api/bs/hrmsalary/report/statistics/report/getDataPerspective", params);
};
//报表分享-确认分享
export const salaryStatisticsPushSendMsg = (params) => {
  return postFetch("/api/bs/salaryreport/salary/statistics/push/sendMsg", params);
};
//报表分享-表单数据
export const salaryStatisticsPushGetForm = (params) => {
  return WeaTools.callApi("/api/bs/salaryreport/salary/statistics/push/getForm", "GET", params);
};
//报表记录-全部撤回
export const salaryStatisticsPushcancelAll = (params) => {
  return WeaTools.callApi("/api/bs/salaryreport/salary/statistics/push/cancelAll", "GET", params);
};
//报表记录-撤回单条记录
export const salaryStatisticsPushcancel = (params) => {
  return WeaTools.callApi("/api/bs/salaryreport/salary/statistics/push/cancel", "GET", params);
};
//报表记录-列表数据
export const salaryStatisticsPushGetTable = (params) => {
  return postFetch("/api/bs/salaryreport/salary/statistics/push/getTable", params);
};
//报表记录-查看分享记录详情
export const salaryStatisticsPushGetDetail = (params) => {
  return postFetch("/api/bs/salaryreport/salary/statistics/push/getDetail", params);
};
//报表记录-追加被分享人
export const salaryStatisticsPushAddSharedSendMsg = (params) => {
  return postFetch("/api/bs/salaryreport/salary/statistics/push/addSharedSendMsg", params);
};
//薪酬统计维度-切换薪资项目
export const statisticsItemChangetab = (params) => {
  return WeaTools.callApi("/api/bs/hrmsalary/report/statistics/item/changeTab", "GET", params);
};
//报表记录-扩展人员维度显示值
export const saveExpandFieldSettings = (params) => {
  return postFetch("/api/bs/hrmsalary/report/statistics/dimension/saveExpandFieldSettings", params);
};
//报表记录-查询薪酬统计维度扩展字段设置
export const getExpandFieldSettings = (params) => {
  return WeaTools.callApi("/api/bs/hrmsalary/report/statistics/dimension/getExpandFieldSettings", "GET", params);
};
//报表记录-复制薪酬统计报表
export const statisticsReportDuplicate = (params) => {
  return WeaTools.callApi("/api/bs/hrmsalary/report/statistics/report/duplicate", "GET", params);
};
//薪酬统计报表-薪资明细列表
export const getSalaryList = (params) => {
  return postFetch("/api/bs/hrmsalary/report/statistics/employee/salaryList", params);
};
//薪酬统计报表-薪资明细列表总计行
export const getSalaryListSum = (params) => {
  return postFetch("/api/bs/hrmsalary/report/statistics/employee/salaryListSum", params);
};
// 薪酬统计报表-薪资明细导出
export const exportSalaryList = (params) => {
  return postExportFetch("/api/bs/hrmsalary/report/statistics/employee/exportSalaryList", params);
};
//薪酬统计报表-保存全局自定义列配置
export const savePageListSetting = (params) => {
  return postFetch("/api/bs/hrmsalary/common/pageList/save/setting", params);
};
//薪酬统计报表-保存页面模板
export const savePageListTemplate = (params) => {
  return postFetch("/api/bs/hrmsalary/common/pageList/template/save", params);
};
// 薪酬统计报表-导出模板示例下载
export const downloadPageListTemplate = (params) => {
  return postExportFetch("/api/bs/hrmsalary/common/pageList/template/file/download", params);
};
//薪酬统计报表-获取页面模板
export const getPageListTemplatelist = (params) => {
  return postFetch("/api/bs/hrmsalary/common/pageList/template/list", params);
};
//薪酬统计报表-切换个体页面模板
export const changePageListTemplate = (params) => {
  return postFetch("/api/bs/hrmsalary/common/pageList/template/change", params);
};
//薪酬统计报表-删除模板
export const deleteTemplatePageList = (params) => {
  return postFetch("/api/bs/hrmsalary/common/pageList/template/delete", params);
};
