Merge branch 'release/2.9.42309.01-个税' into custom-昂立/薪资账套配置流程审批地址
# Conflicts: # pc4mobx/hrmSalary/pages/ledgerPage/components/ledgerSlide.js
This commit is contained in:
commit
06483828b8
|
|
@ -137,3 +137,15 @@ export const getTableRecordDate = ({ url, ...params }) => {
|
|||
return postFetch(url, params);
|
||||
};
|
||||
|
||||
//个税-在线获取
|
||||
export const onlineRequest = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/addUpDeduction/online/request", params);
|
||||
};
|
||||
|
||||
//个税-在线获取结果查询
|
||||
export const onlineFeedback = () => {
|
||||
return fetch("/api/bs/hrmsalary/addUpDeduction/online/feedback", {
|
||||
method: "GET",
|
||||
mode: "cors"
|
||||
}).then((res) => res.json());
|
||||
};
|
||||
|
|
|
|||
|
|
@ -121,3 +121,7 @@ export const deleteAllAddUpSituation = (params) => {
|
|||
export const getAddUpSituation = (params) => {
|
||||
return postFetch('/api/bs/hrmsalary/addUpSituation/getAddUpSituation', params);
|
||||
}
|
||||
//个税相关-在线获取
|
||||
export const onlineActualAddUpAdvanceTax = (params) => {
|
||||
return postFetch('/api/bs/hrmsalary/addUpSituation/online/actualAddUpAdvanceTax', params);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,68 +1,241 @@
|
|||
import { WeaTools } from 'ecCom';
|
||||
import { postFetch } from '../util/request';
|
||||
import { WeaTools } from "ecCom";
|
||||
import { postFetch } from "../util/request";
|
||||
|
||||
//个税申报表-个税申报表列表
|
||||
export const getDeclareList = params => {
|
||||
return fetch('/api/bs/hrmsalary/taxdeclaration/list', {
|
||||
method: 'POST',
|
||||
mode: 'cors',
|
||||
headers: {
|
||||
'Content-Type': 'application/json'
|
||||
},
|
||||
body: JSON.stringify(params)
|
||||
}).then(res => res.json())
|
||||
}
|
||||
return fetch("/api/bs/hrmsalary/taxdeclaration/list", {
|
||||
method: "POST",
|
||||
mode: "cors",
|
||||
headers: {
|
||||
"Content-Type": "application/json"
|
||||
},
|
||||
body: JSON.stringify(params)
|
||||
}).then(res => res.json());
|
||||
};
|
||||
|
||||
//个税申报表-个税申报表表单
|
||||
export const getDeclareForm = params => {
|
||||
return WeaTools.callApi('/api/bs/hrmsalary/taxdeclaration/getForm', 'get', params);
|
||||
}
|
||||
return WeaTools.callApi("/api/bs/hrmsalary/taxdeclaration/getForm", "get", params);
|
||||
};
|
||||
|
||||
//个税申报表-个税申报表生成
|
||||
export const saveDeclare = params => {
|
||||
return fetch('/api/bs/hrmsalary/taxdeclaration/save', {
|
||||
method: 'POST',
|
||||
mode: 'cors',
|
||||
headers: {
|
||||
'Content-Type': 'application/json'
|
||||
},
|
||||
body: JSON.stringify(params)
|
||||
}).then(res => res.json())
|
||||
}
|
||||
return fetch("/api/bs/hrmsalary/taxdeclaration/save", {
|
||||
method: "POST",
|
||||
mode: "cors",
|
||||
headers: {
|
||||
"Content-Type": "application/json"
|
||||
},
|
||||
body: JSON.stringify(params)
|
||||
}).then(res => res.json());
|
||||
};
|
||||
|
||||
//个税申报表-个税申报表相关信息
|
||||
export const getDeclareInfo = params => {
|
||||
return WeaTools.callApi('/api/bs/hrmsalary/taxdeclaration/getTaxDeclarationInfo', 'get', params);
|
||||
}
|
||||
return WeaTools.callApi("/api/bs/hrmsalary/taxdeclaration/getTaxDeclarationInfo", "get", params);
|
||||
};
|
||||
|
||||
// 个税申报表详情列表
|
||||
export const getDetailList = params => {
|
||||
return fetch('/api/bs/hrmsalary/taxdeclaration/detail/list', {
|
||||
method: 'POST',
|
||||
mode: 'cors',
|
||||
headers: {
|
||||
'Content-Type': 'application/json'
|
||||
},
|
||||
body: JSON.stringify(params)
|
||||
}).then(res => res.json())
|
||||
}
|
||||
return fetch("/api/bs/hrmsalary/taxdeclaration/detail/list", {
|
||||
method: "POST",
|
||||
mode: "cors",
|
||||
headers: {
|
||||
"Content-Type": "application/json"
|
||||
},
|
||||
body: JSON.stringify(params)
|
||||
}).then(res => res.json());
|
||||
};
|
||||
|
||||
|
||||
// 个税申报表导出
|
||||
export const exportSalaryArchive = (id = "") => {
|
||||
fetch('/api/bs/hrmsalary/taxdeclaration/export?taxDeclarationId=' + id).then(res => res.blob().then(blob => {
|
||||
var filename=`个税申报表.xlsx`
|
||||
var a = document.createElement('a');
|
||||
var url = window.URL.createObjectURL(blob);
|
||||
a.href = url;
|
||||
a.download = filename;
|
||||
a.click();
|
||||
window.URL.revokeObjectURL(url);
|
||||
}))
|
||||
}
|
||||
fetch("/api/bs/hrmsalary/taxdeclaration/export?taxDeclarationId=" + id).then(res => res.blob().then(blob => {
|
||||
var filename = `个税申报表.xlsx`;
|
||||
var a = document.createElement("a");
|
||||
var url = window.URL.createObjectURL(blob);
|
||||
a.href = url;
|
||||
a.download = filename;
|
||||
a.click();
|
||||
window.URL.revokeObjectURL(url);
|
||||
}));
|
||||
};
|
||||
//个税申报表-撤回申报
|
||||
export const withDrawTaxDeclaration = (params) => {
|
||||
return postFetch('/api/bs/hrmsalary/taxdeclaration/withDrawTaxDeclaration', params);
|
||||
}
|
||||
return postFetch("/api/bs/hrmsalary/taxdeclaration/withDrawTaxDeclaration", params);
|
||||
};
|
||||
|
||||
//人员信息报送-个税扣缴义务人列表
|
||||
export const taxAgentDeclareList = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/employeedeclare/taxAgentDeclareList", params);
|
||||
};
|
||||
//人员信息报送-全部人员列表
|
||||
export const employeedeclareList = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/employeedeclare/list", params);
|
||||
};
|
||||
//人员信息报送-本月新增人员列表
|
||||
export const employeedeclareList4Add = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/employeedeclare/list4Add", params);
|
||||
};
|
||||
//人员信息报送-本月信息变动列表
|
||||
export const employeedeclareList4Update = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/employeedeclare/list4Update", params);
|
||||
};
|
||||
|
||||
//人员信息报送-本月报送失败人员列表
|
||||
export const employeedeclareList4Fail = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/employeedeclare/list4Fail", params);
|
||||
};
|
||||
|
||||
//人员报送-刷新数据
|
||||
export const employeedeclareRefresh = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/employeedeclare/refresh", params);
|
||||
};
|
||||
|
||||
//人员报送-获取报送结果反馈
|
||||
export const getDeclareFeedback = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/employeedeclare/getDeclareFeedback", params);
|
||||
};
|
||||
|
||||
//人员报送-获取整体的报送情况
|
||||
export const getEmployeeDeclareInfo = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/employeedeclare/getDeclareInfo", params);
|
||||
};
|
||||
|
||||
//人员报送-后端业务逻辑是否已经完成
|
||||
export const employeedeclareGetRate = params => {
|
||||
return WeaTools.callApi("/api/bs/hrmsalary/employeedeclare/getRate", "GET", params);
|
||||
};
|
||||
|
||||
//人员报送-获取新建或编辑的表单
|
||||
export const employeedeclareGetForm = params => {
|
||||
return WeaTools.callApi("/api/bs/hrmsalary/employeedeclare/getForm", "GET", params);
|
||||
};
|
||||
|
||||
//人员报送-新增人员/编辑人员保存
|
||||
export const getEmployeeSave = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/employeedeclare/save", params);
|
||||
};
|
||||
|
||||
//人员报送-删除
|
||||
export const employeeDelete = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/employeedeclare/delete", params);
|
||||
};
|
||||
|
||||
//人员报送-全部报送
|
||||
export const employeedeclareDeclare = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/employeedeclare/declare", params);
|
||||
};
|
||||
|
||||
//个税在线对接-获取个税申报记录下的个税申报表TAB
|
||||
export const getTaxDeclarationTab = params => {
|
||||
return WeaTools.callApi("/api/bs/hrmsalary/taxdeclaration/getTaxDeclarationTab", "GET", params);
|
||||
};
|
||||
|
||||
//个税在线对接-个税申报表是否已经生成
|
||||
export const taxdeclarationGetRate = params => {
|
||||
return WeaTools.callApi("/api/bs/hrmsalary/taxdeclaration/getRate", "GET", params);
|
||||
};
|
||||
|
||||
//人员报送-刷新数据
|
||||
export const taxdeclarationRefreshData = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/taxdeclaration/refreshData", params);
|
||||
};
|
||||
|
||||
//人员报送-在线申报
|
||||
export const taxdeclarationDeclare = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/taxdeclaration/declare", params);
|
||||
};
|
||||
//个税申报表申报数据-人员未报送列表
|
||||
export const taxdeclarationEmployeeList4NotDeclare = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/taxdeclaration/employee/list4NotDeclare", params);
|
||||
};
|
||||
//个税申报表申报数据-报送人员无申报数据列表
|
||||
export const taxdeclarationEmployeeList4NoValue = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/taxdeclaration/employee/list4NoValue", params);
|
||||
};
|
||||
//个税申报表申报数据-申报失败列表
|
||||
export const taxdeclarationEmployeeList4Fail = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/taxdeclaration/employee/list4Fail", params);
|
||||
};
|
||||
//个税申报表申报数据-删除个税申报表
|
||||
export const taxdeclarationDelete = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/taxdeclaration/delete", params);
|
||||
};
|
||||
|
||||
//个税申报表申报数据-获取在线申报反馈
|
||||
export const taxdeclarationGetDeclareFeedback = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/taxdeclaration/getDeclareFeedback", params);
|
||||
};
|
||||
|
||||
//个税申报表申报数据-更正申报
|
||||
export const taxdeclaratioUpdateDeclare = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/taxdeclaration/updateDeclare", params);
|
||||
};
|
||||
|
||||
//个税申报表申报数据-作废申报
|
||||
export const taxdeclaratioUpdateCancel = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/taxdeclaration/cancel", params);
|
||||
};
|
||||
|
||||
//个税申报表申报数据-获取作废反馈
|
||||
export const taxdeclaratioGetCancelFeedback = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/taxdeclaration/getCancelFeedback", params);
|
||||
};
|
||||
|
||||
//个税申报表申报数据-三方协议缴款反馈
|
||||
export const taxPaymentAgreementPayFeedback = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/taxPayment/agreement/pay/feedback", params);
|
||||
};
|
||||
|
||||
//个税申报表申报数据-应缴税额查询
|
||||
export const taxPaymentTaxAmount = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/taxPayment/tax/amount", params);
|
||||
};
|
||||
|
||||
//个税申报表申报数据-获取企业的三方信息
|
||||
export const taxPaymentgetAgreement = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/taxPayment/getAgreement", params);
|
||||
};
|
||||
|
||||
//个税申报表申报数据-获取企业的三方信息查询反馈
|
||||
export const taxPaymentgetAgreementFeedback = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/taxPayment/getAgreementFeedback", params);
|
||||
};
|
||||
|
||||
//个税申报表申报数据-同步缴款状态
|
||||
export const taxPaymentVoucherStatusSync = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/taxPayment/voucher/status/sync", params);
|
||||
};
|
||||
|
||||
//个税申报表申报数据-三方缴款,最终支付
|
||||
export const taxPaymentAgreemenPay = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/taxPayment/agreement/pay", params);
|
||||
};
|
||||
|
||||
//个税申报表申报数据-开具企业缴税完税证明
|
||||
export const taxPaymentWithheldVoucherGet = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/taxPayment/withheldVoucher/get", params);
|
||||
};
|
||||
|
||||
//个税申报表申报数据-作废缴款凭证
|
||||
export const taxPaymentVoucherCancel = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/taxPayment/voucher/cancel", params);
|
||||
};
|
||||
|
||||
//个税申报表申报数据-缴款凭证打印
|
||||
export const taxPaymentVoucherPrint = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/taxPayment/voucher/print", params);
|
||||
};
|
||||
|
||||
//个税申报表申报数据-缴款凭证打印反馈
|
||||
export const taxPaymentVoucherPrintFeedback = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/taxPayment/voucher/print/feedback", params);
|
||||
};
|
||||
|
||||
//个税申报表申报数据-缴款凭证打印反馈
|
||||
export const taxdeclarationUpdateIcon = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/taxdeclaration/updateIcon", params);
|
||||
};
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -1,4 +1,5 @@
|
|||
import { WeaTools } from "ecCom";
|
||||
import { postFetch } from "../util/request";
|
||||
|
||||
// form基础数据
|
||||
export const getBaseForm = (params) => {
|
||||
|
|
@ -19,3 +20,8 @@ export const getCondition = (params) => {
|
|||
export const getTableDatas = (params) => {
|
||||
return WeaTools.callApi("/api/demo03/weatableDemo", "GET", params);
|
||||
};
|
||||
|
||||
// 薪资账套-浏览按钮数据
|
||||
export const commonBrowserData = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/common/browser/data", params);
|
||||
};
|
||||
|
|
|
|||
|
|
@ -0,0 +1,55 @@
|
|||
import { WeaTools } from "ecCom";
|
||||
import { postFetch } from "../util/request";
|
||||
|
||||
//智能算薪-计费配置编辑表单
|
||||
export const apiflowBillingConfigGet = (params) => {
|
||||
return WeaTools.callApi("/api/bs/hrmsalary/taxdeclaration/apiflow/billing/config/get", "GET", params);
|
||||
};
|
||||
//智能算薪-查询计费配置开关状态
|
||||
export const apiflowBillingConfigStatus = (params) => {
|
||||
return WeaTools.callApi("/api/bs/hrmsalary/taxdeclaration/apiflow/billing/config/status", "GET", params);
|
||||
};
|
||||
//智能算薪-计费配置保存
|
||||
export const apiflowBillingConfigSave = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/taxdeclaration/apiflow/billing/config/save", params);
|
||||
};
|
||||
//智能算薪-计费配置开关
|
||||
export const apiflowBillingConfigEnable = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/taxdeclaration/apiflow/billing/config/enable", params);
|
||||
};
|
||||
//智能算薪-流量不足提醒初始化表单
|
||||
export const apiflowWarnConfigGetForm = (params) => {
|
||||
return WeaTools.callApi("/api/bs/hrmsalary/taxdeclaration/apiflow/warn/config/getForm", "GET", params);
|
||||
};
|
||||
//智能算薪-接口流量使用记录
|
||||
export const apiflowRecordList = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/taxdeclaration/apiflow/record/list", params);
|
||||
};
|
||||
//智能算薪-接口流量使用记录
|
||||
export const apiflowStatisticsInfo = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/taxdeclaration/apiflow/statistics/info", params);
|
||||
};
|
||||
//智能算薪-接口流量使用明细
|
||||
export const apiflowStatisticsList = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/taxdeclaration/apiflow/statistics/list", params);
|
||||
};
|
||||
//智能算薪-流量不足提醒编辑或保存
|
||||
export const apiflowWarnConfigSave = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/taxdeclaration/apiflow/warn/config/save", params);
|
||||
};
|
||||
//智能算薪-流量不足提醒对象列表
|
||||
export const apiflowWarnReceiverList = (params) => {
|
||||
return WeaTools.callApi("/api/bs/hrmsalary/taxdeclaration/apiflow/warn/receiver/list", "GET", params);
|
||||
};
|
||||
//智能算薪-编辑保存流量不足提醒对象
|
||||
export const apiflowWarnReceiverSave = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/taxdeclaration/apiflow/warn/receiver/save", params);
|
||||
};
|
||||
//智能算薪-编辑保存流量不足提醒对象
|
||||
export const apiflowWarnReceiverGetForm = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/taxdeclaration/apiflow/warn/receiver/getForm", params);
|
||||
};
|
||||
//智能算薪-流量不足提醒对象-删除
|
||||
export const apiflowWarnReceiverDelete = (params) => {
|
||||
return WeaTools.callApi("/api/bs/hrmsalary/taxdeclaration/apiflow/warn/receiver/delete", "GET", params);
|
||||
};
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
import { WeaTools } from 'ecCom';
|
||||
import { WeaTools } from "ecCom";
|
||||
|
||||
/**
|
||||
* 薪资项目api
|
||||
|
|
@ -7,171 +7,171 @@ import { WeaTools } from 'ecCom';
|
|||
|
||||
// 薪资项目-获取列表
|
||||
export const getItemList = params => {
|
||||
return fetch('/api/bs/hrmsalary/salaryitem/list', {
|
||||
method: 'POST',
|
||||
mode: 'cors',
|
||||
headers: {
|
||||
'Content-Type': 'application/json'
|
||||
},
|
||||
body: JSON.stringify(params)
|
||||
}).then(res => res.json())
|
||||
return fetch("/api/bs/hrmsalary/salaryitem/list", {
|
||||
method: "POST",
|
||||
mode: "cors",
|
||||
headers: {
|
||||
"Content-Type": "application/json"
|
||||
},
|
||||
body: JSON.stringify(params)
|
||||
}).then(res => res.json());
|
||||
};
|
||||
|
||||
//薪资项目的高级搜索
|
||||
export const getSaCondition = params => {
|
||||
return WeaTools.callApi('/api/bs/hrmsalary/salaryitem/getSearchCondition', 'GET', params);
|
||||
return WeaTools.callApi("/api/bs/hrmsalary/salaryitem/getSearchCondition", "GET", params);
|
||||
};
|
||||
|
||||
//数据源列表字典项
|
||||
export const formulaDatasourceList = params => {
|
||||
return WeaTools.callApi('/api/bs/hrmsalary/formula/datasource/list', 'GET', params);
|
||||
return WeaTools.callApi("/api/bs/hrmsalary/formula/datasource/list", "GET", params);
|
||||
};
|
||||
|
||||
//薪资项目-系统薪资项目列表
|
||||
export const getSysItemList = params => {
|
||||
return fetch('/api/bs/hrmsalary/salaryitem/sysList', {
|
||||
method: 'POST',
|
||||
mode: 'cors',
|
||||
headers: {
|
||||
'Content-Type': 'application/json'
|
||||
},
|
||||
body: JSON.stringify(params)
|
||||
}).then(res => res.json())
|
||||
return fetch("/api/bs/hrmsalary/salaryitem/sysList", {
|
||||
method: "POST",
|
||||
mode: "cors",
|
||||
headers: {
|
||||
"Content-Type": "application/json"
|
||||
},
|
||||
body: JSON.stringify(params)
|
||||
}).then(res => res.json());
|
||||
};
|
||||
|
||||
//系统薪资项目的高级搜索
|
||||
export const getSysSaCondition = params => {
|
||||
return WeaTools.callApi('/api/bs/hrmsalary/salaryitem/getSysSearchCondition', 'GET', params);
|
||||
}
|
||||
return WeaTools.callApi("/api/bs/hrmsalary/salaryitem/getSysSearchCondition", "GET", params);
|
||||
};
|
||||
|
||||
//薪资项目-批量删除薪资项目
|
||||
export const deleteItem = params => {
|
||||
return fetch('/api/bs/hrmsalary/salaryitem/delete', {
|
||||
method: 'POST',
|
||||
mode: 'cors',
|
||||
headers: {
|
||||
'Content-Type': 'application/json'
|
||||
},
|
||||
body: JSON.stringify(params)
|
||||
}).then(res => res.json())
|
||||
}
|
||||
return fetch("/api/bs/hrmsalary/salaryitem/delete", {
|
||||
method: "POST",
|
||||
mode: "cors",
|
||||
headers: {
|
||||
"Content-Type": "application/json"
|
||||
},
|
||||
body: JSON.stringify(params)
|
||||
}).then(res => res.json());
|
||||
};
|
||||
|
||||
//薪资项目-批量删除列表
|
||||
export const deleteItemList = params => {
|
||||
return fetch('/api/bs/hrmsalary/salaryitem/listCanDelete', {
|
||||
method: 'POST',
|
||||
mode: 'cors',
|
||||
headers: {
|
||||
'Content-Type': 'application/json'
|
||||
},
|
||||
body: JSON.stringify(params)
|
||||
}).then(res => res.json())
|
||||
}
|
||||
return fetch("/api/bs/hrmsalary/salaryitem/listCanDelete", {
|
||||
method: "POST",
|
||||
mode: "cors",
|
||||
headers: {
|
||||
"Content-Type": "application/json"
|
||||
},
|
||||
body: JSON.stringify(params)
|
||||
}).then(res => res.json());
|
||||
};
|
||||
|
||||
//薪资项目-新增薪资项目
|
||||
export const saveItem = params => {
|
||||
delete params.formulaContent
|
||||
return fetch('/api/bs/hrmsalary/salaryitem/save', {
|
||||
method: 'POST',
|
||||
mode: 'cors',
|
||||
headers: {
|
||||
'Content-Type': 'application/json'
|
||||
},
|
||||
body: JSON.stringify(params)
|
||||
}).then(res => res.json())
|
||||
}
|
||||
delete params.formulaContent;
|
||||
return fetch("/api/bs/hrmsalary/salaryitem/save", {
|
||||
method: "POST",
|
||||
mode: "cors",
|
||||
headers: {
|
||||
"Content-Type": "application/json"
|
||||
},
|
||||
body: JSON.stringify(params)
|
||||
}).then(res => res.json());
|
||||
};
|
||||
|
||||
//薪资项目-更新薪资项目
|
||||
export const updateItem = params => {
|
||||
return WeaTools.callApi('/api/bs/hrmsalary/salaryitem/update', 'POST', params);
|
||||
}
|
||||
return WeaTools.callApi("/api/bs/hrmsalary/salaryitem/update", "POST", params);
|
||||
};
|
||||
|
||||
//薪资项目-薪资项目详情
|
||||
export const getItemForm = params => {
|
||||
return WeaTools.callApi('/api/bs/hrmsalary/salaryitem/getSalaryForm', 'GET', params);
|
||||
}
|
||||
return WeaTools.callApi("/api/bs/hrmsalary/salaryitem/getSalaryForm", "GET", params);
|
||||
};
|
||||
|
||||
//薪资项目-添加系统薪资项目
|
||||
export const saveSysItem = params => {
|
||||
return fetch('/api/bs/hrmsalary/salaryitem/saveSys', {
|
||||
method: 'POST',
|
||||
mode: 'cors',
|
||||
headers: {
|
||||
'Content-Type': 'application/json'
|
||||
},
|
||||
body: JSON.stringify(params)
|
||||
}).then(res => res.json())
|
||||
}
|
||||
return fetch("/api/bs/hrmsalary/salaryitem/saveSys", {
|
||||
method: "POST",
|
||||
mode: "cors",
|
||||
headers: {
|
||||
"Content-Type": "application/json"
|
||||
},
|
||||
body: JSON.stringify(params)
|
||||
}).then(res => res.json());
|
||||
};
|
||||
|
||||
//获取薪资项目可选的类型(与属性有联动)
|
||||
export const getItemTypeOption = params => {
|
||||
return WeaTools.callApi('/api/bs/hrmsalary/salaryitem/listSalaryItemTypeOption', 'GET', params);
|
||||
}
|
||||
return WeaTools.callApi("/api/bs/hrmsalary/salaryitem/listSalaryItemTypeOption", "GET", params);
|
||||
};
|
||||
//获取公式描述
|
||||
export const getFormulaDes = params => {
|
||||
return WeaTools.callApi('/api/bs/hrmsalary/formula/des', 'GET', params);
|
||||
}
|
||||
return WeaTools.callApi("/api/bs/hrmsalary/formula/des", "GET", params);
|
||||
};
|
||||
|
||||
// *** 公式 start ***
|
||||
// 获取公式变量类型
|
||||
export const formualSearchGroup = params => {
|
||||
return fetch('/api/bs/hrmsalary/formula/search/group', {
|
||||
method: 'POST',
|
||||
mode: 'cors',
|
||||
headers: {
|
||||
'Content-Type': 'application/json'
|
||||
},
|
||||
body: JSON.stringify(params)
|
||||
}).then(res => res.json())
|
||||
}
|
||||
return fetch("/api/bs/hrmsalary/formula/search/group", {
|
||||
method: "POST",
|
||||
mode: "cors",
|
||||
headers: {
|
||||
"Content-Type": "application/json"
|
||||
},
|
||||
body: JSON.stringify(params)
|
||||
}).then(res => res.json());
|
||||
};
|
||||
|
||||
//获取公式变量字段
|
||||
export const formualSearchField = params => {
|
||||
return fetch('/api/bs/hrmsalary/formula/search/field', {
|
||||
method: 'POST',
|
||||
mode: 'cors',
|
||||
headers: {
|
||||
'Content-Type': 'application/json'
|
||||
},
|
||||
body: JSON.stringify(params)
|
||||
}).then(res => res.json())
|
||||
}
|
||||
return fetch("/api/bs/hrmsalary/formula/search/field", {
|
||||
method: "POST",
|
||||
mode: "cors",
|
||||
headers: {
|
||||
"Content-Type": "application/json"
|
||||
},
|
||||
body: JSON.stringify(params)
|
||||
}).then(res => res.json());
|
||||
};
|
||||
|
||||
// /api/bs/hrmsalary/formula/save
|
||||
// 保存公式
|
||||
export const saveFormual = params => {
|
||||
return fetch('/api/bs/hrmsalary/formula/save', {
|
||||
method: 'POST',
|
||||
mode: 'cors',
|
||||
headers: {
|
||||
'Content-Type': 'application/json'
|
||||
},
|
||||
body: JSON.stringify(params)
|
||||
}).then(res => res.json())
|
||||
}
|
||||
return fetch("/api/bs/hrmsalary/formula/save", {
|
||||
method: "POST",
|
||||
mode: "cors",
|
||||
headers: {
|
||||
"Content-Type": "application/json"
|
||||
},
|
||||
body: JSON.stringify(params)
|
||||
}).then(res => res.json());
|
||||
};
|
||||
// 公式测试
|
||||
export const testFormual = params => {
|
||||
return fetch('/api/bs/hrmsalary/formula/mock', {
|
||||
method: 'POST',
|
||||
mode: 'cors',
|
||||
headers: {
|
||||
'Content-Type': 'application/json'
|
||||
},
|
||||
body: JSON.stringify(params)
|
||||
}).then(res => res.json())
|
||||
}
|
||||
return fetch("/api/bs/hrmsalary/formula/mock", {
|
||||
method: "POST",
|
||||
mode: "cors",
|
||||
headers: {
|
||||
"Content-Type": "application/json"
|
||||
},
|
||||
body: JSON.stringify(params)
|
||||
}).then(res => res.json());
|
||||
};
|
||||
|
||||
// 根据id获取formual
|
||||
export const detailFormual = params => {
|
||||
return fetch('/api/bs/hrmsalary/formula/detail', {
|
||||
method: 'POST',
|
||||
mode: 'cors',
|
||||
headers: {
|
||||
'Content-Type': 'application/json'
|
||||
},
|
||||
body: JSON.stringify(params)
|
||||
}).then(res => res.json())
|
||||
}
|
||||
return fetch("/api/bs/hrmsalary/formula/detail", {
|
||||
method: "POST",
|
||||
mode: "cors",
|
||||
headers: {
|
||||
"Content-Type": "application/json"
|
||||
},
|
||||
body: JSON.stringify(params)
|
||||
}).then(res => res.json());
|
||||
};
|
||||
|
||||
|
||||
// *** 公式 end ***
|
||||
|
|
@ -179,14 +179,28 @@ export const detailFormual = params => {
|
|||
|
||||
// 列出可以删除的薪资项目
|
||||
export const listCanDelete = params => {
|
||||
return fetch('/api/bs/hrmsalary/salaryitem/listCanDelete', {
|
||||
method: 'POST',
|
||||
mode: 'cors',
|
||||
headers: {
|
||||
'Content-Type': 'application/json'
|
||||
},
|
||||
body: JSON.stringify(params)
|
||||
}).then(res => res.json())
|
||||
}
|
||||
|
||||
return fetch("/api/bs/hrmsalary/salaryitem/listCanDelete", {
|
||||
method: "POST",
|
||||
mode: "cors",
|
||||
headers: {
|
||||
"Content-Type": "application/json"
|
||||
},
|
||||
body: JSON.stringify(params)
|
||||
}).then(res => res.json());
|
||||
};
|
||||
|
||||
//获取哪些账套中使用了该薪资项目
|
||||
export const getSalarySobBySalaryItem = params => {
|
||||
return WeaTools.callApi("/api/bs/hrmsalary/salaryitem/getSalarySobBySalaryItem", "GET", params);
|
||||
};
|
||||
// 同步到薪资账套
|
||||
export const syncSalaryItemToSalarySobItem = params => {
|
||||
return fetch("/api/bs/hrmsalary/salaryitem/syncSalaryItemToSalarySobItem ", {
|
||||
method: "POST",
|
||||
mode: "cors",
|
||||
headers: {
|
||||
"Content-Type": "application/json"
|
||||
},
|
||||
body: JSON.stringify(params)
|
||||
}).then(res => res.json());
|
||||
};
|
||||
|
|
|
|||
|
|
@ -172,7 +172,7 @@ export const getLedgerItemGroupForm = params => {
|
|||
|
||||
//保存薪资帐套薪资项目
|
||||
export const saveLedgerItem = params => {
|
||||
const { itemGroups, items, ...extra } = params;
|
||||
const { itemGroups, items, ...extra } = params;
|
||||
const payload = {
|
||||
itemGroups: _.map(itemGroups, item => {
|
||||
return {
|
||||
|
|
@ -330,6 +330,22 @@ export const getAggregate = params => {
|
|||
export const getBackitemForm = params => {
|
||||
return WeaTools.callApi("/api/bs/hrmsalary/salarysob/backitem/getForm", "GET", params);
|
||||
};
|
||||
//薪资账套下的个税申报表-申报字段对应
|
||||
export const taxreportruleGetForm = params => {
|
||||
return WeaTools.callApi("/api/bs/hrmsalary/salarysob/taxreportrule/getForm", "GET", params);
|
||||
};
|
||||
//薪资账套下的个税申报-累计字段对应
|
||||
export const addupruleGetForm = params => {
|
||||
return WeaTools.callApi("/api/bs/hrmsalary/salarysob/adduprule/getForm", "GET", params);
|
||||
};
|
||||
//保存薪资账套下的个税申报表规则
|
||||
export const taxreportruleSave = params => {
|
||||
return postFetch("/api/bs/hrmsalary/salarysob/taxreportrule/save", params);
|
||||
};
|
||||
//保存薪资账套下的累计字段对应关系
|
||||
export const addupruleSave = params => {
|
||||
return postFetch("/api/bs/hrmsalary/salarysob/adduprule/save", params);
|
||||
};
|
||||
//保存回算薪资项目详情
|
||||
export const salarysobBackitemSave = params => {
|
||||
return postFetch("/api/bs/hrmsalary/salarysob/backitem/save", params);
|
||||
|
|
@ -342,6 +358,10 @@ export const salarysobRangePreview = params => {
|
|||
export const salarysobRangeImportData = params => {
|
||||
return postFetch("/api/bs/hrmsalary/salarysob/range/importData", params);
|
||||
};
|
||||
//保存薪资账套个税字段
|
||||
export const saveTaxMapping = params => {
|
||||
return postFetch("/api/bs/hrmsalary/salarysob/tax/saveTaxMapping", params);
|
||||
};
|
||||
//薪资账套-获取薪资账套中薪资项目明细
|
||||
export const getSalaryItemForm = params => {
|
||||
return postFetch("/api/bs/hrmsalary/salarysob/item/getSalaryItemForm", params);
|
||||
|
|
|
|||
|
|
@ -78,3 +78,31 @@ export const statisticsEmployeeDetailList = (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);
|
||||
};
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
import { WeaTools } from "ecCom";
|
||||
import { formPost, postFetch } from "../util/request";
|
||||
import { postFetch } from "../util/request";
|
||||
|
||||
//个税扣缴义务人列表
|
||||
export const getTaxAgentList = (params) => {
|
||||
|
|
@ -7,9 +7,9 @@ export const getTaxAgentList = (params) => {
|
|||
method: "POST",
|
||||
mode: "cors",
|
||||
headers: {
|
||||
"Content-Type": "application/json",
|
||||
"Content-Type": "application/json"
|
||||
},
|
||||
body: JSON.stringify(params),
|
||||
body: JSON.stringify(params)
|
||||
}).then((res) => res.json());
|
||||
};
|
||||
//同步人员范围
|
||||
|
|
@ -18,9 +18,9 @@ export const taxAgentRangeSync = (params) => {
|
|||
method: "POST",
|
||||
mode: "cors",
|
||||
headers: {
|
||||
"Content-Type": "application/json",
|
||||
"Content-Type": "application/json"
|
||||
},
|
||||
body: JSON.stringify(params),
|
||||
body: JSON.stringify(params)
|
||||
}).then((res) => res.json());
|
||||
};
|
||||
|
||||
|
|
@ -108,12 +108,8 @@ export const taxAgentRangeImportData = (params) => {
|
|||
};
|
||||
|
||||
//个税扣缴义务人下拉列表
|
||||
export const getTaxAgentSelectList = (params) => {
|
||||
return WeaTools.callApi(
|
||||
"/api/bs/hrmsalary/taxAgent/selectList",
|
||||
"GET",
|
||||
params
|
||||
);
|
||||
export const getTaxAgentSelectList = (isShare = false) => {
|
||||
return WeaTools.callApi("/api/bs/hrmsalary/taxAgent/selectList", "GET", { isShare });
|
||||
};
|
||||
|
||||
//当前登录人个税扣缴义务人下拉列表
|
||||
|
|
@ -132,3 +128,12 @@ export const hasIconInTax = (params) => {
|
|||
params
|
||||
);
|
||||
};
|
||||
//获取报税信息表单
|
||||
export const taxReturnGetForm = (params) => {
|
||||
return WeaTools.callApi("/api/bs/hrmsalary/taxAgent/taxReturn/getForm", "GET", params);
|
||||
};
|
||||
|
||||
//个税信息-保存并验证报税信息
|
||||
export const saveAndCheck = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/taxAgent/taxReturn/saveAndCheck", params);
|
||||
};
|
||||
|
|
|
|||
|
|
@ -13,6 +13,10 @@ export const getCondition = params => {
|
|||
export const queryList = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/archives/getTable", params);
|
||||
};
|
||||
//社保福利档案_非系统人员列表
|
||||
export const getExtTable = (params) => {
|
||||
return postFetch("/api/bs/hrmsalary/archives/getExtTable", params);
|
||||
};
|
||||
//社保福利档案列表
|
||||
export const queryInsuranceTabTotal = (params) => {
|
||||
return WeaTools.callApi("/api/bs/hrmsalary/archives/queryInsuranceTabTotal", params);
|
||||
|
|
|
|||
Binary file not shown.
|
After Width: | Height: | Size: 6.3 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 6.4 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 6.5 KiB |
|
|
@ -8,6 +8,7 @@ import React, { Component } from "react";
|
|||
import { WeaBrowser, WeaDialog, WeaFormItem, WeaSearchGroup, WeaSelect } from "ecCom";
|
||||
import { Button, message, Modal } from "antd";
|
||||
import { getTaxAgentRangeForm } from "../../apis/taxAgent";
|
||||
import { commonEnumList } from "../../apis/ruleconfig";
|
||||
import { SelectWithAll } from "../../pages/socialSecurityBenefits/standingBookDetail/components/regAddEmployee";
|
||||
import "./index.less";
|
||||
|
||||
|
|
@ -31,41 +32,74 @@ class PersonalScopeModal extends Component {
|
|||
if (isTaxgent) {
|
||||
this.getTaxAgentRangeForm();
|
||||
} else {
|
||||
const employeeStatus = [
|
||||
{ key: "TRIAL", showname: "试用" },
|
||||
{ key: "FORMAL", showname: "正式" },
|
||||
{ key: "TEMPORARY", showname: "临时" },
|
||||
{ key: "DELAY", showname: "试用延期" },
|
||||
{ key: "FIRE", showname: "解雇" },
|
||||
{ key: "DEPARTURE", showname: "离职" },
|
||||
{ key: "RETIRED", showname: "退休" }
|
||||
];
|
||||
const targetTypeList = [
|
||||
{
|
||||
key: "EMPLOYEE",
|
||||
showname: "人员",
|
||||
selected: false
|
||||
},
|
||||
{
|
||||
key: "SUBCOMPANY",
|
||||
showname: "分部",
|
||||
selected: false
|
||||
},
|
||||
{
|
||||
key: "DEPT",
|
||||
showname: "部门",
|
||||
selected: false
|
||||
},
|
||||
{
|
||||
key: "POSITION",
|
||||
showname: "岗位",
|
||||
selected: false
|
||||
}
|
||||
];
|
||||
this.setState({ targetTypeList, employeeStatus });
|
||||
this.commonEnumList();
|
||||
// const employeeStatus = [
|
||||
// { key: "TRIAL", showname: "试用" },
|
||||
// { key: "FORMAL", showname: "正式" },
|
||||
// { key: "TEMPORARY", showname: "临时" },
|
||||
// { key: "DELAY", showname: "试用延期" },
|
||||
// { key: "FIRE", showname: "解雇" },
|
||||
// { key: "DEPARTURE", showname: "离职" },
|
||||
// { key: "RETIRED", showname: "退休" }
|
||||
// ];
|
||||
// const targetTypeList = [
|
||||
// {
|
||||
// key: "EMPLOYEE",
|
||||
// showname: "人员",
|
||||
// selected: false
|
||||
// },
|
||||
// {
|
||||
// key: "SUBCOMPANY",
|
||||
// showname: "分部",
|
||||
// selected: false
|
||||
// },
|
||||
// {
|
||||
// key: "DEPT",
|
||||
// showname: "部门",
|
||||
// selected: false
|
||||
// },
|
||||
// {
|
||||
// key: "POSITION",
|
||||
// showname: "岗位",
|
||||
// selected: false
|
||||
// }
|
||||
// ];
|
||||
// this.setState({ targetTypeList, employeeStatus });
|
||||
}
|
||||
}
|
||||
|
||||
commonEnumList = () => {
|
||||
commonEnumList({ enumClass: "com.engine.salary.enums.UserStatusEnum" }).then(({ status, data }) => {
|
||||
if (status) {
|
||||
const targetTypeList = [
|
||||
{
|
||||
key: "EMPLOYEE",
|
||||
showname: "人员",
|
||||
selected: false
|
||||
},
|
||||
{
|
||||
key: "SUBCOMPANY",
|
||||
showname: "分部",
|
||||
selected: false
|
||||
},
|
||||
{
|
||||
key: "DEPT",
|
||||
showname: "部门",
|
||||
selected: false
|
||||
},
|
||||
{
|
||||
key: "POSITION",
|
||||
showname: "岗位",
|
||||
selected: false
|
||||
}
|
||||
];
|
||||
this.setState({
|
||||
targetTypeList,
|
||||
employeeStatus: _.map(_.filter(data, o => o.value !== 7), it => ({ key: it.enum, showname: it.defaultLabel }))
|
||||
});
|
||||
}
|
||||
});
|
||||
};
|
||||
getTaxAgentRangeForm = () => {
|
||||
getTaxAgentRangeForm().then(({ status, data }) => {
|
||||
if (status) {
|
||||
|
|
@ -91,7 +125,7 @@ class PersonalScopeModal extends Component {
|
|||
employeeStatus: status.split(","),
|
||||
includeType,
|
||||
targetParams: _.map(targetTypeIds.split(","), it => ({ targetType, targetId: it })),
|
||||
[saveKeyVal["key"]]: saveKeyVal["value"],
|
||||
[saveKeyVal["key"]]: saveKeyVal["value"]
|
||||
};
|
||||
this.setState({ loading: true });
|
||||
APISaveFox["save"](payload).then(({ status, errormsg }) => {
|
||||
|
|
|
|||
|
|
@ -1,36 +1,41 @@
|
|||
.tipLabelWrapper {
|
||||
border-left: 1px solid #e2ecf2;
|
||||
border-left: 1px solid #e2ecf2;
|
||||
border-bottom: 1px solid #e2ecf2;
|
||||
border-right: 1px solid #e2ecf2;
|
||||
border-radius: 0px 0px 5px 5px;
|
||||
width: 100%;
|
||||
overflow: hidden;
|
||||
|
||||
.titleWrapper {
|
||||
width: 100%;
|
||||
line-height: 19.2px;
|
||||
padding: 10px;
|
||||
border-bottom: 1px solid #e2ecf2;
|
||||
border-right: 1px solid #e2ecf2;
|
||||
border-radius: 0px 0px 5px 5px;
|
||||
background-color: #f7fbfe;
|
||||
}
|
||||
|
||||
.tipContentWrapper {
|
||||
padding: 10px;
|
||||
background: #FFF;
|
||||
}
|
||||
|
||||
.tipContentItem {
|
||||
line-height: 20px;
|
||||
padding: 10px 16px 0px;
|
||||
color: rgb(153, 153, 153);
|
||||
}
|
||||
|
||||
.tipContentItem:first-child {
|
||||
padding-top: 0;
|
||||
}
|
||||
|
||||
.formLabel {
|
||||
font-size: 14px;
|
||||
}
|
||||
|
||||
.contentWrapper {
|
||||
width: 100%;
|
||||
overflow: hidden;
|
||||
.titleWrapper {
|
||||
width: 100%;
|
||||
line-height: 19.2px;
|
||||
padding: 10px;
|
||||
border-bottom: 1px solid #e2ecf2;
|
||||
background-color: #f7fbfe;
|
||||
}
|
||||
.tipContentWrapper {
|
||||
padding: 10px;
|
||||
}
|
||||
.tipContentItem {
|
||||
line-height: 20px;
|
||||
padding: 0px 16px;
|
||||
padding-top: 10px;
|
||||
color: rgb(153, 153, 153);
|
||||
}
|
||||
.tipContentItem:first {
|
||||
padding-top: 0px;
|
||||
}
|
||||
|
||||
.formLabel {
|
||||
font-size: 14px;
|
||||
}
|
||||
.contentWrapper {
|
||||
width: 100%;
|
||||
overflow: hidden;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -123,10 +123,10 @@ class CodeAction extends Component {
|
|||
<div className="excel-codeAction">
|
||||
<div className="excel-codeAction-item">
|
||||
<div className="excel-codeAction-header">
|
||||
<div className="excel-codeAction-header-title">{getLabel(111, "变量")}</div>
|
||||
<div className="excel-codeAction-header-title">{getLabel(33748, "变量")}</div>
|
||||
</div>
|
||||
<div className="excel-codeAction-content">
|
||||
<WeaInputSearch value={variableText} placeholder={getLabel(111, "请输入变量名称")}
|
||||
<WeaInputSearch value={variableText} placeholder={getLabel(125864, "请输入变量名称")}
|
||||
className="variableOuterInput"
|
||||
onChange={variableText => this.setState({ variableText })}/>
|
||||
<Tree className="variableTree" showLine expandedKeys={variableExpandedKeys}
|
||||
|
|
@ -146,7 +146,7 @@ class CodeAction extends Component {
|
|||
title={
|
||||
<WeaInputSearch
|
||||
value={variItemText}
|
||||
placeholder={getLabel(111, "请输入变量名称")}
|
||||
placeholder={getLabel(125864, "请输入变量名称")}
|
||||
onChange={variItemText => this.setState({ variItemText })}
|
||||
/>
|
||||
}
|
||||
|
|
@ -166,10 +166,10 @@ class CodeAction extends Component {
|
|||
<React.Fragment>
|
||||
<div className="excel-codeAction-item">
|
||||
<div className="excel-codeAction-header">
|
||||
<div className="excel-codeAction-header-title">{getLabel(111, "函数")}</div>
|
||||
<div className="excel-codeAction-header-title">{getLabel(30686, "函数")}</div>
|
||||
</div>
|
||||
<div className="excel-codeAction-content">
|
||||
<WeaInputSearch value={funcText} placeholder={getLabel(111, "请输入函数名称")}
|
||||
<WeaInputSearch value={funcText} placeholder={getLabel(543713, "请输入函数名称")}
|
||||
className="variableOuterInput"
|
||||
onChange={funcText => this.setState({ funcText })}/>
|
||||
<Tree className="variableTree" showLine expandedKeys={funcExpandedKeys}
|
||||
|
|
@ -207,7 +207,7 @@ class CodeAction extends Component {
|
|||
<div className="excel-codeAction-item">
|
||||
<div className="excel-codeAction-header">
|
||||
<div className="excel-codeAction-header-title">
|
||||
{!_.isEmpty(funcHoverItem) ? funcHoverItem.name : getLabel(111, "提示")}
|
||||
{!_.isEmpty(funcHoverItem) ? funcHoverItem.name : getLabel(558, "提示")}
|
||||
</div>
|
||||
</div>
|
||||
<div className="excel-codeAction-content"><TipList tips={funcHoverItem}/></div>
|
||||
|
|
@ -232,12 +232,12 @@ const TipList = (props) => {
|
|||
</div>
|
||||
</div> : <div className="code-action-list">
|
||||
<div className="code-action-tips">
|
||||
<div className="code-action-tips-title">{getLabel(111, "语法")}</div>
|
||||
<div className="code-action-tips-title">{getLabel(543403, "语法")}</div>
|
||||
<div className="code-action-tips-info">
|
||||
<div>{formatString}</div>
|
||||
<div>{description}</div>
|
||||
</div>
|
||||
<div className="code-action-tips-title">{getLabel(111, "参数")}</div>
|
||||
<div className="code-action-tips-title">{getLabel(561, "参数")}</div>
|
||||
{
|
||||
_.map(paramDescs, it => {
|
||||
return <div className="code-action-tips-info">
|
||||
|
|
@ -246,9 +246,9 @@ const TipList = (props) => {
|
|||
</div>;
|
||||
})
|
||||
}
|
||||
<div className="code-action-tips-title">{getLabel(111, "示例")}</div>
|
||||
<div className="code-action-tips-title">{getLabel(82159, "示例")}</div>
|
||||
<span className="code-action-tips-info">{example}</span>
|
||||
<div className="code-action-tips-title">{getLabel(111, "结果")}</div>
|
||||
<div className="code-action-tips-title">{getLabel(356, "结果")}</div>
|
||||
<span className="code-action-tips-info">{result}</span>
|
||||
</div>
|
||||
</div>;
|
||||
|
|
|
|||
|
|
@ -157,7 +157,7 @@ class ExcelEditor extends Component {
|
|||
</div>
|
||||
<Button type="ghost"
|
||||
onClick={() => this.setState({ isFormter: !isFormter }, () => this.autoFormatSelection())}>
|
||||
{!isFormter ? getLabel(111, "格式美化") : getLabel(111, "格式还原")}
|
||||
{!isFormter ? getLabel(543711, "格式美化") : getLabel(543712, "格式还原")}
|
||||
</Button>
|
||||
</div>
|
||||
}
|
||||
|
|
|
|||
|
|
@ -0,0 +1,87 @@
|
|||
/*
|
||||
* Author: 黎永顺
|
||||
* name: 导入-步骤一
|
||||
* Description:
|
||||
* Date: 2023/8/11
|
||||
*/
|
||||
import React, { Component } from "react";
|
||||
import { WeaLocaleProvider } from "ecCom";
|
||||
import { Icon, Upload, message } from "antd";
|
||||
|
||||
const Dragger = Upload.Dragger;
|
||||
const { getLabel } = WeaLocaleProvider;
|
||||
|
||||
class ImpStep1 extends Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
fileList: []
|
||||
};
|
||||
}
|
||||
|
||||
handleChange = (data) => {
|
||||
const { fileList, file } = data;
|
||||
if (file.response && typeof (file.response) != "undefined" && file.status !== "removed") message.success(getLabel(111, "上传成功"));
|
||||
this.setState({ fileList: fileList.slice(-1) });
|
||||
};
|
||||
|
||||
render() {
|
||||
const { fileList } = this.state;
|
||||
const dragger = {
|
||||
accept: ".xlsx",
|
||||
name: "file",
|
||||
multiple: false,
|
||||
action: "/api/doc/upload/uploadFile",
|
||||
fileList,
|
||||
onChange: this.handleChange
|
||||
};
|
||||
return (
|
||||
<div className="weapp-batch-impsteps-picker-content-imp-step1">
|
||||
{/* 导入选项 */}
|
||||
{
|
||||
this.props.importParams &&
|
||||
<div className="weapp-salary-tb-border-bottom import-option">
|
||||
<div>{getLabel(543201, "导入选项")}</div>
|
||||
{this.props.importParams}
|
||||
</div>
|
||||
}
|
||||
<div className="title">{getLabel(543202, "导入Excel")}</div>
|
||||
<p className="draggerUploadWrapper">
|
||||
<Dragger {...dragger}>
|
||||
<div>
|
||||
<p className="iconUpload"><Icon type="inbox"/></p>
|
||||
<p className="uplaod-title">{getLabel(543203, "点击或将文件拖拽到此区域上传")}</p>
|
||||
<p
|
||||
className="uplaod-subTitle">{getLabel(543204, "支持单个或批量上传,严禁上传公司内部资料及其他违禁文件")}</p>
|
||||
</div>
|
||||
</Dragger>
|
||||
</p>
|
||||
|
||||
<div className="bottom-border">
|
||||
<div>{getLabel(27577, "操作步骤")}</div>
|
||||
<p>
|
||||
<span>{`1. ${getLabel(30907, "第一步")},${getLabel(543205, "请选择导出的Excel文件或")}`}</span>
|
||||
<a href={this.props.link} className="weapp-salary-link"
|
||||
target="_blank">{getLabel(543207, "点击这里下载模板")}</a>
|
||||
{this.props.exportDataDom}
|
||||
</p>
|
||||
<p>{`2. ${getLabel(543211, "第二步")},${getLabel(543212, "请一定要确定Excel文档中的格式是模板中的格式")},${getLabel(543213, "没有被修改掉")};`}</p>
|
||||
<p>{`3. ${getLabel(543216, "第三步")},${getLabel(543215, "选择填写好的Excel文档")},${getLabel(543214, "点击“下一步”按钮进行数据预览")};`}</p>
|
||||
<p>
|
||||
{`4. ${getLabel(543217, "第四步")},${getLabel(543218, "如果以上步骤和Excel文档正确的话")},${getLabel(543219, "导入成功会有提示")},${getLabel(543220, "数据会被正确导入")}。${getLabel(543221, "如果有问题")},${getLabel(543222, "则会提示Excel文档的错误之处")}。`}
|
||||
</p>
|
||||
</div>
|
||||
|
||||
<div className="description">
|
||||
<div>{getLabel(543223, "Excel文件说明")}</div>
|
||||
<p>{`1. ${getLabel(543224, "后缀名为xls或者xlsx")};`}</p>
|
||||
<p>{`2. ${getLabel(543225, "数据请勿放在合并的单元格中")};`}</p>
|
||||
<p><span>{`3. ${getLabel(543226, "账单月份格式必须为")}:YYYY-MM;`}</span></p>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
export default ImpStep1;
|
||||
|
|
@ -0,0 +1,49 @@
|
|||
/*
|
||||
* Author: 黎永顺
|
||||
* name: 导入-步骤二
|
||||
* Description:
|
||||
* Date: 2023/9/5
|
||||
*/
|
||||
import React, { Component } from "react";
|
||||
import { WeaTable } from "ecCom";
|
||||
import { postFetch } from "../../../util/request";
|
||||
|
||||
class ImpStep2 extends Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
loading: false, columns: [], dataSource: []
|
||||
};
|
||||
}
|
||||
|
||||
componentDidMount() {
|
||||
this.init();
|
||||
}
|
||||
|
||||
init = () => {
|
||||
const { previewUrl, imageId } = this.props;
|
||||
const payload = { imageId };
|
||||
this.setState({ loading: true });
|
||||
postFetch(previewUrl, payload).then(({ status, data }) => {
|
||||
this.setState({ loading: false });
|
||||
if (status) {
|
||||
const { headers, list } = data;
|
||||
this.setState({
|
||||
columns: _.map(headers, (item, index) => ({ title: item, dataIndex: index + "", width: 120 })),
|
||||
dataSource: _.map(list, item => {
|
||||
return _.reduce(item, (pre, cur, key) => (_.assign(pre, { [key]: cur })), {});
|
||||
})
|
||||
});
|
||||
}
|
||||
}).catch(() => this.setState({ loading: false }));
|
||||
};
|
||||
|
||||
render() {
|
||||
const { dataSource, columns, loading } = this.state;
|
||||
return (
|
||||
<WeaTable dataSource={dataSource} columns={columns} pagination={false} loading={loading} scroll={{ x: 800 }}/>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
export default ImpStep2;
|
||||
|
|
@ -0,0 +1,51 @@
|
|||
/*
|
||||
* Author: 黎永顺
|
||||
* name: 导入-步骤3
|
||||
* Description:
|
||||
* Date: 2023/8/11
|
||||
*/
|
||||
import React, { Component } from "react";
|
||||
import { WeaLocaleProvider, WeaTable } from "ecCom";
|
||||
import successImg from "../../importModal/success.svg";
|
||||
|
||||
const getLabel = WeaLocaleProvider.getLabel;
|
||||
|
||||
class ImpStep3 extends Component {
|
||||
render() {
|
||||
const { importResult } = this.props;
|
||||
return (
|
||||
<div className="weapp-batch-impsteps-picker-content-imp-step3">
|
||||
{
|
||||
!_.isEmpty(importResult) ?
|
||||
<div className="weapp-batch-impsteps-picker-spinText">
|
||||
<p><img src={successImg} alt=""/></p>
|
||||
<p>
|
||||
<span>{getLabel(389249, "已导入")}</span>
|
||||
<span style={{ color: "green" }}> {importResult.successCount}</span>
|
||||
<span>{`${getLabel(30690, "条数据")},${getLabel(25009, "失败")}`}</span>
|
||||
<span style={{ color: "red" }}> {importResult.errorCount} </span>{getLabel(30690, "条数据")}
|
||||
</p>
|
||||
</div> :
|
||||
<div className="weapp-batch-impsteps-picker-spinText">
|
||||
<p>{getLabel(111, "导入失败")}</p>
|
||||
</div>
|
||||
}
|
||||
{
|
||||
!_.isEmpty(importResult.errorData) &&
|
||||
<WeaTable
|
||||
columns={[
|
||||
{
|
||||
title: getLabel(25700, "错误信息"),
|
||||
dataIndex: "message"
|
||||
}
|
||||
]}
|
||||
dataSource={importResult.errorData} pagination={false}
|
||||
scroll={{ y: `calc(100vh - 387px)` }}
|
||||
/>
|
||||
}
|
||||
</div>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
export default ImpStep3;
|
||||
|
|
@ -0,0 +1,154 @@
|
|||
/*
|
||||
* Author: 黎永顺
|
||||
* name: 导入弹框-步骤条
|
||||
* Description:
|
||||
* Date: 2023/8/11
|
||||
*/
|
||||
import React, { Component } from "react";
|
||||
import { Button, message, Modal } from "antd";
|
||||
import { WeaDialog, WeaLocaleProvider, WeaSteps } from "ecCom";
|
||||
import ImpStep1 from "./components/impStep1";
|
||||
import ImpStep2 from "./components/impStep2";
|
||||
import ImpStep3 from "./components/impStep3";
|
||||
import "./index.less";
|
||||
|
||||
const { getLabel } = WeaLocaleProvider;
|
||||
const Step = WeaSteps.Step;
|
||||
|
||||
class Index extends Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
current: 0
|
||||
};
|
||||
}
|
||||
|
||||
componentWillReceiveProps(nextProps, nextContext) {
|
||||
if (JSON.stringify(nextProps.importResult) !== JSON.stringify(this.props.importResult) && !_.isEmpty(nextProps.importResult)) {
|
||||
this.setState({
|
||||
current: this.state.current + 1
|
||||
});
|
||||
}
|
||||
if (nextProps.visible !== this.props.visible && !nextProps.visible) this.setState({ current: 0 });
|
||||
}
|
||||
|
||||
renderChildren = () => {
|
||||
const { current } = this.state;
|
||||
const { importParams, link, excludeKey, importResult, exportDataDom = null } = this.props;
|
||||
let CurrentDom = null;
|
||||
switch (current) {
|
||||
case 0:
|
||||
CurrentDom = <ImpStep1 importParams={importParams} link={link} exportDataDom={exportDataDom}
|
||||
ref={dom => this.step1Ref = dom}/>;
|
||||
break;
|
||||
case 1:
|
||||
CurrentDom = <ImpStep2 {...this.props}/>;
|
||||
if (excludeKey) {
|
||||
CurrentDom = <ImpStep3 importResult={importResult}/>;
|
||||
}
|
||||
break;
|
||||
case 2:
|
||||
CurrentDom = <ImpStep3 importResult={importResult}/>;
|
||||
break;
|
||||
default:
|
||||
CurrentDom = null;
|
||||
break;
|
||||
}
|
||||
return CurrentDom;
|
||||
};
|
||||
/*
|
||||
* Author: 黎永顺
|
||||
* Description: 上一步
|
||||
* Params:
|
||||
* Date: 2023/9/5
|
||||
*/
|
||||
handlePreviousStep = () => {
|
||||
Modal.confirm({
|
||||
title: getLabel(131329, "信息确认"),
|
||||
content: getLabel(111, "是否放弃已上传的文件?"),
|
||||
onOk: () => this.setState({ current: this.state.current - 1 }, () => this.props.onResetImportResult())
|
||||
});
|
||||
};
|
||||
|
||||
/*
|
||||
* Author: 黎永顺
|
||||
* Description: 下一步
|
||||
* Params:
|
||||
* Date: 2023/8/11
|
||||
*/
|
||||
handleNext = () => {
|
||||
const { params, importResult } = this.props;
|
||||
if (_.isEmpty(importResult)) {
|
||||
const { fileList } = this.step1Ref.state;
|
||||
if (!_.isEmpty(params)) {
|
||||
if (!Object.values(params).every(o => !!o)) {
|
||||
Modal.warning({
|
||||
title: getLabel(131329, "信息确认"),
|
||||
content: getLabel(518702, "必要信息不完整,红色*为必填项!")
|
||||
});
|
||||
return;
|
||||
}
|
||||
}
|
||||
if (_.isEmpty(fileList)) {
|
||||
message.warning(getLabel(111, "请先上传EXCEL文件"));
|
||||
return;
|
||||
}
|
||||
const [file] = fileList;
|
||||
const { response } = file;
|
||||
this.props.nextCallback(response.data.fileid);
|
||||
} else {
|
||||
this.setState({ current: this.state.current + 1 });
|
||||
}
|
||||
};
|
||||
|
||||
render() {
|
||||
const { current } = this.state;
|
||||
const stepData = [
|
||||
{ key: 0, label: getLabel(543202, "上传EXCEL") },
|
||||
{ key: 1, label: getLabel(543200, "数据预览") },
|
||||
{ key: 2, label: getLabel(502835, "导入数据") }
|
||||
];
|
||||
const btns = [
|
||||
<Button type="ghost" onClick={this.handlePreviousStep}>{getLabel(1876, "上一步")}</Button>,
|
||||
<Button type="primary" onClick={this.handleNext}
|
||||
loading={this.props.nextloading}>{getLabel(1402, "下一步")}</Button>,
|
||||
<Button type="primary" onClick={() => this.props.onCancel(true)}>{getLabel(555, "完成")}</Button>
|
||||
];
|
||||
return (
|
||||
<WeaDialog
|
||||
{...this.props}
|
||||
scalable hasScroll className="importBox" initLoadCss
|
||||
buttons={current === 0 ? _.nth(btns, 1) : (!this.props.excludeKey && current === 1) ? _.take(btns, 2) : _.takeRight(btns)}
|
||||
style={{
|
||||
width: 800,
|
||||
height: 606.6,
|
||||
minHeight: 200,
|
||||
minWidth: 380,
|
||||
maxHeight: "90%",
|
||||
maxWidth: "90%",
|
||||
overflow: "hidden",
|
||||
transform: "translate(0px, 0px)"
|
||||
}}
|
||||
>
|
||||
<div className="importCont">
|
||||
<div className="weapp-batch-impsteps-picker-content-imp-steps">
|
||||
<WeaSteps current={current}>
|
||||
{/*this.props.key: 不需要展示的步骤*/}
|
||||
{
|
||||
_.map(_.filter(stepData, item => item.key !== this.props.excludeKey), it => (
|
||||
<Step key={it.key} description={it.label}/>))
|
||||
}
|
||||
</WeaSteps>
|
||||
</div>
|
||||
<div className="weapp-batch-impsteps-picker">
|
||||
{
|
||||
this.renderChildren()
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
</WeaDialog>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
export default Index;
|
||||
|
|
@ -0,0 +1,143 @@
|
|||
.importBox {
|
||||
.importCont {
|
||||
padding: 16px 8px;
|
||||
|
||||
.weapp-batch-impsteps-picker-content-imp-steps {
|
||||
width: 80%;
|
||||
margin: 0 auto;
|
||||
}
|
||||
|
||||
.weapp-batch-impsteps-picker {
|
||||
margin: 16px auto;
|
||||
|
||||
.weapp-batch-impsteps-picker-content-imp-step1 {
|
||||
width: 98%;
|
||||
background-color: #fff;
|
||||
margin: 8px auto;
|
||||
border-radius: 3px;
|
||||
padding: 1px 12px;
|
||||
|
||||
.weapp-batch-impsteps-picker-content-imp-step1 div {
|
||||
color: #111;
|
||||
line-height: 22px;
|
||||
}
|
||||
|
||||
.weapp-salary-tb-border-bottom .weapp-salary-tb-filter.weapp-salary-import-param {
|
||||
box-sizing: border-box;
|
||||
padding: 16px;
|
||||
height: auto;
|
||||
flex-wrap: wrap;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.weapp-salary-import-param {
|
||||
border: 1px solid #ebedf0;
|
||||
padding: 8px;
|
||||
margin: 4px 0 14px;
|
||||
}
|
||||
|
||||
.weapp-salary-tb-filter {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
align-items: center;
|
||||
height: 46px;
|
||||
}
|
||||
|
||||
.weapp-salary-tb-border-bottom .weapp-salary-tb-filter.weapp-salary-import-param .tbf-item {
|
||||
display: flex;
|
||||
justify-content: flex-start !important;
|
||||
}
|
||||
|
||||
.weapp-salary-tb-filter .tbf-item {
|
||||
padding: 0 20px 0 0;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
font-size: 12px;
|
||||
color: #111;
|
||||
height: 40px;
|
||||
}
|
||||
|
||||
.weapp-salary-tb-filter .tbf-item > .tbfi-label {
|
||||
flex-basis: 100px;
|
||||
flex-shrink: 0;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
padding-right: 10px;
|
||||
color: #666;
|
||||
}
|
||||
|
||||
.draggerUploadWrapper {
|
||||
margin: 16px 0 0;
|
||||
|
||||
.ant-upload-drag-container {
|
||||
padding: 24px 0 16px;
|
||||
|
||||
.iconUpload {
|
||||
i {
|
||||
color: #5d9cec;
|
||||
font-size: 43px;
|
||||
}
|
||||
}
|
||||
|
||||
.uplaod-title {
|
||||
font-size: 14px;
|
||||
color: #333;
|
||||
height: 24px;
|
||||
line-height: 24px;
|
||||
margin-top: 8px;
|
||||
}
|
||||
|
||||
.uplaod-subTitle {
|
||||
height: 22px;
|
||||
font-size: 12px;
|
||||
color: #666;
|
||||
text-align: center;
|
||||
line-height: 22px;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.bottom-border, .description {
|
||||
margin-top: 12px;
|
||||
|
||||
p {
|
||||
font-size: 12px;
|
||||
color: #666;
|
||||
line-height: 15px;
|
||||
margin: 12px 0;
|
||||
}
|
||||
}
|
||||
|
||||
.bottom-border {
|
||||
border-bottom: 1px solid #e5e5e5;
|
||||
|
||||
.weapp-salary-link {
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
color: #5d9cec;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
.weapp-batch-impsteps-picker-content-imp-step3 {
|
||||
.weapp-batch-impsteps-picker-spinText {
|
||||
position: relative;
|
||||
height: 100%;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
flex-direction: column;
|
||||
text-align: center;
|
||||
|
||||
p {
|
||||
margin: 14px 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
|
@ -20,8 +20,14 @@ import Payroll from "./pages/payroll";
|
|||
import PayrollGrant from "./pages/payroll/payrollGrant";
|
||||
import PayrollDetail from "./pages/payroll/payrollDetail";
|
||||
import Declare from "./pages/declare";
|
||||
import DeclareDetail from "./pages/declareDetail";
|
||||
import Employeedeclare from "./pages/employeedeclare";
|
||||
import EnterprisePayCertificationDetail from "./pages/enterprisePayCertificationDetail";
|
||||
import BankVoucherDetail from "./pages/bankVoucherDetail";
|
||||
import EmployeedeclareDetail from "./pages/employeedeclareDetail";
|
||||
import TaxRate from "./pages/taxRate";
|
||||
import TaxAgent from "./pages/taxAgent";
|
||||
import TaxAgents from "./pages/taxAgent";
|
||||
import TaxAgent from "./pages/salary/taxAgent";
|
||||
import CalculateDetail from "./pages/calculateDetail";
|
||||
import PlaceOnFileDetail from "./pages/calculateDetail/placeOnFileDetail";
|
||||
import CompareDetail from "./pages/calculateDetail/compareDetail";
|
||||
|
|
@ -37,6 +43,7 @@ import EmployeeList from "./pages/employeeView";
|
|||
import ReportView from "./pages/reportView";
|
||||
import MySalaryView from "./pages/mySalary/mySalaryView";
|
||||
import WatermarkPreview from "./pages/payroll/watermarkPreview";
|
||||
import IntelligentCalculateSalarySettings from "./pages/intelligentCalculateSalarySettings";
|
||||
import ExternalPersonManage from "./pages/externalPersonManage";
|
||||
|
||||
import stores from "./stores";
|
||||
|
|
@ -88,6 +95,9 @@ const DataAcquisition = (props) => props.children;
|
|||
// analysisOfSalaryStatistics 薪酬统计分析
|
||||
// reportView 薪酬报表查看
|
||||
// externalPersonManage 非系统人员管理
|
||||
// employeedeclare 人员信息报送
|
||||
// employeedeclareDetail 人员信息报送详情
|
||||
// intelligentCalculateSalarySettings 智能算薪
|
||||
|
||||
const Routes = (
|
||||
<Route
|
||||
|
|
@ -142,6 +152,13 @@ const Routes = (
|
|||
component={TemplatePreview}
|
||||
/>
|
||||
<Route key="declare" path="declare" component={Declare}/>
|
||||
<Route key="declareDetail" path="declareDetail" component={DeclareDetail}/>
|
||||
<Route key="employeedeclare" path="employeedeclare" component={Employeedeclare}/>
|
||||
<Route key="enterprisePayCertificationDetail" path="enterprisePayCertificationDetail"
|
||||
component={EnterprisePayCertificationDetail}/>
|
||||
<Route key="bankVoucherDetail" path="bankVoucherDetail"
|
||||
component={BankVoucherDetail}/>
|
||||
<Route key="employeedeclareDetail" path="employeedeclareDetail" component={EmployeedeclareDetail}/>
|
||||
<Route
|
||||
key="generateDeclarationDetail"
|
||||
path="generateDeclarationDetail"
|
||||
|
|
@ -149,6 +166,7 @@ const Routes = (
|
|||
/>
|
||||
<Route key="taxRate" path="taxRate" component={TaxRate}/>
|
||||
<Route key="taxAgent" path="taxAgent" component={TaxAgent}/>
|
||||
<Route key="taxAgents" path="taxAgents" component={TaxAgents}/>
|
||||
<Route key="mobilepayroll" path="mobilepayroll" component={MobilePayroll}/>
|
||||
<Route key="sysconfig" path="sysconfig" component={SysConfig}/>
|
||||
<Route key="sysconfig-1" path="sysconfig-1" component={RuleConfig}/>
|
||||
|
|
@ -157,6 +175,8 @@ const Routes = (
|
|||
<Route key="analysisOfSalaryStatistics" path="analysisOfSalaryStatistics" component={AnalysisOfSalaryStatistics}/>
|
||||
<Route key="analysisOfSalaryStatisticsId" path="analysisOfSalaryStatistics/:employeeId" component={EmployeeList}/>
|
||||
<Route key="reportView" path="reportView" component={ReportView}/>
|
||||
<Route key="intelligentCalculateSalarySettings" path="intelligentCalculateSalarySettings"
|
||||
component={IntelligentCalculateSalarySettings}/>
|
||||
<Route key="externalPersonManage" path="externalPersonManage" component={ExternalPersonManage}/>
|
||||
</Route>
|
||||
);
|
||||
|
|
|
|||
|
|
@ -11,7 +11,7 @@ export const condition = [
|
|||
conditionType: "SELECT",
|
||||
domkey: ["dimType"],
|
||||
fieldcol: 14,
|
||||
label: getLabel(111, "维度类型"),
|
||||
label: getLabel(389137, "维度类型"),
|
||||
labelcol: 6,
|
||||
options: [],
|
||||
detailtype: 3,
|
||||
|
|
@ -23,7 +23,7 @@ export const condition = [
|
|||
conditionType: "SELECT",
|
||||
domkey: ["setting4Qualitative"],
|
||||
fieldcol: 14,
|
||||
label: getLabel(111, "统计维度"),
|
||||
label: getLabel(506800, "统计维度"),
|
||||
labelcol: 6,
|
||||
options: [],
|
||||
rules: "required|string",
|
||||
|
|
@ -34,7 +34,7 @@ export const condition = [
|
|||
conditionType: "INPUT",
|
||||
domkey: ["dimName"],
|
||||
fieldcol: 14,
|
||||
label: getLabel(111, "统计维度名称"),
|
||||
label: getLabel(543321, "统计维度名称"),
|
||||
labelcol: 6,
|
||||
value: "",
|
||||
rules: "required|string",
|
||||
|
|
@ -45,7 +45,7 @@ export const condition = [
|
|||
conditionType: "SELECT",
|
||||
domkey: ["dimCode"],
|
||||
fieldcol: 14,
|
||||
label: getLabel(111, "分组所属字段"),
|
||||
label: getLabel(543322, "分组所属字段"),
|
||||
labelcol: 6,
|
||||
options: [],
|
||||
viewAttr: 2,
|
||||
|
|
@ -57,13 +57,13 @@ export const condition = [
|
|||
conditionType: "TEXTAREA",
|
||||
domkey: ["remark"],
|
||||
fieldcol: 14,
|
||||
label: getLabel(111, "描述"),
|
||||
label: getLabel(433, "描述"),
|
||||
labelcol: 6,
|
||||
value: "",
|
||||
viewAttr: 2
|
||||
}
|
||||
],
|
||||
title: getLabel(111, "基础设置"),
|
||||
title: getLabel(82751, "基础设置"),
|
||||
defaultshow: true
|
||||
}
|
||||
];
|
||||
|
|
@ -75,7 +75,7 @@ export const reportCondition = [
|
|||
conditionType: "INPUT",
|
||||
domkey: ["reportName"],
|
||||
fieldcol: 14,
|
||||
label: getLabel(111, "报表名称"),
|
||||
label: getLabel(15517, "报表名称"),
|
||||
labelcol: 6,
|
||||
value: "",
|
||||
rules: "required|string",
|
||||
|
|
@ -86,7 +86,7 @@ export const reportCondition = [
|
|||
conditionType: "SELECT",
|
||||
domkey: ["dimensionIds"],
|
||||
fieldcol: 14,
|
||||
label: getLabel(111, "统计维度"),
|
||||
label: getLabel(506800, "统计维度"),
|
||||
labelcol: 6,
|
||||
options: [],
|
||||
rules: "required|string",
|
||||
|
|
|
|||
|
|
@ -89,8 +89,8 @@ class DimensionSlide extends Component {
|
|||
if (dimType === "QUALITATIVE") {
|
||||
if (!setting4Qualitative || !extraParams.dimName) {
|
||||
Modal.warning({
|
||||
title: getLabel(111, "信息确认"),
|
||||
content: getLabel(111, "必要信息不完整,红色*为必填项!")
|
||||
title: getLabel(131329, "信息确认"),
|
||||
content: getLabel(383779, "必要信息不完整,红色*为必填项!")
|
||||
});
|
||||
return;
|
||||
}
|
||||
|
|
@ -100,8 +100,8 @@ class DimensionSlide extends Component {
|
|||
} else {
|
||||
if (!extraParams.dimName) {
|
||||
Modal.warning({
|
||||
title: getLabel(111, "信息确认"),
|
||||
content: getLabel(111, "必要信息不完整,红色*为必填项!")
|
||||
title: getLabel(131329, "信息确认"),
|
||||
content: getLabel(383779, "必要信息不完整,红色*为必填项!")
|
||||
});
|
||||
return;
|
||||
}
|
||||
|
|
@ -109,7 +109,7 @@ class DimensionSlide extends Component {
|
|||
const { setting4RationGroupSpacing } = this.state;
|
||||
const bool = _.every(setting4RationGroupSpacing, it => it.startValue !== "" && it.endValue !== "" && it.startValue <= it.endValue);
|
||||
if (_.isEmpty(setting4RationGroupSpacing) || !bool) {
|
||||
message.warning(getLabel(111, "请完善分组设置相关数据!分组设置不能为空,起始值结束值必填,且起始值需小于结束值!"));
|
||||
message.warning(getLabel(543318, "请完善分组设置相关数据!分组设置不能为空,起始值结束值必填,且起始值需小于结束值!"));
|
||||
return;
|
||||
} else {
|
||||
payload = {
|
||||
|
|
@ -127,7 +127,7 @@ class DimensionSlide extends Component {
|
|||
const { setting4RationGroupIndividual } = this.state;
|
||||
const bool = _.every(setting4RationGroupIndividual, it => it.value !== "");
|
||||
if (_.isEmpty(setting4RationGroupIndividual) || !bool) {
|
||||
message.warning(getLabel(111, "请完善分组设置相关数据!分组设置不能为空,且数值必填"));
|
||||
message.warning(getLabel(543319, "请完善分组设置相关数据!分组设置不能为空,且数值必填"));
|
||||
return;
|
||||
} else {
|
||||
payload = {
|
||||
|
|
@ -141,11 +141,11 @@ class DimensionSlide extends Component {
|
|||
dimensionSave(payload).then(({ status, errormsg }) => {
|
||||
this.setState({ loading: false });
|
||||
if (status) {
|
||||
message.success(getLabel(111, "保存成功"));
|
||||
message.success(getLabel(22619, "保存成功"));
|
||||
onCancel(true);
|
||||
this.props.form.resetForm();
|
||||
} else {
|
||||
message.error(errormsg || getLabel(111, "保存失败"));
|
||||
message.error(errormsg || getLabel(22620, "保存失败"));
|
||||
}
|
||||
}).catch(() => this.setState({ loading: false }));
|
||||
};
|
||||
|
|
@ -176,15 +176,15 @@ class DimensionSlide extends Component {
|
|||
className="dimensionSlideWrapper"
|
||||
title={
|
||||
<div className="dimensionTitle">
|
||||
<span>{formId ? getLabel(111, "编辑统计维度") : getLabel(111, "新建统计维度")}</span>
|
||||
<Button type="primary" onClick={this.handleSave} loading={loading}>{getLabel(111, "保存")}</Button>
|
||||
<span>{formId ? getLabel(543407, "编辑统计维度") : getLabel(543314, "新建统计维度")}</span>
|
||||
<Button type="primary" onClick={this.handleSave} loading={loading}>{getLabel(537558, "保存")}</Button>
|
||||
</div>
|
||||
}
|
||||
>
|
||||
{getSearchs(form, condition, 1, false, this.formItemChange)}
|
||||
{
|
||||
dimType !== "QUALITATIVE" &&
|
||||
<WeaSearchGroup title={getLabel(111, "分组设置")} showGroup>
|
||||
<WeaSearchGroup title={getLabel(34105, "分组设置")} showGroup>
|
||||
{
|
||||
dimType === "RATION_GROUP_SPACING" &&
|
||||
<GroupSpacingEditTable onChange={this.handleConvertGroupDatasource}
|
||||
|
|
|
|||
|
|
@ -47,15 +47,15 @@ class DimensionTable extends Component {
|
|||
};
|
||||
dimensionDelete = (payload) => {
|
||||
Modal.confirm({
|
||||
title: getLabel(111, "信息确认"),
|
||||
content: getLabel(111, "确认要删除吗?"),
|
||||
title: getLabel(131329, "信息确认"),
|
||||
content: getLabel(388758, "确认要删除吗?"),
|
||||
onOk: () => {
|
||||
dimensionDelete(payload).then(({ status, errormsg }) => {
|
||||
if (status) {
|
||||
message.success(getLabel(111, "删除成功"));
|
||||
message.success(getLabel(502230, "删除成功"));
|
||||
this.dimensionList();
|
||||
} else {
|
||||
message.error(errormsg || getLabel(111, "删除失败"));
|
||||
message.error(errormsg || getLabel(20462, "删除失败"));
|
||||
}
|
||||
});
|
||||
}
|
||||
|
|
@ -67,7 +67,7 @@ class DimensionTable extends Component {
|
|||
const { onEdit } = this.props;
|
||||
const pagination = {
|
||||
...pageInfo,
|
||||
showTotal: total => `${getLabel(111, "共")} ${total} ${getLabel(111, "条")}`,
|
||||
showTotal: total => `${getLabel(18609, "共")} ${total} ${getLabel(18256, "条")}`,
|
||||
showQuickJumper: true,
|
||||
showSizeChanger: true,
|
||||
pageSizeOptions: ["10", "20", "50", "100"],
|
||||
|
|
@ -83,22 +83,22 @@ class DimensionTable extends Component {
|
|||
}
|
||||
};
|
||||
const columns = [
|
||||
{ dataIndex: "dimName", title: getLabel(111, "统计维度") },
|
||||
{ dataIndex: "remark", title: getLabel(111, "描述") },
|
||||
{ dataIndex: "dimType", title: getLabel(111, "维度类型") },
|
||||
{ dataIndex: "dimName", title: getLabel(506800, "统计维度") },
|
||||
{ dataIndex: "remark", title: getLabel(433, "描述") },
|
||||
{ dataIndex: "dimType", title: getLabel(389137, "维度类型") },
|
||||
{
|
||||
dataIndex: "operate", title: getLabel(111, "操作"),
|
||||
dataIndex: "operate", title: getLabel(30585, "操作"),
|
||||
render: (_, record) => {
|
||||
return (
|
||||
<span className="space10">
|
||||
{
|
||||
record.canEdit &&
|
||||
<a href="javascript: void(0);" onClick={() => onEdit(record.id)}>{getLabel(111, "编辑")}</a>
|
||||
<a href="javascript: void(0);" onClick={() => onEdit(record.id)}>{getLabel(501169, "编辑")}</a>
|
||||
}
|
||||
{
|
||||
record.canDelete &&
|
||||
<a href="javascript: void(0);"
|
||||
onClick={() => this.dimensionDelete([record.id])}>{getLabel(111, "删除")}</a>
|
||||
onClick={() => this.dimensionDelete([record.id])}>{getLabel(535052, "删除")}</a>
|
||||
}
|
||||
</span>
|
||||
);
|
||||
|
|
|
|||
|
|
@ -55,7 +55,7 @@ class EmployeeDetails extends Component {
|
|||
width: 80,
|
||||
render: (_, record) => {
|
||||
return <a target="_blank"
|
||||
href={`${window.location.origin}/spa/hrmSalary/static/index.html#/main/hrmSalary/analysisOfSalaryStatistics/${record.id}?name=${record.name}&dept=${record.department || ""}`}>{getLabel(111, "查看")}</a>;
|
||||
href={`${window.location.origin}/spa/hrmSalary/static/index.html#/main/hrmSalary/analysisOfSalaryStatistics/${record.id}?name=${record.name}&dept=${record.department || ""}`}>{getLabel(33564, "查看")}</a>;
|
||||
}
|
||||
}]
|
||||
});
|
||||
|
|
@ -67,7 +67,7 @@ class EmployeeDetails extends Component {
|
|||
const { dataSource, loading, columns, pageInfo } = this.state;
|
||||
const pagination = {
|
||||
...pageInfo,
|
||||
showTotal: total => `${getLabel(111, "共")} ${total} ${getLabel(111, "条")}`,
|
||||
showTotal: total => `${getLabel(18609, "共")} ${total} ${getLabel(18256, "条")}`,
|
||||
showQuickJumper: true,
|
||||
showSizeChanger: true,
|
||||
pageSizeOptions: ["10", "20", "50", "100"],
|
||||
|
|
|
|||
|
|
@ -32,7 +32,7 @@ class GroupIndividualEditTable extends Component {
|
|||
const { dataSource } = this.state;
|
||||
const columns = [
|
||||
{
|
||||
title: getLabel(111, "分组设置值"),
|
||||
title: getLabel(543320, "分组设置值"),
|
||||
dataIndex: "value",
|
||||
key: "value",
|
||||
com: [
|
||||
|
|
|
|||
|
|
@ -39,7 +39,7 @@ class GroupSpacingEditTable extends Component {
|
|||
const { dataSource } = this.state;
|
||||
const columns = [
|
||||
{
|
||||
title: getLabel(111, "起始值"),
|
||||
title: getLabel(541412, "起始值"),
|
||||
dataIndex: "startValue",
|
||||
key: "startValue",
|
||||
com: [
|
||||
|
|
@ -47,19 +47,19 @@ class GroupSpacingEditTable extends Component {
|
|||
]
|
||||
},
|
||||
{
|
||||
title: getLabel(111, "含"),
|
||||
title: getLabel(33864, "含"),
|
||||
dataIndex: "includeStart",
|
||||
key: "includeStart",
|
||||
com: [
|
||||
{
|
||||
type: "CHECKBOX",
|
||||
key: "includeStart",
|
||||
otherParams: { content: getLabel(111, "含") }
|
||||
otherParams: { content: getLabel(33864, "含") }
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
title: getLabel(111, "至"),
|
||||
title: getLabel(15322, "至"),
|
||||
dataIndex: "to",
|
||||
key: "to",
|
||||
com: [
|
||||
|
|
@ -67,7 +67,7 @@ class GroupSpacingEditTable extends Component {
|
|||
]
|
||||
},
|
||||
{
|
||||
title: getLabel(111, "结束值"),
|
||||
title: getLabel(508931, "结束值"),
|
||||
dataIndex: "endValue",
|
||||
key: "endValue",
|
||||
com: [
|
||||
|
|
@ -75,14 +75,14 @@ class GroupSpacingEditTable extends Component {
|
|||
]
|
||||
},
|
||||
{
|
||||
title: getLabel(111, "含"),
|
||||
title: getLabel(33864, "含"),
|
||||
dataIndex: "includeEnd",
|
||||
key: "includeEnd",
|
||||
com: [
|
||||
{
|
||||
type: "CHECKBOX",
|
||||
key: "includeEnd",
|
||||
otherParams: { content: getLabel(111, "含") }
|
||||
otherParams: { content: getLabel(33864, "含") }
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
@ -90,7 +90,7 @@ class GroupSpacingEditTable extends Component {
|
|||
return (
|
||||
<WeaTableEdit
|
||||
draggable={true} deleteConfirm columns={columns}
|
||||
datas={_.map(dataSource, item => ({ ...item, to: getLabel(111, "至") }))}
|
||||
datas={_.map(dataSource, item => ({ ...item, to: getLabel(15322, "至") }))}
|
||||
showCopy={false} onChange={this.handleChangeTableData}
|
||||
/>
|
||||
);
|
||||
|
|
|
|||
|
|
@ -34,16 +34,16 @@ class ReportList extends Component {
|
|||
};
|
||||
reportStatisticsReportDelete = (payload) => {
|
||||
Modal.confirm({
|
||||
title: getLabel(111, "信息确认"),
|
||||
content: getLabel(111, "确认删除本条数据吗?"),
|
||||
title: getLabel(131329, "信息确认"),
|
||||
content: getLabel(543231, "确认删除本条数据吗?"),
|
||||
onOk: () => {
|
||||
const { reportName = "" } = this.props;
|
||||
reportStatisticsReportDelete(payload).then(({ status, errormsg }) => {
|
||||
if (status) {
|
||||
message.success(getLabel(111, "删除成功"));
|
||||
message.success(getLabel(502230, "删除成功"));
|
||||
this.reportStatisticsReportList({ reportName });
|
||||
} else {
|
||||
message.error(errormsg || getLabel(111, "删除失败"));
|
||||
message.error(errormsg || getLabel(20462, "删除失败"));
|
||||
}
|
||||
});
|
||||
}
|
||||
|
|
@ -71,28 +71,31 @@ class ReportList extends Component {
|
|||
return (
|
||||
<Row gutter={16} className="reportRow">
|
||||
{
|
||||
_.isEmpty(dataSource) ? <div className="empty">{getLabel(111, "暂无数据")}</div> :
|
||||
_.isEmpty(dataSource) ? <div className="empty">{getLabel(83553, "暂无数据")}</div> :
|
||||
_.map(dataSource, it => {
|
||||
const { reportName, dimension, id, dimensionId } = it;
|
||||
const { reportName, dimension, id, dimensionId, isShare } = it;
|
||||
return <Col className="gutter-row" span={6} onClick={() => this.handleGoReportView(id)}>
|
||||
<div className="card-item">
|
||||
<div className="cardLeft"><i className="icon-coms-fa"/></div>
|
||||
<div className="cardCenter">
|
||||
<span className="reportName">{reportName}</span>
|
||||
<div className="dimension">
|
||||
<div className="label">{getLabel(111, "统计维度")}:</div>
|
||||
<div className="label">{getLabel(506800, "统计维度")}:</div>
|
||||
<div className="value">{dimension}</div>
|
||||
</div>
|
||||
</div>
|
||||
<div className="cardRight">
|
||||
<Dropdown overlay={
|
||||
<Menu onClick={e => this.handleOptsClick(e, id, dimensionId)}>
|
||||
<Menu.Item key="edit">{getLabel(111, "编辑")}</Menu.Item>
|
||||
<Menu.Item key="delete">{getLabel(111, "删除")}</Menu.Item>
|
||||
</Menu>
|
||||
}>
|
||||
<Button type="ghost"><i className="icon-coms-more"/></Button>
|
||||
</Dropdown>
|
||||
{
|
||||
!isShare &&
|
||||
<Dropdown overlay={
|
||||
<Menu onClick={e => this.handleOptsClick(e, id, dimensionId)}>
|
||||
<Menu.Item key="edit">{getLabel(501169, "编辑")}</Menu.Item>
|
||||
<Menu.Item key="delete">{getLabel(535052, "删除")}</Menu.Item>
|
||||
</Menu>
|
||||
}>
|
||||
<Button type="ghost"><i className="icon-coms-more"/></Button>
|
||||
</Dropdown>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
</Col>;
|
||||
|
|
|
|||
|
|
@ -31,15 +31,15 @@ class StatisticsModal extends Component {
|
|||
this.setState({ loading: false });
|
||||
if (status) {
|
||||
onCancel(true);
|
||||
message.success(getLabel(111, "保存成功"));
|
||||
message.success(getLabel(22619, "保存成功"));
|
||||
form.resetForm();
|
||||
} else {
|
||||
message.error(errormsg || getLabel(111, "保存失败"));
|
||||
message.error(errormsg || getLabel(22620, "保存失败"));
|
||||
}
|
||||
}).catch(() => this.setState({ loading: false }));
|
||||
} else {
|
||||
Modal.warning({
|
||||
title: getLabel(111, "信息确认"),
|
||||
title: getLabel(131329, "信息确认"),
|
||||
content: getLabel(111, "必要信息不完整,红色*为必填项!")
|
||||
});
|
||||
}
|
||||
|
|
|
|||
|
|
@ -0,0 +1,494 @@
|
|||
/*
|
||||
* Author: 黎永顺
|
||||
* name: 个税在线申报-银行端缴款凭证打印查看页面
|
||||
* Description:
|
||||
* Date: 2023/8/24
|
||||
*/
|
||||
import React, { Component } from "react";
|
||||
import { Button, message, Spin } from "antd";
|
||||
import { WeaLocaleProvider } from "ecCom";
|
||||
import { printDom } from "../../util";
|
||||
import { getQueryString } from "../../util/url";
|
||||
import { taxPaymentVoucherPrintFeedback } from "../../apis/declare";
|
||||
import "./index.less";
|
||||
|
||||
const { getLabel } = WeaLocaleProvider;
|
||||
|
||||
class Index extends Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
loading: false,
|
||||
bankVoucherDetail: {}
|
||||
};
|
||||
}
|
||||
|
||||
componentDidMount() {
|
||||
this.taxPaymentVoucherPrintFeedback();
|
||||
}
|
||||
|
||||
taxPaymentVoucherPrintFeedback = () => {
|
||||
const payload = {
|
||||
taxDeclareRecordId: getQueryString("taxDeclareRecordId"),
|
||||
taxAgentId: getQueryString("taxAgentId"),
|
||||
taxYearMonth: getQueryString("taxYearMonth"),
|
||||
checkFeedback: 0
|
||||
};
|
||||
this.setState({ loading: true });
|
||||
taxPaymentVoucherPrintFeedback(payload).then(({ status, data, errormsg }) => {
|
||||
this.setState({ loading: false });
|
||||
if (status) {
|
||||
this.setState({ bankVoucherDetail: data });
|
||||
} else {
|
||||
message.error(errormsg || "");
|
||||
}
|
||||
}).catch(() => this.setState({ loading: false }));
|
||||
};
|
||||
print = () => {
|
||||
printDom({
|
||||
hideDomId: "header_print_btn"
|
||||
});
|
||||
};
|
||||
|
||||
render() {
|
||||
const { loading, bankVoucherDetail } = this.state;
|
||||
if (loading) {
|
||||
return <div className="loading-layout">
|
||||
<Spin spinning={loading}/>
|
||||
</div>;
|
||||
}
|
||||
return (
|
||||
<div className="printBankLayout">
|
||||
<div className="print-bank-voucher-container">
|
||||
<div id="header_print_btn">
|
||||
<Button type="primary" onClick={this.print}>{getLabel(111, "打印")}</Button>
|
||||
</div>
|
||||
<div className="content">
|
||||
<div id="bank_voucher_detail_area" style={{
|
||||
display: "flex",
|
||||
flexDirection: "column",
|
||||
width: "1000px"
|
||||
}}>
|
||||
<div style={{
|
||||
"height": " calc(36 * 1px)",
|
||||
"fontSize": "calc(20 * 1px)",
|
||||
"textAlign": "center",
|
||||
"lineHeight": " calc(32 * 1px)",
|
||||
"fontWeight": "900"
|
||||
}}>{getLabel(111, "银行端查询缴税凭证")}</div>
|
||||
<div style={{
|
||||
height: "calc(28 * 1px)",
|
||||
display: "flex",
|
||||
alignItems: "center",
|
||||
justifyContent: "space-between"
|
||||
}}>
|
||||
<div style={{ display: "flex" }}>
|
||||
<div className="label">{getLabel(111, "银行端查询缴税凭证号:")}</div>
|
||||
<div className="value">{bankVoucherDetail.voucherNo || ""}</div>
|
||||
</div>
|
||||
<div className="time">{bankVoucherDetail.firstPrintDate}</div>
|
||||
</div>
|
||||
|
||||
<div style={{
|
||||
borderLeft: "calc(2 * 1px) solid #999",
|
||||
borderRight: "calc(2 * 1px) solid #999"
|
||||
}}>
|
||||
<div style={{
|
||||
width: "100%",
|
||||
minHeight: "calc(50 * 1px)",
|
||||
display: "flex",
|
||||
alignItems: "center",
|
||||
flexGrow: "0",
|
||||
flexShrink: "0",
|
||||
borderTop: "calc(2 * 1px) solid #999"
|
||||
}}>
|
||||
<div style={{
|
||||
width: "50%",
|
||||
alignSelf: "stretch",
|
||||
display: "flex",
|
||||
alignItems: "center"
|
||||
}}>
|
||||
<div className="label" style={{
|
||||
height: "100%",
|
||||
padding: "calc(16 * 1px)",
|
||||
flexBasis: "40%",
|
||||
display: "flex",
|
||||
alignItems: "center",
|
||||
borderRight: "calc(2 * 1px) solid #999",
|
||||
flexShrink: "0",
|
||||
flexGrow: "0"
|
||||
}}>{getLabel(111, "纳税人识别码")}</div>
|
||||
<div className="value" style={{
|
||||
flexBasis: "60%",
|
||||
flexShrink: "0",
|
||||
flexGrow: "0",
|
||||
padding: "calc(16 * 1px)"
|
||||
}}>{bankVoucherDetail.taxCode || ""}</div>
|
||||
</div>
|
||||
<div style={{
|
||||
width: "50%",
|
||||
alignSelf: "stretch",
|
||||
display: "flex",
|
||||
alignItems: "center"
|
||||
}}>
|
||||
<div className="label" style={{
|
||||
height: "100%",
|
||||
padding: "calc(16 * 1px)",
|
||||
borderLeft: "calc(2 * 1px) solid #999",
|
||||
flexBasis: "40%",
|
||||
display: "flex",
|
||||
alignItems: "center",
|
||||
borderRight: "calc(2 * 1px) solid #999",
|
||||
flexShrink: "0",
|
||||
flexGrow: "0"
|
||||
}}>{getLabel(111, "税务机关代码")}</div>
|
||||
<div className="value" style={{
|
||||
width: "50%",
|
||||
alignSelf: "stretch",
|
||||
display: "flex",
|
||||
alignItems: "center",
|
||||
padding: "calc(16 * 1px)"
|
||||
}}>{bankVoucherDetail.taxAuthoritiesNo || ""}</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div style={{
|
||||
width: "100%",
|
||||
minHeight: "calc(50 * 1px)",
|
||||
display: "flex",
|
||||
alignItems: "center",
|
||||
flexGrow: "0",
|
||||
flexShrink: "0",
|
||||
borderTop: "calc(2 * 1px) solid #999"
|
||||
}}>
|
||||
<div style={{
|
||||
width: "50%",
|
||||
alignSelf: "stretch",
|
||||
display: "flex",
|
||||
alignItems: "center"
|
||||
}}>
|
||||
<div className="label" style={{
|
||||
height: "100%",
|
||||
padding: "calc(16 * 1px)",
|
||||
flexBasis: "40%",
|
||||
display: "flex",
|
||||
alignItems: "center",
|
||||
borderRight: "calc(2 * 1px) solid #999",
|
||||
flexShrink: "0",
|
||||
flexGrow: "0"
|
||||
}}>{getLabel(111, "纳税人名称")}</div>
|
||||
<div className="value" style={{
|
||||
flexBasis: "60%",
|
||||
flexShrink: "0",
|
||||
flexGrow: "0",
|
||||
padding: "calc(16 * 1px)"
|
||||
}}>{bankVoucherDetail.taxAgentName || ""}</div>
|
||||
</div>
|
||||
<div style={{
|
||||
width: "50%",
|
||||
alignSelf: "stretch",
|
||||
display: "flex",
|
||||
alignItems: "center"
|
||||
}}>
|
||||
<div className="label" style={{
|
||||
height: "100%",
|
||||
padding: "calc(16 * 1px)",
|
||||
borderLeft: "calc(2 * 1px) solid #999",
|
||||
flexBasis: "40%",
|
||||
display: "flex",
|
||||
alignItems: "center",
|
||||
borderRight: "calc(2 * 1px) solid #999",
|
||||
flexShrink: "0",
|
||||
flexGrow: "0"
|
||||
}}>{getLabel(111, "税务机关名称")}</div>
|
||||
<div className="value" style={{
|
||||
width: "50%",
|
||||
alignSelf: "stretch",
|
||||
display: "flex",
|
||||
alignItems: "center",
|
||||
padding: "calc(16 * 1px)"
|
||||
}}>{bankVoucherDetail.taxAuthoritiesName}</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div style={{
|
||||
width: "100%",
|
||||
minHeight: "calc(50 * 1px)",
|
||||
display: "flex",
|
||||
alignItems: "center",
|
||||
flexGrow: "0",
|
||||
flexShrink: "0",
|
||||
borderTop: "calc(2 * 1px) solid #999"
|
||||
}}>
|
||||
<div style={{
|
||||
width: "50%",
|
||||
alignSelf: "stretch",
|
||||
display: "flex",
|
||||
alignItems: "center"
|
||||
}}>
|
||||
<div className="label" style={{
|
||||
height: "100%",
|
||||
padding: "calc(16 * 1px)",
|
||||
flexBasis: "40%",
|
||||
display: "flex",
|
||||
alignItems: "center",
|
||||
borderRight: "calc(2 * 1px) solid #999",
|
||||
flexShrink: "0",
|
||||
flexGrow: "0"
|
||||
}}>{getLabel(111, "付款人名称")}</div>
|
||||
<div className="value" style={{
|
||||
flexBasis: "60%",
|
||||
flexShrink: "0",
|
||||
flexGrow: "0",
|
||||
padding: "calc(16 * 1px)"
|
||||
}}>{}</div>
|
||||
</div>
|
||||
<div style={{
|
||||
width: "50%",
|
||||
alignSelf: "stretch",
|
||||
display: "flex",
|
||||
alignItems: "center"
|
||||
}}>
|
||||
<div className="label" style={{
|
||||
height: "100%",
|
||||
padding: "calc(16 * 1px)",
|
||||
borderLeft: "calc(2 * 1px) solid #999",
|
||||
flexBasis: "40%",
|
||||
display: "flex",
|
||||
alignItems: "center",
|
||||
borderRight: "calc(2 * 1px) solid #999",
|
||||
flexShrink: "0",
|
||||
flexGrow: "0"
|
||||
}}>{getLabel(111, "开户银行名称")}</div>
|
||||
<div className="value" style={{
|
||||
width: "50%",
|
||||
alignSelf: "stretch",
|
||||
display: "flex",
|
||||
alignItems: "center",
|
||||
padding: "calc(16 * 1px)"
|
||||
}}>{}</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div style={{
|
||||
width: "100%",
|
||||
minHeight: "calc(50 * 1px)",
|
||||
display: "flex",
|
||||
alignItems: "center",
|
||||
flexGrow: "0",
|
||||
flexShrink: "0",
|
||||
borderTop: "calc(2 * 1px) solid #999"
|
||||
}}>
|
||||
<div style={{
|
||||
width: "50%",
|
||||
alignSelf: "stretch",
|
||||
display: "flex",
|
||||
alignItems: "center"
|
||||
}}>
|
||||
<div className="label" style={{
|
||||
height: "100%",
|
||||
padding: "calc(16 * 1px)",
|
||||
flexBasis: "40%",
|
||||
display: "flex",
|
||||
alignItems: "center",
|
||||
borderRight: "calc(2 * 1px) solid #999",
|
||||
flexShrink: "0",
|
||||
flexGrow: "0"
|
||||
}}>{getLabel(111, "付款人账号")}</div>
|
||||
<div className="value" style={{
|
||||
flexBasis: "60%",
|
||||
flexShrink: "0",
|
||||
flexGrow: "0",
|
||||
padding: "calc(16 * 1px)"
|
||||
}}>{}</div>
|
||||
</div>
|
||||
<div style={{
|
||||
width: "50%",
|
||||
alignSelf: "stretch",
|
||||
display: "flex",
|
||||
alignItems: "center"
|
||||
}}>
|
||||
<div className="label" style={{
|
||||
height: "100%",
|
||||
padding: "calc(16 * 1px)",
|
||||
borderLeft: "calc(2 * 1px) solid #999",
|
||||
flexBasis: "40%",
|
||||
display: "flex",
|
||||
alignItems: "center",
|
||||
borderRight: "calc(2 * 1px) solid #999",
|
||||
flexShrink: "0",
|
||||
flexGrow: "0"
|
||||
}}>{getLabel(111, "税款限缴日期")}</div>
|
||||
<div className="value" style={{
|
||||
width: "50%",
|
||||
alignSelf: "stretch",
|
||||
display: "flex",
|
||||
alignItems: "center",
|
||||
padding: "calc(16 * 1px)"
|
||||
}}>{bankVoucherDetail.deadline || ""}</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div className="table" style={{
|
||||
display: "flex",
|
||||
flexDirection: "column",
|
||||
borderBottom: "calc(2 * 1px) solid #999",
|
||||
width: "100%"
|
||||
}}>
|
||||
<div className="thead" style={{
|
||||
borderTop: "calc(2 * 1px) solid #999",
|
||||
display: "flex",
|
||||
width: "100%",
|
||||
justifyContent: "space-between"
|
||||
}}>
|
||||
<div style={{
|
||||
width: "calc(100%/ 3)",
|
||||
padding: "calc(16 * 1px)",
|
||||
minHeight: "calc(50 * 1px)",
|
||||
display: "flex",
|
||||
alignItems: "center",
|
||||
flexGrow: "0",
|
||||
flexShrink: "0"
|
||||
}}>{getLabel(111, "征收顶目名称")}</div>
|
||||
<div style={{
|
||||
width: "calc(100%/ 3)",
|
||||
padding: "calc(16 * 1px)",
|
||||
minHeight: "calc(50 * 1px)",
|
||||
display: "flex",
|
||||
alignItems: "center",
|
||||
borderLeft: "calc(2 * 1px) solid #999",
|
||||
flexGrow: "0",
|
||||
flexShrink: "0"
|
||||
}}>{getLabel(111, "征收品目名称")}</div>
|
||||
<div style={{
|
||||
width: "calc(100%/ 3)",
|
||||
padding: "calc(16 * 1px)",
|
||||
minHeight: "calc(50 * 1px)",
|
||||
display: "flex",
|
||||
alignItems: "center",
|
||||
borderLeft: "calc(2 * 1px) solid #999",
|
||||
flexGrow: "0",
|
||||
flexShrink: "0"
|
||||
}}>{getLabel(111, "应繳税额")}</div>
|
||||
</div>
|
||||
<div className="tbody" style={{
|
||||
display: "flex",
|
||||
flexDirection: "column",
|
||||
width: "100%"
|
||||
}}>
|
||||
{
|
||||
!_.isEmpty(bankVoucherDetail.details) ? bankVoucherDetail.details.map((row, index) => (
|
||||
<div className="tr" key={index} style={{
|
||||
display: "flex",
|
||||
borderTop: " calc(2 * 1px) solid #999",
|
||||
justifyContent: "space-between"
|
||||
}}>
|
||||
<div style={{
|
||||
width: "calc(100%/ 3)",
|
||||
padding: "calc(16 * 1px)",
|
||||
minHeight: " calc(50 * 1px)",
|
||||
display: "flex",
|
||||
alignItems: "center",
|
||||
flexGrow: "0",
|
||||
flexShrink: "0"
|
||||
}}>{row.paymentCode}</div>
|
||||
<div style={{
|
||||
width: "calc(100%/ 3)",
|
||||
padding: "calc(16 * 1px)",
|
||||
minHeight: " calc(50 * 1px)",
|
||||
display: "flex",
|
||||
alignItems: "center",
|
||||
borderLeft: "calc(2 * 1px) solid #999",
|
||||
flexGrow: "0",
|
||||
flexShrink: "0"
|
||||
}}>{row.paymentItem}</div>
|
||||
<div style={{
|
||||
width: "calc(100%/ 3)",
|
||||
padding: "calc(16 * 1px)",
|
||||
minHeight: " calc(50 * 1px)",
|
||||
display: "flex",
|
||||
alignItems: "center",
|
||||
borderLeft: "calc(2 * 1px) solid #999",
|
||||
flexGrow: "0",
|
||||
flexShrink: "0"
|
||||
}}>{row.payAmount}</div>
|
||||
</div>
|
||||
)) : null
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
<div style={{
|
||||
minHeight: "calc(50 * 1px)",
|
||||
display: "flex",
|
||||
alignItems: "center",
|
||||
padding: "calc(16 * 1px)",
|
||||
borderBottom: "calc(2 * 1px) solid #999"
|
||||
}}>{getLabel(111, "金额合计(小写):")} {bankVoucherDetail.lowerFormatAmount}</div>
|
||||
<div style={{
|
||||
minHeight: "calc(50 * 1px)",
|
||||
display: "flex",
|
||||
alignItems: "center",
|
||||
padding: "calc(16 * 1px)",
|
||||
borderBottom: "calc(2 * 1px) solid #999"
|
||||
}}>{getLabel(111, "金额合计(大写):")} {bankVoucherDetail.upperFormatAmount}</div>
|
||||
|
||||
<div className="signet" style={{
|
||||
minHeight: "calc(140 * 1px)",
|
||||
width: "100%",
|
||||
display: "flex",
|
||||
alignItems: "center",
|
||||
borderBottom: " calc(2 * 1px) solid #999",
|
||||
justifyContent: "space-between"
|
||||
}}>
|
||||
<div className="item one" style={{
|
||||
alignSelf: "stretch",
|
||||
width: "calc(100%/ 3)",
|
||||
display: "flex",
|
||||
alignItems: "flex-start",
|
||||
justifyContent: "center",
|
||||
flexDirection: "column",
|
||||
padding: "calc(16 * 1px)"
|
||||
|
||||
}}>
|
||||
<div className="drawee" style={{
|
||||
marginBottom: "calc(16 * 1px)"
|
||||
}}>{getLabel(111, "付款人 (签章)")}</div>
|
||||
<div className="operator">{getLabel(111, "经办人 (签章)")}</div>
|
||||
</div>
|
||||
<div style={{
|
||||
alignSelf: "stretch",
|
||||
borderLeft: "calc(2 * 1px) solid #999",
|
||||
width: "calc(100%/ 3)",
|
||||
display: "flex",
|
||||
alignItems: "flex-start",
|
||||
justifyContent: "center",
|
||||
flexDirection: "column",
|
||||
padding: "calc(16 * 1px)"
|
||||
}}>
|
||||
<div>{getLabel(111, "银行记账员")}</div>
|
||||
<div> {getLabel(111, "(签章)")}</div>
|
||||
</div>
|
||||
<div style={{
|
||||
alignSelf: "stretch",
|
||||
borderLeft: "calc(2 * 1px) solid #999",
|
||||
width: "calc(100%/ 3)",
|
||||
display: "flex",
|
||||
alignItems: "flex-start",
|
||||
justifyContent: "center",
|
||||
flexDirection: "column",
|
||||
padding: "calc(16 * 1px)"
|
||||
}}>
|
||||
<div>{getLabel(111, "备注:")}</div>
|
||||
<div> {bankVoucherDetail.remark}</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
export default Index;
|
||||
|
|
@ -0,0 +1,30 @@
|
|||
.loading-layout {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.printBankLayout {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
overflow-y: auto;
|
||||
|
||||
.print-bank-voucher-container {
|
||||
font-size: 14px;
|
||||
|
||||
#header_print_btn {
|
||||
display: flex;
|
||||
padding: calc(16 * 1px) calc(32 * 1px) 0;
|
||||
justify-content: flex-end;
|
||||
}
|
||||
|
||||
.content {
|
||||
padding: calc(32 * 1px) 0 calc(16 * 1px);
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -270,3 +270,9 @@
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
.salaryMonthTip-layout{
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -6,9 +6,10 @@ import EditSalaryDetail from "./editSalaryDetail";
|
|||
import SlideModalTitle from "../../components/slideModalTitle";
|
||||
import { getQueryString } from "../../util/url";
|
||||
import { inject, observer } from "mobx-react";
|
||||
import ProgressModal from "../../components/progressModal";
|
||||
import { SalaryMonthTip } from "./userSure";
|
||||
import { toJS } from "mobx";
|
||||
import "./index.less";
|
||||
import ProgressModal from "../../components/progressModal";
|
||||
|
||||
@inject("calculateStore", "taxAgentStore")
|
||||
@observer
|
||||
|
|
@ -151,6 +152,7 @@ export default class SalaryDetail extends React.Component {
|
|||
progressVisible: false,
|
||||
progress: 0
|
||||
}, () => {
|
||||
const { current, pageSize } = this.pageInfo;
|
||||
const childFrameObj = document.getElementById("atdTable");
|
||||
const payload = {
|
||||
type: "PR",
|
||||
|
|
@ -158,7 +160,8 @@ export default class SalaryDetail extends React.Component {
|
|||
url: "/api/bs/hrmsalary/salaryacct/acctresult/list",
|
||||
queryParams: {
|
||||
salaryAcctRecordId,
|
||||
...this.props.employeeName
|
||||
...this.props.employeeName,
|
||||
current, pageSize
|
||||
}
|
||||
};
|
||||
childFrameObj.contentWindow.postMessage(JSON.stringify(payload), "*");
|
||||
|
|
@ -186,13 +189,15 @@ export default class SalaryDetail extends React.Component {
|
|||
this.setState({ loading: false });
|
||||
const childFrameObj = document.getElementById("atdTable");
|
||||
const salaryAcctRecordId = getQueryString("id");
|
||||
const { current, pageSize } = this.pageInfo;
|
||||
const payload = {
|
||||
type: "PR",
|
||||
listType: "",
|
||||
url: "/api/bs/hrmsalary/salaryacct/acctresult/list",
|
||||
queryParams: {
|
||||
salaryAcctRecordId,
|
||||
...this.props.employeeName
|
||||
...this.props.employeeName,
|
||||
current, pageSize
|
||||
}
|
||||
};
|
||||
childFrameObj.contentWindow.postMessage(JSON.stringify(payload), "*");
|
||||
|
|
@ -211,17 +216,9 @@ export default class SalaryDetail extends React.Component {
|
|||
<div className="salaryBarWrapper">
|
||||
<span>薪资所属月:{baseSalarySobCycle.salaryMonth}</span>
|
||||
<WeaHelpfulTip
|
||||
style={{ marginLeft: "10px" }}
|
||||
width={200}
|
||||
title={
|
||||
`薪资周期\n
|
||||
${baseSalarySobCycle.salaryCycle && baseSalarySobCycle.salaryCycle.fromDate}至${baseSalarySobCycle.salaryCycle && baseSalarySobCycle.salaryCycle.endDate}\n
|
||||
税款所属期\n
|
||||
${baseSalarySobCycle.taxCycle}\n
|
||||
考勤取值周期\n
|
||||
${baseSalarySobCycle.attendCycle && baseSalarySobCycle.attendCycle.fromDate}至${baseSalarySobCycle.attendCycle && baseSalarySobCycle.attendCycle.endDate}\n
|
||||
福利台账月份\n
|
||||
引用${baseSalarySobCycle.socialSecurityCycle}的福利台账数据`}
|
||||
style={{ marginLeft: 10 }}
|
||||
title={!_.isEmpty(baseSalarySobCycle) ?
|
||||
<SalaryMonthTip baseSalarySobCycle={baseSalarySobCycle}/> : ""}
|
||||
placement="topLeft"
|
||||
/>
|
||||
{/*暂时隐藏*/}
|
||||
|
|
|
|||
|
|
@ -1,10 +1,20 @@
|
|||
import React from "react";
|
||||
import { Button, Col, Icon, message, Modal, Row } from "antd";
|
||||
import { WeaBrowser, WeaFormItem, WeaHelpfulTip, WeaInput, WeaSearchGroup, WeaSelect, WeaTab } from "ecCom";
|
||||
import {
|
||||
WeaBrowser,
|
||||
WeaFormItem,
|
||||
WeaHelpfulTip,
|
||||
WeaInput,
|
||||
WeaLocaleProvider,
|
||||
WeaSearchGroup,
|
||||
WeaSelect,
|
||||
WeaTab
|
||||
} from "ecCom";
|
||||
import { inject, observer } from "mobx-react";
|
||||
import "./index.less";
|
||||
import { getQueryString } from "../../util/url";
|
||||
import "./index.less";
|
||||
|
||||
const { getLabel } = WeaLocaleProvider;
|
||||
@inject("calculateStore", "salaryFileStore")
|
||||
@observer
|
||||
export default class UserSure extends React.Component {
|
||||
|
|
@ -120,7 +130,7 @@ export default class UserSure extends React.Component {
|
|||
url: "/api/bs/hrmsalary/salaryacct/acctemployee/list",
|
||||
queryParams: {
|
||||
salaryAcctRecordId,
|
||||
...this.state.searchItemsValue,
|
||||
...this.state.searchItemsValue
|
||||
}
|
||||
};
|
||||
childFrameObj.contentWindow.postMessage(JSON.stringify(payload), "*"); //window.postMessage
|
||||
|
|
@ -375,12 +385,8 @@ export default class UserSure extends React.Component {
|
|||
<Row>
|
||||
<Col span={6}>
|
||||
薪资所属月:<WeaHelpfulTip
|
||||
width={100}
|
||||
title={`薪资周期\n${baseSalarySobCycle.salaryCycle &&
|
||||
baseSalarySobCycle.salaryCycle.fromDate}至${baseSalarySobCycle.salaryCycle &&
|
||||
baseSalarySobCycle.salaryCycle.endDate}\n税款所属期\n${baseSalarySobCycle.taxCycle}\n考勤取值周期\n${baseSalarySobCycle.attendCycle &&
|
||||
baseSalarySobCycle.attendCycle.fromDate}至${baseSalarySobCycle.attendCycle &&
|
||||
baseSalarySobCycle.attendCycle.endDate}\n福利台账月份\n引用${baseSalarySobCycle.socialSecurityCycle}的福利台账数据`}
|
||||
title={!_.isEmpty(baseSalarySobCycle) ?
|
||||
<SalaryMonthTip baseSalarySobCycle={baseSalarySobCycle}/> : ""}
|
||||
placement="topLeft"
|
||||
/>
|
||||
</Col>
|
||||
|
|
@ -430,7 +436,7 @@ export default class UserSure extends React.Component {
|
|||
url: "/api/bs/hrmsalary/salaryacct/acctemployee/list",
|
||||
queryParams: {
|
||||
salaryAcctRecordId,
|
||||
...this.state.searchItemsValue,
|
||||
...this.state.searchItemsValue
|
||||
}
|
||||
};
|
||||
childFrameObj.contentWindow.postMessage(JSON.stringify(payload), "*"); //window.postMessage
|
||||
|
|
@ -460,7 +466,7 @@ export default class UserSure extends React.Component {
|
|||
url: "/api/bs/hrmsalary/salaryacct/reducedemployee/list",
|
||||
queryParams: {
|
||||
salaryAcctRecordId,
|
||||
...this.state.searchItemsValue,
|
||||
...this.state.searchItemsValue
|
||||
}
|
||||
};
|
||||
childFrameObj.contentWindow.postMessage(JSON.stringify(payload), "*");
|
||||
|
|
@ -490,7 +496,7 @@ export default class UserSure extends React.Component {
|
|||
url: "/api/bs/hrmsalary/salaryacct/addedemployee/list",
|
||||
queryParams: {
|
||||
salaryAcctRecordId,
|
||||
...this.state.searchItemsValue,
|
||||
...this.state.searchItemsValue
|
||||
}
|
||||
};
|
||||
childFrameObj.contentWindow.postMessage(JSON.stringify(payload), "*");
|
||||
|
|
@ -587,3 +593,32 @@ export default class UserSure extends React.Component {
|
|||
);
|
||||
}
|
||||
}
|
||||
|
||||
export const SalaryMonthTip = (props) => {
|
||||
const { baseSalarySobCycle } = props;
|
||||
const { salaryCycle, taxCycle, attendCycle, socialSecurityCycle } = baseSalarySobCycle;
|
||||
const { fromDate: salaryCycleFromDate, endDate: salaryCycleEndDate } = salaryCycle;
|
||||
const { fromDate: attendCycleFromDate, endDate: attendCycleEndDate } = attendCycle;
|
||||
return (
|
||||
<div className="salaryMonthTip-layout">
|
||||
<div className="salaryMonthTipItem">
|
||||
<div className="label">{getLabel(543375, "薪资周期")}</div>
|
||||
<div className="value">{`${salaryCycleFromDate}${getLabel(15322, "至")}${salaryCycleEndDate}`}</div>
|
||||
</div>
|
||||
<div className="salaryMonthTipItem">
|
||||
<div className="label">{getLabel(542240, "税款所属期")}</div>
|
||||
<div className="value">{taxCycle}</div>
|
||||
</div>
|
||||
<div className="salaryMonthTipItem">
|
||||
<div className="label">{getLabel(543475, "考勤取值周期")}</div>
|
||||
<div className="value">{`${attendCycleFromDate}${getLabel(15322, "至")}${attendCycleEndDate}`}</div>
|
||||
</div>
|
||||
<div className="salaryMonthTipItem">
|
||||
<div className="label">{getLabel(543466, "福利台账月份")}</div>
|
||||
<div className="value">
|
||||
{`${getLabel(19422, "引用")}${socialSecurityCycle}${getLabel(543476, "的福利台账数据")}`}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
};
|
||||
|
|
|
|||
|
|
@ -469,7 +469,27 @@ export const dataCollectCondition = [
|
|||
viewAttr: 2
|
||||
}
|
||||
],
|
||||
title: '数据采集',
|
||||
title: "数据采集",
|
||||
defaultshow: true
|
||||
}
|
||||
];
|
||||
|
||||
|
||||
export const cumTaxPeriodCondition = [
|
||||
{
|
||||
items: [{
|
||||
colSpan: 1,
|
||||
conditionType: "MONTHPICKER",
|
||||
domkey: ["declareMonth"],
|
||||
fieldcol: 18,
|
||||
label: "税款所属期",
|
||||
lanId: 542240,
|
||||
labelcol: 6,
|
||||
value: "",
|
||||
rules: "required",
|
||||
viewAttr: 3
|
||||
}],
|
||||
title: "",
|
||||
defaultshow: true
|
||||
}
|
||||
];
|
||||
|
|
|
|||
|
|
@ -0,0 +1,82 @@
|
|||
/*
|
||||
* Author: 黎永顺
|
||||
* name: 个税对接-在线获取
|
||||
* Description:
|
||||
* Date: 2023/9/5
|
||||
*/
|
||||
import React, { Component } from "react";
|
||||
import { inject, observer } from "mobx-react";
|
||||
import { WeaDialog, WeaLocaleProvider } from "ecCom";
|
||||
import { Button, message } from "antd";
|
||||
import { getSearchs } from "../../../../util";
|
||||
import { cumTaxPeriodCondition } from "../columns";
|
||||
import { onlineRequest } from "../../../../apis/cumDeduct";
|
||||
import { onlineActualAddUpAdvanceTax } from "../../../../apis/cumSituation";
|
||||
|
||||
const getLabel = WeaLocaleProvider.getLabel;
|
||||
const APIFox = {
|
||||
online: onlineRequest,
|
||||
advance: onlineActualAddUpAdvanceTax
|
||||
};
|
||||
|
||||
@inject("cumDeductStore")
|
||||
@observer
|
||||
class SalaryCumDeductChooseTaxPeriodDialog extends Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
loading: false
|
||||
};
|
||||
}
|
||||
|
||||
componentWillReceiveProps(nextProps, nextContext) {
|
||||
const { cumDeductStore: { cumTaxPeriodForm, changeCumTaxPeriodForm } } = nextProps;
|
||||
if (nextProps.visible !== this.props.visible && nextProps.visible) {
|
||||
cumTaxPeriodForm.initFormFields(cumTaxPeriodCondition);
|
||||
}
|
||||
if (nextProps.visible !== this.props.visible && !nextProps.visible) {
|
||||
cumTaxPeriodForm.resetForm();
|
||||
changeCumTaxPeriodForm();
|
||||
}
|
||||
}
|
||||
|
||||
save = () => {
|
||||
const { cumDeductStore: { cumTaxPeriodForm }, type } = this.props;
|
||||
cumTaxPeriodForm.validateForm().then(f => {
|
||||
const { declareMonth } = cumTaxPeriodForm.getFormParams();
|
||||
if (f.isValid) {
|
||||
this.setState({ loading: true });
|
||||
APIFox[type]({ declareMonth: declareMonth + "-01" }).then(({ status, errormsg }) => {
|
||||
this.setState({ loading: false });
|
||||
if (status) {
|
||||
message.success(getLabel(111, "获取成功!"));
|
||||
this.props.onCancel();
|
||||
} else {
|
||||
message.error(errormsg);
|
||||
}
|
||||
}).catch(() => this.setState({ loading: false }));
|
||||
} else {
|
||||
f.showErrors();
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
render() {
|
||||
const { loading } = this.state;
|
||||
const { cumDeductStore: { cumTaxPeriodForm } } = this.props;
|
||||
return (
|
||||
<WeaDialog
|
||||
{...this.props} className="paymentDialog" initLoadCss
|
||||
style={{ width: 550 }}
|
||||
buttons={[<Button type="primary" loading={loading} onClick={this.save}>{getLabel(33703, "确认")}</Button>]}
|
||||
bottomLeft={getLabel(111, "点击保存后,稍后请点击【获取结果下载】下载获取结果。获取的数据将覆盖列表原本数据(有则覆盖无则新增)。")}
|
||||
>
|
||||
<div className="paymentDialogContent">
|
||||
{getSearchs(cumTaxPeriodForm, cumTaxPeriodCondition, 1, false)}
|
||||
</div>
|
||||
</WeaDialog>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
export default SalaryCumDeductChooseTaxPeriodDialog;
|
||||
|
|
@ -1,6 +1,14 @@
|
|||
import React, { Component } from "react";
|
||||
import { inject, observer } from "mobx-react";
|
||||
import { WeaDatePicker, WeaFormItem, WeaHelpfulTip, WeaInput, WeaSearchGroup, WeaSelect } from "ecCom";
|
||||
import {
|
||||
WeaDatePicker,
|
||||
WeaFormItem,
|
||||
WeaHelpfulTip,
|
||||
WeaInput,
|
||||
WeaLocaleProvider,
|
||||
WeaSearchGroup,
|
||||
WeaSelect
|
||||
} from "ecCom";
|
||||
import { Button, Dropdown, Menu, message, Modal } from "antd";
|
||||
import {
|
||||
autoAddAll,
|
||||
|
|
@ -11,8 +19,10 @@ import {
|
|||
getAddUpDeduction,
|
||||
getCumDeductSaCondition,
|
||||
importCumDeductParam,
|
||||
importCumDeductPreview
|
||||
importCumDeductPreview,
|
||||
onlineFeedback
|
||||
} from "../../../apis/cumDeduct";
|
||||
import { apiflowBillingConfigStatus } from "../../../apis/intelligentCalculateSalarySettings";
|
||||
import DataTables from "../dataTables";
|
||||
import AddItems from "../addItems";
|
||||
import ImportFormCom from "./components/importFormCom";
|
||||
|
|
@ -22,6 +32,9 @@ import { removePropertyCondition } from "../../../util/response";
|
|||
import { convertToUrlString } from "../../../util/url";
|
||||
import Layout from "../layout";
|
||||
import moment from "moment";
|
||||
import SalaryCumDeductChooseTaxPeriodDialog from "./components/salaryCumDeductChooseTaxPeriodDialog";
|
||||
|
||||
const getLabel = WeaLocaleProvider.getLabel;
|
||||
|
||||
@inject("taxAgentStore", "cumDeductStore")
|
||||
@observer
|
||||
|
|
@ -54,7 +67,12 @@ class Index extends Component {
|
|||
},
|
||||
exportPayloadUrl: "",
|
||||
exportPayloadType: false,
|
||||
advanceCondition: null
|
||||
advanceCondition: null,
|
||||
cumTaxPeriodDialog: {
|
||||
visible: false, title: "", type: ""
|
||||
},
|
||||
feedbackLoading: false,
|
||||
incomeTaxStatus: false
|
||||
};
|
||||
this.tableRef = null;
|
||||
this.addItemRef = null;
|
||||
|
|
@ -63,8 +81,14 @@ class Index extends Component {
|
|||
|
||||
componentDidMount() {
|
||||
this.getAdvanceCondition();
|
||||
this.apiflowBillingConfigStatus();
|
||||
}
|
||||
|
||||
apiflowBillingConfigStatus = () => {
|
||||
apiflowBillingConfigStatus().then(({ status, data }) => {
|
||||
this.setState({ incomeTaxStatus: status && data });
|
||||
});
|
||||
};
|
||||
/*
|
||||
* Author: 黎永顺
|
||||
* Description:一键累计
|
||||
|
|
@ -383,8 +407,8 @@ class Index extends Component {
|
|||
* Date: 2023/2/17
|
||||
*/
|
||||
getTopBtns = () => {
|
||||
const { addAllLoading } = this.state;
|
||||
return [
|
||||
const { addAllLoading, cumTaxPeriodDialog, feedbackLoading, incomeTaxStatus } = this.state;
|
||||
const commonBtns = [
|
||||
<Button type="primary" onClick={this.handleOpenImport}>导入</Button>,
|
||||
<Button type="ghost" onClick={() => this.handleAddData()}>新建</Button>,
|
||||
<Button type="ghost" loading={addAllLoading} onClick={this.autoAddAll}>一键累计</Button>,
|
||||
|
|
@ -401,6 +425,18 @@ class Index extends Component {
|
|||
<Button type="ghost">更多</Button>
|
||||
</Dropdown>
|
||||
];
|
||||
const incomeTaxBtns = [
|
||||
<Button type="primary" onClick={() => this.setState({
|
||||
cumTaxPeriodDialog: {
|
||||
...cumTaxPeriodDialog,
|
||||
visible: true, type: "online",
|
||||
title: getLabel(542240, "税款所属期")
|
||||
}
|
||||
})}>{getLabel(111, "在线获取")}</Button>,
|
||||
<Button type="ghost" onClick={this.onlineFeedback}
|
||||
loading={feedbackLoading}>{getLabel(111, "查询在线获取结果")}</Button>
|
||||
];
|
||||
return incomeTaxStatus ? [...incomeTaxBtns, ...commonBtns] : commonBtns;
|
||||
};
|
||||
handleDataMenuClick = ({ key: keyFunc }) => this[keyFunc]();
|
||||
/*
|
||||
|
|
@ -498,11 +534,26 @@ class Index extends Component {
|
|||
});
|
||||
};
|
||||
|
||||
onlineFeedback = () => {
|
||||
this.setState({ feedbackLoading: true });
|
||||
onlineFeedback().then(({ status, errormsg }) => {
|
||||
this.setState({ feedbackLoading: false });
|
||||
if (status) {
|
||||
message.success(getLabel(111, "获取成功!"));
|
||||
this.tableRef.getTableDate();
|
||||
} else {
|
||||
message.error(errormsg);
|
||||
}
|
||||
}).catch((error) => {
|
||||
this.setState({ feedbackLoading: false });
|
||||
});
|
||||
};
|
||||
|
||||
render() {
|
||||
const { taxAgentStore: { showOperateBtn }, cumDeductStore: { form } } = this.props;
|
||||
const {
|
||||
declareMonth, taxAgentId, slidePayload, saveLoading, exportPayloadUrl, advanceCondition,
|
||||
importPayload, exportPayloadType
|
||||
importPayload, exportPayloadType, cumTaxPeriodDialog
|
||||
} = this.state;
|
||||
const tablePayload = { declareMonth: [declareMonth], taxAgentId };
|
||||
return (
|
||||
|
|
@ -526,6 +577,12 @@ class Index extends Component {
|
|||
onViewDetails={(record) => this.handleAddData("累计专项附加扣除记录", record)}
|
||||
form={form}
|
||||
/>
|
||||
<SalaryCumDeductChooseTaxPeriodDialog
|
||||
{...cumTaxPeriodDialog}
|
||||
onCancel={() => this.setState({
|
||||
cumTaxPeriodDialog: { ...cumTaxPeriodDialog, visible: false, title: "", type: "" }
|
||||
})}
|
||||
/>
|
||||
</Layout>
|
||||
);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -108,66 +108,68 @@ export const dataCollectCondition = [
|
|||
precision: 2,
|
||||
viewAttr: 2
|
||||
},
|
||||
{
|
||||
conditionType: "INPUTNUMBER",
|
||||
domkey: ["addUpChildEducation"],
|
||||
fieldcol: 14,
|
||||
label: "累计子女教育",
|
||||
labelcol: 8,
|
||||
value: "",
|
||||
precision: 2,
|
||||
viewAttr: 2
|
||||
},
|
||||
{
|
||||
conditionType: "INPUTNUMBER",
|
||||
domkey: ["addUpContinuingEducation"],
|
||||
fieldcol: 14,
|
||||
label: "累计继续教育",
|
||||
labelcol: 8,
|
||||
value: "",
|
||||
precision: 2,
|
||||
viewAttr: 2
|
||||
},
|
||||
{
|
||||
conditionType: "INPUTNUMBER",
|
||||
domkey: ["addUpHousingLoanInterest"],
|
||||
fieldcol: 14,
|
||||
label: "累计住房贷款利息",
|
||||
labelcol: 8,
|
||||
value: "",
|
||||
precision: 2,
|
||||
viewAttr: 2
|
||||
},
|
||||
{
|
||||
conditionType: "INPUTNUMBER",
|
||||
domkey: ["addUpHousingRent"],
|
||||
fieldcol: 14,
|
||||
label: "累计住房租金",
|
||||
labelcol: 8,
|
||||
value: "",
|
||||
precision: 2,
|
||||
viewAttr: 2
|
||||
},
|
||||
{
|
||||
conditionType: "INPUTNUMBER",
|
||||
domkey: ["addUpSupportElderly"],
|
||||
fieldcol: 14,
|
||||
label: "累计赡养老人",
|
||||
labelcol: 8,
|
||||
value: "",
|
||||
precision: 2,
|
||||
viewAttr: 2
|
||||
},
|
||||
{
|
||||
conditionType: "INPUTNUMBER",
|
||||
domkey: ["addUpIllnessMedical"],
|
||||
fieldcol: 14,
|
||||
label: "累计大病医疗",
|
||||
labelcol: 8,
|
||||
value: "",
|
||||
precision: 2,
|
||||
viewAttr: 2
|
||||
},
|
||||
|
||||
// {
|
||||
// conditionType: "INPUTNUMBER",
|
||||
// domkey: ["addUpChildEducation"],
|
||||
// fieldcol: 14,
|
||||
// label: "累计子女教育",
|
||||
// labelcol: 8,
|
||||
// value: "",
|
||||
// precision: 2,
|
||||
// viewAttr: 2
|
||||
// },
|
||||
// {
|
||||
// conditionType: "INPUTNUMBER",
|
||||
// domkey: ["addUpContinuingEducation"],
|
||||
// fieldcol: 14,
|
||||
// label: "累计继续教育",
|
||||
// labelcol: 8,
|
||||
// value: "",
|
||||
// precision: 2,
|
||||
// viewAttr: 2
|
||||
// },
|
||||
// {
|
||||
// conditionType: "INPUTNUMBER",
|
||||
// domkey: ["addUpHousingLoanInterest"],
|
||||
// fieldcol: 14,
|
||||
// label: "累计住房贷款利息",
|
||||
// labelcol: 8,
|
||||
// value: "",
|
||||
// precision: 2,
|
||||
// viewAttr: 2
|
||||
// },
|
||||
// {
|
||||
// conditionType: "INPUTNUMBER",
|
||||
// domkey: ["addUpHousingRent"],
|
||||
// fieldcol: 14,
|
||||
// label: "累计住房租金",
|
||||
// labelcol: 8,
|
||||
// value: "",
|
||||
// precision: 2,
|
||||
// viewAttr: 2
|
||||
// },
|
||||
// {
|
||||
// conditionType: "INPUTNUMBER",
|
||||
// domkey: ["addUpSupportElderly"],
|
||||
// fieldcol: 14,
|
||||
// label: "累计赡养老人",
|
||||
// labelcol: 8,
|
||||
// value: "",
|
||||
// precision: 2,
|
||||
// viewAttr: 2
|
||||
// },
|
||||
// {
|
||||
// conditionType: "INPUTNUMBER",
|
||||
// domkey: ["addUpIllnessMedical"],
|
||||
// fieldcol: 14,
|
||||
// label: "累计大病医疗",
|
||||
// labelcol: 8,
|
||||
// value: "",
|
||||
// precision: 2,
|
||||
// viewAttr: 2
|
||||
// },
|
||||
|
||||
{
|
||||
conditionType: "INPUTNUMBER",
|
||||
domkey: ["addUpEnterpriseAndOther"],
|
||||
|
|
@ -230,14 +232,47 @@ export const dataCollectCondition = [
|
|||
},
|
||||
{
|
||||
conditionType: "INPUTNUMBER",
|
||||
domkey: ["addUpInfantCare"],
|
||||
domkey: ["actualAddUpAdvanceTax"],
|
||||
fieldcol: 14,
|
||||
label: "累计婴幼儿照护",
|
||||
label: "实际累计已预扣预缴税额",
|
||||
labelcol: 8,
|
||||
value: "",
|
||||
precision: 2,
|
||||
viewAttr: 2
|
||||
}
|
||||
},
|
||||
{
|
||||
conditionType: "INPUTNUMBER",
|
||||
domkey: ["taxAdjustment"],
|
||||
fieldcol: 14,
|
||||
label: "个税调差",
|
||||
helpfulTitle: "1、【个税调差】=【实际累计已预扣预缴税额】-【累计已预扣预缴税额】。\n" +
|
||||
"2、直接输入或导入【个税调差】值,则以输入/导入为准,公式失效。再次编辑减数或被减数,会再次按公式自动计算。",
|
||||
labelcol: 8,
|
||||
value: "",
|
||||
precision: 2,
|
||||
viewAttr: 2
|
||||
},
|
||||
{
|
||||
conditionType: "INPUTNUMBER",
|
||||
domkey: ["addUpTaxableIncome"],
|
||||
fieldcol: 14,
|
||||
label: "累计应纳税所得额",
|
||||
labelcol: 8,
|
||||
value: "",
|
||||
precision: 2,
|
||||
viewAttr: 2
|
||||
},
|
||||
|
||||
// {
|
||||
// conditionType: "INPUTNUMBER",
|
||||
// domkey: ["addUpInfantCare"],
|
||||
// fieldcol: 14,
|
||||
// label: "累计婴幼儿照护",
|
||||
// labelcol: 8,
|
||||
// value: "",
|
||||
// precision: 2,
|
||||
// viewAttr: 2
|
||||
// }
|
||||
],
|
||||
title: "数据采集",
|
||||
defaultshow: true
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@
|
|||
*/
|
||||
import React, { Component } from "react";
|
||||
import { inject, observer } from "mobx-react";
|
||||
import { WeaSearchGroup } from "ecCom";
|
||||
import { WeaLocaleProvider, WeaSearchGroup } from "ecCom";
|
||||
import { Button, Dropdown, Menu, message, Modal } from "antd";
|
||||
import {
|
||||
createAddUpSituation,
|
||||
|
|
@ -18,6 +18,7 @@ import {
|
|||
importCumSituationParam,
|
||||
importCumSituationPreview
|
||||
} from "../../../apis/cumSituation";
|
||||
import { apiflowBillingConfigStatus } from "../../../apis/intelligentCalculateSalarySettings";
|
||||
import { removePropertyCondition } from "../../../util/response";
|
||||
import DataTables from "../dataTables";
|
||||
import Layout from "../layout";
|
||||
|
|
@ -29,6 +30,9 @@ import AddItems from "../addItems";
|
|||
import TableRecord from "../components/tableRecord";
|
||||
import { situationModalColumns } from "../cumDeduct/columns";
|
||||
import { convertToUrlString } from "../../../util/url";
|
||||
import SalaryCumDeductChooseTaxPeriodDialog from "../cumDeduct/components/salaryCumDeductChooseTaxPeriodDialog";
|
||||
|
||||
const getLabel = WeaLocaleProvider.getLabel;
|
||||
|
||||
@inject("taxAgentStore", "cumSituationStore")
|
||||
@observer
|
||||
|
|
@ -61,7 +65,11 @@ class Index extends Component {
|
|||
},
|
||||
exportPayloadUrl: "",
|
||||
exportPayloadType: false,
|
||||
advanceCondition: null
|
||||
advanceCondition: null,
|
||||
incomeTaxStatus: false,
|
||||
cumTaxPeriodDialog: {
|
||||
visible: false, title: "", type: ""
|
||||
}
|
||||
};
|
||||
this.tableRef = null;
|
||||
this.addItemRef = null;
|
||||
|
|
@ -70,8 +78,14 @@ class Index extends Component {
|
|||
|
||||
componentDidMount() {
|
||||
this.getAdvanceCondition();
|
||||
this.apiflowBillingConfigStatus();
|
||||
}
|
||||
|
||||
apiflowBillingConfigStatus = () => {
|
||||
apiflowBillingConfigStatus().then(({ status, data }) => {
|
||||
this.setState({ incomeTaxStatus: status && data });
|
||||
});
|
||||
};
|
||||
/*
|
||||
* Author: 黎永顺
|
||||
* Description: 高级搜素框-表单项
|
||||
|
|
@ -304,6 +318,29 @@ class Index extends Component {
|
|||
exportPayloadUrl: `${window.location.origin}/api/bs/hrmsalary/addUpSituation/export?ids=${ids.join(",")}&year=${year}&taxYearMonth=${year}-${declareMonth}&taxAgentId=${taxAgentId}`
|
||||
});
|
||||
};
|
||||
/*
|
||||
* Author: 黎永顺
|
||||
* Description: 个税相关-在线获取
|
||||
* Params:
|
||||
* Date: 2023/9/6
|
||||
*/
|
||||
handleOnlineAccess = () => {
|
||||
Modal.confirm({
|
||||
title: getLabel(131329, "信息确认"),
|
||||
content: getLabel(111, "确定要在线获取税局数据更新实际累计已预扣预缴税额?\n" +
|
||||
"此操作会依据实际累计已预扣预缴税额自动计算个税调差,不可回退,可重复获取,每次获取后重复数据会进行覆盖处理。"),
|
||||
onOk: this.onlineActualAddUpAdvanceTax
|
||||
});
|
||||
};
|
||||
onlineActualAddUpAdvanceTax = () => {
|
||||
this.setState({
|
||||
cumTaxPeriodDialog: {
|
||||
...this.state.cumTaxPeriodDialog,
|
||||
visible: true, type: "advance",
|
||||
title: getLabel(542240, "税款所属期")
|
||||
}
|
||||
});
|
||||
};
|
||||
/*
|
||||
* Author: 黎永顺
|
||||
* Description: 顶部操作按钮
|
||||
|
|
@ -311,9 +348,10 @@ class Index extends Component {
|
|||
* Date: 2023/2/17
|
||||
*/
|
||||
getTopBtns = () => {
|
||||
const { addAllLoading } = this.state;
|
||||
return [
|
||||
const { addAllLoading, incomeTaxStatus } = this.state;
|
||||
const commonBtns = [
|
||||
<Button type="primary" onClick={this.handleOpenImport}>导入</Button>,
|
||||
<Button type="ghost" onClick={this.handleOnlineAccess}>{getLabel(111, "在线获取")}</Button>,
|
||||
<Button type="ghost" onClick={() => this.handleAddData()}>新建</Button>,
|
||||
<Dropdown
|
||||
overlay={
|
||||
|
|
@ -328,6 +366,7 @@ class Index extends Component {
|
|||
<Button type="ghost">更多</Button>
|
||||
</Dropdown>
|
||||
];
|
||||
return incomeTaxStatus ? commonBtns : _.filter(commonBtns, (__, index) => index !== 1);
|
||||
};
|
||||
handleDataMenuClick = ({ key: keyFunc }) => this[keyFunc]();
|
||||
/*
|
||||
|
|
@ -516,7 +555,7 @@ class Index extends Component {
|
|||
const { taxAgentStore: { showOperateBtn }, cumSituationStore: { form } } = this.props;
|
||||
const {
|
||||
declareMonth, taxAgentId, slidePayload, saveLoading, exportPayloadUrl, advanceCondition,
|
||||
importPayload, year, exportPayloadType
|
||||
importPayload, year, exportPayloadType, cumTaxPeriodDialog
|
||||
} = this.state;
|
||||
const tablePayload = { taxYearMonth: `${year}-${declareMonth}`, year, taxAgentId };
|
||||
return (
|
||||
|
|
@ -532,6 +571,12 @@ class Index extends Component {
|
|||
onPreviewImport={this.handlePreviewImport} detailOptBtns={this.getDetailOptBtns()}
|
||||
columns={situationModalColumns}
|
||||
>
|
||||
<SalaryCumDeductChooseTaxPeriodDialog
|
||||
{...cumTaxPeriodDialog}
|
||||
onCancel={() => this.setState({
|
||||
cumTaxPeriodDialog: { ...cumTaxPeriodDialog, visible: false, title: "", type: "" }
|
||||
})}
|
||||
/>
|
||||
<DataTables
|
||||
ref={dom => this.tableRef = dom}
|
||||
url="/api/bs/hrmsalary/addUpSituation/list"
|
||||
|
|
|
|||
|
|
@ -56,7 +56,7 @@ class Layout extends Component {
|
|||
title, btns, leftComp, children, taxAgentStore: { showOperateBtn },
|
||||
slidePayload, onClose, onSave, slideLoading, form, condition,
|
||||
onAdSearch, onCancel, importPayload, onImportSetStep, onImportFile,
|
||||
onPreviewImport, detailOptBtns, columns
|
||||
onPreviewImport, detailOptBtns, columns, tabBtns = []
|
||||
} = this.props;
|
||||
const { visible, title: subtitle, children: slideChildren } = slidePayload;
|
||||
const {
|
||||
|
|
@ -80,6 +80,7 @@ class Layout extends Component {
|
|||
onSearch={onAdSearch}
|
||||
onSearchChange={(v) => form.updateFields({ username: v })}
|
||||
searchsBaseValue={form.getFormParams().username}
|
||||
buttons={showOperateBtn ? tabBtns : []}
|
||||
/>
|
||||
<div className="dataContent">
|
||||
<WeaNewScroll height="100%">{children}</WeaNewScroll>
|
||||
|
|
|
|||
|
|
@ -9,8 +9,10 @@ import {
|
|||
WeaSelect,
|
||||
WeaTextarea
|
||||
} from "ecCom";
|
||||
import { Button } from "antd";
|
||||
import { Button, message } from "antd";
|
||||
import { inject, observer } from "mobx-react";
|
||||
import { taxdeclarationGetRate } from "../../apis/declare";
|
||||
import moment from "moment";
|
||||
import "./index.less";
|
||||
|
||||
const getLabel = WeaLocaleProvider.getLabel;
|
||||
|
|
@ -25,6 +27,7 @@ export default class GenerateModal extends React.Component {
|
|||
description: "",
|
||||
loading: false
|
||||
};
|
||||
this.timer = null;
|
||||
}
|
||||
|
||||
// 生成申报表
|
||||
|
|
@ -47,13 +50,41 @@ export default class GenerateModal extends React.Component {
|
|||
return;
|
||||
}
|
||||
this.setState({ loading: true });
|
||||
saveDeclare({ salaryMonthStr: date, taxAgentId, description }).then(() => {
|
||||
saveDeclare({
|
||||
salaryMonth: moment(date).startOf("month").format("YYYY-MM-DD"),
|
||||
taxAgentId,
|
||||
description
|
||||
}).then((data) => {
|
||||
this.setState({ loading: false });
|
||||
this.props.onGenerate();
|
||||
this.props.onCancel();
|
||||
message.destroy();
|
||||
message.loading(getLabel(111, "正在生成中..."), 0);
|
||||
this.timer = setInterval(async () => {
|
||||
const { status: resStatus, data: result } = await this.taxdeclarationGetRate(data);
|
||||
const { status: rateStatus, finish, msg } = result;
|
||||
if (resStatus && rateStatus) {
|
||||
if (finish) {
|
||||
message.destroy();
|
||||
clearInterval(this.timer);
|
||||
message.success(msg || getLabel(22619, "保存成功!"));
|
||||
this.props.onGenerate();
|
||||
}
|
||||
} else {
|
||||
clearInterval(this.timer);
|
||||
message.destroy();
|
||||
message.warning(msg || getLabel(111, "生成申报表失败!"));
|
||||
this.props.onGenerate();
|
||||
}
|
||||
}, 1000);
|
||||
}).catch(() => {
|
||||
message.destroy();
|
||||
clearInterval(this.timer);
|
||||
this.setState({ loading: false });
|
||||
});
|
||||
};
|
||||
taxdeclarationGetRate = (index) => {
|
||||
return taxdeclarationGetRate({ index });
|
||||
};
|
||||
|
||||
render() {
|
||||
const { taxAgentStore: { taxAgentAdminOption } } = this.props;
|
||||
|
|
|
|||
|
|
@ -1,11 +1,11 @@
|
|||
import React from "react";
|
||||
import { inject, observer } from "mobx-react";
|
||||
import { Button, DatePicker, message, Modal } from "antd";
|
||||
import { Button, DatePicker, message, Modal, Tag } from "antd";
|
||||
import { WeaLocaleProvider, WeaNewScroll, WeaTop } from "ecCom";
|
||||
import CustomTab from "../../components/customTab";
|
||||
import CustomTable from "../../components/customTable";
|
||||
import GenerateModal from "./generateModal";
|
||||
import { getDeclareList, withDrawTaxDeclaration } from "../../apis/declare";
|
||||
import { getDeclareList, taxdeclarationDelete, taxdeclarationUpdateIcon } from "../../apis/declare";
|
||||
import { sysConfCodeRule } from "../../apis/ruleconfig";
|
||||
import moment from "moment";
|
||||
|
||||
|
|
@ -65,13 +65,13 @@ export default class Declare extends React.Component {
|
|||
if (status && data === "1") this.setState({ showWithDrawBtn: data === "1" });
|
||||
});
|
||||
};
|
||||
withDrawTaxDeclaration = (taxDeclarationId) => {
|
||||
withDrawTaxDeclaration({ taxDeclarationId }).then(({ status, errormsg }) => {
|
||||
taxdeclarationDelete = (taxDeclarationId) => {
|
||||
taxdeclarationDelete([taxDeclarationId]).then(({ status, errormsg }) => {
|
||||
if (status) {
|
||||
message.success(getLabel(111, "撤回成功"));
|
||||
message.success(getLabel(502230, "删除成功"));
|
||||
this.getDeclareList();
|
||||
} else {
|
||||
message.error(errormsg || getLabel(111, "撤回失败"));
|
||||
message.error(errormsg || getLabel(20462, "删除失败"));
|
||||
}
|
||||
});
|
||||
};
|
||||
|
|
@ -96,6 +96,17 @@ export default class Declare extends React.Component {
|
|||
}
|
||||
}, () => this.getDeclareList());
|
||||
};
|
||||
handleUpdateicon = (record) => {
|
||||
const { id: taxDeclareRecordId } = record;
|
||||
taxdeclarationUpdateIcon({ taxDeclareRecordId }).then(({ status, errormsg }) => {
|
||||
this.getDeclareList();
|
||||
if (status) {
|
||||
message.success(getLabel(502230, "删除成功!"));
|
||||
} else {
|
||||
message.error(errormsg || getLabel(20462, "删除失败!"));
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
render() {
|
||||
const { taxAgentStore: { showOperateBtn } } = this.props;
|
||||
|
|
@ -129,7 +140,7 @@ export default class Declare extends React.Component {
|
|||
onClick={() => {
|
||||
this.setState({ declarationModalVisible: true });
|
||||
}}>
|
||||
生成申报单
|
||||
{getLabel(111, "生成申报表")}
|
||||
</Button>
|
||||
}
|
||||
</div>
|
||||
|
|
@ -147,21 +158,38 @@ export default class Declare extends React.Component {
|
|||
<CustomTable
|
||||
loading={loading}
|
||||
columns={[
|
||||
...columns,
|
||||
..._.map(columns, it => {
|
||||
if (it.dataIndex === "taxDeclareStatusDesc") {
|
||||
return {
|
||||
...it,
|
||||
render: (text, record) => {
|
||||
return (<div className="declare-status-box">
|
||||
{text}
|
||||
{
|
||||
record.displayIcon &&
|
||||
<span title={getLabel(111, "该个税申报表对应的核算数据被重新核算")} className="icon-span">
|
||||
<Tag closable onClose={() => this.handleUpdateicon(record)}>
|
||||
<i className="icon-coms02-Warning-01"/>
|
||||
</Tag>
|
||||
</span>
|
||||
}
|
||||
</div>);
|
||||
}
|
||||
};
|
||||
}
|
||||
return { ...it };
|
||||
}),
|
||||
{
|
||||
title: "操作",
|
||||
dataIndex: "operate",
|
||||
render: (text, record) => {
|
||||
return (
|
||||
<React.Fragment>
|
||||
<a href="javascript:void(0);"
|
||||
onClick={() => {
|
||||
window.open(
|
||||
"/spa/hrmSalary/static/index.html#/main/hrmSalary/generateDeclarationDetail?id=" +
|
||||
record.id
|
||||
);
|
||||
}}>
|
||||
查看
|
||||
<a
|
||||
href={`${window.ecologyContentPath || ""}/spa/hrmSalary/static/index.html#/main/hrmSalary/declareDetail?id=${record.id}`}
|
||||
target="_blank"
|
||||
>
|
||||
{getLabel(83110, "查看详情")}
|
||||
</a>
|
||||
{
|
||||
showWithDrawBtn &&
|
||||
|
|
@ -169,13 +197,13 @@ export default class Declare extends React.Component {
|
|||
href="javascript:void(0);" style={{ marginLeft: 10 }}
|
||||
onClick={() => {
|
||||
Modal.confirm({
|
||||
title: getLabel(111, "信息确认"),
|
||||
content: getLabel(111, "确认撤回该条数据吗?"),
|
||||
onOk: () => this.withDrawTaxDeclaration(record.id)
|
||||
title: getLabel(131329, "信息确认"),
|
||||
content: getLabel(388758, "确认要删除吗?"),
|
||||
onOk: () => this.taxdeclarationDelete(record.id)
|
||||
});
|
||||
}}
|
||||
>
|
||||
{getLabel(111, "撤回")}
|
||||
{getLabel(535052, "删除")}
|
||||
</a>
|
||||
}
|
||||
</React.Fragment>
|
||||
|
|
|
|||
|
|
@ -1,7 +1,8 @@
|
|||
.generateDeclarationDetail {
|
||||
.tabWrapper{
|
||||
.tabWrapper {
|
||||
padding-left: 10px
|
||||
}
|
||||
|
||||
.tableWrapper {
|
||||
height: calc(100vh - 48px);
|
||||
overflow: auto;
|
||||
|
|
@ -24,3 +25,32 @@
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
.declare-status-box {
|
||||
.icon-span {
|
||||
cursor: pointer;
|
||||
|
||||
.ant-tag:hover .anticon-cross {
|
||||
display: block;
|
||||
}
|
||||
|
||||
.ant-tag {
|
||||
background: transparent;
|
||||
border-radius: 0;
|
||||
border: none;
|
||||
position: relative;
|
||||
|
||||
.anticon-cross {
|
||||
position: absolute;
|
||||
right: -1px;
|
||||
top: -1px;
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
|
||||
i.icon-coms02-Warning-01 {
|
||||
font-size: 16px;
|
||||
color: red;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -0,0 +1,93 @@
|
|||
export const paymentFeedbackConditions = [
|
||||
{
|
||||
items: [
|
||||
{
|
||||
colSpan: 1,
|
||||
conditionType: "SELECT",
|
||||
domkey: ["type"],
|
||||
fieldcol: 12,
|
||||
label: "缴款方式",
|
||||
lanId: 111,
|
||||
labelcol: 6,
|
||||
value: "",
|
||||
rules: "required",
|
||||
viewAttr: 3,
|
||||
detailtype: 3,
|
||||
options: []
|
||||
}
|
||||
],
|
||||
defaultshow: true
|
||||
}
|
||||
];
|
||||
export const paymentTripartiteConditions = [
|
||||
{
|
||||
items: [
|
||||
{
|
||||
colSpan: 1,
|
||||
conditionType: "INPUT",
|
||||
domkey: ["taxAgent"],
|
||||
fieldcol: 12,
|
||||
label: "个税扣缴义务人",
|
||||
lanId: 537996,
|
||||
labelcol: 6,
|
||||
value: "",
|
||||
viewAttr: 1
|
||||
},
|
||||
{
|
||||
colSpan: 1,
|
||||
conditionType: "INPUT",
|
||||
domkey: ["amount"],
|
||||
fieldcol: 12,
|
||||
label: "应缴金额",
|
||||
lanId: 111,
|
||||
labelcol: 6,
|
||||
value: "",
|
||||
viewAttr: 1
|
||||
},
|
||||
{
|
||||
colSpan: 1,
|
||||
conditionType: "INPUT",
|
||||
domkey: ["personNum"],
|
||||
fieldcol: 12,
|
||||
label: "申报人数",
|
||||
lanId: 111,
|
||||
labelcol: 6,
|
||||
value: "",
|
||||
viewAttr: 1
|
||||
}
|
||||
],
|
||||
defaultshow: true
|
||||
}
|
||||
];
|
||||
export const paymentBankConditions = [
|
||||
{
|
||||
items: [
|
||||
{
|
||||
colSpan: 1,
|
||||
conditionType: "SELECT",
|
||||
domkey: ["protocolNumber"],
|
||||
fieldcol: 12,
|
||||
label: "开户行",
|
||||
lanId: 111,
|
||||
labelcol: 6,
|
||||
value: "",
|
||||
rules: "required",
|
||||
viewAttr: 3,
|
||||
options: []
|
||||
},
|
||||
{
|
||||
colSpan: 1,
|
||||
conditionType: "SELECT",
|
||||
domkey: ["count"],
|
||||
fieldcol: 12,
|
||||
label: "开户行号",
|
||||
lanId: 111,
|
||||
labelcol: 6,
|
||||
value: "",
|
||||
viewAttr: 1,
|
||||
options: []
|
||||
}
|
||||
],
|
||||
defaultshow: true
|
||||
}
|
||||
];
|
||||
|
|
@ -0,0 +1,157 @@
|
|||
/*
|
||||
* Author: 黎永顺
|
||||
* name: 个税申报-异常、失败详情
|
||||
* Description:
|
||||
* Date: 2023/8/18
|
||||
*/
|
||||
import React, { Component } from "react";
|
||||
import { WeaDialog, WeaInputSearch, WeaLocaleProvider, WeaReqTop, WeaTable } from "ecCom";
|
||||
import { Button, Col, Row } from "antd";
|
||||
import {
|
||||
taxdeclarationEmployeeList4Fail,
|
||||
taxdeclarationEmployeeList4NotDeclare,
|
||||
taxdeclarationEmployeeList4NoValue
|
||||
} from "../../../apis/declare";
|
||||
import { convertToUrlString, getQueryString } from "../../../util/url";
|
||||
|
||||
const { getLabel } = WeaLocaleProvider;
|
||||
const APIFox = {
|
||||
list4NotDeclare: taxdeclarationEmployeeList4NotDeclare,
|
||||
list4NoValue: taxdeclarationEmployeeList4NoValue,
|
||||
list4Fail: taxdeclarationEmployeeList4Fail
|
||||
};
|
||||
|
||||
class DeclareResultDialog extends Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
keyword: "", selectedKey: "",
|
||||
pageInfo: { current: 1, pageSize: 10, total: 0 },
|
||||
loading: false, columns: [], dataSource: []
|
||||
};
|
||||
}
|
||||
|
||||
componentWillReceiveProps(nextProps, nextContext) {
|
||||
if (nextProps.visible !== this.props.visible && nextProps.visible) {
|
||||
const { type } = nextProps;
|
||||
this.setState({
|
||||
selectedKey: _.head(type).key
|
||||
}, () => this.queryList());
|
||||
}
|
||||
}
|
||||
|
||||
queryList = () => {
|
||||
const taxDeclareRecordId = getQueryString("id");
|
||||
const { keyword, pageInfo, selectedKey } = this.state;
|
||||
const payload = {
|
||||
...pageInfo, keyword, taxDeclareRecordId
|
||||
};
|
||||
this.setState({ loading: true });
|
||||
APIFox[selectedKey](payload).then(({ status, data }) => {
|
||||
this.setState({ loading: false });
|
||||
if (status) {
|
||||
const { columns, list: dataSource, pageNum: current, pageSize, total } = data;
|
||||
this.setState({
|
||||
dataSource, pageInfo: { ...pageInfo, current, pageSize, total }, columns
|
||||
});
|
||||
} else {
|
||||
|
||||
}
|
||||
}).catch(() => this.setState({ loading: false }));
|
||||
};
|
||||
errorExport = () => {
|
||||
let exportUrl = "";
|
||||
const { selectedKey, keyword } = this.state;
|
||||
const payload = {
|
||||
taxDeclareRecordId: getQueryString("id"), keyword
|
||||
};
|
||||
if (selectedKey === "list4NotDeclare") {
|
||||
exportUrl = "/api/bs/hrmsalary/taxdeclaration/employee/export4NotDeclare";
|
||||
} else if (selectedKey === "list4NoValue") {
|
||||
exportUrl = "/api/bs/hrmsalary/taxdeclaration/employee/export4NoValue";
|
||||
}
|
||||
window.open(`${window.ecologyContentPath || ""}${exportUrl}?${convertToUrlString(payload)}`, "_blank");
|
||||
};
|
||||
failExport = () => {
|
||||
const payload = {
|
||||
taxDeclareRecordId: getQueryString("id")
|
||||
};
|
||||
window.open(`${window.ecologyContentPath || ""}/api/bs/hrmsalary/taxdeclaration/employee/export4Fail?${convertToUrlString(payload)}`, "_blank");
|
||||
};
|
||||
|
||||
render() {
|
||||
const { type } = this.props;
|
||||
const { loading, columns, dataSource, pageInfo, selectedKey, keyword } = this.state;
|
||||
const pagination = {
|
||||
...pageInfo,
|
||||
showTotal: total => `${getLabel(18609, "共")} ${total} ${getLabel(18256, "条")}`,
|
||||
showQuickJumper: true,
|
||||
showSizeChanger: true,
|
||||
pageSizeOptions: ["10", "20", "50", "100"],
|
||||
onShowSizeChange: (current, pageSize) => {
|
||||
this.setState({
|
||||
pageInfo: { ...pageInfo, current, pageSize }
|
||||
}, () => this.queryList());
|
||||
},
|
||||
onChange: current => {
|
||||
this.setState({
|
||||
pageInfo: { ...pageInfo, current }
|
||||
}, () => this.queryList());
|
||||
}
|
||||
};
|
||||
return (
|
||||
<WeaDialog
|
||||
{...this.props}
|
||||
scalable hasScroll className="declareResultDialog" initLoadCss
|
||||
title={
|
||||
type.length === 1 ?
|
||||
(<Row className="declareResultDialogTitle" type="flex">
|
||||
<Col span={12} className="declareResultDialogTitle-left">
|
||||
<span className="title">{this.props.title}</span>
|
||||
</Col>
|
||||
<Col span={12} className="declareResultDialogTitle-right">
|
||||
<Button type="primary" onClick={this.failExport}>{getLabel(17416, "导出")}</Button>
|
||||
</Col>
|
||||
</Row>) :
|
||||
<WeaReqTop
|
||||
title={this.props.title} buttonSpace={10} tabDatas={type} selectedKey={selectedKey}
|
||||
buttons={[
|
||||
<Button type="primary" onClick={this.errorExport}>{getLabel(17416, "导出")}</Button>
|
||||
]}
|
||||
onChange={key => this.setState({ selectedKey: key }, () => this.queryList())}
|
||||
/>
|
||||
}
|
||||
style={{
|
||||
width: 1150,
|
||||
height: 606.6,
|
||||
minHeight: 200,
|
||||
minWidth: 380,
|
||||
maxHeight: "90%",
|
||||
maxWidth: "90%",
|
||||
overflow: "hidden",
|
||||
transform: "translate(0px, 0px)"
|
||||
}}
|
||||
>
|
||||
<div className="declareResultDialogContent">
|
||||
{
|
||||
type.length !== 1 &&
|
||||
< div className="declareNoSearchBox">
|
||||
<WeaInputSearch
|
||||
style={{ width: 200 }} placeholder={getLabel(111, "请输入姓名/工号/身份证号")}
|
||||
value={keyword} onChange={val => this.setState({ keyword: val })}
|
||||
onSearch={this.queryList}
|
||||
/>
|
||||
</div>
|
||||
}
|
||||
<WeaTable
|
||||
columns={columns} dataSource={dataSource}
|
||||
loading={loading} className="declareTable"
|
||||
pagination={pagination}
|
||||
/>
|
||||
</div>
|
||||
</WeaDialog>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
export default DeclareResultDialog;
|
||||
|
|
@ -0,0 +1,351 @@
|
|||
/*
|
||||
* Author: 黎永顺
|
||||
* name: 在线申报-缴款按钮
|
||||
* Description:
|
||||
* Date: 2023/8/22
|
||||
*/
|
||||
import React, { Component } from "react";
|
||||
import { WeaLocaleProvider } from "ecCom";
|
||||
import { inject, observer } from "mobx-react";
|
||||
import { Button, Dropdown, Menu, message, Modal } from "antd";
|
||||
import PaymentDialog from "./paymentDialog";
|
||||
import {
|
||||
taxPaymentAgreemenPay,
|
||||
taxPaymentgetAgreement,
|
||||
taxPaymentgetAgreementFeedback,
|
||||
taxPaymentTaxAmount,
|
||||
taxPaymentVoucherCancel,
|
||||
taxPaymentVoucherPrint
|
||||
} from "../../../apis/declare";
|
||||
import { getQueryString } from "../../../util/url";
|
||||
import { paymentBankConditions, paymentTripartiteConditions } from "./constants";
|
||||
|
||||
const { getLabel } = WeaLocaleProvider;
|
||||
|
||||
@inject("declareStore")
|
||||
@observer
|
||||
class PaymentBtn extends Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
paymentDialog: {
|
||||
visible: false, title: "",
|
||||
buttons: [], conditions: [],
|
||||
taxAmount: ""
|
||||
}
|
||||
};
|
||||
this.timer = null;
|
||||
}
|
||||
|
||||
handleTripartiteContributions = () => {
|
||||
Modal.confirm({
|
||||
title: getLabel(131329, "信息确认"),
|
||||
content: <div>
|
||||
<div style={{ textAlign: "center" }}>{getLabel(111, "确定要进行三方缴款吗?")}</div>
|
||||
<div
|
||||
style={{ textAlign: "center" }}>{getLabel(111, "若申请过银行缴款,点击确定,将自动作废银行缴款凭证。并进行三方缴款。 ")}</div>
|
||||
</div>,
|
||||
onOk: () => {
|
||||
taxPaymentTaxAmount({ taxDeclareRecordId: getQueryString("id") })
|
||||
.then(({ status, data, errormsg }) => {
|
||||
if (status) {
|
||||
const { paymentDialog } = this.state;
|
||||
this.setState({
|
||||
paymentDialog: {
|
||||
...paymentDialog, visible: true,
|
||||
title: getLabel(111, "应缴纳"), taxAmount: data.amount,
|
||||
buttons: [
|
||||
<Button type="primary" onClick={this.taxPaymentgetAgreement}>{getLabel(111, "确认缴款")}</Button>
|
||||
],
|
||||
conditions: _.map(paymentTripartiteConditions, item => {
|
||||
return {
|
||||
...item,
|
||||
items: _.map(item.items, it => {
|
||||
const key = it["domkey"][0];
|
||||
return {
|
||||
...it,
|
||||
value: data[key]
|
||||
};
|
||||
})
|
||||
};
|
||||
})
|
||||
}
|
||||
});
|
||||
} else {
|
||||
message.error(errormsg);
|
||||
}
|
||||
});
|
||||
}
|
||||
});
|
||||
};
|
||||
taxPaymentgetAgreement = () => {
|
||||
const { taxCycle: taxYearMonth, taxAgentId } = this.props.declareInfo;
|
||||
const payload = {
|
||||
taxDeclareRecordId: getQueryString("id"),
|
||||
taxAgentId, taxYearMonth
|
||||
};
|
||||
this.setState({
|
||||
paymentDialog: {
|
||||
...this.state.paymentDialog,
|
||||
buttons: [
|
||||
<Button type="primary" loading={true}>{getLabel(111, "确认缴款")}</Button>
|
||||
]
|
||||
}
|
||||
});
|
||||
taxPaymentgetAgreement(payload).then(({ status, data, errormsg }) => {
|
||||
if (status) {
|
||||
this.handleCancel();
|
||||
this.getBankAccountInfo({ ...payload, requestId: data });
|
||||
} else {
|
||||
this.setState({
|
||||
paymentDialog: {
|
||||
...this.state.paymentDialog,
|
||||
buttons: [
|
||||
<Button type="primary" onClick={() => this.taxPaymentgetAgreement()}
|
||||
loading={false}>{getLabel(111, "确认缴款")}</Button>
|
||||
]
|
||||
}
|
||||
});
|
||||
message.error(errormsg);
|
||||
}
|
||||
}).catch(() => {
|
||||
this.setState({
|
||||
paymentDialog: {
|
||||
...this.state.paymentDialog,
|
||||
buttons: [
|
||||
<Button type="primary" onClick={() => this.taxPaymentgetAgreement()}
|
||||
loading={false}>{getLabel(111, "确认缴款")}</Button>
|
||||
]
|
||||
}
|
||||
});
|
||||
});
|
||||
};
|
||||
getBankAccountInfo = (payload) => {
|
||||
let loop = () => {
|
||||
clearTimeout(this.timer);
|
||||
this.timer = setTimeout(async () => {
|
||||
let response = await taxPaymentgetAgreementFeedback(payload);
|
||||
const { data, status, errormsg } = response;
|
||||
if (status) {
|
||||
const { finish, form } = data;
|
||||
if (finish) {
|
||||
const { feedbacks, bankForm } = form;
|
||||
const { paymentDialog } = this.state;
|
||||
this.setState({
|
||||
paymentDialog: {
|
||||
...paymentDialog, visible: true,
|
||||
title: getLabel(111, "银行账号信息"),
|
||||
buttons: [
|
||||
<Button type="primary" onClick={this.taxPaymentAgreemenPay}>{getLabel(826, "确定")}</Button>
|
||||
],
|
||||
conditions: _.map(paymentBankConditions, item => {
|
||||
return {
|
||||
...item,
|
||||
items: _.map(item.items, it => {
|
||||
const key = it["domkey"][0];
|
||||
if (key === "protocolNumber") {
|
||||
return {
|
||||
...it,
|
||||
value: !_.isEmpty(bankForm) ? bankForm.bank : "",
|
||||
options: _.map(feedbacks, o => ({ key: o.sfxyh, showname: o.yhhbmc }))
|
||||
};
|
||||
} else if (key === "count") {
|
||||
return {
|
||||
...it,
|
||||
value: !_.isEmpty(bankForm) ? bankForm.bank : "",
|
||||
options: _.map(feedbacks, o => ({ key: o.sfxyh, showname: o.khhhh }))
|
||||
};
|
||||
}
|
||||
return { ...it };
|
||||
})
|
||||
};
|
||||
})
|
||||
}
|
||||
});
|
||||
} else {
|
||||
loop();
|
||||
}
|
||||
} else {
|
||||
message.warning(errormsg);
|
||||
clearTimeout(this.timer);
|
||||
}
|
||||
}, 800);
|
||||
};
|
||||
loop();
|
||||
};
|
||||
taxPaymentAgreemenPay = () => {
|
||||
const { paymentDialog } = this.state;
|
||||
const { taxAmount } = paymentDialog;
|
||||
const { declareStore: { paymentForm } } = this.props;
|
||||
const { taxCycle: taxYearMonth, taxAgentId } = this.props.declareInfo;
|
||||
paymentForm.validateForm().then(f => {
|
||||
if (f.isValid) {
|
||||
const { protocolNumber } = paymentForm.getFormParams();
|
||||
const payload = {
|
||||
taxDeclareRecordId: getQueryString("id"),
|
||||
taxAgentId, taxYearMonth, taxAmount, protocolNumber
|
||||
};
|
||||
this.setState({
|
||||
paymentDialog: {
|
||||
...this.state.paymentDialog,
|
||||
buttons: [
|
||||
<Button type="primary" loading={true}>{getLabel(826, "确定")}</Button>
|
||||
]
|
||||
}
|
||||
});
|
||||
taxPaymentAgreemenPay(payload).then(({ status, errormsg }) => {
|
||||
this.setState({
|
||||
paymentDialog: {
|
||||
...this.state.paymentDialog,
|
||||
buttons: [
|
||||
<Button type="primary" loading={false}
|
||||
onClick={this.taxPaymentAgreemenPay}>{getLabel(826, "确定")}</Button>
|
||||
]
|
||||
}
|
||||
});
|
||||
if (status) {
|
||||
message.success(getLabel(111, "缴款处理中,请稍后点击缴款反馈按钮获取缴款信息"));
|
||||
this.handleCancel();
|
||||
} else {
|
||||
message.error(errormsg);
|
||||
}
|
||||
}).catch(() => this.setState({
|
||||
paymentDialog: {
|
||||
...this.state.paymentDialog,
|
||||
buttons: [
|
||||
<Button type="primary" loading={false}
|
||||
onClick={this.taxPaymentAgreemenPay}>{getLabel(826, "确定")}</Button>
|
||||
]
|
||||
}
|
||||
}));
|
||||
} else {
|
||||
f.showErrors();
|
||||
}
|
||||
});
|
||||
};
|
||||
handleMenuChange = ({ key }) => {
|
||||
if (key === "bank_voucher_payment") {
|
||||
taxPaymentTaxAmount({ taxDeclareRecordId: getQueryString("id") })
|
||||
.then(({ status, data, errormsg }) => {
|
||||
if (status) {
|
||||
const { paymentDialog } = this.state;
|
||||
this.setState({
|
||||
paymentDialog: {
|
||||
...paymentDialog, visible: true, title: getLabel(111, "应缴纳"),
|
||||
buttons: [
|
||||
<Button type="primary" onClick={this.taxPaymentVoucherPrint}>{getLabel(111, "确认缴款")}</Button>
|
||||
],
|
||||
conditions: _.map(paymentTripartiteConditions, item => {
|
||||
return {
|
||||
...item,
|
||||
items: _.map(item.items, it => {
|
||||
const key = it["domkey"][0];
|
||||
return {
|
||||
...it,
|
||||
value: data[key]
|
||||
};
|
||||
})
|
||||
};
|
||||
})
|
||||
}
|
||||
});
|
||||
} else {
|
||||
message.error(errormsg);
|
||||
}
|
||||
});
|
||||
} else if (key === "destory_voucher") {
|
||||
Modal.confirm({
|
||||
title: getLabel(131329, "信息确认"),
|
||||
content: getLabel(111, "确定作废缴款凭证吗?作废后可重新获取。"),
|
||||
onOk: () => {
|
||||
const { taxAgentId, taxCycle: taxYearMonth } = this.props.declareInfo;
|
||||
const payload = {
|
||||
taxDeclareRecordId: getQueryString("id"),
|
||||
taxAgentId, taxYearMonth
|
||||
};
|
||||
taxPaymentVoucherCancel(payload).then(({ status, errormsg }) => {
|
||||
if (status) {
|
||||
message.success(getLabel(111, "作废缴款凭证成功!"));
|
||||
} else {
|
||||
message.error(errormsg || getLabel(111, "作废失败!"));
|
||||
}
|
||||
});
|
||||
}
|
||||
});
|
||||
}
|
||||
};
|
||||
taxPaymentVoucherPrint = () => {
|
||||
const { taxCycle: taxYearMonth, taxAgentId } = this.props.declareInfo;
|
||||
const payload = {
|
||||
taxDeclareRecordId: getQueryString("id"),
|
||||
taxAgentId, taxYearMonth
|
||||
};
|
||||
this.setState({
|
||||
paymentDialog: {
|
||||
...this.state.paymentDialog,
|
||||
buttons: [
|
||||
<Button type="primary" loading={true}>{getLabel(111, "确认缴款")}</Button>
|
||||
]
|
||||
}
|
||||
});
|
||||
taxPaymentVoucherPrint(payload).then(({ status, errormsg }) => {
|
||||
if (status) {
|
||||
message.success(getLabel(111, "处理中,请稍后点击缴款反馈!"));
|
||||
this.handleCancel();
|
||||
} else {
|
||||
this.setState({
|
||||
paymentDialog: {
|
||||
...this.state.paymentDialog,
|
||||
buttons: [
|
||||
<Button type="primary" onClick={() => this.taxPaymentVoucherPrint()}
|
||||
loading={false}>{getLabel(111, "确认缴款")}</Button>
|
||||
]
|
||||
}
|
||||
});
|
||||
message.error(errormsg || getLabel(111, "缴款反馈失败!"));
|
||||
}
|
||||
}).catch(() => {
|
||||
this.setState({
|
||||
paymentDialog: {
|
||||
...this.state.paymentDialog,
|
||||
buttons: [
|
||||
<Button type="primary" onClick={() => this.taxPaymentVoucherPrint()}
|
||||
loading={false}>{getLabel(111, "确认缴款")}</Button>
|
||||
]
|
||||
}
|
||||
});
|
||||
});
|
||||
};
|
||||
handleCancel = () => {
|
||||
const { paymentDialog } = this.state;
|
||||
this.setState({
|
||||
paymentDialog: {
|
||||
...paymentDialog, visible: false,
|
||||
title: "", buttons: [], conditions: []
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
render() {
|
||||
const { paymentDialog } = this.state;
|
||||
return (
|
||||
<React.Fragment>
|
||||
<Dropdown.Button
|
||||
onClick={this.handleTripartiteContributions}
|
||||
overlay={
|
||||
<Menu onClick={this.handleMenuChange}>
|
||||
<Menu.Item key="bank_voucher_payment">{getLabel(111, "银行端凭证缴款")}</Menu.Item>
|
||||
<Menu.Item key="destory_voucher">{getLabel(111, "作废缴款凭证")}</Menu.Item>
|
||||
</Menu>
|
||||
}
|
||||
type="ghost">{getLabel(111, "三方缴款")}</Dropdown.Button>
|
||||
<PaymentDialog
|
||||
{...paymentDialog}
|
||||
onCancel={this.handleCancel}
|
||||
/>
|
||||
</React.Fragment>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
export default PaymentBtn;
|
||||
|
|
@ -0,0 +1,51 @@
|
|||
/*
|
||||
* Author: 黎永顺
|
||||
* name: 在线申报-缴款弹框
|
||||
* Description:
|
||||
* Date: 2023/8/22
|
||||
*/
|
||||
import React, { Component } from "react";
|
||||
import { inject, observer } from "mobx-react";
|
||||
import { WeaDialog } from "ecCom";
|
||||
import { getSearchs } from "../../../util";
|
||||
|
||||
@inject("declareStore")
|
||||
@observer
|
||||
class PaymentDialog extends Component {
|
||||
componentWillReceiveProps(nextProps, nextContext) {
|
||||
const { declareStore: { paymentForm, changePaymentForm }, conditions } = nextProps;
|
||||
if (nextProps.visible !== this.props.visible && nextProps.visible && nextProps.conditions) {
|
||||
paymentForm.initFormFields(conditions);
|
||||
}
|
||||
if (nextProps.visible !== this.props.visible && !nextProps.visible) {
|
||||
paymentForm.resetForm();
|
||||
changePaymentForm();
|
||||
}
|
||||
}
|
||||
|
||||
handleChange = (val) => {
|
||||
const key = Object.keys(val)[0];
|
||||
if (key === "protocolNumber") {
|
||||
const { declareStore: { paymentForm } } = this.props;
|
||||
paymentForm.updateFields({
|
||||
count: val[key].value
|
||||
});
|
||||
}
|
||||
};
|
||||
|
||||
render() {
|
||||
const { conditions, declareStore: { paymentForm } } = this.props;
|
||||
return (
|
||||
<WeaDialog
|
||||
{...this.props} className="paymentDialog" initLoadCss
|
||||
style={{ width: 550 }}
|
||||
>
|
||||
<div className="paymentDialogContent">
|
||||
{!_.isEmpty(conditions) && getSearchs(paymentForm, conditions, 1, false, this.handleChange)}
|
||||
</div>
|
||||
</WeaDialog>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
export default PaymentDialog;
|
||||
|
|
@ -0,0 +1,42 @@
|
|||
/*
|
||||
* Author: 黎永顺
|
||||
* name: 在线申报-三方缴款详情
|
||||
* Description:
|
||||
* Date: 2023/8/22
|
||||
*/
|
||||
import React, { Component } from "react";
|
||||
import { WeaDialog, WeaLocaleProvider } from "ecCom";
|
||||
|
||||
const { getLabel } = WeaLocaleProvider;
|
||||
|
||||
class PaymentFeedBackDetail extends Component {
|
||||
|
||||
render() {
|
||||
const { showData } = this.props;
|
||||
return (
|
||||
<WeaDialog
|
||||
{...this.props} className="paymentDialog" initLoadCss
|
||||
style={{ width: 550 }}
|
||||
>
|
||||
<div className="with-holding-pay-detail">
|
||||
<div className="status">{getLabel(111, "缴款成功")}</div>
|
||||
<div className="line">
|
||||
<div className="label">{getLabel(111, "状态:")}</div>
|
||||
<div className="value">{getLabel(111, "申报成功,已缴款")}</div>
|
||||
</div>
|
||||
<div className="line">
|
||||
<div className="label">{getLabel(111, "实缴金额:")}</div>
|
||||
<div
|
||||
className="value">{showData.payAmount} {parseFloat(showData.otherAmount) > 0 ? `(含滞纳金等{${showData.otherAmount}元)` : ""} </div>
|
||||
</div>
|
||||
<div className="line">
|
||||
<div className="label">{getLabel(111, "申报人数:")}</div>
|
||||
<div className="value">{showData.personNum} </div>
|
||||
</div>
|
||||
</div>
|
||||
</WeaDialog>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
export default PaymentFeedBackDetail;
|
||||
|
|
@ -0,0 +1,199 @@
|
|||
/*
|
||||
* Author: 黎永顺
|
||||
* name: 在线申报-缴款反馈按钮
|
||||
* Description:
|
||||
* Date: 2023/8/22
|
||||
*/
|
||||
import React, { Component } from "react";
|
||||
import { WeaLocaleProvider } from "ecCom";
|
||||
import { Button, message } from "antd";
|
||||
import { inject, observer } from "mobx-react";
|
||||
import PaymentDialog from "./paymentDialog";
|
||||
import PaymentFeedBackDetail from "./paymentFeedBackDetail";
|
||||
import { paymentFeedbackConditions } from "./constants";
|
||||
import { convertToUrlString, getQueryString } from "../../../util/url";
|
||||
import { taxPaymentAgreementPayFeedback, taxPaymentVoucherPrintFeedback } from "../../../apis/declare";
|
||||
|
||||
const { getLabel } = WeaLocaleProvider;
|
||||
|
||||
@inject("declareStore")
|
||||
@observer
|
||||
class PaymentFeedbackBtn extends Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
paymentDialog: {
|
||||
visible: false, title: "",
|
||||
buttons: [], conditions: null
|
||||
},
|
||||
paymentFeedbackDialog: {
|
||||
visible: false, title: "", showData: {}
|
||||
},
|
||||
loading: false
|
||||
};
|
||||
}
|
||||
|
||||
getFeedback = () => {
|
||||
const { declareStore: { paymentForm } } = this.props;
|
||||
paymentForm.validateForm().then(f => {
|
||||
const { type } = paymentForm.getFormParams();
|
||||
if (f.isValid) {
|
||||
if (type === "WITHHOLDING_PAY") {
|
||||
// 三方缴款 弹窗,打印新开页面
|
||||
this.taxPaymentAgreementPayFeedback();
|
||||
} else {
|
||||
this.taxPaymentVoucherPrintFeedback();
|
||||
}
|
||||
} else {
|
||||
f.showErrors();
|
||||
}
|
||||
});
|
||||
};
|
||||
taxPaymentAgreementPayFeedback = () => {
|
||||
const { taxCycle: taxYearMonth, taxAgentId } = this.props.declareInfo;
|
||||
const payload = {
|
||||
taxDeclareRecordId: getQueryString("id"),
|
||||
taxAgentId, taxYearMonth
|
||||
};
|
||||
this.setState({
|
||||
paymentDialog: {
|
||||
...this.state.paymentDialog,
|
||||
buttons: [
|
||||
<Button type="primary" loading={true}>{getLabel(111, "获取反馈")}</Button>
|
||||
]
|
||||
}
|
||||
});
|
||||
taxPaymentAgreementPayFeedback(payload).then(({ status, data, errormsg }) => {
|
||||
this.setState({
|
||||
paymentDialog: {
|
||||
...this.state.paymentDialog,
|
||||
buttons: [
|
||||
<Button type="primary" loading={false} onClick={this.getFeedback}>{getLabel(111, "获取反馈")}</Button>
|
||||
]
|
||||
}
|
||||
});
|
||||
if (status) {
|
||||
this.handleCancel();
|
||||
this.setState({
|
||||
paymentFeedbackDialog: {
|
||||
...this.state.paymentFeedbackDialog,
|
||||
visible: true, title: getLabel(111, "三方缴款详情"),
|
||||
showData: data
|
||||
}
|
||||
});
|
||||
} else {
|
||||
message.error(errormsg || getLabel(111, "缴款反馈失败!"));
|
||||
}
|
||||
}).catch(() => {
|
||||
this.setState({
|
||||
paymentDialog: {
|
||||
...this.state.paymentDialog,
|
||||
buttons: [
|
||||
<Button type="primary" loading={false} onClick={this.getFeedback}>{getLabel(111, "获取反馈")}</Button>
|
||||
]
|
||||
}
|
||||
});
|
||||
});
|
||||
};
|
||||
taxPaymentVoucherPrintFeedback = () => {
|
||||
const { taxCycle: taxYearMonth, taxAgentId } = this.props.declareInfo;
|
||||
const payload = {
|
||||
taxDeclareRecordId: getQueryString("id"),
|
||||
taxAgentId, taxYearMonth, checkFeedback: 1
|
||||
};
|
||||
this.setState({
|
||||
paymentDialog: {
|
||||
...this.state.paymentDialog,
|
||||
buttons: [
|
||||
<Button type="primary" loading={true}>{getLabel(111, "获取反馈")}</Button>
|
||||
]
|
||||
}
|
||||
});
|
||||
taxPaymentVoucherPrintFeedback(payload).then(({ status, data, errormsg }) => {
|
||||
this.setState({
|
||||
paymentDialog: {
|
||||
...this.state.paymentDialog,
|
||||
buttons: [
|
||||
<Button type="primary" loading={false} onClick={this.getFeedback}>{getLabel(111, "获取反馈")}</Button>
|
||||
]
|
||||
}
|
||||
});
|
||||
if (status) {
|
||||
this.handleCancel();
|
||||
window.open(`${window.ecologyContentPath || ""}/spa/hrmSalary/static/index.html#/main/hrmSalary/bankVoucherDetail?${convertToUrlString(payload)}`);
|
||||
} else {
|
||||
message.error(errormsg || getLabel(111, "缴款反馈失败!"));
|
||||
}
|
||||
}).catch(() => {
|
||||
this.setState({
|
||||
paymentDialog: {
|
||||
...this.state.paymentDialog,
|
||||
buttons: [
|
||||
<Button type="primary" loading={false} onClick={this.getFeedback}>{getLabel(111, "获取反馈")}</Button>
|
||||
]
|
||||
}
|
||||
});
|
||||
});
|
||||
};
|
||||
handlePaymentFeedback = () => {
|
||||
const { paymentDialog } = this.state;
|
||||
this.setState({
|
||||
paymentDialog: {
|
||||
...paymentDialog, visible: true,
|
||||
title: getLabel(111, "获取反馈"),
|
||||
buttons: [
|
||||
<Button type="primary" onClick={this.getFeedback}>{getLabel(111, "获取反馈")}</Button>
|
||||
],
|
||||
conditions: _.map(paymentFeedbackConditions, item => {
|
||||
return {
|
||||
...item,
|
||||
items: _.map(item.items, it => {
|
||||
return {
|
||||
...it,
|
||||
options: [
|
||||
{ key: "WITHHOLDING_PAY", showname: getLabel(111, "三方缴款") },
|
||||
{ key: "WITHHOLDING_VOUCHER", showname: getLabel(111, "缴款凭证打印") }
|
||||
]
|
||||
};
|
||||
})
|
||||
};
|
||||
})
|
||||
}
|
||||
});
|
||||
};
|
||||
handleCancel = () => {
|
||||
const { paymentDialog } = this.state;
|
||||
this.setState({
|
||||
paymentDialog: {
|
||||
...paymentDialog, visible: false,
|
||||
title: "", buttons: [], conditions: null
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
render() {
|
||||
const { paymentDialog, paymentFeedbackDialog } = this.state;
|
||||
return (
|
||||
<React.Fragment>
|
||||
<Button type="ghost" onClick={this.handlePaymentFeedback}>{getLabel(111, "缴款反馈")}</Button>
|
||||
<PaymentDialog
|
||||
{...paymentDialog}
|
||||
onCancel={this.handleCancel}
|
||||
/>
|
||||
<PaymentFeedBackDetail
|
||||
{...paymentFeedbackDialog}
|
||||
onCancel={() => {
|
||||
this.setState({
|
||||
paymentFeedbackDialog: {
|
||||
...paymentFeedbackDialog,
|
||||
visible: false, title: "", showData: {}
|
||||
}
|
||||
}, () => this.props.updateDeclare());
|
||||
}}
|
||||
/>
|
||||
</React.Fragment>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
export default PaymentFeedbackBtn;
|
||||
|
|
@ -0,0 +1,107 @@
|
|||
/*
|
||||
* Author: 黎永顺
|
||||
* name: 个税申报表详情-基本信息
|
||||
* Description:
|
||||
* Date: 2023/8/18
|
||||
*/
|
||||
import React, { Component } from "react";
|
||||
import { message, Tag } from "antd";
|
||||
import { WeaLocaleProvider } from "ecCom";
|
||||
import DeclareResultDialog from "./declareResultDialog";
|
||||
import { taxdeclarationUpdateIcon } from "../../../apis/declare";
|
||||
import { getQueryString } from "../../../util/url";
|
||||
|
||||
const { getLabel } = WeaLocaleProvider;
|
||||
|
||||
class TaxDeclarationInfo extends Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
resDialog: {
|
||||
visible: false, title: "",
|
||||
type: []
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
handleSeeResult = (type, title) => {
|
||||
this.setState({
|
||||
resDialog: { ...this.state.resDialog, visible: true, title: `${title}${getLabel(111, "详情")}`, type }
|
||||
});
|
||||
};
|
||||
handleUpdateicon = () => {
|
||||
taxdeclarationUpdateIcon({ taxDeclareRecordId: getQueryString("id") })
|
||||
.then(({ status, errormsg }) => {
|
||||
if (status) {
|
||||
message.success(getLabel(502230, "删除成功!"));
|
||||
} else {
|
||||
message.error(errormsg || getLabel(20462, "删除失败!"));
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
render() {
|
||||
const { resDialog } = this.state;
|
||||
const { declareInfo } = this.props;
|
||||
const { abnormalSize, declareFailSize } = declareInfo;
|
||||
const infoItem = [
|
||||
{ key: "salaryMonth", label: getLabel(542604, "薪资所属月") },
|
||||
{ key: "taxAgentName", label: getLabel(537996, "个税扣缴义务人") },
|
||||
{ key: "declareTypeDesc", label: getLabel(111, "申报类型") },
|
||||
{ key: "declareStatusDesc", label: getLabel(111, "申报状态") },
|
||||
{ key: "taxCycle", label: getLabel(542240, "税款所属期") },
|
||||
{ key: "taxPaidAmount", label: getLabel(111, "已缴金额") }
|
||||
];
|
||||
return (
|
||||
<div className="taxDeclarationInfo_layout">
|
||||
<div className="base-info">
|
||||
{
|
||||
_.map(infoItem, item => {
|
||||
return <div className="info-item">
|
||||
<span className="label">{item["label"]}:</span>
|
||||
<span className="value">
|
||||
{declareInfo[item["key"]]}
|
||||
{
|
||||
(item["key"] === "declareStatusDesc" && declareInfo["displayIcon"]) &&
|
||||
<span title={getLabel(111, "该个税申报表对应的核算数据被重新核算")} className="icon-span">
|
||||
<Tag closable onClose={this.handleUpdateicon}>
|
||||
<i className="icon-coms02-Warning-01"/>
|
||||
</Tag>
|
||||
</span>
|
||||
}
|
||||
</span>
|
||||
{
|
||||
item.key === "taxPaidAmount" &&
|
||||
<span className="value">{getLabel(111, "元")}</span>
|
||||
}
|
||||
</div>;
|
||||
})
|
||||
}
|
||||
</div>
|
||||
<div className="weapp-salary-btn-flex tools-line">
|
||||
<span className="item"
|
||||
onClick={() => this.handleSeeResult([
|
||||
{ key: "list4NotDeclare", title: getLabel(111, "待报送") },
|
||||
{ key: "list4NoValue", title: getLabel(111, "缺申报数据") }
|
||||
], getLabel(111, "申报校验异常"))}>
|
||||
{getLabel(111, "申报校验异常")}({abnormalSize || 0})
|
||||
</span>
|
||||
<span className="item"
|
||||
onClick={() => this.handleSeeResult([{ key: "list4Fail" }], getLabel(111, "申报失败数据"))}>
|
||||
{getLabel(111, "申报失败数据")}({declareFailSize || 0})
|
||||
</span>
|
||||
<DeclareResultDialog
|
||||
{...resDialog}
|
||||
onCancel={() => {
|
||||
this.setState({
|
||||
resDialog: { ...resDialog, visible: false, title: "", type: [] }
|
||||
});
|
||||
}}
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
export default TaxDeclarationInfo;
|
||||
|
|
@ -0,0 +1,324 @@
|
|||
/*
|
||||
* Author: 黎永顺
|
||||
* name: 个税查看详情页面
|
||||
* Description:
|
||||
* Date: 2023/8/18
|
||||
*/
|
||||
import React, { Component } from "react";
|
||||
import { WeaLocaleProvider, WeaTab, WeaTable } from "ecCom";
|
||||
import { Button, message } from "antd";
|
||||
import TaxDeclarationInfo from "./components/taxDeclarationInfo";
|
||||
import { apiflowBillingConfigStatus } from "../../apis/intelligentCalculateSalarySettings";
|
||||
import PaymentBtn from "./components/paymentBtn";
|
||||
import PaymentFeedbackBtn from "./components/paymentFeedbackBtn";
|
||||
import {
|
||||
getDeclareInfo,
|
||||
getDetailList,
|
||||
getTaxDeclarationTab,
|
||||
taxdeclaratioGetCancelFeedback,
|
||||
taxdeclarationDeclare,
|
||||
taxdeclarationGetDeclareFeedback,
|
||||
taxdeclarationGetRate,
|
||||
taxdeclarationRefreshData,
|
||||
taxdeclaratioUpdateCancel,
|
||||
taxdeclaratioUpdateDeclare,
|
||||
taxPaymentVoucherStatusSync,
|
||||
taxPaymentWithheldVoucherGet
|
||||
} from "../../apis/declare";
|
||||
import { convertToUrlString, getQueryString } from "../../util/url";
|
||||
import "./index.less";
|
||||
|
||||
const { getLabel } = WeaLocaleProvider;
|
||||
|
||||
const APIFox = {
|
||||
refresh: taxdeclarationRefreshData, //刷新数据
|
||||
declare: taxdeclarationDeclare, //在线申报
|
||||
feedback: taxdeclarationGetDeclareFeedback,//申报反馈
|
||||
correct: taxdeclaratioUpdateDeclare,//更正申报
|
||||
cancel: taxdeclaratioUpdateCancel,//作废申报
|
||||
cancelFeedback: taxdeclaratioGetCancelFeedback//作废反馈
|
||||
};
|
||||
|
||||
class Index extends Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
tabs: [], selectedKey: "", columns: [], dataSource: [],
|
||||
loading: {
|
||||
query: false, refresh: false, declare: false, feedback: false,
|
||||
correct: false, cancel: false, cancelFeedback: false, refreshingPay: false,
|
||||
issuance: false
|
||||
},
|
||||
intelCalcSalaryStatus: false, //智能算薪 总开关是否开启
|
||||
declareInfo: {}, pageInfo: { current: 0, pageSize: 10, total: 0 }
|
||||
};
|
||||
this.timer = null;
|
||||
}
|
||||
|
||||
componentDidMount() {
|
||||
const promise = this.init();
|
||||
}
|
||||
|
||||
init = async () => {
|
||||
const [tabsResult, infoResult, calcResult] = await Promise.all([this.getTaxDeclarationTab(), this.getDeclareInfo(), this.apiflowBillingConfigStatus()]);
|
||||
const { data: tabDataSource, status: tabStatus } = tabsResult;
|
||||
const { data: infoDataSource, status: infoStatus } = infoResult;
|
||||
const { data: calcSalaryStatus, status: calcStatus } = calcResult;
|
||||
this.setState({
|
||||
tabs: tabStatus ? _.map(tabDataSource, it => ({
|
||||
viewcondition: `${it.incomeCategory}%%${it.taxDeclarationId}`,
|
||||
title: it.tabName
|
||||
})) : this.state.tabs,
|
||||
selectedKey: tabStatus ? `${_.take(tabDataSource)[0].incomeCategory}%%${_.take(tabDataSource)[0].taxDeclarationId}` : this.state.selectedKey,
|
||||
declareInfo: infoStatus ? infoDataSource : this.state.declareInfo,
|
||||
intelCalcSalaryStatus: calcStatus && calcSalaryStatus
|
||||
});
|
||||
this.getDetailList();
|
||||
};
|
||||
declare = async () => {
|
||||
const [infoResult] = await Promise.all([this.getDeclareInfo()]);
|
||||
const { data: infoDataSource, status: infoStatus } = infoResult;
|
||||
this.setState({
|
||||
declareInfo: infoStatus ? infoDataSource : this.state.declareInfo
|
||||
});
|
||||
this.getDetailList();
|
||||
};
|
||||
getTaxDeclarationTab = () => {
|
||||
return getTaxDeclarationTab({ id: getQueryString("id") });
|
||||
};
|
||||
getDeclareInfo = () => {
|
||||
return getDeclareInfo({ id: getQueryString("id") });
|
||||
};
|
||||
apiflowBillingConfigStatus = () => {
|
||||
return apiflowBillingConfigStatus();
|
||||
};
|
||||
taxdeclarationGetRate = (index) => {
|
||||
return taxdeclarationGetRate({ index });
|
||||
};
|
||||
getDetailList = () => {
|
||||
const { loading, pageInfo, selectedKey } = this.state;
|
||||
const [incomeCategory, taxDeclarationId] = selectedKey.split("%%");
|
||||
const payload = {
|
||||
...pageInfo, incomeCategory, taxDeclarationId,
|
||||
taxDeclareRecordId: getQueryString("id")
|
||||
};
|
||||
this.setState({ loading: { ...loading, query: true } });
|
||||
getDetailList(payload).then(({ status, data }) => {
|
||||
this.setState({ loading: { ...loading, query: false } });
|
||||
if (status) {
|
||||
const { columns, list: dataSource, pageNum: current, pageSize, total } = data;
|
||||
this.setState({
|
||||
dataSource, pageInfo: { ...pageInfo, current, pageSize, total },
|
||||
columns: _.map(columns, (it, idx) => {
|
||||
if (idx <= 1) {
|
||||
return { ...it, width: 150, fixed: "left" };
|
||||
}
|
||||
return { ...it, width: 150 };
|
||||
})
|
||||
});
|
||||
}
|
||||
}).catch(() => this.setState({ loading: { ...loading, query: false } }));
|
||||
};
|
||||
handleOperateDeclare = (type) => {
|
||||
const loadingTxt = {
|
||||
refresh: getLabel(111, "刷新中..."), //刷新数据
|
||||
declare: getLabel(111, "申报中..."), //在线申报
|
||||
feedback: getLabel(111, "反馈中..."),//申报反馈
|
||||
correct: getLabel(111, "更正申报中..."),//更正申报
|
||||
cancel: getLabel(111, "作废申报中..."),//作废申报
|
||||
cancelFeedback: getLabel(111, "作废反馈中...")//作废反馈
|
||||
}, successTxt = {
|
||||
refresh: getLabel(111, "刷新数据成功!"), //刷新数据
|
||||
declare: getLabel(111, "在线申报成功!"), //在线申报
|
||||
feedback: getLabel(111, "申报反馈成功!"),//申报反馈
|
||||
correct: getLabel(111, "更正申报成功!"),//更正申报
|
||||
cancel: getLabel(111, "作废申报成功!"),//作废申报
|
||||
cancelFeedback: getLabel(111, "作废反馈成功!")//作废反馈
|
||||
}, failTxt = {
|
||||
refresh: getLabel(111, "刷新数据失败!"), //刷新数据
|
||||
declare: getLabel(111, "在线申报失败!"), //在线申报
|
||||
feedback: getLabel(111, "申报反馈失败!"),//申报反馈
|
||||
correct: getLabel(111, "更正申报失败!"),//更正申报
|
||||
cancel: getLabel(111, "作废申报失败!"),//作废申报
|
||||
cancelFeedback: getLabel(111, "作废反馈失败!")//作废反馈
|
||||
};
|
||||
this.setState({ loading: { ...this.state.loading, [type]: true } });
|
||||
APIFox[type]({ taxDeclareRecordId: getQueryString("id") })
|
||||
.then(async ({ status, data, errormsg }) => {
|
||||
if (status) {
|
||||
message.destroy();
|
||||
message.loading(loadingTxt[type], 0);
|
||||
this.timer = setInterval(async () => {
|
||||
const { status: resStatus, data: result } = await this.taxdeclarationGetRate(data);
|
||||
const { status: rateStatus, finish, msg } = result;
|
||||
if (resStatus && rateStatus) {
|
||||
if (finish) {
|
||||
this.setState({ loading: { ...this.state.loading, [type]: false } });
|
||||
clearInterval(this.timer);
|
||||
message.destroy();
|
||||
message.success(successTxt[type]);
|
||||
const promise = type === "refresh" ? await this.init() : await this.declare();
|
||||
}
|
||||
} else {
|
||||
this.setState({ loading: { ...this.state.loading, [type]: false } });
|
||||
clearInterval(this.timer);
|
||||
message.destroy();
|
||||
message.warning(msg || failTxt[type]);
|
||||
const promise = type === "refresh" ? await this.init() : await this.declare();
|
||||
}
|
||||
}, 1000);
|
||||
} else {
|
||||
this.setState({ loading: { ...this.state.loading, [type]: false } });
|
||||
clearInterval(this.timer);
|
||||
message.destroy();
|
||||
message.warning(errormsg);
|
||||
}
|
||||
}).catch(() => {
|
||||
message.destroy();
|
||||
clearInterval(this.timer);
|
||||
this.setState({ loading: { ...this.state.loading, [type]: false } });
|
||||
});
|
||||
};
|
||||
taxPaymentVoucherStatusSync = () => {
|
||||
const { taxAgentId, taxCycle: taxYearMonth } = this.state.declareInfo;
|
||||
const payload = {
|
||||
taxDeclareRecordId: getQueryString("id"),
|
||||
taxAgentId, taxYearMonth
|
||||
};
|
||||
this.setState({ loading: { ...this.state.loading, refreshingPay: true } });
|
||||
taxPaymentVoucherStatusSync(payload).then(({ status, errormsg }) => {
|
||||
this.setState({ loading: { ...this.state.loading, refreshingPay: false } });
|
||||
if (status) {
|
||||
message.success(getLabel(111, "刷新成功!"));
|
||||
const promise = this.declare();
|
||||
} else {
|
||||
message.error(errormsg || getLabel(111, "刷新失败!"));
|
||||
}
|
||||
}).catch(() => this.setState({ loading: { ...this.state.loading, refreshingPay: false } }));
|
||||
};
|
||||
getEnterprisePayCertificate = () => {
|
||||
const { taxAgentId, taxCycle: taxYearMonth } = this.state.declareInfo;
|
||||
const payload = {
|
||||
taxDeclareRecordId: getQueryString("id"),
|
||||
taxAgentId, taxYearMonth
|
||||
};
|
||||
this.setState({ loading: { ...this.state.loading, issuance: true } });
|
||||
taxPaymentWithheldVoucherGet(payload).then(({ status, data, errormsg }) => {
|
||||
this.setState({ loading: { ...this.state.loading, issuance: false } });
|
||||
if (status && !_.isEmpty(data.vouchers)) {
|
||||
window.open(`${window.ecologyContentPath || ""}/spa/hrmSalary/static/index.html#/main/hrmSalary/enterprisePayCertificationDetail?${convertToUrlString(payload)}`);
|
||||
} else {
|
||||
message.error(errormsg || "");
|
||||
}
|
||||
}).catch(() => this.setState({ loading: { ...this.state.loading, issuance: false } }));
|
||||
};
|
||||
export = () => {
|
||||
const [incomeCategory, taxDeclarationId] = this.state.selectedKey.split("%%");
|
||||
const payload = {
|
||||
taxDeclareRecordId: getQueryString("id"),
|
||||
taxDeclarationId: taxDeclarationId.toString(),
|
||||
incomeCategory
|
||||
};
|
||||
window.open(`${window.ecologyContentPath || ""}/api/bs/hrmsalary/taxdeclaration/detail/export?${convertToUrlString(payload)}`, "_blank");
|
||||
};
|
||||
|
||||
render() {
|
||||
const {
|
||||
tabs, selectedKey, columns, pageInfo,
|
||||
dataSource, loading, declareInfo, intelCalcSalaryStatus
|
||||
} = this.state;
|
||||
let btns = [
|
||||
<Button type="primary" onClick={this.export}>{getLabel(17416, "导出")}</Button>,
|
||||
<Button type="ghost" onClick={() => this.handleOperateDeclare("declare")}
|
||||
loading={loading.declare}>{getLabel(111, "在线申报")}</Button>,
|
||||
<Button type="ghost" onClick={() => this.handleOperateDeclare("refresh")}
|
||||
loading={loading.refresh}>{getLabel(111, "刷新数据")}</Button>
|
||||
];
|
||||
const pagination = {
|
||||
...pageInfo,
|
||||
showTotal: total => `${getLabel(18609, "共")} ${total} ${getLabel(18256, "条")}`,
|
||||
showQuickJumper: true,
|
||||
showSizeChanger: true,
|
||||
pageSizeOptions: ["10", "20", "50", "100"],
|
||||
onShowSizeChange: (current, pageSize) => {
|
||||
this.setState({
|
||||
pageInfo: { ...pageInfo, current, pageSize }
|
||||
}, () => this.getDetailList());
|
||||
},
|
||||
onChange: current => {
|
||||
this.setState({
|
||||
pageInfo: { ...pageInfo, current }
|
||||
}, () => this.getDetailList());
|
||||
}
|
||||
};
|
||||
//申报状态:作废中
|
||||
declareInfo.declareStatus === "DECLARE_CANCELLING" && (btns.splice(1, 2, <Button
|
||||
type="ghost" loading={loading.cancelFeedback}
|
||||
onClick={() => this.handleOperateDeclare("cancelFeedback")}>{getLabel(111, "作废反馈")}</Button>));
|
||||
//申报状态:申报中
|
||||
declareInfo.declareStatus === "DECLARING" && (btns.splice(1, 2, <Button
|
||||
type="ghost" loading={loading.feedback}
|
||||
onClick={() => this.handleOperateDeclare("feedback")}>{getLabel(111, "申报反馈")}</Button>));
|
||||
//申报状态:缴款中
|
||||
declareInfo.declareStatus === "DECLARE_SUCCESS_PAYING" && (btns.splice(1, 2));
|
||||
//申报状态:已缴款
|
||||
declareInfo.declareStatus === "DECLARE_SUCCESS_PAID" && (btns.splice(1, 2,
|
||||
<Button type="ghost" loading={loading.correct}
|
||||
onClick={() => this.handleOperateDeclare("correct")}>{getLabel(111, "更正申报")}</Button>));
|
||||
//申报状态:申报成功,无需缴款
|
||||
declareInfo.declareStatus === "DECLARE_SUCCESS_NO_PAY" &&
|
||||
(btns.splice(1, 2,
|
||||
<Button type="ghost" loading={loading.correct}
|
||||
onClick={() => this.handleOperateDeclare("correct")}>{getLabel(111, "更正申报")}</Button>,
|
||||
<Button type="ghost"
|
||||
loading={loading.cancel}
|
||||
onClick={() => this.handleOperateDeclare("cancel")}>{getLabel(111, "作废申报")}</Button>
|
||||
));
|
||||
//申报状态:申报成功,未缴款
|
||||
declareInfo.declareStatus === "DECLARE_SUCCESS_UNPAID" &&
|
||||
(btns.splice(1, 2,
|
||||
<Button type="ghost" loading={loading.correct}
|
||||
onClick={() => this.handleOperateDeclare("correct")}>{getLabel(111, "更正申报")}</Button>,
|
||||
<Button type="ghost"
|
||||
loading={loading.cancel}
|
||||
onClick={() => this.handleOperateDeclare("cancel")}>{getLabel(111, "作废申报")}</Button>,
|
||||
<Button type="ghost"
|
||||
loading={loading.refreshingPay}
|
||||
onClick={this.taxPaymentVoucherStatusSync}>{getLabel(111, "刷新缴款状态")}</Button>
|
||||
));
|
||||
if (!intelCalcSalaryStatus) {
|
||||
if (["NOT_DECLARE", "DECLARE_FAIL"].includes(declareInfo.declareStatus)) {
|
||||
btns.splice(1, 1);
|
||||
}
|
||||
}
|
||||
if (intelCalcSalaryStatus && (declareInfo.declareStatus === "DECLARE_SUCCESS_UNPAID")) {
|
||||
btns.push(
|
||||
<PaymentBtn declareInfo={declareInfo} updateDeclare={this.declare}/>,
|
||||
<PaymentFeedbackBtn declareInfo={declareInfo} updateDeclare={this.declare}/>
|
||||
);
|
||||
}
|
||||
if (intelCalcSalaryStatus && declareInfo.taxPaidAmount && parseFloat(declareInfo.taxPaidAmount) > 0) {
|
||||
btns.push(<Button type="ghost" loading={loading.issuance}
|
||||
onClick={this.getEnterprisePayCertificate}>{getLabel(111, "开具企业完税证明")}</Button>);
|
||||
}
|
||||
return (
|
||||
<div className="declareDetail-layout">
|
||||
<TaxDeclarationInfo declareInfo={declareInfo}/>
|
||||
<div className="declareDetail-layout-content">
|
||||
<WeaTab
|
||||
datas={tabs} keyParam="viewcondition" selectedKey={selectedKey}
|
||||
buttons={btns}
|
||||
/>
|
||||
<WeaTable
|
||||
loading={loading.query} bordered
|
||||
columns={columns} dataSource={dataSource}
|
||||
pagination={pagination}
|
||||
scroll={{ x: 1200, y: `calc(100vh - 190px)` }}
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
export default Index;
|
||||
|
|
@ -0,0 +1,211 @@
|
|||
.declareDetail-layout {
|
||||
.declareDetail-layout-content {
|
||||
padding: 0 16px;
|
||||
}
|
||||
|
||||
.icon-span {
|
||||
cursor: pointer;
|
||||
|
||||
.ant-tag:hover .anticon-cross {
|
||||
display: block;
|
||||
}
|
||||
|
||||
.ant-tag {
|
||||
background: transparent;
|
||||
border-radius: 0;
|
||||
border: none;
|
||||
position: relative;
|
||||
|
||||
.anticon-cross {
|
||||
position: absolute;
|
||||
right: -1px;
|
||||
top: -1px;
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
|
||||
i.icon-coms02-Warning-01 {
|
||||
font-size: 16px;
|
||||
color: red;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.taxDeclarationInfo_layout {
|
||||
border-bottom: 1px solid #e5e5e5;
|
||||
height: 48px;
|
||||
padding: 0 16px;
|
||||
font-size: 12px;
|
||||
color: #111;
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
|
||||
.base-info {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: flex-start;
|
||||
|
||||
.info-item {
|
||||
margin-right: 25px;
|
||||
|
||||
.label {
|
||||
color: #666;
|
||||
}
|
||||
|
||||
.value {
|
||||
color: #111;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.weapp-salary-btn-flex {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: flex-end;
|
||||
cursor: auto;
|
||||
}
|
||||
|
||||
.tools-line {
|
||||
font-size: 12px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
color: #111;
|
||||
|
||||
.item {
|
||||
margin-left: 8px;
|
||||
cursor: pointer;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.declareResultDialog {
|
||||
.wea-new-top-req-wapper .wea-new-top-req-main {
|
||||
padding: 12px 0 0 0;
|
||||
background: transparent;
|
||||
}
|
||||
|
||||
.wea-new-top-req-wapper .wea-new-top-req-main .wea-new-top-req-title-text {
|
||||
color: #111;
|
||||
font-weight: 700;
|
||||
}
|
||||
|
||||
.wea-new-top-req-wapper .wea-new-top-req {
|
||||
background: transparent;
|
||||
}
|
||||
|
||||
.wea-new-top-req-wapper .wea-new-top-req-title > div:first-child > div {
|
||||
max-width: 500px !important;
|
||||
}
|
||||
|
||||
.wea-new-top-req-wapper .wea-new-top-req-title > div:last-child {
|
||||
background: transparent;
|
||||
}
|
||||
|
||||
.declareResultDialogTitle {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
|
||||
.declareResultDialogTitle-left {
|
||||
text-align: left;
|
||||
|
||||
.title {
|
||||
color: #111;
|
||||
font-weight: 700;
|
||||
}
|
||||
}
|
||||
|
||||
.declareResultDialogTitle-right {
|
||||
text-align: right;
|
||||
}
|
||||
}
|
||||
|
||||
.declareResultDialogContent {
|
||||
height: 100%;
|
||||
padding: 16px;
|
||||
background: #f6f6f6;
|
||||
overflow-y: auto;
|
||||
|
||||
.declareTable {
|
||||
background: #FFF;
|
||||
}
|
||||
|
||||
.declareNoSearchBox {
|
||||
display: flex;
|
||||
justify-content: flex-end;
|
||||
padding: 5px 5px 9px 0;
|
||||
background: #Ffff;
|
||||
margin-bottom: 16px;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
.paymentDialog {
|
||||
.ant-modal-title {
|
||||
.text-elli {
|
||||
color: #111;
|
||||
font-weight: 700;
|
||||
}
|
||||
}
|
||||
|
||||
.ant-modal-footer {
|
||||
.ext-link {
|
||||
padding-left: 0 !important;
|
||||
padding-right: 10px !important;
|
||||
text-align: left !important;
|
||||
}
|
||||
}
|
||||
|
||||
.paymentDialogContent {
|
||||
padding: 16px 25px;
|
||||
background: #f6f6f6;
|
||||
|
||||
.wea-search-group {
|
||||
border: 1px solid #e5e5e5;
|
||||
padding: 0;
|
||||
border-bottom: none;
|
||||
|
||||
.ant-row, .ant-col-24 {
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
.wea-form-item {
|
||||
padding: 5px 16px;
|
||||
background: #fff;
|
||||
border-bottom: 1px solid #e5e5e5;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.with-holding-pay-detail {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
padding: 16px;
|
||||
|
||||
& > div {
|
||||
line-height: 32px;
|
||||
}
|
||||
|
||||
.status {
|
||||
height: 32px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
color: #8ED36E;
|
||||
}
|
||||
|
||||
.line {
|
||||
display: flex;
|
||||
height: 32px;
|
||||
align-items: center;
|
||||
|
||||
.label {
|
||||
width: 30%;
|
||||
flex-grow: 0;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,111 @@
|
|||
/*
|
||||
* Author: 黎永顺
|
||||
* name: 人员信息报送
|
||||
* Description:
|
||||
* Date: 2023/7/24
|
||||
*/
|
||||
import React, { Component } from "react";
|
||||
import { WeaInputSearch, WeaLocaleProvider, WeaTable, WeaTop } from "ecCom";
|
||||
import { Col, message, Row } from "antd";
|
||||
import { taxAgentDeclareList } from "../../apis/declare";
|
||||
import TipLabel from "../../components/TipLabel";
|
||||
import "./index.less";
|
||||
|
||||
|
||||
const { getLabel } = WeaLocaleProvider;
|
||||
|
||||
class Index extends Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
dataSource: [], loading: false, taxAgentName: "",
|
||||
pageInfo: { current: 1, pageSize: 10, total: 0 }
|
||||
};
|
||||
}
|
||||
|
||||
componentDidMount() {
|
||||
this.taxAgentDeclareList();
|
||||
}
|
||||
|
||||
taxAgentDeclareList = () => {
|
||||
const { pageInfo, taxAgentName } = this.state;
|
||||
const payload = { ...pageInfo, taxAgentName };
|
||||
this.setState({ loading: true });
|
||||
taxAgentDeclareList(payload).then(({ status, data, errormsg }) => {
|
||||
this.setState({ loading: false });
|
||||
if (status) {
|
||||
const { pageNum: current, pageSize, total, list: dataSource } = data;
|
||||
this.setState({
|
||||
pageInfo: { ...pageInfo, current, pageSize, total },
|
||||
dataSource
|
||||
});
|
||||
} else {
|
||||
message.error(errormsg);
|
||||
}
|
||||
}).catch(() => this.setState({ loading: false }));
|
||||
};
|
||||
|
||||
render() {
|
||||
const { pageInfo, taxAgentName, dataSource } = this.state;
|
||||
const tipList = [
|
||||
getLabel(544290, "1、点击查看详情,管理各个个税扣缴义务人的人员报送信息,如购买了在线报送服务,可在线报送,如未购买在线报送服务,也可导出数据线下报送。")
|
||||
];
|
||||
return (
|
||||
<WeaTop
|
||||
title={getLabel(544289, "人员信息报送")} iconBgcolor="#F14A2D"
|
||||
icon={<i className="icon-coms-fa"/>}
|
||||
buttons={[
|
||||
<WeaInputSearch placeholder={getLabel(543634, "请输入个税扣缴义务人名称")}
|
||||
value={taxAgentName} onChange={val => this.setState({ taxAgentName: val })}
|
||||
onSearch={this.taxAgentDeclareList}
|
||||
/>
|
||||
]}
|
||||
>
|
||||
<div style={{ height: "100%", background: "#f6f6f6", padding: 16 }}>
|
||||
<Row gutter={16}>
|
||||
<Col span={16}>
|
||||
<WeaTable
|
||||
className="declareTable"
|
||||
columns={[
|
||||
{
|
||||
title: getLabel(537996, "个税扣缴义务人"),
|
||||
dataIndex: "taxAgentName"
|
||||
},
|
||||
{
|
||||
title: getLabel(30585, "操作"),
|
||||
dataIndex: "operate",
|
||||
width: 260,
|
||||
render: (_, record) => (<a
|
||||
href={`${window.ecologyContentPath || ""}/spa/hrmSalary/static/index.html#/main/hrmSalary/employeedeclareDetail?id=${record.id}&taxName=${record.taxAgentName}`}
|
||||
target="_blank">{getLabel(83110, "查看详情")}</a>)
|
||||
}
|
||||
]}
|
||||
dataSource={dataSource}
|
||||
pagination={{
|
||||
...pageInfo,
|
||||
showTotal: total => `${getLabel(18609, "共")} ${total} ${getLabel(18256, "条")}`,
|
||||
showQuickJumper: true,
|
||||
showSizeChanger: true,
|
||||
pageSizeOptions: ["10", "20", "50", "100"],
|
||||
onShowSizeChange: (current, pageSize) => {
|
||||
this.setState({
|
||||
pageInfo: { ...pageInfo, current, pageSize }
|
||||
}, () => this.taxAgentDeclareList());
|
||||
},
|
||||
onChange: current => {
|
||||
this.setState({
|
||||
pageInfo: { ...pageInfo, current }
|
||||
}, () => this.taxAgentDeclareList());
|
||||
}
|
||||
}}
|
||||
/>
|
||||
</Col>
|
||||
<Col span={8}><TipLabel tipList={tipList}/></Col>
|
||||
</Row>
|
||||
</div>
|
||||
</WeaTop>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
export default Index;
|
||||
|
|
@ -0,0 +1,3 @@
|
|||
.declareTable {
|
||||
background: #FFF;
|
||||
}
|
||||
|
|
@ -0,0 +1,79 @@
|
|||
/*
|
||||
* Author: 黎永顺
|
||||
* name: 人员信息报送-基础信息
|
||||
* Description:
|
||||
* Date: 2023/8/14
|
||||
*/
|
||||
import React, { Component } from "react";
|
||||
import { WeaLocaleProvider } from "ecCom";
|
||||
import { getQueryString } from "../../../util/url";
|
||||
import EmployeeDeclareDetailCalcDialog from "./employeeDeclareDetailCalcDialog";
|
||||
import { getEmployeeDeclareInfo } from "../../../apis/declare";
|
||||
|
||||
const { getLabel } = WeaLocaleProvider;
|
||||
|
||||
class BaseInfo extends Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
declareCalcDialog: {
|
||||
visible: false, taxCycle: ""
|
||||
},
|
||||
declareInfo: {}
|
||||
};
|
||||
}
|
||||
|
||||
/*
|
||||
* Author: 黎永顺
|
||||
* Description: 人员报送-获取整体的报送情况
|
||||
* Params:
|
||||
* Date: 2023/8/14
|
||||
*/
|
||||
getEmployeeDeclareInfo = () => {
|
||||
const payload = {
|
||||
taxAgentId: getQueryString("id"),
|
||||
taxCycle: this.props.taxCycle
|
||||
};
|
||||
getEmployeeDeclareInfo(payload).then(({ status, data }) => {
|
||||
if (status) this.setState({ declareInfo: data });
|
||||
});
|
||||
};
|
||||
handleOpenFailDialog = () => {
|
||||
this.setState({
|
||||
declareCalcDialog: {
|
||||
visible: true, taxCycle: this.props.taxCycle
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
render() {
|
||||
const { declareCalcDialog, declareInfo } = this.state;
|
||||
const { declareFailSize, notDeclareSize } = declareInfo;
|
||||
return (
|
||||
<div className="base-info">
|
||||
<div className="left">
|
||||
<span>{getLabel(537996, "个税扣缴义务人")}:{decodeURIComponent(getQueryString("taxName") || "")}</span></div>
|
||||
<div className="right">
|
||||
<div className="header-declare-info">
|
||||
<a href="javascript:void(0);" className="fail"
|
||||
onClick={this.handleOpenFailDialog}>{getLabel(111, "报送失败")}: {declareFailSize || 0}</a>
|
||||
<span className="not">{getLabel(111, "未报送")}: {notDeclareSize || 0}</span>
|
||||
</div>
|
||||
</div>
|
||||
{/*报送失败数据查看*/}
|
||||
<EmployeeDeclareDetailCalcDialog
|
||||
{...declareCalcDialog}
|
||||
onCancel={() => {
|
||||
this.setState({
|
||||
declareCalcDialog: {
|
||||
visible: false, taxCycle: ""
|
||||
}
|
||||
});
|
||||
}}
|
||||
/>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
export default BaseInfo;
|
||||
|
|
@ -0,0 +1,102 @@
|
|||
/*
|
||||
* Author: 黎永顺
|
||||
* name: 报送信息-失败查看弹框
|
||||
* Description:
|
||||
* Date: 2023/8/14
|
||||
*/
|
||||
import React, { Component } from "react";
|
||||
import { WeaDialog, WeaLocaleProvider, WeaTable } from "ecCom";
|
||||
import { employeedeclareList4Fail } from "../../../apis/declare";
|
||||
import { Button, Col, Row } from "antd";
|
||||
import { getQueryString } from "../../../util/url";
|
||||
|
||||
const { getLabel } = WeaLocaleProvider;
|
||||
|
||||
class EmployeeDeclareDetailCalcDialog extends Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
pageInfo: { current: 1, pageSize: 10, total: 0 },
|
||||
loading: false, columns: [], dataSource: []
|
||||
};
|
||||
}
|
||||
|
||||
componentWillReceiveProps(nextProps, nextContext) {
|
||||
if (nextProps.visible !== this.props.visible && nextProps.visible) this.employeedeclareList4Fail(nextProps);
|
||||
}
|
||||
|
||||
employeedeclareList4Fail = (props) => {
|
||||
const { pageInfo } = this.state;
|
||||
const payload = {
|
||||
...pageInfo,
|
||||
taxAgentId: getQueryString("id"),
|
||||
taxCycle: props.taxCycle
|
||||
};
|
||||
this.setState({ loading: true });
|
||||
employeedeclareList4Fail(payload).then(({ status, data }) => {
|
||||
this.setState({ loading: false });
|
||||
if (status) {
|
||||
const { columns, list: dataSource, pageNum: current, pageSize, total } = data;
|
||||
this.setState({
|
||||
columns, dataSource,
|
||||
pageInfo: { ...pageInfo, current, pageSize, total }
|
||||
});
|
||||
}
|
||||
}).catch(() => this.setState({ loading: false }));
|
||||
};
|
||||
|
||||
render() {
|
||||
const { loading, columns, dataSource, pageInfo } = this.state;
|
||||
const pagination = {
|
||||
...pageInfo,
|
||||
showTotal: total => `${getLabel(18609, "共")} ${total} ${getLabel(18256, "条")}`,
|
||||
showQuickJumper: true,
|
||||
showSizeChanger: true,
|
||||
pageSizeOptions: ["10", "20", "50", "100"],
|
||||
onShowSizeChange: (current, pageSize) => {
|
||||
this.setState({
|
||||
pageInfo: { ...pageInfo, current, pageSize }
|
||||
}, () => this.employeedeclareList4Fail(this.props));
|
||||
},
|
||||
onChange: current => {
|
||||
this.setState({
|
||||
pageInfo: { ...pageInfo, current }
|
||||
}, () => this.employeedeclareList4Fail(this.props));
|
||||
}
|
||||
};
|
||||
return (
|
||||
<WeaDialog
|
||||
{...this.props}
|
||||
scalable hasScroll className="declareCalcDialog" initLoadCss
|
||||
title={(<Row className="declareCalcDialogTitle" type="flex">
|
||||
<Col span={12} className="declareCalcDialogTitle-left">
|
||||
<span className="title">{getLabel(111, "报送失败数据详情")}</span>
|
||||
</Col>
|
||||
<Col span={12} className="declareCalcDialogTitle-right">
|
||||
{/*<Button type="primary" onClick={this.handleSubmit}>{getLabel(81272, "导出全部")}</Button>*/}
|
||||
</Col>
|
||||
</Row>)}
|
||||
style={{
|
||||
width: 1150,
|
||||
height: 606.6,
|
||||
minHeight: 200,
|
||||
minWidth: 380,
|
||||
maxHeight: "90%",
|
||||
maxWidth: "90%",
|
||||
overflow: "hidden",
|
||||
transform: "translate(0px, 0px)"
|
||||
}}
|
||||
>
|
||||
<div className="declareCalcDialogContent">
|
||||
<WeaTable
|
||||
columns={columns} dataSource={dataSource}
|
||||
loading={loading} className="declareTable"
|
||||
pagination={pagination}
|
||||
/>
|
||||
</div>
|
||||
</WeaDialog>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
export default EmployeeDeclareDetailCalcDialog;
|
||||
|
|
@ -0,0 +1,267 @@
|
|||
/*
|
||||
* Author: 黎永顺
|
||||
* name: 报送信息-编辑、新增弹框
|
||||
* Description:
|
||||
* Date: 2023/8/14
|
||||
*/
|
||||
import React, { Component } from "react";
|
||||
import { WeaLocaleProvider, WeaSlideModal } from "ecCom";
|
||||
import { Button, Col, message, Modal, Row } from "antd";
|
||||
import { inject, observer } from "mobx-react";
|
||||
import { declareConditions } from "../constants";
|
||||
import { getSearchs } from "../../../util";
|
||||
import { getQueryString } from "../../../util/url";
|
||||
import { employeedeclareGetForm, getEmployeeSave } from "../../../apis/declare";
|
||||
|
||||
const { getLabel } = WeaLocaleProvider;
|
||||
|
||||
@inject("employeeDeclareStore")
|
||||
@observer
|
||||
class EmployeeDeclareDetailSchemaEditDialog extends Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
loading: false,
|
||||
eConditions: [],
|
||||
employeeInfo: {}
|
||||
};
|
||||
this.employeeChangeInfo = {};
|
||||
}
|
||||
|
||||
componentWillReceiveProps(nextProps, nextContext) {
|
||||
if (nextProps.visible !== this.props.visible && nextProps.visible) this.employeedeclareGetForm(nextProps);
|
||||
if (nextProps.visible !== this.props.visible && !nextProps.visible) this.employeeChangeInfo = {};
|
||||
}
|
||||
|
||||
employeedeclareGetForm = (props) => {
|
||||
employeedeclareGetForm(_.pick(props, ["id"])).then(({ status, data }) => {
|
||||
if (status) {
|
||||
this.setState({
|
||||
eConditions: _.map(declareConditions, it => {
|
||||
return {
|
||||
...it,
|
||||
items: _.map(it.items, child => {
|
||||
if (child.domkey[0] === "employmentStatus") {
|
||||
return {
|
||||
...child,
|
||||
value: _.take(props.employmentStatusList)[0].enum,
|
||||
options: _.map(props.employmentStatusList, it => ({
|
||||
key: it.enum,
|
||||
showname: getLabel(it.labelId, it.defaultLabel)
|
||||
}))
|
||||
};
|
||||
} else if (child.domkey[0] === "employmentType") {
|
||||
return {
|
||||
...child,
|
||||
value: _.take(props.employmentTypeList)[0].enum,
|
||||
options: _.map(props.employmentTypeList, it => ({
|
||||
key: it.enum,
|
||||
showname: getLabel(it.labelId, it.defaultLabel)
|
||||
}))
|
||||
};
|
||||
} else if (child.domkey[0] === "gender") {
|
||||
return {
|
||||
...child,
|
||||
value: "MALE",
|
||||
options: [
|
||||
{ key: "MALE", showname: getLabel(111, "男") },
|
||||
{ key: "FEMALE", showname: getLabel(111, "女") }
|
||||
]
|
||||
};
|
||||
} else if (child.domkey[0] === "employeeType") {
|
||||
return {
|
||||
...child,
|
||||
viewAttr: props.id ? 1 : 3,
|
||||
options: [
|
||||
{ key: "ORGANIZATION", showname: getLabel(30042, "人员") }
|
||||
]
|
||||
};
|
||||
}
|
||||
if (child.conditionType === "SELECT" && child.domkey[0] !== "gender" && child.domkey[0] !== "employmentStatus" && child.domkey[0] !== "employmentType") {
|
||||
return {
|
||||
...child,
|
||||
options: [
|
||||
{ key: "ON", showname: getLabel(538048, "是") },
|
||||
{ key: "OFF", showname: getLabel(111, "否") }
|
||||
]
|
||||
};
|
||||
}
|
||||
return { ...child };
|
||||
})
|
||||
};
|
||||
}),
|
||||
employeeInfo: data.data
|
||||
}, () => {
|
||||
const { data: result, columns } = data;
|
||||
const { employeeDeclareStore: { declareForm } } = this.props;
|
||||
declareForm.initFormFields(this.state.eConditions);
|
||||
const filedKes = _.map(columns, it => it.dataIndex);
|
||||
_.map(filedKes, item => {
|
||||
if (item === "disability" || item === "lonelyOld" || item === "martyrDependents") {
|
||||
declareForm.updateFields({ [item]: result[item] || "OFF" });
|
||||
} else if (item === "deductExpenses") {
|
||||
declareForm.updateFields({ [item]: result[item] || "ON" });
|
||||
} else if (item === "gender") {
|
||||
declareForm.updateFields({ [item]: result[item] || "MALE" });
|
||||
} else if (item === "employmentStatus") {
|
||||
declareForm.updateFields({ [item]: result[item] || _.take(props.employmentStatusList)[0].enum });
|
||||
} else if (item === "employmentType") {
|
||||
declareForm.updateFields({ [item]: result[item] || _.take(props.employmentTypeList)[0].enum });
|
||||
} else if (item === "cardType") {
|
||||
declareForm.updateFields({ [item]: "居民身份证" });
|
||||
} else if (item === "employee") {
|
||||
const [employeeData] = result[item] || [];
|
||||
!_.isEmpty(employeeData) && declareForm.updateFields({
|
||||
employeeType: {
|
||||
value: [employeeData._entityType, [employeeData.id, employeeData.name, [{
|
||||
id: employeeData.id,
|
||||
lastname: employeeData.name
|
||||
}]]],
|
||||
valueSpan: ["employeeId"]
|
||||
}
|
||||
});
|
||||
} else {
|
||||
declareForm.updateFields({ [item]: result[item] || "" });
|
||||
}
|
||||
});
|
||||
});
|
||||
}
|
||||
});
|
||||
};
|
||||
onChange = (res) => {
|
||||
const { eConditions } = this.state;
|
||||
const { employeeDeclareStore: { declareForm } } = this.props;
|
||||
const key = Object.keys(res)[0];
|
||||
const value = res[key].value;
|
||||
if (key === "employeeType") {
|
||||
const [v1, v2] = value;
|
||||
this.employeeChangeInfo = {
|
||||
employee: [{ _entityType: v1, name: v2[1], id: v2[0] }]
|
||||
};
|
||||
}
|
||||
switch (key) {
|
||||
case "employmentStatus":
|
||||
this.setState({
|
||||
eConditions: _.map(eConditions, it => {
|
||||
return {
|
||||
...it,
|
||||
items: _.map(it.items, child => {
|
||||
if (child.domkey[0] === "dismissDate") {
|
||||
return {
|
||||
...child,
|
||||
viewAttr: value === "ABNORMAL" ? 3 : 2
|
||||
};
|
||||
}
|
||||
return { ...child };
|
||||
})
|
||||
};
|
||||
})
|
||||
}, () => {
|
||||
declareForm.initFormFields(this.state.eConditions);
|
||||
const [employeeData] = this.state.employeeInfo["employee"] || this.employeeChangeInfo["employee"] || [];
|
||||
!_.isEmpty(employeeData) && declareForm.updateFields({
|
||||
employeeType: {
|
||||
value: [employeeData._entityType, [employeeData.id, employeeData.name, [{
|
||||
id: employeeData.id,
|
||||
lastname: employeeData.name
|
||||
}]]],
|
||||
valueSpan: ["employeeId"]
|
||||
}
|
||||
});
|
||||
});
|
||||
break;
|
||||
case "employmentType":
|
||||
this.setState({
|
||||
eConditions: _.map(eConditions, it => {
|
||||
return {
|
||||
...it,
|
||||
items: _.map(it.items, child => {
|
||||
if (child.domkey[0] === "employmentDate") {
|
||||
return {
|
||||
...child,
|
||||
viewAttr: value !== "OTHER" ? 3 : 2
|
||||
};
|
||||
}
|
||||
return { ...child };
|
||||
})
|
||||
};
|
||||
})
|
||||
}, () => {
|
||||
declareForm.initFormFields(this.state.eConditions);
|
||||
const [employeeData] = this.state.employeeInfo["employee"] || this.employeeChangeInfo["employee"] || [];
|
||||
!_.isEmpty(employeeData) && declareForm.updateFields({
|
||||
employeeType: {
|
||||
value: [employeeData._entityType, [employeeData.id, employeeData.name, [{
|
||||
id: employeeData.id,
|
||||
lastname: employeeData.name
|
||||
}]]],
|
||||
valueSpan: ["employeeId"]
|
||||
}
|
||||
});
|
||||
});
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
};
|
||||
|
||||
handleSubmit = () => {
|
||||
const { employeeDeclareStore: { declareForm: form } } = this.props;
|
||||
form.validateForm().then(f => {
|
||||
if (f.isValid) {
|
||||
const { employmentType, employmentDate, employmentStatus, dismissDate, ...params } = form.getFormParams();
|
||||
if ((employmentType !== "OTHER" && !employmentDate) || (employmentStatus === "ABNORMAL" && !dismissDate)) {
|
||||
Modal.warning({
|
||||
title: getLabel(131329, "信息确认"),
|
||||
content: getLabel(518702, "必要信息不完整,红色*为必填项!")
|
||||
});
|
||||
return;
|
||||
}
|
||||
const payload = {
|
||||
...form.getFormParams(), id: this.props.id,
|
||||
cardType: "RESIDENT_IDENTITY_CARDS", //暂时写死身份证类型
|
||||
taxAgentId: getQueryString("id"),
|
||||
taxCycle: this.props.taxCycle
|
||||
};
|
||||
this.setState({ loading: true });
|
||||
getEmployeeSave(payload).then(({ status, errormsg }) => {
|
||||
this.setState({ loading: false });
|
||||
if (status) {
|
||||
message.success(getLabel(22619, "保存成功!"));
|
||||
this.props.onClose("true");
|
||||
} else {
|
||||
message.error(errormsg || getLabel(22620, "保存失败!"));
|
||||
}
|
||||
}).catch(() => this.setState({ loading: false }));
|
||||
} else {
|
||||
f.showErrors();
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
render() {
|
||||
const { eConditions, loading } = this.state;
|
||||
const { employeeDeclareStore: { declareForm: form }, title = "" } = this.props;
|
||||
return (
|
||||
<WeaSlideModal
|
||||
{...this.props}
|
||||
top={0} measureT="%"
|
||||
width={800} measureX="px"
|
||||
height={100} measureY="%"
|
||||
direction="right"
|
||||
title={(<Row className="declareSchemeDialogTitle" type="flex">
|
||||
<Col span={12} className="declareSchemeDialogTitle-left">
|
||||
<div className="icon-circle-base"><i className="icon-coms-fa"/></div>
|
||||
<span className="title">{title || getLabel(111, "本月新增数据")}</span>
|
||||
</Col>
|
||||
<Col span={12} className="declareSchemeDialogTitle-right">
|
||||
<Button type="primary" onClick={this.handleSubmit} loading={loading}>{getLabel(537558, "保存")}</Button>
|
||||
</Col>
|
||||
</Row>)}
|
||||
content={(<div className="declareSchemeDialog">{getSearchs(form, eConditions, 1, false, this.onChange)}</div>)}
|
||||
/>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
export default EmployeeDeclareDetailSchemaEditDialog;
|
||||
|
|
@ -0,0 +1,434 @@
|
|||
export const submitStatus = [
|
||||
{
|
||||
key: "ALL",
|
||||
showname: "全部(报送状态)",
|
||||
lanId: 111
|
||||
}
|
||||
];
|
||||
|
||||
|
||||
export const advanceConditions = [
|
||||
{
|
||||
items: [
|
||||
{
|
||||
colSpan: 1,
|
||||
conditionType: "INPUT",
|
||||
domkey: ["keyword"],
|
||||
fieldcol: 18,
|
||||
label: "姓名或工号",
|
||||
lanId: 111,
|
||||
labelcol: 6,
|
||||
value: ""
|
||||
},
|
||||
{
|
||||
browserConditionParam: {
|
||||
completeParams: {},
|
||||
conditionDataParams: {},
|
||||
dataParams: {},
|
||||
destDataParams: {},
|
||||
hasAddBtn: false,
|
||||
hasAdvanceSerach: true,
|
||||
idSeparator: ",",
|
||||
isAutoComplete: 1,
|
||||
isDetail: 0,
|
||||
isMultCheckbox: false,
|
||||
isSingle: false,
|
||||
linkUrl: "",
|
||||
pageSize: 10,
|
||||
quickSearchName: "",
|
||||
replaceDatas: [],
|
||||
title: "",
|
||||
type: "57"
|
||||
},
|
||||
colSpan: 1,
|
||||
conditionType: "BROWSER",
|
||||
domkey: ["departmentIds"],
|
||||
fieldcol: 18,
|
||||
label: "部门",
|
||||
lanId: 27511,
|
||||
labelcol: 6
|
||||
},
|
||||
{
|
||||
browserConditionParam: {
|
||||
completeParams: {},
|
||||
conditionDataParams: {},
|
||||
dataParams: {},
|
||||
destDataParams: {},
|
||||
hasAddBtn: false,
|
||||
hasAdvanceSerach: true,
|
||||
idSeparator: ",",
|
||||
isAutoComplete: 1,
|
||||
isDetail: 0,
|
||||
isMultCheckbox: false,
|
||||
isSingle: false,
|
||||
linkUrl: "",
|
||||
pageSize: 10,
|
||||
quickSearchName: "",
|
||||
replaceDatas: [],
|
||||
title: "",
|
||||
type: "278"
|
||||
},
|
||||
colSpan: 1,
|
||||
conditionType: "BROWSER",
|
||||
domkey: ["positionIds"],
|
||||
fieldcol: 18,
|
||||
label: "岗位",
|
||||
lanId: 6086,
|
||||
labelcol: 6
|
||||
},
|
||||
{
|
||||
colSpan: 1,
|
||||
conditionType: "SELECT",
|
||||
domkey: ["employmentStatus"],
|
||||
fieldcol: 18,
|
||||
label: "人员状态",
|
||||
lanId: 382300,
|
||||
labelcol: 6,
|
||||
value: "",
|
||||
options: []
|
||||
},
|
||||
{
|
||||
colSpan: 1,
|
||||
conditionType: "SELECT",
|
||||
domkey: ["employmentType"],
|
||||
fieldcol: 18,
|
||||
label: "任职受雇从业类型",
|
||||
lanId: 111,
|
||||
labelcol: 6,
|
||||
value: "",
|
||||
options: []
|
||||
},
|
||||
{
|
||||
colSpan: 1,
|
||||
conditionType: "RANGEPICKER",
|
||||
domkey: ["fromEmploymentDate", "endEmploymentDate"],
|
||||
fieldcol: 18,
|
||||
label: "任职受雇日期",
|
||||
lanId: 111,
|
||||
labelcol: 6,
|
||||
value: ""
|
||||
},
|
||||
{
|
||||
colSpan: 1,
|
||||
conditionType: "RANGEPICKER",
|
||||
domkey: ["fromDismissDate", "endDismissDate"],
|
||||
fieldcol: 18,
|
||||
label: "离职日期",
|
||||
lanId: 111,
|
||||
labelcol: 6,
|
||||
value: ""
|
||||
},
|
||||
{
|
||||
colSpan: 1,
|
||||
conditionType: "SELECT",
|
||||
domkey: ["disability"],
|
||||
fieldcol: 18,
|
||||
label: "是否残疾",
|
||||
lanId: 111,
|
||||
labelcol: 6,
|
||||
value: "",
|
||||
options: []
|
||||
},
|
||||
{
|
||||
colSpan: 1,
|
||||
conditionType: "SELECT",
|
||||
domkey: ["lonelyOld"],
|
||||
fieldcol: 18,
|
||||
label: "是否孤老",
|
||||
lanId: 111,
|
||||
labelcol: 6,
|
||||
value: "",
|
||||
options: []
|
||||
},
|
||||
{
|
||||
colSpan: 1,
|
||||
conditionType: "SELECT",
|
||||
domkey: ["martyrDependents"],
|
||||
fieldcol: 18,
|
||||
label: "是否是烈属",
|
||||
lanId: 111,
|
||||
labelcol: 6,
|
||||
value: "",
|
||||
options: []
|
||||
},
|
||||
{
|
||||
colSpan: 1,
|
||||
conditionType: "SELECT",
|
||||
domkey: ["deductExpenses"],
|
||||
fieldcol: 18,
|
||||
label: "是否扣除减除费用",
|
||||
lanId: 111,
|
||||
labelcol: 6,
|
||||
value: "",
|
||||
options: []
|
||||
}
|
||||
],
|
||||
defaultshow: true
|
||||
}
|
||||
];
|
||||
|
||||
export const declareConditions = [
|
||||
{
|
||||
items: [
|
||||
{
|
||||
colSpan: 1,
|
||||
fieldcol: 12,
|
||||
labelcol: 6,
|
||||
rules: "selectLinkageRequired",
|
||||
conditionType: "SELECT_LINKAGE",
|
||||
selectLinkageDatas: {
|
||||
"ORGANIZATION": {
|
||||
browserConditionParam: {
|
||||
completeParams: {},
|
||||
conditionDataParams: {},
|
||||
dataParams: {},
|
||||
destDataParams: {},
|
||||
hasAddBtn: false,
|
||||
hasAdvanceSerach: true,
|
||||
idSeparator: ",",
|
||||
isAutoComplete: 1,
|
||||
isDetail: 0,
|
||||
isMultCheckbox: false,
|
||||
isSingle: true,
|
||||
linkUrl: "",
|
||||
pageSize: 10,
|
||||
quickSearchName: "",
|
||||
replaceDatas: [],
|
||||
title: "",
|
||||
type: "1"
|
||||
},
|
||||
conditionType: "BROWSER",
|
||||
domkey: ["employeeId"]
|
||||
},
|
||||
"EXT_EMPLOYEE": {
|
||||
conditionType: "BROWSER",
|
||||
domkey: ["INPUT2"]
|
||||
}
|
||||
},
|
||||
options: [],
|
||||
domkey: ["employeeType"],
|
||||
label: "系统名称",
|
||||
lanId: 111,
|
||||
viewAttr: 3
|
||||
},
|
||||
{
|
||||
colSpan: 1,
|
||||
conditionType: "INPUT",
|
||||
domkey: ["employeeName"],
|
||||
fieldcol: 12,
|
||||
label: "证件姓名",
|
||||
lanId: 111,
|
||||
labelcol: 6,
|
||||
value: "",
|
||||
rules: "required",
|
||||
viewAttr: 3
|
||||
},
|
||||
{
|
||||
colSpan: 1,
|
||||
conditionType: "INPUT",
|
||||
domkey: ["jobNum"],
|
||||
fieldcol: 12,
|
||||
label: "工号",
|
||||
lanId: 1933,
|
||||
labelcol: 6,
|
||||
value: "",
|
||||
viewAttr: 2
|
||||
},
|
||||
{
|
||||
colSpan: 1,
|
||||
conditionType: "INPUT",
|
||||
domkey: ["nationality"],
|
||||
fieldcol: 12,
|
||||
label: "国籍",
|
||||
lanId: 111,
|
||||
labelcol: 6,
|
||||
value: "",
|
||||
viewAttr: 1
|
||||
},
|
||||
{
|
||||
colSpan: 1,
|
||||
conditionType: "INPUT",
|
||||
domkey: ["cardType"],
|
||||
fieldcol: 12,
|
||||
label: "证件类型",
|
||||
lanId: 111,
|
||||
labelcol: 6,
|
||||
value: "居民身份证",
|
||||
viewAttr: 1
|
||||
},
|
||||
{
|
||||
colSpan: 1,
|
||||
conditionType: "INPUT",
|
||||
domkey: ["cardNum"],
|
||||
fieldcol: 12,
|
||||
label: "证件号码",
|
||||
lanId: 1839,
|
||||
labelcol: 6,
|
||||
value: "",
|
||||
rules: "required",
|
||||
viewAttr: 3
|
||||
},
|
||||
{
|
||||
colSpan: 1,
|
||||
conditionType: "SELECT",
|
||||
domkey: ["gender"],
|
||||
fieldcol: 12,
|
||||
label: "性别",
|
||||
lanId: 111,
|
||||
labelcol: 6,
|
||||
value: "",
|
||||
viewAttr: 3,
|
||||
rules: "required",
|
||||
options: []
|
||||
},
|
||||
{
|
||||
colSpan: 1,
|
||||
conditionType: "DATEPICKER",
|
||||
domkey: ["birthday"],
|
||||
fieldcol: 12,
|
||||
label: "出生日期",
|
||||
lanId: 111,
|
||||
labelcol: 6,
|
||||
rules: "required",
|
||||
value: "",
|
||||
viewAttr: 3
|
||||
},
|
||||
{
|
||||
colSpan: 1,
|
||||
conditionType: "SELECT",
|
||||
domkey: ["employmentStatus"],
|
||||
fieldcol: 12,
|
||||
label: "状态",
|
||||
lanId: 535101,
|
||||
labelcol: 6,
|
||||
value: "",
|
||||
viewAttr: 3,
|
||||
rules: "required",
|
||||
detailtype: 3,
|
||||
options: []
|
||||
},
|
||||
{
|
||||
colSpan: 1,
|
||||
conditionType: "INPUT",
|
||||
domkey: ["mobile"],
|
||||
fieldcol: 12,
|
||||
label: "手机号码",
|
||||
lanId: 111,
|
||||
labelcol: 6,
|
||||
value: "",
|
||||
rules: "required",
|
||||
viewAttr: 3
|
||||
},
|
||||
{
|
||||
colSpan: 1,
|
||||
conditionType: "SELECT",
|
||||
domkey: ["employmentType"],
|
||||
fieldcol: 12,
|
||||
label: "任职受雇从业类型",
|
||||
lanId: 111,
|
||||
labelcol: 6,
|
||||
value: "",
|
||||
viewAttr: 3,
|
||||
rules: "required",
|
||||
options: []
|
||||
},
|
||||
{
|
||||
colSpan: 1,
|
||||
conditionType: "DATEPICKER",
|
||||
domkey: ["employmentDate"],
|
||||
fieldcol: 12,
|
||||
label: "任职受雇从业日期",
|
||||
lanId: 111,
|
||||
labelcol: 6,
|
||||
value: "",
|
||||
viewAttr: 3
|
||||
},
|
||||
{
|
||||
colSpan: 1,
|
||||
conditionType: "DATEPICKER",
|
||||
domkey: ["dismissDate"],
|
||||
fieldcol: 12,
|
||||
label: "离职日期",
|
||||
lanId: 111,
|
||||
labelcol: 6,
|
||||
value: "",
|
||||
viewAttr: 2
|
||||
},
|
||||
{
|
||||
colSpan: 1,
|
||||
conditionType: "SELECT",
|
||||
domkey: ["disability"],
|
||||
fieldcol: 12,
|
||||
label: "是否残疾",
|
||||
lanId: 111,
|
||||
labelcol: 6,
|
||||
value: "",
|
||||
viewAttr: 2,
|
||||
detailtype: 3,
|
||||
options: []
|
||||
},
|
||||
{
|
||||
colSpan: 1,
|
||||
conditionType: "INPUT",
|
||||
domkey: ["disabilityCardNo"],
|
||||
fieldcol: 12,
|
||||
label: "残疾证号",
|
||||
lanId: 111,
|
||||
labelcol: 6,
|
||||
value: "",
|
||||
viewAttr: 2
|
||||
},
|
||||
{
|
||||
colSpan: 1,
|
||||
conditionType: "SELECT",
|
||||
domkey: ["lonelyOld"],
|
||||
fieldcol: 12,
|
||||
label: "是否孤老",
|
||||
lanId: 111,
|
||||
labelcol: 6,
|
||||
value: "",
|
||||
viewAttr: 2,
|
||||
detailtype: 3,
|
||||
options: []
|
||||
},
|
||||
{
|
||||
colSpan: 1,
|
||||
conditionType: "SELECT",
|
||||
domkey: ["martyrDependents"],
|
||||
fieldcol: 12,
|
||||
label: "是否是烈属",
|
||||
lanId: 111,
|
||||
labelcol: 6,
|
||||
value: "",
|
||||
viewAttr: 2,
|
||||
detailtype: 3,
|
||||
options: []
|
||||
},
|
||||
{
|
||||
colSpan: 1,
|
||||
conditionType: "INPUT",
|
||||
domkey: ["martyrDependentsCardNo"],
|
||||
fieldcol: 12,
|
||||
label: "烈属证号",
|
||||
lanId: 111,
|
||||
labelcol: 6,
|
||||
value: "",
|
||||
viewAttr: 2
|
||||
},
|
||||
{
|
||||
colSpan: 1,
|
||||
conditionType: "SELECT",
|
||||
domkey: ["deductExpenses"],
|
||||
fieldcol: 12,
|
||||
label: "是否扣除减除费用",
|
||||
lanId: 111,
|
||||
labelcol: 6,
|
||||
value: "",
|
||||
viewAttr: 2,
|
||||
detailtype: 3,
|
||||
options: []
|
||||
}
|
||||
],
|
||||
defaultshow: true
|
||||
}
|
||||
];
|
||||
|
|
@ -0,0 +1,528 @@
|
|||
/*
|
||||
* Author: 黎永顺
|
||||
* name: 人员信息报送-查看详情
|
||||
* Description:
|
||||
* Date: 2023/8/11
|
||||
*/
|
||||
import React, { Component } from "react";
|
||||
import { WeaDatePicker, WeaLocaleProvider, WeaSelect, WeaTab, WeaTop } from "ecCom";
|
||||
import { Button, Dropdown, Menu, message, Modal, Spin } from "antd";
|
||||
import BaseInfo from "./components/baseInfo";
|
||||
import EmployeeDeclareDetailSchemaEditDialog from "./components/employeeDeclareDetailSchemaEditDialog";
|
||||
import { commonEnumList } from "../../apis/payrollFiles";
|
||||
import {
|
||||
employeedeclareDeclare,
|
||||
employeedeclareGetRate,
|
||||
employeedeclareList,
|
||||
employeedeclareList4Add,
|
||||
employeedeclareList4Update,
|
||||
employeedeclareRefresh,
|
||||
employeeDelete,
|
||||
getDeclareFeedback
|
||||
} from "../../apis/declare";
|
||||
import { advanceConditions, submitStatus } from "./constants";
|
||||
import moment from "moment";
|
||||
import { getSearchs } from "../../util";
|
||||
import { inject, observer } from "mobx-react";
|
||||
import { toJS } from "mobx";
|
||||
import { getQueryString } from "../../util/url";
|
||||
import "./index.less";
|
||||
|
||||
const { getLabel } = WeaLocaleProvider;
|
||||
const API = {
|
||||
list: employeedeclareList,
|
||||
list4Add: employeedeclareList4Add,
|
||||
list4Update: employeedeclareList4Update
|
||||
};
|
||||
|
||||
@inject("taxAgentStore", "employeeDeclareStore")
|
||||
@observer
|
||||
class Index extends Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
selectedKey: "list", showSearchAd: false, declareStatus: "ALL",
|
||||
taxCycle: new Date(), loading: { query: false, refresh: false, feedback: false, declare: false },
|
||||
pageInfo: { current: 1, pageSize: 10, total: 0 },
|
||||
declareEditDialog: { visible: false, id: "", title: "" },
|
||||
declareStatusList: [], employmentStatusList: [],
|
||||
employmentTypeList: [], adConditons: [],
|
||||
selectedRowKeys: []
|
||||
};
|
||||
this.baseInfoRef = null;
|
||||
this.timer = null;
|
||||
}
|
||||
|
||||
componentDidMount() {
|
||||
document.title = getLabel(544289, "人员信息报送");
|
||||
window.addEventListener("message", this.handleReceive, false);
|
||||
this.initEmployeeDeclare().then(r => {
|
||||
});
|
||||
}
|
||||
|
||||
initEmployeeDeclare = async () => {
|
||||
const { employeeDeclareStore: { advanceForm } } = this.props;
|
||||
const [declareStatusList, employmentStatusList, employmentTypeList] = await Promise.all([this.commonEnumList("DeclareStatusEnum"), this.commonEnumList("EmploymentStatusEnum"), this.commonEnumList("EmploymentTypeEnum")]);
|
||||
if (declareStatusList.status && employmentStatusList.status && employmentTypeList.status) {
|
||||
this.setState({
|
||||
declareStatusList: declareStatusList.data,
|
||||
employmentStatusList: employmentStatusList.data,
|
||||
employmentTypeList: employmentTypeList.data,
|
||||
adConditons: _.map(advanceConditions, it => {
|
||||
return {
|
||||
...it,
|
||||
items: _.map(it.items, child => {
|
||||
if (child.domkey[0] === "employmentStatus") {
|
||||
return {
|
||||
...child,
|
||||
options: _.map(employmentStatusList.data, it => ({
|
||||
key: it.enum,
|
||||
showname: getLabel(it.labelId, it.defaultLabel)
|
||||
}))
|
||||
};
|
||||
} else if (child.domkey[0] === "employmentType") {
|
||||
return {
|
||||
...child,
|
||||
options: _.map(employmentTypeList.data, it => ({
|
||||
key: it.enum,
|
||||
showname: getLabel(it.labelId, it.defaultLabel)
|
||||
}))
|
||||
};
|
||||
}
|
||||
if (child.conditionType === "SELECT" && child.domkey[0] !== "employmentStatus" && child.domkey[0] !== "employmentType") {
|
||||
return {
|
||||
...child,
|
||||
options: [
|
||||
{ key: "ON", showname: getLabel(538048, "是") },
|
||||
{ key: "OFF", showname: getLabel(111, "否") }
|
||||
]
|
||||
};
|
||||
}
|
||||
return { ...child };
|
||||
})
|
||||
};
|
||||
})
|
||||
}, () => {
|
||||
advanceForm.initFormFields(this.state.adConditons);
|
||||
});
|
||||
}
|
||||
};
|
||||
|
||||
componentWillUnmount() {
|
||||
window.removeEventListener("message", this.handleReceive, false);
|
||||
}
|
||||
|
||||
handleReceive = ({ data }) => {
|
||||
const { type, payload: { id, params } = {} } = data;
|
||||
if (type === "init") {
|
||||
this.queryEmployeeList();
|
||||
} else if (type === "turn") {
|
||||
if (id === "PAGEINFO") {
|
||||
const { pageNum: current, size: pageSize } = params;
|
||||
this.setState({ pageInfo: { ...this.state.pageInfo, current, pageSize } });
|
||||
} else if (id === "EDIT") {
|
||||
this.setState({
|
||||
declareEditDialog: {
|
||||
...this.state.declareEditDialog,
|
||||
visible: true, id: params.id, title: params.employeeName
|
||||
}
|
||||
});
|
||||
} else if (id === "DELETE") {
|
||||
this.handleDeleteDeclare([params.id]);
|
||||
} else if (id === "ROWSELECT") {
|
||||
const { selectedRowKeys } = params;
|
||||
this.setState({ selectedRowKeys });
|
||||
}
|
||||
}
|
||||
};
|
||||
postMessageToChild = (payload = {}) => {
|
||||
const i18n = {
|
||||
"总计": getLabel(523, "总计"), "编辑": getLabel(501169, "编辑"),
|
||||
"操作": getLabel(30585, "操作"), "删除": getLabel(535052, "删除"),
|
||||
"共": getLabel(83698, "共"), "条": getLabel(18256, "条"),
|
||||
"加载中": getLabel(83698, "加载中")
|
||||
};
|
||||
const childFrameObj = document.getElementById("atdTable");
|
||||
childFrameObj && childFrameObj.contentWindow.postMessage(JSON.stringify({ ...payload, i18n }), "*");
|
||||
};
|
||||
commonEnumList = (key) => {
|
||||
const payload = { enumClass: `com.engine.salary.enums.employeedeclare.${key}` };
|
||||
return commonEnumList(payload);
|
||||
};
|
||||
/*
|
||||
* Author: 黎永顺
|
||||
* Description: 报送列表查询
|
||||
* Params:
|
||||
* Date: 2023/8/14
|
||||
*/
|
||||
queryEmployeeList = () => {
|
||||
const { employeeDeclareStore: { advanceForm: form } } = this.props;
|
||||
const { pageInfo, declareStatus, taxCycle, selectedKey, selectedRowKeys } = this.state;
|
||||
const { departmentIds, positionIds, ...formParams } = form.getFormParams();
|
||||
const payload = {
|
||||
...formParams, ...pageInfo,
|
||||
declareStatus,
|
||||
taxAgentId: getQueryString("id"),
|
||||
taxCycle: moment(taxCycle).startOf("month").format("YYYY-MM-DD"),
|
||||
departmentIds: departmentIds ? departmentIds.split(",") : [],
|
||||
positionIds: positionIds ? positionIds.split(",") : []
|
||||
};
|
||||
this.setState({ loading: { ...this.state.loading, query: true } });
|
||||
API[selectedKey](payload).then(({ status, data }) => {
|
||||
this.setState({ loading: { ...this.state.loading, query: false } });
|
||||
if (status) {
|
||||
const { pageInfo: result } = data;
|
||||
const { columns, list: dataSource, pageNum: current, pageSize, total } = result;
|
||||
this.baseInfoRef.getEmployeeDeclareInfo();
|
||||
this.setState({
|
||||
pageInfo: { ...pageInfo, current, pageSize, total }
|
||||
}, () => {
|
||||
const payload = {
|
||||
dataSource, selectedRowKeys, selectedKey,
|
||||
pageInfo: this.state.pageInfo,
|
||||
columns: _.map(columns, it => {
|
||||
if (it.dataIndex === "employeeName" || it.dataIndex === "subCompanyName") {
|
||||
return { ...it, width: 150, fixed: "left" };
|
||||
}
|
||||
if (it.dataIndex === "declareStatusDesc") {
|
||||
return { ...it, width: 150, fixed: "right" };
|
||||
}
|
||||
return { ...it, width: 150 };
|
||||
})
|
||||
};
|
||||
this.postMessageToChild(payload);
|
||||
});
|
||||
}
|
||||
}).then(() => this.setState({ loading: { ...this.state.loading, query: false } }));
|
||||
};
|
||||
/*
|
||||
* Author: 黎永顺
|
||||
* Description: 刷新数据
|
||||
* Params:
|
||||
* Date: 2023/8/14
|
||||
*/
|
||||
employeedeclareRefresh = () => {
|
||||
const payload = {
|
||||
taxAgentId: getQueryString("id"),
|
||||
taxCycle: moment(this.state.taxCycle).startOf("month").format("YYYY-MM-DD")
|
||||
};
|
||||
this.setState({ loading: { ...this.state.loading, refresh: true } });
|
||||
employeedeclareRefresh(payload).then(async ({ status, data, errormsg }) => {
|
||||
if (status) {
|
||||
message.destroy();
|
||||
message.loading(getLabel(111, "刷新中..."), 0);
|
||||
this.timer = setInterval(async () => {
|
||||
const { status: resStatus, data: result } = await employeedeclareGetRate({ index: data });
|
||||
const { status: rateStatus, finish, msg } = result;
|
||||
if (resStatus && rateStatus) {
|
||||
if (finish) {
|
||||
this.setState({ loading: { ...this.state.loading, refresh: false } });
|
||||
clearInterval(this.timer);
|
||||
message.destroy();
|
||||
message.success(getLabel(111, "刷新成功!"));
|
||||
this.queryEmployeeList();
|
||||
}
|
||||
} else {
|
||||
this.setState({ loading: { ...this.state.loading, refresh: false } });
|
||||
clearInterval(this.timer);
|
||||
message.destroy();
|
||||
message.warning(msg || getLabel(111, "刷新失败!"));
|
||||
this.queryEmployeeList();
|
||||
}
|
||||
}, 1000);
|
||||
} else {
|
||||
this.setState({ loading: { ...this.state.loading, refresh: false } });
|
||||
clearInterval(this.timer);
|
||||
message.destroy();
|
||||
message.error(errormsg);
|
||||
}
|
||||
}).catch(() => {
|
||||
clearInterval(this.timer);
|
||||
message.destroy();
|
||||
this.setState({ loading: { ...this.state.loading, refresh: false } });
|
||||
});
|
||||
};
|
||||
/*
|
||||
* Author: 黎永顺
|
||||
* Description:获取报送结果反馈
|
||||
* Params:
|
||||
* Date: 2023/8/15
|
||||
*/
|
||||
getDeclareFeedback = () => {
|
||||
const payload = {
|
||||
taxAgentId: getQueryString("id"),
|
||||
taxCycle: moment(this.state.taxCycle).startOf("month").format("YYYY-MM-DD")
|
||||
};
|
||||
this.setState({ loading: { ...this.state.loading, feedback: true } });
|
||||
getDeclareFeedback(payload).then(async ({ status, data, errormsg }) => {
|
||||
if (status) {
|
||||
message.destroy();
|
||||
message.loading(getLabel(111, "获取报送中..."), 0);
|
||||
this.timer = setInterval(async () => {
|
||||
const { status: resStatus, data: result } = await employeedeclareGetRate({ index: data });
|
||||
const { status: rateStatus, finish, msg } = result;
|
||||
if (resStatus && rateStatus) {
|
||||
if (finish) {
|
||||
this.setState({ loading: { ...this.state.loading, feedback: false } });
|
||||
clearInterval(this.timer);
|
||||
message.destroy();
|
||||
message.success(getLabel(111, "获取报送结果成功!"));
|
||||
this.queryEmployeeList();
|
||||
}
|
||||
} else {
|
||||
this.setState({ loading: { ...this.state.loading, feedback: false } });
|
||||
clearInterval(this.timer);
|
||||
message.destroy();
|
||||
message.warning(msg || getLabel(111, "获取失败!"));
|
||||
this.queryEmployeeList();
|
||||
}
|
||||
}, 1000);
|
||||
} else {
|
||||
this.setState({ loading: { ...this.state.loading, feedback: false } });
|
||||
clearInterval(this.timer);
|
||||
message.destroy();
|
||||
message.error(errormsg);
|
||||
}
|
||||
}).catch(() => {
|
||||
clearInterval(this.timer);
|
||||
message.destroy();
|
||||
this.setState({ loading: { ...this.state.loading, feedback: false } });
|
||||
});
|
||||
};
|
||||
/*
|
||||
* Author: 黎永顺
|
||||
* Description: 删除个税申报人员信息
|
||||
* Params:
|
||||
* Date: 2023/8/15
|
||||
*/
|
||||
handleDeleteDeclare = (paylaod) => {
|
||||
const { selectedRowKeys } = this.state;
|
||||
Modal.confirm({
|
||||
title: getLabel(131329, "信息确认"),
|
||||
content: getLabel(543548, "确认删除吗?"),
|
||||
onOk: () => {
|
||||
employeeDelete(paylaod).then(({ status, errormsg }) => {
|
||||
if (status) {
|
||||
message.success(getLabel(502230, "删除成功!"));
|
||||
this.setState({
|
||||
selectedRowKeys: _.xorWith(selectedRowKeys, paylaod, _.isEqual)
|
||||
});
|
||||
this.queryEmployeeList();
|
||||
} else {
|
||||
message.error(errormsg || getLabel(20462, "删除失败!"));
|
||||
}
|
||||
});
|
||||
}
|
||||
});
|
||||
};
|
||||
/*
|
||||
* Author: 黎永顺
|
||||
* Description: 全部报送
|
||||
* Params:
|
||||
* Date: 2023/8/15
|
||||
*/
|
||||
employeedeclareDeclare = () => {
|
||||
const payload = {
|
||||
taxAgentId: getQueryString("id"),
|
||||
taxCycle: moment(this.state.taxCycle).startOf("month").format("YYYY-MM-DD")
|
||||
};
|
||||
this.setState({ loading: { ...this.state.loading, declare: true } });
|
||||
employeedeclareDeclare(payload).then(async ({ status, data, errormsg }) => {
|
||||
if (status) {
|
||||
message.destroy();
|
||||
message.loading(getLabel(111, "报送中..."), 0);
|
||||
this.timer = setInterval(async () => {
|
||||
const { status: resStatus, data: result } = await employeedeclareGetRate({ index: data });
|
||||
const { status: rateStatus, finish, msg } = result;
|
||||
if (resStatus && rateStatus) {
|
||||
if (finish) {
|
||||
this.setState({ loading: { ...this.state.loading, declare: false } });
|
||||
clearInterval(this.timer);
|
||||
message.destroy();
|
||||
message.success(getLabel(111, "全部报送成功!"));
|
||||
this.queryEmployeeList();
|
||||
}
|
||||
} else {
|
||||
this.setState({ loading: { ...this.state.loading, declare: false } });
|
||||
clearInterval(this.timer);
|
||||
message.destroy();
|
||||
message.warning(msg || getLabel(111, "报送失败!"));
|
||||
this.queryEmployeeList();
|
||||
}
|
||||
}, 1000);
|
||||
} else {
|
||||
this.setState({ loading: { ...this.state.loading, declare: false } });
|
||||
clearInterval(this.timer);
|
||||
message.destroy();
|
||||
message.error(errormsg);
|
||||
}
|
||||
}).catch(() => {
|
||||
clearInterval(this.timer);
|
||||
message.destroy();
|
||||
this.setState({ loading: { ...this.state.loading, declare: false } });
|
||||
});
|
||||
};
|
||||
handleAdd = () => {
|
||||
this.setState({
|
||||
declareEditDialog: {
|
||||
...this.state.declareEditDialog,
|
||||
visible: true
|
||||
}
|
||||
});
|
||||
};
|
||||
handleMenuClick = ({ key }) => {
|
||||
const { selectedRowKeys } = this.state;
|
||||
switch (key) {
|
||||
case "1":
|
||||
if (_.isEmpty(selectedRowKeys)) {
|
||||
message.warning(getLabel(111, "请先选择需要删除的人员!"));
|
||||
return;
|
||||
}
|
||||
this.handleDeleteDeclare(selectedRowKeys);
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
};
|
||||
|
||||
render() {
|
||||
const {
|
||||
selectedKey, showSearchAd, declareStatus, declareStatusList, taxCycle, declareEditDialog, loading,
|
||||
pageInfo, adConditons, employmentTypeList, employmentStatusList
|
||||
} = this.state;
|
||||
const { taxAgentStore: { showOperateBtn }, employeeDeclareStore: { advanceForm: form, declareForm } } = this.props;
|
||||
const menu = (
|
||||
<Menu onClick={this.handleMenuClick}>
|
||||
<Menu.Item key="1">{getLabel(32136, "批量删除")}</Menu.Item>
|
||||
{/*<Menu.Item key="2">{getLabel(111, "批量编辑")}</Menu.Item>*/}
|
||||
{/*<Menu.Item key="3">{getLabel(81272, "导出全部")}</Menu.Item>*/}
|
||||
{/*<Menu.Item key="4">{getLabel(543715, "导出所选")}</Menu.Item>*/}
|
||||
</Menu>
|
||||
);
|
||||
const buttons = [
|
||||
<WeaDatePicker arrow type="month" className="pickerDateCustom flex a-center" value={taxCycle}
|
||||
onChange={val => this.setState({
|
||||
taxCycle: val,
|
||||
pageInfo: {
|
||||
...pageInfo,
|
||||
current: 1
|
||||
}
|
||||
}, () => this.queryEmployeeList())}/>,
|
||||
<Button type="primary" onClick={this.employeedeclareDeclare}
|
||||
loading={loading.declare}>{getLabel(111, "全部报送")}</Button>,
|
||||
<Button type="ghost" onClick={this.getDeclareFeedback}
|
||||
loading={loading.feedback}>{getLabel(111, "获取报送结果")}</Button>,
|
||||
<Button type="ghost" onClick={this.employeedeclareRefresh}
|
||||
loading={loading.refresh}>{getLabel(111, "刷新数据")}</Button>,
|
||||
<Dropdown overlay={menu}>
|
||||
<Button type="ghost" icon="ellipsis" className="moreBtn"/>
|
||||
</Dropdown>
|
||||
];
|
||||
const topTab = [
|
||||
{ title: getLabel(332, "全部"), viewcondition: "list" },
|
||||
{ title: getLabel(111, "本月新增"), viewcondition: "list4Add" },
|
||||
{ title: getLabel(111, "本月信息变动"), viewcondition: "list4Update" }
|
||||
];
|
||||
const tabBtns = [
|
||||
<Dropdown.Button
|
||||
onClick={this.handleAdd}
|
||||
overlay={
|
||||
<Menu>
|
||||
{/*<Menu.Item key="1">{getLabel(32935, "导入")}</Menu.Item>*/}
|
||||
</Menu>
|
||||
}
|
||||
type="primary">{getLabel(1421, "新增")}</Dropdown.Button>,
|
||||
<WeaSelect
|
||||
value={declareStatus}
|
||||
style={{ width: 150 }}
|
||||
options={[
|
||||
..._.map(submitStatus, it => ({ ...it, showname: getLabel(it.lanId, it.showname) })),
|
||||
..._.map(declareStatusList, it => ({
|
||||
key: it.enum,
|
||||
showname: getLabel(it.labelId, it.defaultLabel)
|
||||
}))
|
||||
]}
|
||||
onChange={declareStatus => this.setState({
|
||||
declareStatus,
|
||||
pageInfo: {
|
||||
...pageInfo,
|
||||
current: 1
|
||||
}
|
||||
}, () => this.queryEmployeeList())}
|
||||
/>
|
||||
];
|
||||
// !showOperateBtn && tabBtns.shift();
|
||||
selectedKey !== "list" && tabBtns.shift();
|
||||
return (
|
||||
<WeaTop
|
||||
title={getLabel(544289, "人员信息报送")} iconBgcolor="#F14A2D"
|
||||
icon={<i className="icon-coms-fa"/>} className="declareWrapper"
|
||||
buttons={buttons}
|
||||
// buttons={showOperateBtn ? buttons : []}
|
||||
>
|
||||
<div style={{ height: "100%", background: "#f6f6f6" }} className="flex flex-rollback">
|
||||
{/*基础信息*/}
|
||||
<BaseInfo
|
||||
ref={dom => this.baseInfoRef = dom}
|
||||
taxCycle={moment(taxCycle).startOf("month").format("YYYY-MM-DD")}
|
||||
/>
|
||||
{/*列表数据*/}
|
||||
<div className="listview-com-layout flex-1 flex flex-rollback">
|
||||
<WeaTab
|
||||
datas={topTab} keyParam="viewcondition" showSearchAd={showSearchAd}
|
||||
selectedKey={selectedKey} searchType={["base", "advanced"]}
|
||||
setShowSearchAd={bool => this.setState({ showSearchAd: bool })}
|
||||
advanceHeight={300} searchsAd={getSearchs(form, toJS(adConditons), 2)}
|
||||
buttons={tabBtns} searchsBaseValue={form.getFormParams().keyword}
|
||||
onSearchChange={(v) => form.updateFields({ keyword: v })}
|
||||
onChange={key => this.setState({
|
||||
selectedKey: key,
|
||||
pageInfo: { ...pageInfo, current: 1 }
|
||||
}, () => this.queryEmployeeList())}
|
||||
onAdReset={() => form.resetForm()}
|
||||
onSearch={() => this.setState({
|
||||
pageInfo: { ...pageInfo, current: 1 }
|
||||
}, () => this.queryEmployeeList())}
|
||||
onAdSearch={() => this.setState({
|
||||
pageInfo: {
|
||||
...pageInfo,
|
||||
current: 1
|
||||
}
|
||||
}, () => this.queryEmployeeList())}
|
||||
/>
|
||||
<div className="flex-1">
|
||||
<Spin spinning={loading.query}>
|
||||
<iframe
|
||||
style={{ border: 0, width: "100%", height: "100%" }}
|
||||
// src="http://localhost:7607/#/employeeDeclareTable"
|
||||
src="/spa/hrmSalary/hrmSalaryCalculateDetail/index.html#/employeeDeclareTable"
|
||||
id="atdTable"
|
||||
/>
|
||||
</Spin>
|
||||
{/*新增编辑报送信息*/}
|
||||
<EmployeeDeclareDetailSchemaEditDialog
|
||||
{...declareEditDialog}
|
||||
taxCycle={moment(taxCycle).startOf("month").format("YYYY-MM-DD")}
|
||||
employmentStatusList={employmentStatusList}
|
||||
employmentTypeList={employmentTypeList}
|
||||
onClose={(isFresh) => {
|
||||
this.setState({
|
||||
declareEditDialog: {
|
||||
...declareEditDialog,
|
||||
visible: false, id: "", title: ""
|
||||
}
|
||||
}, () => {
|
||||
declareForm.resetForm();
|
||||
isFresh === "true" && this.queryEmployeeList();
|
||||
});
|
||||
}}
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</WeaTop>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
export default Index;
|
||||
|
|
@ -0,0 +1,180 @@
|
|||
.declareWrapper {
|
||||
.wea-new-top {
|
||||
.moreBtn {
|
||||
border: 1px solid transparent;
|
||||
|
||||
i {
|
||||
font-weight: 700;
|
||||
transform: rotate(90deg);
|
||||
}
|
||||
}
|
||||
|
||||
.moreBtn:hover {
|
||||
border: 1px solid #57c5f7;
|
||||
background: #ffffff;
|
||||
color: #57c5f7;
|
||||
}
|
||||
}
|
||||
|
||||
.base-info {
|
||||
background: #ebf4ff;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
min-height: 50px;
|
||||
margin-bottom: 8px;
|
||||
border-radius: 4px;
|
||||
padding: 0 16px;
|
||||
|
||||
.right .header-declare-info {
|
||||
display: flex;
|
||||
justify-content: space-around;
|
||||
align-items: center;
|
||||
font-size: 12px;
|
||||
margin-right: 16px;
|
||||
|
||||
.fail {
|
||||
color: #5d9cec;
|
||||
cursor: pointer;
|
||||
margin-right: 10px;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.listview-com-layout {
|
||||
padding: 0 16px;
|
||||
|
||||
.wea-tab .wea-tab-right, .wea-input-focus {
|
||||
background: transparent;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.pickerDateCustom {
|
||||
.icon-coms-Browse-box-delete, .icon-coms-Browse-box-Add-to {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
border: 1px solid #e5e5e5;
|
||||
background: transparent;
|
||||
cursor: pointer;
|
||||
outline: none;
|
||||
padding: 0 6px;
|
||||
height: 30px;
|
||||
top: auto;
|
||||
}
|
||||
|
||||
.icon-coms-Browse-box-delete:hover, .icon-coms-Browse-box-Add-to:hover {
|
||||
color: #5d9cec;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
.declareTable {
|
||||
background: #FFF;
|
||||
}
|
||||
|
||||
|
||||
.wea-slide-modal-title {
|
||||
border-bottom: 1px solid #e5e5e5 !important;
|
||||
}
|
||||
|
||||
.wea-slide-modal-content {
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
.declareSchemeDialogTitle {
|
||||
border-bottom: 1px solid #e5e5e5;
|
||||
|
||||
.declareSchemeDialogTitle-left {
|
||||
text-align: left;
|
||||
padding-left: 16px;
|
||||
|
||||
.icon-circle-base {
|
||||
background: rgb(241, 74, 45);
|
||||
}
|
||||
|
||||
.title {
|
||||
color: #111;
|
||||
font-weight: 700;
|
||||
}
|
||||
}
|
||||
|
||||
.declareSchemeDialogTitle-right {
|
||||
text-align: right;
|
||||
padding-right: 56px;
|
||||
}
|
||||
}
|
||||
|
||||
.declareSchemeDialog {
|
||||
height: 100%;
|
||||
padding: 16px;
|
||||
overflow-y: auto;
|
||||
background: #f6f6f6;
|
||||
|
||||
.wea-search-group .wea-content {
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
.wea-search-group {
|
||||
border: 1px solid #e5e5e5;
|
||||
border-bottom: none;
|
||||
background: #fff;
|
||||
|
||||
.wea-form-item {
|
||||
padding: 5px 16px;
|
||||
border-bottom: 1px solid #e5e5e5;
|
||||
}
|
||||
}
|
||||
|
||||
.wea-search-group, .wea-form-cell {
|
||||
padding: 0;
|
||||
}
|
||||
}
|
||||
|
||||
.declareCalcDialog {
|
||||
.declareCalcDialogTitle {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
|
||||
.declareCalcDialogTitle-left {
|
||||
text-align: left;
|
||||
|
||||
.title {
|
||||
color: #111;
|
||||
font-weight: 700;
|
||||
}
|
||||
}
|
||||
|
||||
.declareCalcDialogTitle-right {
|
||||
text-align: right;
|
||||
}
|
||||
}
|
||||
|
||||
.declareCalcDialogContent {
|
||||
height: 100%;
|
||||
padding: 16px;
|
||||
background: #f6f6f6;
|
||||
overflow-y: auto;
|
||||
}
|
||||
}
|
||||
|
||||
.flex {
|
||||
display: flex;
|
||||
}
|
||||
|
||||
.flex-rollback {
|
||||
flex-direction: column;
|
||||
}
|
||||
|
||||
.flex-1 {
|
||||
flex: 1;
|
||||
|
||||
.ant-spin-nested-loading, .ant-spin-container {
|
||||
height: 99%;
|
||||
}
|
||||
}
|
||||
|
||||
.a-center {
|
||||
align-items: center;
|
||||
}
|
||||
|
|
@ -0,0 +1,86 @@
|
|||
/*
|
||||
* Author: 黎永顺
|
||||
* name: 在线申报-个税开具证明查看页面
|
||||
* Description:
|
||||
* Date: 2023/8/23
|
||||
*/
|
||||
import React, { Component } from "react";
|
||||
import { Icon, Menu, message, Spin } from "antd";
|
||||
import { WeaLocaleProvider } from "ecCom";
|
||||
import { getQueryString } from "../../util/url";
|
||||
import { taxPaymentWithheldVoucherGet } from "../../apis/declare";
|
||||
import "./index.less";
|
||||
|
||||
const { getLabel } = WeaLocaleProvider;
|
||||
|
||||
class Index extends Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
loading: false, current: "",
|
||||
enterprisePayCertifiTipMsg: "",
|
||||
dataSource: []
|
||||
};
|
||||
}
|
||||
|
||||
componentDidMount() {
|
||||
this.getEnterprisePayCertificate();
|
||||
}
|
||||
|
||||
getEnterprisePayCertificate = () => {
|
||||
const payload = {
|
||||
taxDeclareRecordId: getQueryString("taxDeclareRecordId"),
|
||||
taxAgentId: getQueryString("taxAgentId"),
|
||||
taxYearMonth: getQueryString("taxYearMonth")
|
||||
};
|
||||
this.setState({ loading: true });
|
||||
taxPaymentWithheldVoucherGet(payload).then(({ status, data, errormsg }) => {
|
||||
this.setState({ loading: false });
|
||||
if (status && !_.isEmpty(data.vouchers)) {
|
||||
this.setState({
|
||||
dataSource: data.vouchers,
|
||||
enterprisePayCertifiTipMsg: data.msg || "",
|
||||
current: _.head(data.vouchers).name
|
||||
});
|
||||
} else {
|
||||
message.error(errormsg || "");
|
||||
}
|
||||
}).catch(() => this.setState({ loading: false }));
|
||||
};
|
||||
|
||||
render() {
|
||||
const { dataSource, loading, enterprisePayCertifiTipMsg, current } = this.state;
|
||||
if (loading) {
|
||||
return <div className="loading-layout">
|
||||
<Spin spinning={loading} tip={getLabel(111, "获取企业完税证明中...")}/>
|
||||
</div>;
|
||||
}
|
||||
if (_.isEmpty(dataSource)) {
|
||||
return <div className="pay-certification-detail empty">
|
||||
<p className="iconEmpty"><Icon type="inbox"/></p>
|
||||
<p className="empty-title">{getLabel(83553, "暂无数据")}</p>
|
||||
<p
|
||||
className="empty-subTitle">{enterprisePayCertifiTipMsg || getLabel(111, "暂无企业完税证明相关信息")}</p>
|
||||
</div>;
|
||||
}
|
||||
return (
|
||||
<div className="pay-certification-detail">
|
||||
<div className="left">
|
||||
<Menu selectedKeys={[current]} mode="inline" onClick={({ key: current }) => this.setState({ current })}>
|
||||
{
|
||||
_.map(dataSource, item => {
|
||||
return <Menu.Item key={item.name}>{item.name}</Menu.Item>;
|
||||
})
|
||||
}
|
||||
</Menu>
|
||||
</div>
|
||||
<div className="right">
|
||||
<iframe src={`data:application/pdf;base64,${_.find(dataSource, it => it.name === current).content}`}
|
||||
style={{ border: 0, width: "100%", height: "100%" }}/>
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
export default Index;
|
||||
|
|
@ -0,0 +1,54 @@
|
|||
.loading-layout {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.pay-certification-detail {
|
||||
display: flex;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
|
||||
.left {
|
||||
width: 220px;
|
||||
flex-grow: 0;
|
||||
flex-shrink: 0;
|
||||
height: 100vh;
|
||||
overflow-y: auto;
|
||||
}
|
||||
|
||||
.right {
|
||||
width: calc(100vw - 220px);
|
||||
height: 100vh;
|
||||
}
|
||||
|
||||
&.empty {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
flex-direction: column;
|
||||
|
||||
p {
|
||||
line-height: 36px;
|
||||
}
|
||||
|
||||
.empty-title {
|
||||
color: #111;
|
||||
font-size: 16px;
|
||||
}
|
||||
|
||||
.empty-subTitle {
|
||||
color: #666;
|
||||
font-size: 14px;
|
||||
}
|
||||
|
||||
.iconEmpty {
|
||||
i {
|
||||
color: #5d9cec;
|
||||
font-size: 43px;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,94 @@
|
|||
export const trafficUsageConditions = [
|
||||
{
|
||||
items: [
|
||||
{
|
||||
colSpan: 1,
|
||||
conditionType: "RANGEPICKER",
|
||||
domkey: ["startDate", "endDate"],
|
||||
fieldcol: 22,
|
||||
label: "",
|
||||
labelcol: 0,
|
||||
value: ""
|
||||
},
|
||||
{
|
||||
colSpan: 1,
|
||||
conditionType: "SELECT",
|
||||
domkey: ["taxAgentId"],
|
||||
fieldcol: 22,
|
||||
label: "",
|
||||
labelcol: 0,
|
||||
value: "",
|
||||
options: []
|
||||
},
|
||||
{
|
||||
colSpan: 1,
|
||||
conditionType: "SELECT",
|
||||
domkey: ["businessType"],
|
||||
fieldcol: 22,
|
||||
label: "",
|
||||
labelcol: 0,
|
||||
value: "",
|
||||
options: [
|
||||
{ key: "", showname: "全部(接口业务)", lanId: 111 },
|
||||
{ key: "1", showname: "累计专项附加扣除", lanId: 538006 },
|
||||
{ key: "2", showname: "人员信息报送", lanId: 544289 },
|
||||
{ key: "3", showname: "个税申报", lanId: 543353 }
|
||||
]
|
||||
},
|
||||
{
|
||||
colSpan: 1,
|
||||
conditionType: "SELECT",
|
||||
domkey: ["result"],
|
||||
fieldcol: 22,
|
||||
label: "",
|
||||
labelcol: 0,
|
||||
value: "",
|
||||
options: [
|
||||
{ key: "", showname: "全部(结果)", lanId: 111 },
|
||||
{ key: "20", showname: "成功", lanId: 111 },
|
||||
{ key: "30", showname: "失败", lanId: 25009 }
|
||||
]
|
||||
}
|
||||
],
|
||||
defaultshow: true
|
||||
}
|
||||
];
|
||||
export const remindObjConditions = [
|
||||
{
|
||||
items: [
|
||||
{
|
||||
browserConditionParam: {
|
||||
completeParams: {},
|
||||
conditionDataParams: {},
|
||||
dataParams: {},
|
||||
destDataParams: {},
|
||||
hasAddBtn: false,
|
||||
hasAdvanceSerach: true,
|
||||
idSeparator: ",",
|
||||
isAutoComplete: 1,
|
||||
isDetail: 0,
|
||||
isMultCheckbox: false,
|
||||
isSingle: true,
|
||||
linkUrl: "",
|
||||
pageSize: 10,
|
||||
quickSearchName: "",
|
||||
replaceDatas: [],
|
||||
title: "",
|
||||
type: "1",
|
||||
viewAttr: 3,
|
||||
rules: "required"
|
||||
},
|
||||
colSpan: 1,
|
||||
conditionType: "BROWSER",
|
||||
rules: "required|string",
|
||||
domkey: ["employeeId"],
|
||||
fieldcol: 12,
|
||||
label: "提醒对象",
|
||||
lanId: 111,
|
||||
labelcol: 6,
|
||||
viewAttr: 3
|
||||
}
|
||||
],
|
||||
defaultshow: true
|
||||
}
|
||||
];
|
||||
|
|
@ -0,0 +1,94 @@
|
|||
/*
|
||||
* Author: 黎永顺
|
||||
* name: 智能算薪-添加提醒对象
|
||||
* Description:
|
||||
* Date: 2023/8/29
|
||||
*/
|
||||
import React, { Component } from "react";
|
||||
import { inject, observer } from "mobx-react";
|
||||
import { WeaDialog, WeaLocaleProvider } from "ecCom";
|
||||
import { Button, message } from "antd";
|
||||
import { getSearchs } from "../../../util";
|
||||
import { remindObjConditions } from "./constants";
|
||||
import { apiflowWarnReceiverGetForm, apiflowWarnReceiverSave } from "../../../apis/intelligentCalculateSalarySettings";
|
||||
|
||||
const getLabel = WeaLocaleProvider.getLabel;
|
||||
|
||||
@inject("intelligentStore")
|
||||
@observer
|
||||
class EditBeRemindObjDialog extends Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
loading: false
|
||||
};
|
||||
}
|
||||
|
||||
componentWillReceiveProps(nextProps, nextContext) {
|
||||
const { intelligentStore: { remindObjform }, id } = nextProps;
|
||||
if (nextProps.visible !== this.props.visible && nextProps.visible) {
|
||||
remindObjform.initFormFields(remindObjConditions);
|
||||
id && this.apiflowWarnReceiverGetForm(nextProps);
|
||||
}
|
||||
if (nextProps.visible !== this.props.visible && !nextProps.visible) {
|
||||
remindObjform.resetForm();
|
||||
}
|
||||
}
|
||||
|
||||
apiflowWarnReceiverGetForm = (props) => {
|
||||
const { intelligentStore: { remindObjform } } = this.props;
|
||||
const { id } = props;
|
||||
apiflowWarnReceiverGetForm({ id }).then(({ status, data }) => {
|
||||
if (status) {
|
||||
const { employee } = data;
|
||||
remindObjform.updateFields({
|
||||
"employeeId": {
|
||||
value: employee[0].id,
|
||||
valueSpan: employee[0].content,
|
||||
valueObj: [{ id: employee[0].id, name: employee[0].content }]
|
||||
}
|
||||
});
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
save = () => {
|
||||
const { intelligentStore: { remindObjform }, warnConfigId, id } = this.props;
|
||||
remindObjform.validateForm().then(f => {
|
||||
const { employeeId } = remindObjform.getFormParams();
|
||||
if (f.isValid) {
|
||||
this.setState({ loading: true });
|
||||
apiflowWarnReceiverSave({ employeeId, warnConfigId, id }).then(({ status, errormsg }) => {
|
||||
this.setState({ loading: false });
|
||||
if (status) {
|
||||
message.success(getLabel(22619, "保存成功!"));
|
||||
this.props.updateWarnList();
|
||||
this.props.onCancel();
|
||||
} else {
|
||||
message.error(errormsg);
|
||||
}
|
||||
}).catch(() => this.setState({ loading: false }));
|
||||
} else {
|
||||
f.showErrors();
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
render() {
|
||||
const { intelligentStore: { remindObjform } } = this.props;
|
||||
return (
|
||||
<WeaDialog
|
||||
{...this.props} className="paymentDialog" initLoadCss
|
||||
style={{ width: 550 }}
|
||||
buttons={[<Button type="primary" onClick={this.save}
|
||||
loading={this.state.loading}>{getLabel(537558, "保存")}</Button>]}
|
||||
>
|
||||
<div className="paymentDialogContent">
|
||||
{getSearchs(remindObjform, remindObjConditions, 1)}
|
||||
</div>
|
||||
</WeaDialog>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
export default EditBeRemindObjDialog;
|
||||
|
|
@ -0,0 +1,149 @@
|
|||
/*
|
||||
* Author: 黎永顺
|
||||
* name: 启用设置
|
||||
* Description:
|
||||
* Date: 2023/7/19
|
||||
*/
|
||||
import React, { Component } from "react";
|
||||
import { Button, Col, Input, message, Modal, Row } from "antd";
|
||||
import TipLabel from "../../../components/TipLabel";
|
||||
import { WeaCheckbox, WeaFormItem, WeaLocaleProvider, WeaSearchGroup } from "ecCom";
|
||||
import {
|
||||
apiflowBillingConfigEnable,
|
||||
apiflowBillingConfigGet,
|
||||
apiflowBillingConfigSave
|
||||
} from "../../../apis/intelligentCalculateSalarySettings";
|
||||
|
||||
const getLabel = WeaLocaleProvider.getLabel;
|
||||
|
||||
class EnableSettings extends Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
enable: "1", id: "",
|
||||
appKey: "", appSecret: "",
|
||||
loading: false
|
||||
};
|
||||
}
|
||||
|
||||
componentDidMount() {
|
||||
this.apiflowBillingConfigGet();
|
||||
}
|
||||
|
||||
apiflowBillingConfigGet = () => {
|
||||
apiflowBillingConfigGet().then(({ status, data }) => {
|
||||
if (status) {
|
||||
const { id, appKey, appSecret, enable } = data;
|
||||
this.setState({
|
||||
appKey, appSecret, enable: enable ? "1" : "0", id
|
||||
});
|
||||
}
|
||||
});
|
||||
};
|
||||
apiflowBillingConfigEnable = (enable) => {
|
||||
apiflowBillingConfigEnable({ enable }).then(({ status, errormsg }) => {
|
||||
if (status) {
|
||||
message.success(enable === "OFF" ? getLabel(111, "关闭成功!") : getLabel(111, "开启成功!"));
|
||||
enable === "OFF" && this.setState({ enable: "0" });
|
||||
} else {
|
||||
message.error(errormsg || (enable === "OFF" ? getLabel(111, "关闭失败!") : getLabel(111, "开启失败!")));
|
||||
this.setState({ enable: this.state.enable });
|
||||
}
|
||||
});
|
||||
};
|
||||
apiflowBillingConfigSave = () => {
|
||||
const { enable, id, appKey, appSecret } = this.state;
|
||||
const payload = {
|
||||
id, appKey, appSecret,
|
||||
enable: enable === "1" ? "ON" : "OFF"
|
||||
};
|
||||
this.setState({ loading: true });
|
||||
apiflowBillingConfigSave(payload).then(({ status, errormsg }) => {
|
||||
this.setState({ loading: false });
|
||||
if (status) {
|
||||
message.success(getLabel(384521, "设置成功!"));
|
||||
} else {
|
||||
message.error(errormsg || getLabel(384522, "设置失败!"));
|
||||
}
|
||||
}).catch(() => this.setState({ loading: false }));
|
||||
};
|
||||
handleEnale = (enable) => {
|
||||
if (enable === "1") {
|
||||
this.setState({ enable }, () => this.apiflowBillingConfigEnable("ON"));
|
||||
} else {
|
||||
Modal.confirm({
|
||||
title: getLabel(131329, "信息确认"),
|
||||
content: getLabel(544344, "确定要关闭智能算薪功能吗?关闭后,将无法使用在线报送人员信息、在线获取专项附加扣除数据、在线个税申报等功能!"),
|
||||
onOk: () => this.apiflowBillingConfigEnable("OFF"),
|
||||
onCancel: () => {
|
||||
this.setState({ enable: this.state.enable });
|
||||
}
|
||||
});
|
||||
}
|
||||
};
|
||||
handleChangeInput = (key, val) => this.setState({ [key]: val });
|
||||
|
||||
render() {
|
||||
const { enable, appKey, appSecret, loading } = this.state;
|
||||
const tipList = [
|
||||
getLabel(544282, "1、智能算薪默认是开启的,若购买了智能算薪,请先配置账号密码,在购买的流量足够的前提下即可正常使用;"),
|
||||
getLabel(544283, "2、您可在【接口流量统计】中查看接口流量使用情况;"),
|
||||
getLabel(544284, "3、您可以设置【流量不足提醒】,提前提醒可以避免次月要用时因流量不足无法使用的情况。"),
|
||||
getLabel(544285, "4、如您需了解您购买的流量的使用明细,可查看【流量使用记录】;")
|
||||
];
|
||||
const InputAccount = label => {
|
||||
return (
|
||||
<WeaFormItem label={label} labelCol={{ span: 4 }} wrapperCol={{ span: 18 }}>
|
||||
<Input
|
||||
value={appKey} autoComplete="new-password" placeholder={getLabel(83869, "请输入")}
|
||||
onChange={e => this.handleChangeInput("appKey", e.target.value)}
|
||||
/>
|
||||
</WeaFormItem>
|
||||
);
|
||||
};
|
||||
const InputPassword = label => {
|
||||
return (
|
||||
<WeaFormItem label={label} labelCol={{ span: 4 }} wrapperCol={{ span: 18 }}>
|
||||
<Input
|
||||
value={appSecret} type="password" autoComplete="new-password" placeholder={getLabel(83869, "请输入")}
|
||||
onChange={e => this.handleChangeInput("appSecret", e.target.value)}
|
||||
/>
|
||||
</WeaFormItem>
|
||||
);
|
||||
};
|
||||
return (
|
||||
<Row className="enable-settings" gutter={16}>
|
||||
<Col span={16}>
|
||||
<div className="swith-area">
|
||||
<div className="left">
|
||||
<div className="title">{getLabel(111, "智能算薪")}</div>
|
||||
<div
|
||||
className="info">{getLabel(111, "开启智能算薪并输入正确的账号密码,且购买了智能算薪流量,才能正常使用智能算薪功能。")}</div>
|
||||
</div>
|
||||
<div className="right"><WeaCheckbox display="switch" value={enable} onChange={this.handleEnale}/></div>
|
||||
</div>
|
||||
<div className="userinfo">
|
||||
<div className="left">
|
||||
<WeaSearchGroup
|
||||
showGroup needTigger={false} col={3}
|
||||
items={[
|
||||
{ com: InputAccount(getLabel(83594, "账号")) },
|
||||
{ com: InputPassword(getLabel(33150, "密码")) }
|
||||
]}
|
||||
/>
|
||||
</div>
|
||||
<div className="right">
|
||||
<Button type="primary" onClick={this.apiflowBillingConfigSave}
|
||||
loading={loading}>{getLabel(725, "提交")}</Button>
|
||||
</div>
|
||||
</div>
|
||||
</Col>
|
||||
<Col span={8}>
|
||||
<TipLabel tipList={tipList}/>
|
||||
</Col>
|
||||
</Row>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
export default EnableSettings;
|
||||
|
|
@ -0,0 +1,264 @@
|
|||
/*
|
||||
* Author: 黎永顺
|
||||
* name:流量不足提醒
|
||||
* Description:
|
||||
* Date: 2023/7/19
|
||||
*/
|
||||
import React, { Component } from "react";
|
||||
import {
|
||||
WeaButtonIcon,
|
||||
WeaCheckbox,
|
||||
WeaFormItem,
|
||||
WeaInputNumber,
|
||||
WeaLocaleProvider,
|
||||
WeaSearchGroup,
|
||||
WeaTable
|
||||
} from "ecCom";
|
||||
import { message, Modal, Spin } from "antd";
|
||||
import EditBeRemindObjDialog from "./editBeRemindObjDialog";
|
||||
import {
|
||||
apiflowWarnConfigGetForm,
|
||||
apiflowWarnReceiverDelete,
|
||||
apiflowWarnReceiverList
|
||||
} from "../../../apis/intelligentCalculateSalarySettings";
|
||||
|
||||
const getLabel = WeaLocaleProvider.getLabel;
|
||||
|
||||
class InsufficientTrafficAlert extends Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
enable: "0",
|
||||
remindEvent: { businessId: "", eventId: "", moduleId: "", id: "" },
|
||||
threshold: null, channelList: [
|
||||
{ label: "EMobile", type: "IM", channel: "1", value: "1", config: {} },
|
||||
{ label: "邮件", type: "email", channel: "3", value: "1", config: {} },
|
||||
{ label: "短信", type: "message", channel: "4", value: "1", config: {} }
|
||||
], columns: [], dataSource: [],
|
||||
loading: false, remindObjDialog: { visible: false, title: "", warnConfigId: "", id: "" }
|
||||
};
|
||||
}
|
||||
|
||||
componentDidMount() {
|
||||
this.apiflowWarnConfigGetForm();
|
||||
}
|
||||
|
||||
apiflowWarnConfigGetForm = () => {
|
||||
const { remindEvent } = this.state;
|
||||
apiflowWarnConfigGetForm().then(({ status, data }) => {
|
||||
if (status) {
|
||||
const { enable, businessId, eventId, moduleId, id, threshold } = data;
|
||||
this.setState({
|
||||
enable: enable ? "1" : "0",
|
||||
remindEvent: { ...remindEvent, businessId, eventId, moduleId, id },
|
||||
threshold
|
||||
}, () => {
|
||||
this.state.enable === "1" && this.apiflowWarnReceiverList();
|
||||
});
|
||||
}
|
||||
});
|
||||
};
|
||||
apiflowWarnReceiverList = () => {
|
||||
const { remindEvent } = this.state;
|
||||
const { id } = remindEvent;
|
||||
const payload = {
|
||||
warnConfigId: id || this.props.warnConfigId
|
||||
};
|
||||
apiflowWarnReceiverList(payload).then(({ status, data }) => {
|
||||
if (status) {
|
||||
const { columns, list: dataSource } = data;
|
||||
this.setState({
|
||||
dataSource,
|
||||
columns: _.map(columns, item => {
|
||||
const { dataIndex } = item;
|
||||
let width = "";
|
||||
switch (dataIndex) {
|
||||
case "employeeName":
|
||||
case "mobile":
|
||||
width = "30%";
|
||||
break;
|
||||
case "email":
|
||||
width = "40%";
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
return { ...item, width };
|
||||
})
|
||||
});
|
||||
}
|
||||
});
|
||||
};
|
||||
apiflowWarnReceiverDelete = (id) => {
|
||||
Modal.confirm({
|
||||
title: getLabel(131329, "信息确认"),
|
||||
content: getLabel(111, "确定删除吗?删除后数据不可找回"),
|
||||
onOk: () => {
|
||||
apiflowWarnReceiverDelete({ id }).then(({ status, errormsg }) => {
|
||||
if (status) {
|
||||
message.success(getLabel(502230, "删除成功!"));
|
||||
this.apiflowWarnReceiverList();
|
||||
} else {
|
||||
message.error(errormsg || getLabel(20462, "删除失败!"));
|
||||
}
|
||||
});
|
||||
}
|
||||
});
|
||||
};
|
||||
handleEnale = (enable) => {
|
||||
if (enable === "1") {
|
||||
this.setState({ enable }, () => this.apiflowWarnReceiverList());
|
||||
} else {
|
||||
Modal.confirm({
|
||||
title: getLabel(131329, "信息确认"),
|
||||
content: getLabel(111, "确认关闭提醒吗?关闭并保存后,流量不足时将无法及时提醒。"),
|
||||
onOk: () => {
|
||||
this.setState({ enable });
|
||||
},
|
||||
onCancel: () => {
|
||||
this.setState({ enable: this.state.enable });
|
||||
}
|
||||
});
|
||||
}
|
||||
};
|
||||
handleChangeChannel = (o) => {
|
||||
const { channelList } = this.state;
|
||||
this.setState({
|
||||
channelList: _.map(channelList, item => {
|
||||
if (item.type === o.type) {
|
||||
return { ...item, ...o };
|
||||
}
|
||||
return { ...item };
|
||||
})
|
||||
});
|
||||
};
|
||||
|
||||
render() {
|
||||
const {
|
||||
remindEvent, enable, channelList, threshold,
|
||||
loading, columns, dataSource, remindObjDialog
|
||||
} = this.state;
|
||||
const { id } = remindEvent;
|
||||
return (
|
||||
<WeaSearchGroup showGroup needTigger={false} className="insufficientAlertWrapper">
|
||||
<WeaFormItem label={getLabel(501480, "提醒")} labelCol={{ span: 4 }} wrapperCol={{ span: 20 }}>
|
||||
<WeaCheckbox display="switch" value={enable} onChange={this.handleEnale}/>
|
||||
</WeaFormItem>
|
||||
{
|
||||
enable === "1" &&
|
||||
<React.Fragment>
|
||||
<WeaFormItem
|
||||
label={getLabel(544288, "提醒规则")}
|
||||
labelCol={{ span: 4 }} wrapperCol={{ span: 20 }}
|
||||
>
|
||||
<ReminderRules value={threshold} onChange={o => this.setState({ threshold: o })}/>
|
||||
</WeaFormItem>
|
||||
{/*<WeaFormItem*/}
|
||||
{/* colon={false} labelCol={{ span: 4 }} wrapperCol={{ span: 20 }}*/}
|
||||
{/* label={*/}
|
||||
{/* <div className="flex items-center">*/}
|
||||
{/* <span>{getLabel(544287, "提醒推送方式")}:</span>*/}
|
||||
{/* <WeaHelpfulTip*/}
|
||||
{/* width={200} style={{ marginLeft: 10 }}*/}
|
||||
{/* title={getLabel(111, "使用邮箱之前,请先确认是否设置邮件提醒账号。\n" + "使用短信之前,请先确认是否新建签名。")}*/}
|
||||
{/* placement="topLeft"*/}
|
||||
{/* />*/}
|
||||
{/* </div>*/}
|
||||
{/* }*/}
|
||||
{/*>*/}
|
||||
{/* <Pushmethod channelList={channelList} onChange={this.handleChangeChannel}/>*/}
|
||||
{/*</WeaFormItem>*/}
|
||||
</React.Fragment>
|
||||
}
|
||||
{
|
||||
enable === "1" &&
|
||||
<div className="table">
|
||||
<div className="title flex items-center">
|
||||
<span className="titleLeft">{getLabel(111, "提醒对象设置")}</span>
|
||||
<WeaButtonIcon
|
||||
buttonType="add" type="primary"
|
||||
onClick={() => this.setState({
|
||||
remindObjDialog: {
|
||||
...remindObjDialog, visible: true, title: getLabel(111, "添加提醒对象"),
|
||||
warnConfigId: id || this.props.warnConfigId
|
||||
}
|
||||
})}
|
||||
/>
|
||||
{/* 添加提醒对象*/}
|
||||
<EditBeRemindObjDialog
|
||||
{...remindObjDialog}
|
||||
updateWarnList={this.apiflowWarnReceiverList}
|
||||
onCancel={() => this.setState({
|
||||
remindObjDialog: {
|
||||
...remindObjDialog, visible: false, title: "", warnConfigId: "", id: ""
|
||||
}
|
||||
})}
|
||||
/>
|
||||
</div>
|
||||
{
|
||||
loading ? <div className="loading-layout">
|
||||
<Spin spinning={loading}/>
|
||||
</div> : <WeaTable
|
||||
dataSource={dataSource} loading={loading}
|
||||
columns={[
|
||||
...columns,
|
||||
{
|
||||
title: getLabel(30585, "操作"), dataIndex: "operate", width: 120,
|
||||
render: (__, record) => (<div className="space">
|
||||
<a
|
||||
href="javascript:void(0);" className="mr10"
|
||||
onClick={() => this.setState({
|
||||
remindObjDialog: {
|
||||
...remindObjDialog, visible: true, title: getLabel(111, "添加提醒对象"),
|
||||
warnConfigId: id || this.props.warnConfigId, id: record.id
|
||||
}
|
||||
})}>{getLabel(501169, "编辑")}</a>
|
||||
<a href="javascript:void(0);"
|
||||
onClick={() => this.apiflowWarnReceiverDelete(record.id)}>{getLabel(535052, "删除")}</a>
|
||||
</div>)
|
||||
}
|
||||
]} pagination={false}
|
||||
scroll={{ y: `calc(100vh - 190px)` }}
|
||||
/>
|
||||
}
|
||||
</div>
|
||||
}
|
||||
</WeaSearchGroup>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
export default InsufficientTrafficAlert;
|
||||
|
||||
|
||||
const ReminderRules = (props) => {
|
||||
const { onChange, value } = props;
|
||||
return (
|
||||
<div className="threshold">
|
||||
<span className="before">{getLabel(111, "流量不足")}</span>
|
||||
<WeaInputNumber value={value} onChange={onChange} style={{ width: 180 }} viewAttr={3} precision={3}/>
|
||||
<span className="after">{getLabel(111, "时提醒")}</span>
|
||||
<span
|
||||
className="tip">{getLabel(111, "为确保智能算薪正常使用,设置建议:若每个月消耗流量10,000,则不足10,000时提醒,以此预留一个月时间续流量")}</span>
|
||||
</div>
|
||||
);
|
||||
};
|
||||
|
||||
const Pushmethod = (props) => {
|
||||
const { onChange, channelList } = props;
|
||||
return <div className="channel-list">
|
||||
{
|
||||
_.map(channelList, item => {
|
||||
const { label, type, value } = item;
|
||||
return (
|
||||
<div className="channel-item">
|
||||
<WeaCheckbox value={value} content={label} onChange={o => onChange({ ...item, value: o })}/>
|
||||
{(type !== "email" && value === "1") && <i className="icon-coms-Flow-setting"/>}
|
||||
</div>
|
||||
);
|
||||
})
|
||||
}
|
||||
</div>;
|
||||
};
|
||||
|
||||
|
||||
|
|
@ -0,0 +1,162 @@
|
|||
/*
|
||||
* Author: 黎永顺
|
||||
* name: 智能算薪-接口流量统计
|
||||
* Description:
|
||||
* Date: 2023/8/29
|
||||
*/
|
||||
import React, { Component } from "react";
|
||||
import { Button, message, Spin } from "antd";
|
||||
import { WeaLocaleProvider, WeaTable } from "ecCom";
|
||||
import { apiflowStatisticsInfo, apiflowStatisticsList } from "../../../apis/intelligentCalculateSalarySettings";
|
||||
|
||||
const getLabel = WeaLocaleProvider.getLabel;
|
||||
|
||||
class InterfaceFlowStatistics extends Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
statisticsInfo: {
|
||||
lastUpdateTime: "",
|
||||
staticData: [
|
||||
{
|
||||
key: "total",
|
||||
label: getLabel(111, "购买接口总流量"),
|
||||
value: "",
|
||||
icon: require("../../../common/purchased.png")
|
||||
},
|
||||
{
|
||||
key: "remain", label: getLabel(111, "剩余总流量"), value: "", icon: require("../../../common/remaining.png")
|
||||
},
|
||||
{
|
||||
key: "used", label: getLabel(111, "已使用总流量"), value: "", icon: require("../../../common/traffic.png")
|
||||
}
|
||||
]
|
||||
},
|
||||
columns: [], dataSource: [],
|
||||
pageInfo: { current: 1, pageSize: 10, total: 0 },
|
||||
loading: false
|
||||
};
|
||||
}
|
||||
|
||||
componentDidMount() {
|
||||
this.apiflowStatisticsInfo();
|
||||
this.apiflowStatisticsList();
|
||||
}
|
||||
|
||||
apiflowStatisticsInfo = () => {
|
||||
const { statisticsInfo } = this.state;
|
||||
apiflowStatisticsInfo().then(({ status, data }) => {
|
||||
if (status) {
|
||||
const { lastUpdateTime, ...extraData } = data;
|
||||
this.setState({
|
||||
statisticsInfo: {
|
||||
...statisticsInfo,
|
||||
lastUpdateTime,
|
||||
staticData: _.map(statisticsInfo.staticData, item => ({
|
||||
...item,
|
||||
value: extraData[item["key"]]
|
||||
}))
|
||||
}
|
||||
}, () => this.props.updateTime(this.state.statisticsInfo));
|
||||
}
|
||||
});
|
||||
};
|
||||
apiflowStatisticsList = () => {
|
||||
const { pageInfo } = this.state;
|
||||
const payload = { ...pageInfo };
|
||||
this.setState({ loading: true });
|
||||
apiflowStatisticsList(payload).then(({ status, data, errormsg }) => {
|
||||
this.setState({ loading: false });
|
||||
if (status) {
|
||||
const { columns, list: dataSource, pageNum: current, pageSize, total } = data;
|
||||
this.setState({
|
||||
dataSource, pageInfo: { ...pageInfo, current, pageSize, total },
|
||||
columns: _.map(columns, item => {
|
||||
const { dataIndex } = item;
|
||||
let width = "";
|
||||
switch (dataIndex) {
|
||||
case "taxAgentName":
|
||||
case "used":
|
||||
width = "40%";
|
||||
break;
|
||||
default:
|
||||
width = "10%";
|
||||
break;
|
||||
}
|
||||
return { ...item, width };
|
||||
})
|
||||
});
|
||||
} else {
|
||||
message.error(errormsg);
|
||||
}
|
||||
}).catch(() => this.setState({ loading: false }));
|
||||
};
|
||||
handleExport = () => {
|
||||
window.open(`${window.ecologyContentPath || ""}/api/bs/hrmsalary/taxdeclaration/apiflow/statistics/export`, "_blank");
|
||||
};
|
||||
|
||||
render() {
|
||||
const { statisticsInfo, pageInfo, loading, dataSource, columns } = this.state;
|
||||
const { staticData } = statisticsInfo;
|
||||
const pagination = {
|
||||
...pageInfo,
|
||||
showTotal: total => `${getLabel(18609, "共")} ${total} ${getLabel(18256, "条")}`,
|
||||
showQuickJumper: true,
|
||||
showSizeChanger: true,
|
||||
pageSizeOptions: ["10", "20", "50", "100"],
|
||||
onShowSizeChange: (current, pageSize) => {
|
||||
this.setState({
|
||||
pageInfo: { ...pageInfo, current, pageSize }
|
||||
}, () => this.apiflowStatisticsList());
|
||||
},
|
||||
onChange: current => {
|
||||
this.setState({
|
||||
pageInfo: { ...pageInfo, current }
|
||||
}, () => this.apiflowStatisticsList());
|
||||
}
|
||||
};
|
||||
return (
|
||||
<div className="statisticsInfo-layout">
|
||||
<div className="static-data">
|
||||
{
|
||||
_.map(staticData, item => {
|
||||
const { label, icon, value } = item;
|
||||
return (
|
||||
<div className="item">
|
||||
<div className="left"><img src={icon} alt=""/></div>
|
||||
<div className="right">
|
||||
<div className="data">{value}</div>
|
||||
<div className="title">{label}</div>
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
})
|
||||
}
|
||||
</div>
|
||||
<div className="detail-area">
|
||||
<div className="title">
|
||||
<div className="text">{getLabel(111, "使用明细")}</div>
|
||||
<Button type="primary" onClick={this.handleExport}>{getLabel(81272, "导出全部")}</Button>
|
||||
</div>
|
||||
{
|
||||
loading ? <div className="loading-layout">
|
||||
<Spin spinning={loading}/>
|
||||
</div> : <WeaTable
|
||||
dataSource={dataSource} pagination={pagination} loading={loading}
|
||||
columns={[
|
||||
...columns,
|
||||
{
|
||||
title: getLabel(30585, "操作"), dataIndex: "operate",
|
||||
render: () => (<a href="">{getLabel(111, "月统计详情")}</a>)
|
||||
}
|
||||
]}
|
||||
scroll={{ y: `calc(100vh - 190px)` }}
|
||||
/>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
export default InterfaceFlowStatistics;
|
||||
|
|
@ -0,0 +1,136 @@
|
|||
/*
|
||||
* Author: 黎永顺
|
||||
* name: 智能算薪-流量使用记录
|
||||
* Description:
|
||||
* Date: 2023/8/28
|
||||
*/
|
||||
import React, { Component } from "react";
|
||||
import { inject, observer } from "mobx-react";
|
||||
import { WeaLocaleProvider, WeaTable } from "ecCom";
|
||||
import { trafficUsageConditions } from "./constants";
|
||||
import { getSearchs } from "../../../util";
|
||||
import moment from "moment";
|
||||
import { apiflowRecordList } from "../../../apis/intelligentCalculateSalarySettings";
|
||||
|
||||
const getLabel = WeaLocaleProvider.getLabel;
|
||||
|
||||
@inject("taxAgentStore", "intelligentStore")
|
||||
@observer
|
||||
class TrafficUsageRecords extends Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
conditions: [], columns: [], dataSource: [],
|
||||
pageInfo: { current: 1, pageSize: 10, total: 0 },
|
||||
loading: false
|
||||
};
|
||||
}
|
||||
|
||||
componentDidMount() {
|
||||
const { taxAgentStore: { fetchTaxAgentOption }, intelligentStore: { form } } = this.props;
|
||||
fetchTaxAgentOption().then(({ data }) => {
|
||||
this.setState({
|
||||
conditions: _.map(trafficUsageConditions, item => {
|
||||
return {
|
||||
...item,
|
||||
items: _.map(item.items, o => {
|
||||
if (o.conditionType === "SELECT" && o.domkey[0] === "taxAgentId") {
|
||||
return {
|
||||
...o,
|
||||
options: [
|
||||
{ key: "", showname: getLabel(111, "全部(个税扣缴义务人)") },
|
||||
..._.map(data, (i) => ({ key: i.id, showname: i.content }))
|
||||
]
|
||||
};
|
||||
} else if (o.conditionType === "SELECT" && o.domkey[0] !== "taxAgentId") {
|
||||
return {
|
||||
...o,
|
||||
options: _.map(o.options, it => ({ ...it, showname: getLabel(it.lanId, it.showname) }))
|
||||
};
|
||||
}
|
||||
return { ...o };
|
||||
})
|
||||
};
|
||||
})
|
||||
}, () => {
|
||||
form.initFormFields(this.state.conditions);
|
||||
form.updateFields({
|
||||
["startDate__endDate"]: {
|
||||
value: [moment().startOf("month").format("YYYY-MM-DD"), moment().format("YYYY-MM-DD")]
|
||||
}
|
||||
});
|
||||
this.apiflowRecordList();
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
apiflowRecordList = () => {
|
||||
const { pageInfo } = this.state;
|
||||
const { intelligentStore: { form } } = this.props;
|
||||
const payload = { ...form.getFormParams(), ...pageInfo };
|
||||
this.setState({ loading: true });
|
||||
apiflowRecordList(payload).then(({ status, data }) => {
|
||||
this.setState({ loading: false });
|
||||
if (status) {
|
||||
const { columns, list: dataSource, pageNum: current, pageSize, total } = data;
|
||||
this.setState({
|
||||
dataSource, pageInfo: { ...pageInfo, current, pageSize, total },
|
||||
columns: _.map(columns, item => {
|
||||
const { dataIndex } = item;
|
||||
let width = "";
|
||||
switch (dataIndex) {
|
||||
case "indexNum":
|
||||
case "taxAgentName":
|
||||
case "employeeName":
|
||||
case "businessTypeName":
|
||||
case "creator":
|
||||
case "result":
|
||||
width = "10%";
|
||||
break;
|
||||
case "idCardNo":
|
||||
width = "20%";
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
return { ...item, width };
|
||||
})
|
||||
});
|
||||
}
|
||||
}).catch(() => this.setState({ loading: false }));
|
||||
};
|
||||
|
||||
render() {
|
||||
const { intelligentStore: { form } } = this.props;
|
||||
const { conditions, loading, pageInfo, dataSource, columns } = this.state;
|
||||
const pagination = {
|
||||
...pageInfo,
|
||||
showTotal: total => `${getLabel(18609, "共")} ${total} ${getLabel(18256, "条")}`,
|
||||
showQuickJumper: true,
|
||||
showSizeChanger: true,
|
||||
pageSizeOptions: ["10", "20", "50", "100"],
|
||||
onShowSizeChange: (current, pageSize) => {
|
||||
this.setState({
|
||||
pageInfo: { ...pageInfo, current, pageSize }
|
||||
}, () => this.apiflowRecordList());
|
||||
},
|
||||
onChange: current => {
|
||||
this.setState({
|
||||
pageInfo: { ...pageInfo, current }
|
||||
}, () => this.apiflowRecordList());
|
||||
}
|
||||
};
|
||||
return (
|
||||
<div className="trafficUsageRecords-layout">
|
||||
<div className="head">{getSearchs(form, conditions, 4, false, this.apiflowRecordList)}</div>
|
||||
<WeaTable
|
||||
columns={columns} dataSource={dataSource}
|
||||
pagination={pagination} loading={loading}
|
||||
scroll={{ y: `calc(100vh - 226px)` }}
|
||||
/>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
export default TrafficUsageRecords;
|
||||
|
|
@ -0,0 +1,121 @@
|
|||
import React, { Component } from "react";
|
||||
import { inject, observer } from "mobx-react";
|
||||
import { WeaLocaleProvider, WeaReqTop } from "ecCom";
|
||||
import { Button, message, Modal } from "antd";
|
||||
import EnableSettings from "./components/enableSettings";
|
||||
import InsufficientTrafficAlert from "./components/insufficientTrafficAlert";
|
||||
import TrafficUsageRecords from "./components/trafficUsageRecords";
|
||||
import InterfaceFlowStatistics from "./components/interfaceFlowStatistics";
|
||||
import { apiflowWarnConfigSave } from "../../apis/intelligentCalculateSalarySettings";
|
||||
import "./index.less";
|
||||
import { convertToUrlString } from "../../util/url";
|
||||
|
||||
const getLabel = WeaLocaleProvider.getLabel;
|
||||
const tabs = [
|
||||
{ key: "ENABLE_SETTINGS", title: getLabel(111, "启用设置") },
|
||||
{ key: "INTERFACE_FLOW_STATISTICS", title: getLabel(111, "接口流量统计") },
|
||||
{ key: "INSUFFICIENT_TRAFFIC_ALERT", title: getLabel(111, "流量不足提醒") },
|
||||
{ key: "TRAFFIC_USAGE_RECORD", title: getLabel(111, "流量使用记录") }
|
||||
];
|
||||
|
||||
@inject("intelligentStore")
|
||||
@observer
|
||||
class Index extends Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
selectedKey: "ENABLE_SETTINGS", lastUpdateTime: "",
|
||||
loading: false, warnConfigId: ""
|
||||
};
|
||||
this.alertRef = null;
|
||||
}
|
||||
|
||||
/*
|
||||
* Author: 黎永顺
|
||||
* Description:流量不足提醒 - 基础信息保存
|
||||
* Params:
|
||||
* Date: 2023/8/29
|
||||
*/
|
||||
saveItaBaseInfo = () => {
|
||||
const { channelList, enable, threshold, remindEvent } = this.alertRef.state;
|
||||
const validateError = (enable === "1") && (_.every(channelList, o => o.channel !== "1") || _.isNil(threshold));
|
||||
if (validateError) {
|
||||
Modal.warning({
|
||||
title: getLabel(131329, "信息确认"),
|
||||
content: getLabel(518702, "必要信息不完整,红色*为必填项!")
|
||||
});
|
||||
return;
|
||||
}
|
||||
const { businessId, id } = remindEvent;
|
||||
const config = _.map(_.filter(channelList, p => p.value === "1"), o => ({ channel: o.channel, config: o.config }));
|
||||
const payload = {
|
||||
id, businessId, threshold,
|
||||
enable: enable === "1",
|
||||
config: JSON.stringify(config)
|
||||
};
|
||||
this.setState({ loading: true });
|
||||
apiflowWarnConfigSave(payload).then(({ status, data, errormsg }) => {
|
||||
this.setState({ loading: false });
|
||||
if (status) {
|
||||
message.success(getLabel(22619, "保存成功!"));
|
||||
this.setState({ warnConfigId: data });
|
||||
payload.enable && this.alertRef.apiflowWarnReceiverList();
|
||||
} else {
|
||||
message.error(errormsg);
|
||||
}
|
||||
}).catch(() => this.setState({ loading: false }));
|
||||
};
|
||||
renderChildren = () => {
|
||||
const { selectedKey, warnConfigId } = this.state;
|
||||
let CurrentDom = null;
|
||||
switch (selectedKey) {
|
||||
case "ENABLE_SETTINGS":
|
||||
CurrentDom = <EnableSettings/>;
|
||||
break;
|
||||
case "INTERFACE_FLOW_STATISTICS":
|
||||
CurrentDom =
|
||||
<InterfaceFlowStatistics updateTime={(data) => this.setState({ lastUpdateTime: data.lastUpdateTime })}/>;
|
||||
break;
|
||||
case "INSUFFICIENT_TRAFFIC_ALERT":
|
||||
CurrentDom = <InsufficientTrafficAlert ref={dom => this.alertRef = dom} warnConfigId={warnConfigId}/>;
|
||||
break;
|
||||
case "TRAFFIC_USAGE_RECORD":
|
||||
CurrentDom = <TrafficUsageRecords/>;
|
||||
break;
|
||||
default:
|
||||
CurrentDom = null;
|
||||
break;
|
||||
}
|
||||
return CurrentDom;
|
||||
};
|
||||
handleExport = () => {
|
||||
const { intelligentStore: { form } } = this.props;
|
||||
window.open(`${window.ecologyContentPath || ""}/api/bs/hrmsalary/taxdeclaration/apiflow/record/export?${convertToUrlString(form.getFormParams())}`, "_blank");
|
||||
};
|
||||
|
||||
render() {
|
||||
const { selectedKey, lastUpdateTime, loading } = this.state;
|
||||
const buttons = selectedKey === "INSUFFICIENT_TRAFFIC_ALERT" ?
|
||||
[<Button type="primary" onClick={this.saveItaBaseInfo} loading={loading}>{getLabel(537558, "保存")}</Button>] :
|
||||
selectedKey === "TRAFFIC_USAGE_RECORD" ?
|
||||
[<Button type="primary" onClick={this.handleExport}>{getLabel(17416, "导出")}</Button>] :
|
||||
selectedKey === "INTERFACE_FLOW_STATISTICS" ? [
|
||||
<span className="statistic-time">
|
||||
<span className="label">{getLabel(111, "最后统计时间:")}</span>
|
||||
<span className="value">{lastUpdateTime}</span>
|
||||
</span>
|
||||
] : [];
|
||||
return (
|
||||
<WeaReqTop
|
||||
title={getLabel(111, "智能算薪")} selectedKey={selectedKey}
|
||||
icon={<i className="icon-coms-fa"/>} iconBgcolor="#F14A2D"
|
||||
tabDatas={tabs} onChange={selectedKey => this.setState({ selectedKey })}
|
||||
buttons={buttons} className="intelligentSetting-layout"
|
||||
>
|
||||
<div style={{ height: "100%", background: "#f6f6f6", padding: 16 }}>{this.renderChildren()}</div>
|
||||
</WeaReqTop>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
export default Index;
|
||||
|
|
@ -0,0 +1,224 @@
|
|||
.intelligentSetting-layout {
|
||||
.wea-new-top-req-title > div:last-child {
|
||||
right: 16px !important;
|
||||
}
|
||||
|
||||
.statistic-time {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: flex-end;
|
||||
font-size: 12px;
|
||||
}
|
||||
|
||||
.space {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
|
||||
.mr10 {
|
||||
margin-right: 10px;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.enable-settings {
|
||||
.swith-area, .userinfo {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
padding: 10px 16px;
|
||||
background-color: #fff;
|
||||
box-sizing: border-box;
|
||||
height: 80px;
|
||||
border: 2px solid #e5e5e5;
|
||||
border-left-color: #5d9cec;
|
||||
|
||||
.left {
|
||||
padding: 10px 0;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: space-around;
|
||||
|
||||
.title {
|
||||
font-size: 14px;
|
||||
margin-bottom: 4px;
|
||||
}
|
||||
|
||||
.info {
|
||||
font-size: 12px;
|
||||
color: #999;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.userinfo {
|
||||
margin-top: 16px;
|
||||
|
||||
.left {
|
||||
flex: 1 !important;
|
||||
|
||||
.wea-search-group, .wea-form-cell {
|
||||
padding: 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.insufficientAlertWrapper {
|
||||
background: #fff;
|
||||
padding: 0;
|
||||
border: 1px solid #f2f2f2;
|
||||
border-bottom: none;
|
||||
|
||||
.flex {
|
||||
display: flex;
|
||||
}
|
||||
|
||||
.items-center {
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.wea-content {
|
||||
padding: 0;
|
||||
|
||||
.wea-form-item {
|
||||
padding: 5px 12px;
|
||||
border-bottom: 1px solid #f2f2f2;
|
||||
}
|
||||
}
|
||||
|
||||
.threshold {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
|
||||
.before {
|
||||
margin-right: 6px;
|
||||
}
|
||||
|
||||
.after {
|
||||
margin-left: 16px;
|
||||
margin-right: 16px;
|
||||
}
|
||||
|
||||
.tip {
|
||||
display: inline-block;
|
||||
color: #999;
|
||||
padding: 6px 0;
|
||||
}
|
||||
}
|
||||
|
||||
.channel-list {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
|
||||
& > .channel-item:not(:first-child) {
|
||||
margin-left: 16px;
|
||||
}
|
||||
|
||||
.channel-item {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
min-height: 30px;
|
||||
}
|
||||
|
||||
.icon-coms-Flow-setting {
|
||||
font-size: 16px;
|
||||
cursor: pointer;
|
||||
margin-top: 5px;
|
||||
}
|
||||
}
|
||||
|
||||
.table {
|
||||
.title {
|
||||
height: 40px;
|
||||
justify-content: space-between;
|
||||
background: #f6f6f6;
|
||||
|
||||
.titleLeft {
|
||||
font-size: 14px;
|
||||
color: #111;
|
||||
padding: 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.trafficUsageRecords-layout {
|
||||
height: 100%;
|
||||
box-sizing: border-box;
|
||||
|
||||
.head {
|
||||
margin-bottom: 16px;
|
||||
|
||||
.wea-search-group {
|
||||
width: 80%;
|
||||
}
|
||||
|
||||
.wea-search-group, .wea-content, .wea-form-cell, .wea-form-item {
|
||||
padding: 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.statisticsInfo-layout {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
|
||||
.static-data {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-around;
|
||||
height: 80px;
|
||||
background-color: #fff;
|
||||
border: 2px solid #e5e5e5;
|
||||
|
||||
.item {
|
||||
display: flex;
|
||||
|
||||
.left {
|
||||
width: 65px;
|
||||
height: 65px;
|
||||
|
||||
img {
|
||||
width: 100%;
|
||||
height: 100%
|
||||
}
|
||||
}
|
||||
|
||||
.right {
|
||||
margin-left: 8px;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: center;
|
||||
|
||||
.data {
|
||||
color: #111;
|
||||
font-size: 14px;
|
||||
}
|
||||
|
||||
.title {
|
||||
margin-top: 8px;
|
||||
color: #999;
|
||||
font-size: 14px;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.detail-area {
|
||||
margin-top: 8px;
|
||||
|
||||
.title {
|
||||
height: 40px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
|
||||
.text {
|
||||
font-size: 14px;
|
||||
color: #111;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,120 @@
|
|||
/*
|
||||
* Author: 黎永顺
|
||||
* name: 个税对接-累计字段对应
|
||||
* Description:
|
||||
* Date: 2023/8/17
|
||||
*/
|
||||
import React, { Component } from "react";
|
||||
import { WeaLocaleProvider, WeaSearchGroup, WeaTab } from "ecCom";
|
||||
import LedgerFieldsItemPopver from "./ledgerFieldsItemPopver";
|
||||
import { addupruleGetForm } from "../../../apis/ledger";
|
||||
import LedgerFieldsTable from "./ledgerFieldsTable";
|
||||
|
||||
const { getLabel } = WeaLocaleProvider;
|
||||
|
||||
class CumulativeFields extends Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
selectedKey: "", tabs: [],
|
||||
addupruleFields: []
|
||||
};
|
||||
}
|
||||
|
||||
componentDidMount() {
|
||||
this.taxreportruleGetForm();
|
||||
}
|
||||
|
||||
taxreportruleGetForm = () => {
|
||||
const { editId, saveSalarySobId } = this.props;
|
||||
addupruleGetForm({ id: editId || saveSalarySobId }).then(({ status, data }) => {
|
||||
if (status && !_.isEmpty(data)) {
|
||||
this.setState({
|
||||
tabs: _.map(data, it => ({ viewcondition: it.incomeCategoryId, title: it.incomeCategoryName })),
|
||||
selectedKey: _.take(data)[0].incomeCategoryId,
|
||||
addupruleFields: data
|
||||
}, () => this.props.onSetAdduprule(this.state.addupruleFields, this.state.selectedKey));
|
||||
}
|
||||
});
|
||||
};
|
||||
handleChangeSwitch = (visible, id) => {
|
||||
const { addupruleFields, selectedKey } = this.state;
|
||||
this.setState({
|
||||
addupruleFields: _.map(addupruleFields, it => {
|
||||
if (it.incomeCategoryId === selectedKey) {
|
||||
return {
|
||||
...it,
|
||||
addUpRules: _.map(it.addUpRules, child => {
|
||||
if (child.id === id) {
|
||||
return { ...child, visible };
|
||||
}
|
||||
return { ...child, visible: false };
|
||||
})
|
||||
};
|
||||
}
|
||||
return { ...it };
|
||||
})
|
||||
}, () => this.props.onSetAdduprule(this.state.addupruleFields, this.state.selectedKey));
|
||||
};
|
||||
handleChangeAddupruleFieldsItem = (salaryItem, recordRuleId) => {
|
||||
const { addupruleFields, selectedKey } = this.state;
|
||||
this.setState({
|
||||
addupruleFields: _.map(addupruleFields, it => {
|
||||
if (it.incomeCategoryId === selectedKey) {
|
||||
return {
|
||||
...it,
|
||||
addUpRules: _.map(it.addUpRules, child => {
|
||||
if (child.id === recordRuleId) {
|
||||
return { ...child, visible: false, salaryItem };
|
||||
}
|
||||
return { ...child, visible: false };
|
||||
})
|
||||
};
|
||||
}
|
||||
return { ...it };
|
||||
})
|
||||
}, () => this.props.onSetAdduprule(this.state.addupruleFields, this.state.selectedKey));
|
||||
};
|
||||
|
||||
render() {
|
||||
const { editId, saveSalarySobId } = this.props;
|
||||
const { selectedKey, tabs, addupruleFields } = this.state;
|
||||
const dataSource = _.takeWhile(addupruleFields, it => it.incomeCategoryId === selectedKey);
|
||||
return (
|
||||
<WeaSearchGroup
|
||||
className="incomeWrapper" showGroup needTigger={false}
|
||||
title={
|
||||
<div className="incomeTitleContail">
|
||||
<WeaTab
|
||||
datas={tabs} keyParam="viewcondition" selectedKey={selectedKey}
|
||||
/>
|
||||
</div>
|
||||
}
|
||||
>
|
||||
<LedgerFieldsTable
|
||||
columns={[
|
||||
{
|
||||
title: getLabel(111, "往期累计情况字段"),
|
||||
width: "50%",
|
||||
dataIndex: "addUpColumnName"
|
||||
},
|
||||
{
|
||||
title: getLabel(111, "对应本账套薪资项目"),
|
||||
width: "50%",
|
||||
dataIndex: "salaryItem",
|
||||
render: (_, record) => (
|
||||
<LedgerFieldsItemPopver salarySobId={editId || saveSalarySobId} record={record}
|
||||
onChangeSwitch={this.handleChangeSwitch}
|
||||
onChange={this.handleChangeAddupruleFieldsItem}
|
||||
/>
|
||||
)
|
||||
}
|
||||
]}
|
||||
dataSource={dataSource}
|
||||
/>
|
||||
</WeaSearchGroup>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
export default CumulativeFields;
|
||||
|
|
@ -0,0 +1,139 @@
|
|||
/*
|
||||
* Author: 黎永顺
|
||||
* name: 个税申报字段对应
|
||||
* Description:
|
||||
* Date: 2023/2/16
|
||||
*/
|
||||
import React, { Component } from "react";
|
||||
import { WeaHelpfulTip, WeaLocaleProvider, WeaSearchGroup, WeaTab } from "ecCom";
|
||||
import LedgerFieldsItemPopver from "./ledgerFieldsItemPopver";
|
||||
import { taxreportruleGetForm } from "../../../apis/ledger";
|
||||
import LedgerFieldsTable from "./ledgerFieldsTable";
|
||||
|
||||
const { getLabel } = WeaLocaleProvider;
|
||||
|
||||
class IncomeTaxFields extends Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
selectedKey: "", tabs: [],
|
||||
incomeTaxFields: [], keywords: ""
|
||||
};
|
||||
}
|
||||
|
||||
componentDidMount() {
|
||||
this.taxreportruleGetForm();
|
||||
}
|
||||
|
||||
taxreportruleGetForm = () => {
|
||||
const { editId, saveSalarySobId } = this.props;
|
||||
taxreportruleGetForm({ id: editId || saveSalarySobId }).then(({ status, data }) => {
|
||||
if (status && !_.isEmpty(data)) {
|
||||
this.setState({
|
||||
tabs: _.map(data, it => ({ viewcondition: it.incomeCategoryId, title: it.incomeCategoryName })),
|
||||
selectedKey: _.take(data)[0].incomeCategoryId,
|
||||
incomeTaxFields: data
|
||||
}, () => this.props.onSetTaxreportrule(this.state.incomeTaxFields, this.state.selectedKey));
|
||||
}
|
||||
});
|
||||
};
|
||||
handleChangeSwitch = (visible, id) => {
|
||||
const { incomeTaxFields, selectedKey } = this.state;
|
||||
this.setState({
|
||||
incomeTaxFields: _.map(incomeTaxFields, it => {
|
||||
if (it.incomeCategoryId === selectedKey) {
|
||||
return {
|
||||
...it,
|
||||
taxReportRules: _.map(it.taxReportRules, child => {
|
||||
if (child.id === id) {
|
||||
return { ...child, visible };
|
||||
}
|
||||
return { ...child, visible: false };
|
||||
})
|
||||
};
|
||||
}
|
||||
return { ...it };
|
||||
})
|
||||
}, () => this.props.onSetTaxreportrule(this.state.incomeTaxFields, this.state.selectedKey));
|
||||
};
|
||||
handleChangeIncomeFieldsItem = (salaryItem, recordRuleId) => {
|
||||
const { incomeTaxFields, selectedKey } = this.state;
|
||||
this.setState({
|
||||
incomeTaxFields: _.map(incomeTaxFields, it => {
|
||||
if (it.incomeCategoryId === selectedKey) {
|
||||
return {
|
||||
...it,
|
||||
taxReportRules: _.map(it.taxReportRules, child => {
|
||||
if (child.id === recordRuleId) {
|
||||
return { ...child, visible: false, salaryItem };
|
||||
}
|
||||
return { ...child, visible: false };
|
||||
})
|
||||
};
|
||||
}
|
||||
return { ...it };
|
||||
})
|
||||
}, () => {
|
||||
this.props.onSetTaxreportrule(this.state.incomeTaxFields, this.state.selectedKey);
|
||||
});
|
||||
};
|
||||
|
||||
render() {
|
||||
const { editId, saveSalarySobId } = this.props;
|
||||
const { selectedKey, tabs, incomeTaxFields, keywords } = this.state;
|
||||
const list = _.map(incomeTaxFields, it => {
|
||||
if (it.incomeCategoryId === selectedKey) {
|
||||
return {
|
||||
...it,
|
||||
taxReportRules: _.filter(it.taxReportRules, item => item.reportColumnName.indexOf(keywords) !== -1)
|
||||
};
|
||||
}
|
||||
return { ...it };
|
||||
});
|
||||
const dataSource = _.takeWhile(list, it => it.incomeCategoryId === selectedKey);
|
||||
return (
|
||||
<WeaSearchGroup
|
||||
className="incomeWrapper" showGroup needTigger={false}
|
||||
title={
|
||||
<div className="incomeTitleContail">
|
||||
<WeaTab
|
||||
datas={tabs} keyParam="viewcondition" selectedKey={selectedKey}
|
||||
searchType={["base"]} searchsBasePlaceHolder={getLabel(111, "请输入对象")}
|
||||
onSearch={val => this.setState({ keywords: val })}
|
||||
/>
|
||||
</div>
|
||||
}
|
||||
>
|
||||
<LedgerFieldsTable
|
||||
columns={[
|
||||
{
|
||||
title: <span>
|
||||
<span style={{ marginRight: 8 }}>{getLabel(111, "个税申报表字段")}</span>
|
||||
<WeaHelpfulTip
|
||||
title={getLabel(111, "若【个税申报表字段】与【对应本账套薪资项目】对应,则申报表内数据为当前账套核算数据,若【个税申报表字段】未与【对应本账套薪资项目】对应,则申报表内数据默认显示为0")}
|
||||
placement="top" width={250}
|
||||
/>
|
||||
</span>,
|
||||
width: "50%",
|
||||
dataIndex: "reportColumnName"
|
||||
},
|
||||
{
|
||||
title: getLabel(111, "对应本账套薪资项目"),
|
||||
width: "50%",
|
||||
dataIndex: "salaryItem",
|
||||
render: (_, record) => (
|
||||
<LedgerFieldsItemPopver salarySobId={editId || saveSalarySobId} record={record}
|
||||
onChangeSwitch={this.handleChangeSwitch}
|
||||
onChange={this.handleChangeIncomeFieldsItem}
|
||||
/>
|
||||
)
|
||||
}
|
||||
]}
|
||||
dataSource={dataSource}
|
||||
/>
|
||||
</WeaSearchGroup>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
export default IncomeTaxFields;
|
||||
|
|
@ -253,7 +253,6 @@
|
|||
color: #55a1f8;
|
||||
}
|
||||
|
||||
|
||||
.moveModalWrapper {
|
||||
.ant-radio-group {
|
||||
display: grid;
|
||||
|
|
@ -281,3 +280,84 @@
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
//个税申报字段对应
|
||||
.incomeWrapper {
|
||||
padding: 0;
|
||||
|
||||
.wea-content {
|
||||
padding: 10px 16px;
|
||||
}
|
||||
}
|
||||
|
||||
.income_pop_wrapper .ant-popover-inner-content {
|
||||
padding: 8px;
|
||||
}
|
||||
|
||||
.income_pop_wrapper {
|
||||
width: 180px !important;
|
||||
}
|
||||
|
||||
.income_result_wrapper {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
min-height: 80px;
|
||||
max-height: 250px;
|
||||
overflow-y: auto;
|
||||
}
|
||||
|
||||
.income_result_wrapper li {
|
||||
line-height: 30px;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.income_result_wrapper li:not(.emptyLi):hover {
|
||||
background: #e9f7ff;
|
||||
}
|
||||
|
||||
.income_result_wrapper li.emptyLi {
|
||||
text-align: center;
|
||||
|
||||
.anticon-inbox {
|
||||
color: #5d9cec;
|
||||
font-size: 24px;
|
||||
}
|
||||
}
|
||||
|
||||
.incomeSearchGroup {
|
||||
input {
|
||||
border-right: none;
|
||||
}
|
||||
|
||||
button {
|
||||
border-left: none;
|
||||
border-radius: 0;
|
||||
height: 28px;
|
||||
line-height: 28px;
|
||||
}
|
||||
}
|
||||
|
||||
.incomeDialog {
|
||||
.incomeDialogTitle {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
|
||||
.incomeDialogTitle-left {
|
||||
text-align: left;
|
||||
|
||||
.title {
|
||||
color: #111;
|
||||
font-weight: 700;
|
||||
}
|
||||
}
|
||||
|
||||
.incomeDialogTitle-right {
|
||||
text-align: right;
|
||||
}
|
||||
}
|
||||
|
||||
.incomeDialogContent {
|
||||
height: 100%;
|
||||
padding: 16px;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -85,7 +85,7 @@ class LedgerBaseSetting extends Component {
|
|||
description: "",
|
||||
canEdit: "true"
|
||||
}
|
||||
});
|
||||
}, () => this.props.onTaxableItemsChange(this.state.settingBaseInfo.taxableItems));
|
||||
};
|
||||
getLedgerBasicForm = (id) => {
|
||||
getLedgerBasicForm({ id }).then(({ status, data }) => {
|
||||
|
|
@ -103,6 +103,7 @@ class LedgerBaseSetting extends Component {
|
|||
}
|
||||
}, () => {
|
||||
this.props.onSaveParams(this.state.settingBaseInfo);
|
||||
this.props.onTaxableItemsChange(this.state.settingBaseInfo.taxableItems);
|
||||
});
|
||||
}
|
||||
});
|
||||
|
|
@ -157,6 +158,7 @@ class LedgerBaseSetting extends Component {
|
|||
}
|
||||
}, () => {
|
||||
onSaveParams(this.state.settingBaseInfo);
|
||||
this.props.onTaxableItemsChange(this.state.settingBaseInfo.taxableItems);
|
||||
});
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -0,0 +1,137 @@
|
|||
/*
|
||||
* Author: 黎永顺
|
||||
* name: 薪资账套-申报字段对应查询弹框
|
||||
* Description:
|
||||
* Date: 2023/8/16
|
||||
*/
|
||||
import React, { Component } from "react";
|
||||
import { Icon, Popover } from "antd";
|
||||
import { WeaInputSearch, WeaLocaleProvider } from "ecCom";
|
||||
import { commonBrowserData } from "../../../apis";
|
||||
import LedgerSalaryItemSelectDialog from "./ledgerSalaryItemSelectDialog";
|
||||
|
||||
const { getLabel } = WeaLocaleProvider;
|
||||
|
||||
class LedgerFieldsItemPopver extends Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
dataList: [],
|
||||
keywords: "",
|
||||
salaryItemSelectDialog: {
|
||||
visible: false, salarySobId: ""
|
||||
}
|
||||
};
|
||||
this.handleDebounce = null;
|
||||
}
|
||||
|
||||
componentWillReceiveProps(nextProps, nextContext) {
|
||||
if (nextProps.record !== this.props.record && nextProps.record.visible) {
|
||||
this.commonBrowserData(nextProps);
|
||||
} else {
|
||||
const { record } = nextProps;
|
||||
const salaryItemName = record.salaryItem[0] ? record.salaryItem[0].name : "";
|
||||
this.setState({ dataList: [], keywords: salaryItemName });
|
||||
}
|
||||
}
|
||||
|
||||
handleFocusChange = (visible) => {
|
||||
const { keywords } = this.state;
|
||||
const { record, onChangeSwitch } = this.props;
|
||||
visible && onChangeSwitch(visible, record.id);
|
||||
if (visible && keywords) {
|
||||
this.setState({ keywords: "" });
|
||||
}
|
||||
};
|
||||
handleChange = (keywords) => {
|
||||
this.setState({ keywords }, () => this.handleSearch());
|
||||
!keywords && this.props.onChange([], this.props.record.id);
|
||||
};
|
||||
commonBrowserData = (props) => {
|
||||
const { salarySobId } = props;
|
||||
const { keywords } = this.state;
|
||||
const payload = {
|
||||
type: "salaryItemBrowser",
|
||||
jsonParam: JSON.stringify({ salarySobId, key: keywords })
|
||||
};
|
||||
commonBrowserData(payload).then(({ status, data }) => {
|
||||
if (status) {
|
||||
const { list: dataList } = data;
|
||||
this.setState({ dataList });
|
||||
}
|
||||
});
|
||||
};
|
||||
handleSearch = () => {
|
||||
if (!this.handleDebounce) {
|
||||
this.handleDebounce = _.debounce(() => {
|
||||
this.commonBrowserData(this.props);
|
||||
this.handleDebounce = null;
|
||||
}, 500);
|
||||
}
|
||||
this.handleDebounce();
|
||||
};
|
||||
handleClickItem = (item) => {
|
||||
this.setState({
|
||||
keywords: item.name
|
||||
}, () => this.props.onChange([item], this.props.record.id));
|
||||
};
|
||||
|
||||
render() {
|
||||
const { keywords, dataList, salaryItemSelectDialog } = this.state;
|
||||
const { record, onChangeSwitch, salarySobId } = this.props;
|
||||
return (
|
||||
<React.Fragment>
|
||||
<Popover content={
|
||||
<ul className="income_result_wrapper">
|
||||
{
|
||||
!_.isEmpty(dataList) ?
|
||||
_.map(dataList, it => (<li key={it.key} onClick={() => this.handleClickItem(it)}>{it.name}</li>)) :
|
||||
<li className="emptyLi">
|
||||
<Icon type="inbox"/>
|
||||
<p className="empty-title">{getLabel(83553, "暂无数据")}</p>
|
||||
</li>
|
||||
}
|
||||
</ul>
|
||||
} trigger="click" placement="right" overlayClassName="income_pop_wrapper"
|
||||
visible={record.visible}
|
||||
onVisibleChange={(visible) => onChangeSwitch(visible, record.id)}
|
||||
>
|
||||
<WeaInputSearch
|
||||
style={{ width: 200 }} placeholder={getLabel(18214, "请选择")}
|
||||
onFocusChange={this.handleFocusChange}
|
||||
value={keywords} onSearchChange={this.handleChange}
|
||||
onSearch={() => this.setState({
|
||||
salaryItemSelectDialog: {
|
||||
...salaryItemSelectDialog,
|
||||
visible: true,
|
||||
salarySobId
|
||||
}
|
||||
})}
|
||||
/>
|
||||
</Popover>
|
||||
<LedgerSalaryItemSelectDialog
|
||||
{...salaryItemSelectDialog}
|
||||
handleClickItem={this.handleClickItem}
|
||||
handleClearSalaryItem={() => {
|
||||
this.setState({
|
||||
salaryItemSelectDialog: {
|
||||
...salaryItemSelectDialog,
|
||||
visible: false,
|
||||
salarySobId: ""
|
||||
}
|
||||
}, () => this.props.onChange([], this.props.record.id));
|
||||
}}
|
||||
onCancel={() => this.setState({
|
||||
salaryItemSelectDialog: {
|
||||
...salaryItemSelectDialog,
|
||||
visible: false,
|
||||
salarySobId: ""
|
||||
}
|
||||
})}
|
||||
/>
|
||||
</React.Fragment>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
export default LedgerFieldsItemPopver;
|
||||
|
|
@ -0,0 +1,35 @@
|
|||
/*
|
||||
* Author: 黎永顺
|
||||
* name: 个税申报-字段对应查看列表
|
||||
* Description:
|
||||
* Date: 2023/8/16
|
||||
*/
|
||||
import React, { Component } from "react";
|
||||
import { WeaTable } from "ecCom";
|
||||
|
||||
class LedgerFieldsTable extends Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
dataSource: []
|
||||
};
|
||||
}
|
||||
|
||||
componentWillReceiveProps(nextProps, nextContext) {
|
||||
if (nextProps.dataSource !== this.props.dataSource && !_.isEmpty(nextProps.dataSource)) {
|
||||
this.setState({
|
||||
dataSource: _.take(nextProps.dataSource)[0].taxReportRules || _.take(nextProps.dataSource)[0].addUpRules
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
render() {
|
||||
const { columns } = this.props;
|
||||
const { dataSource } = this.state;
|
||||
return (
|
||||
<WeaTable dataSource={dataSource} columns={columns} pagination={false} bordered/>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
export default LedgerFieldsTable;
|
||||
|
|
@ -23,7 +23,7 @@ class LedgerSalaryItemEditSlide extends Component {
|
|||
const key = Object.keys(params)[0];
|
||||
this.props.onUpdateRequest(request, key);
|
||||
};
|
||||
handleShowFormal = () => this.props.onEditFormnul();
|
||||
handleShowFormal = (salaryItemName) => this.props.onEditFormnul(salaryItemName);
|
||||
|
||||
render() {
|
||||
return (
|
||||
|
|
|
|||
|
|
@ -0,0 +1,119 @@
|
|||
/*
|
||||
* Author: 黎永顺
|
||||
* name: 个税对应字段-薪资项目选择弹框
|
||||
* Description:
|
||||
* Date: 2023/8/17
|
||||
*/
|
||||
import React, { Component } from "react";
|
||||
import { WeaDialog, WeaInputSearch, WeaLocaleProvider } from "ecCom";
|
||||
import { Button, Col, Row, Table } from "antd";
|
||||
import { commonBrowserData } from "../../../apis";
|
||||
|
||||
const { getLabel } = WeaLocaleProvider;
|
||||
|
||||
class LedgerSalaryItemSelectDialog extends Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
pageInfo: { current: 1, pageSize: 20, total: 0 },
|
||||
loading: false, columns: [], dataSource: [],
|
||||
keywords: ""
|
||||
};
|
||||
}
|
||||
|
||||
componentWillReceiveProps(nextProps, nextContext) {
|
||||
if (nextProps.visible !== this.props.visible && nextProps.visible) this.commonBrowserData(nextProps);
|
||||
}
|
||||
|
||||
commonBrowserData = (props) => {
|
||||
const { salarySobId } = props;
|
||||
const { keywords, pageInfo } = this.state;
|
||||
const payload = {
|
||||
type: "salaryItemBrowser",
|
||||
jsonParam: JSON.stringify({ salarySobId, key: keywords }),
|
||||
...pageInfo
|
||||
};
|
||||
this.setState({ loading: true });
|
||||
commonBrowserData(payload).then(({ status, data }) => {
|
||||
this.setState({ loading: false });
|
||||
if (status) {
|
||||
const { list: dataSource, columns, pageNum: current, pageSize, total } = data;
|
||||
this.setState({
|
||||
dataSource, columns,
|
||||
pageInfo: { ...pageInfo, current, pageSize, total }
|
||||
});
|
||||
}
|
||||
}).catch(() => this.setState({ loading: false }));
|
||||
};
|
||||
handleRowClick = (record) => {
|
||||
this.props.onCancel();
|
||||
this.props.handleClickItem(record);
|
||||
};
|
||||
|
||||
render() {
|
||||
const { loading, columns, dataSource, pageInfo, keywords } = this.state;
|
||||
const pagination = {
|
||||
...pageInfo,
|
||||
showTotal: total => `${getLabel(18609, "共")} ${total} ${getLabel(18256, "条")}`,
|
||||
showQuickJumper: true,
|
||||
showSizeChanger: true,
|
||||
pageSizeOptions: ["20", "50", "100"],
|
||||
onShowSizeChange: (current, pageSize) => {
|
||||
this.setState({
|
||||
pageInfo: { ...pageInfo, current, pageSize }
|
||||
}, () => this.commonBrowserData(this.props));
|
||||
},
|
||||
onChange: current => {
|
||||
this.setState({
|
||||
pageInfo: { ...pageInfo, current }
|
||||
}, () => this.commonBrowserData(this.props));
|
||||
}
|
||||
};
|
||||
return (
|
||||
<WeaDialog
|
||||
{...this.props} hasScroll className="incomeDialog" initLoadCss
|
||||
buttons={[
|
||||
<Button type="primary" onClick={this.props.handleClearSalaryItem}>{getLabel(111, "清除")}</Button>
|
||||
]}
|
||||
title={(<Row className="incomeDialogTitle" type="flex">
|
||||
<Col span={12} className="incomeDialogTitle-left">
|
||||
<span className="title">{getLabel(543598, "请选择薪资项目")}</span>
|
||||
</Col>
|
||||
<Col span={12} className="incomeDialogTitle-right">
|
||||
<Button type="ghost" icon="reload" title={getLabel(111, "刷新")} onClick={() => {
|
||||
this.setState({
|
||||
keywords: "",
|
||||
pageInfo: { ...pageInfo, current: 1 }
|
||||
}, () => this.commonBrowserData(this.props));
|
||||
}}/>
|
||||
</Col>
|
||||
</Row>)}
|
||||
style={{
|
||||
width: 850,
|
||||
height: 606.6,
|
||||
minHeight: 200,
|
||||
minWidth: 380,
|
||||
maxHeight: "90%",
|
||||
maxWidth: "90%",
|
||||
overflow: "hidden",
|
||||
transform: "translate(0px, 0px)"
|
||||
}}
|
||||
>
|
||||
<div className="incomeDialogContent">
|
||||
<WeaInputSearch
|
||||
style={{ width: "100%", margin: "6px 0" }} placeholder={getLabel(500351, "请输入关键字")}
|
||||
value={keywords} onChange={val => this.setState({ keywords: val })}
|
||||
onSearch={() => this.commonBrowserData(this.props)}
|
||||
/>
|
||||
<Table
|
||||
showHeader={false} dataSource={dataSource}
|
||||
loading={loading} pagination={pagination}
|
||||
columns={columns} onRowClick={this.handleRowClick}
|
||||
/>
|
||||
</div>
|
||||
</WeaDialog>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
export default LedgerSalaryItemSelectDialog;
|
||||
|
|
@ -28,7 +28,8 @@ class LedgerSalaryItemTable extends Component {
|
|||
visible: false,
|
||||
formulaId: "",
|
||||
valueType: "",
|
||||
dataType: ""
|
||||
dataType: "",
|
||||
name: ""
|
||||
}
|
||||
};
|
||||
}
|
||||
|
|
@ -188,13 +189,13 @@ class LedgerSalaryItemTable extends Component {
|
|||
originSqlContent: ((valueType.toString() === "2" && (!originFormulaContent || originFormulaContent === " ")) || (valueType.toString() === "1") || (valueType.toString() === "2" && originFormulaContent)) ? " " : originSqlContent
|
||||
}, salaryItemId);
|
||||
};
|
||||
handleEditFormnul = () => {
|
||||
handleEditFormnul = (salaryItemName) => {
|
||||
const { salaryItemPayload, editFormulModal } = this.state;
|
||||
const { record } = salaryItemPayload;
|
||||
const { valueType, formulaId, dataType, originFormulaContent, originSqlContent } = record;
|
||||
this.setState({
|
||||
editFormulModal: {
|
||||
...editFormulModal, visible: true, valueType, dataType,
|
||||
...editFormulModal, visible: true, valueType, dataType, name: salaryItemName,
|
||||
formulaId: ((valueType.toString() === "2" && (originFormulaContent || originFormulaContent !== " ")) || valueType.toString() === "3" && (originSqlContent || originSqlContent === " ")) ? formulaId : ""
|
||||
}
|
||||
});
|
||||
|
|
@ -205,7 +206,7 @@ class LedgerSalaryItemTable extends Component {
|
|||
editFormulModal: {
|
||||
...editFormulModal,
|
||||
visible: false,
|
||||
formulaId: "",
|
||||
formulaId: "", name: "",
|
||||
valueType: "", dataType: ""
|
||||
}
|
||||
});
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@
|
|||
*/
|
||||
import React, { Component } from "react";
|
||||
import { inject, observer } from "mobx-react";
|
||||
import { WeaSlideModal, WeaSteps } from "ecCom";
|
||||
import { WeaLocaleProvider, WeaSlideModal, WeaSteps } from "ecCom";
|
||||
import { Button, message, Modal } from "antd";
|
||||
import SlideModalTitle from "../../../components/slideModalTitle";
|
||||
import LedgerBaseSetting from "./ledgerBaseSetting";
|
||||
|
|
@ -14,17 +14,19 @@ import LedgerAssociatedPersonnel from "./ledgerAssociatedPersonnel";
|
|||
import LedgerSalaryAdjustmentRules from "./ledgerSalaryAdjustmentRules";
|
||||
import LedgerBackCalculatedSalaryItem from "./ledgerBackCalculatedSalaryItem";
|
||||
import LedgerSalaryItem from "./ledgerSalaryItem";
|
||||
import { saveAdjustmentRule, saveLedgerBasic, saveLedgerItem } from "../../../apis/ledger";
|
||||
import IncomeTaxFields from "./incomeTaxFields";
|
||||
import CumulativeFields from "./cumulativeFields";
|
||||
import {
|
||||
addupruleSave,
|
||||
saveAdjustmentRule,
|
||||
saveLedgerBasic,
|
||||
saveLedgerItem,
|
||||
taxreportruleSave
|
||||
} from "../../../apis/ledger";
|
||||
import "./index.less";
|
||||
|
||||
const { getLabel } = WeaLocaleProvider;
|
||||
const Step = WeaSteps.Step;
|
||||
const tabs = [
|
||||
{ key: 0, title: "基础设置" },
|
||||
{ key: 1, title: "关联人员" },
|
||||
{ key: 2, title: "薪资项目" },
|
||||
{ key: 3, title: "回算薪资项目" },
|
||||
{ key: 4, title: "调薪计薪规则" }
|
||||
];
|
||||
|
||||
@inject("taxAgentStore", "ledgerStore")
|
||||
@observer
|
||||
|
|
@ -37,7 +39,10 @@ class LedgerSlide extends Component {
|
|||
baseSettingInfo: {},
|
||||
adjustRules: [],
|
||||
empFields: [], itemGroups: [],
|
||||
saveSalarySobId: ""
|
||||
incomeTaxFields: [], incomeTaxKeys: "", //个税申报字段对应
|
||||
addupruleFields: [], addupruleKeys: "", //累计字段对应
|
||||
saveSalarySobId: "",
|
||||
taxableItems: "" //薪资类型 1||489 对应显示个税设置-累计字段对应
|
||||
};
|
||||
}
|
||||
|
||||
|
|
@ -143,6 +148,115 @@ class LedgerSlide extends Component {
|
|||
}
|
||||
}).catch(() => this.setState({ loading: false }));
|
||||
};
|
||||
/*
|
||||
* Author: 黎永顺
|
||||
* Description:个税申报字段对应-保存
|
||||
* Params:
|
||||
* Date: 2023/8/16
|
||||
*/
|
||||
taxreportruleSave = () => {
|
||||
const { taxableItems, incomeTaxKeys, incomeTaxFields, saveSalarySobId } = this.state;
|
||||
const { editId } = this.props;
|
||||
if ((!editId && taxableItems && taxableItems.toString() !== "1" && taxableItems.toString() !== "489")) {
|
||||
this.saveLedgerAdjustRule();
|
||||
} else {
|
||||
const payload = {
|
||||
salarySobId: editId || saveSalarySobId,
|
||||
incomeCategoryParams: _.map(incomeTaxFields, it => {
|
||||
if (it.incomeCategoryId === incomeTaxKeys) {
|
||||
return {
|
||||
incomeCategory: it.incomeCategoryId,
|
||||
taxReportRuleParams: _.map(it.taxReportRules, child => {
|
||||
return {
|
||||
reportColumnDataIndex: child.reportColumnDataIndex,
|
||||
salaryItemId: _.map(child.salaryItem, o => o.id).join(",")
|
||||
};
|
||||
})
|
||||
};
|
||||
}
|
||||
return {
|
||||
incomeCategory: it.incomeCategoryId,
|
||||
taxReportRuleParams: []
|
||||
};
|
||||
})
|
||||
};
|
||||
this.saveTaxreportrule(payload);
|
||||
}
|
||||
};
|
||||
saveTaxreportrule = (payload) => {
|
||||
this.setState({ loading: true });
|
||||
taxreportruleSave(payload).then(({ status, errormsg }) => {
|
||||
this.setState({ loading: false });
|
||||
if (status) {
|
||||
message.success(getLabel(22619, "保存成功!"));
|
||||
} else {
|
||||
message.error(errormsg || getLabel(22620, "保存失败!"));
|
||||
}
|
||||
}).catch(() => this.setState({ loading: false }));
|
||||
};
|
||||
/*
|
||||
* Author: 黎永顺
|
||||
* Description:保存薪资账套下的累计字段对应关系
|
||||
* Params:
|
||||
* Date: 2023/8/17
|
||||
*/
|
||||
addupruleSave = () => {
|
||||
const { taxableItems, incomeTaxFields, incomeTaxKeys, addupruleFields, addupruleKeys, saveSalarySobId } = this.state;
|
||||
const { editId } = this.props;
|
||||
if ((!editId && taxableItems && taxableItems.toString() !== "1" && taxableItems.toString() !== "489")) {
|
||||
const payload = {
|
||||
salarySobId: editId || saveSalarySobId,
|
||||
incomeCategoryParams: _.map(incomeTaxFields, it => {
|
||||
if (it.incomeCategoryId === incomeTaxKeys) {
|
||||
return {
|
||||
incomeCategory: it.incomeCategoryId,
|
||||
taxReportRuleParams: _.map(it.taxReportRules, child => {
|
||||
return {
|
||||
reportColumnDataIndex: child.reportColumnDataIndex,
|
||||
salaryItemId: _.map(child.salaryItem, o => o.id).join(",")
|
||||
};
|
||||
})
|
||||
};
|
||||
}
|
||||
return {
|
||||
incomeCategory: it.incomeCategoryId,
|
||||
taxReportRuleParams: []
|
||||
};
|
||||
})
|
||||
};
|
||||
this.saveTaxreportrule(payload);
|
||||
} else {
|
||||
const payload = {
|
||||
salarySobId: editId || saveSalarySobId,
|
||||
incomeCategoryParams: _.map(addupruleFields, it => {
|
||||
if (it.incomeCategoryId === addupruleKeys) {
|
||||
return {
|
||||
incomeCategory: it.incomeCategoryId,
|
||||
addUpRuleParams: _.map(it.addUpRules, child => {
|
||||
return {
|
||||
addUpColumnDataIndex: child.addUpColumnDataIndex,
|
||||
salaryItemId: _.map(child.salaryItem, o => o.id).join(",")
|
||||
};
|
||||
})
|
||||
};
|
||||
}
|
||||
return {
|
||||
incomeCategory: it.incomeCategoryId,
|
||||
taxReportRuleParams: []
|
||||
};
|
||||
})
|
||||
};
|
||||
this.setState({ loading: true });
|
||||
addupruleSave(payload).then(({ status, errormsg }) => {
|
||||
this.setState({ loading: false });
|
||||
if (status) {
|
||||
message.success(getLabel(22619, "保存成功!"));
|
||||
} else {
|
||||
message.error(errormsg || getLabel(22620, "保存失败!"));
|
||||
}
|
||||
}).catch(() => this.setState({ loading: false }));
|
||||
}
|
||||
};
|
||||
handleChangeSlideTab = (current) => {
|
||||
this.setState({ current: Number(current) });
|
||||
};
|
||||
|
|
@ -168,11 +282,15 @@ class LedgerSlide extends Component {
|
|||
this.setState({ empFields, itemGroups });
|
||||
};
|
||||
renderChildren = () => {
|
||||
const { current, saveSalarySobId } = this.state;
|
||||
const { editId } = this.props;
|
||||
const { current, saveSalarySobId, taxableItems } = this.state;
|
||||
let CurrentDom = null;
|
||||
switch (current) {
|
||||
case 0:
|
||||
CurrentDom = <LedgerBaseSetting {...this.props} onSaveParams={this.handleChangeSaveParams}/>;
|
||||
CurrentDom = <LedgerBaseSetting
|
||||
{...this.props} onSaveParams={this.handleChangeSaveParams}
|
||||
onTaxableItemsChange={(val) => this.setState({ taxableItems: val })}
|
||||
/>;
|
||||
break;
|
||||
case 1:
|
||||
CurrentDom = <LedgerAssociatedPersonnel {...this.props} saveSalarySobId={saveSalarySobId}/>;
|
||||
|
|
@ -185,6 +303,29 @@ class LedgerSlide extends Component {
|
|||
CurrentDom = <LedgerBackCalculatedSalaryItem {...this.props} saveSalarySobId={saveSalarySobId}/>;
|
||||
break;
|
||||
case 4:
|
||||
CurrentDom = (!editId && taxableItems && taxableItems.toString() !== "1" && taxableItems.toString() !== "489") ?
|
||||
<IncomeTaxFields {...this.props} saveSalarySobId={saveSalarySobId}
|
||||
onSetTaxreportrule={(incomeTaxFields, selectedKey) => this.setState({
|
||||
incomeTaxFields,
|
||||
incomeTaxKeys: selectedKey
|
||||
})}/> :
|
||||
<CumulativeFields {...this.props} saveSalarySobId={saveSalarySobId}
|
||||
onSetAdduprule={(addupruleFields, selectedKey) => this.setState({
|
||||
addupruleFields,
|
||||
addupruleKeys: selectedKey
|
||||
})}/>;
|
||||
break;
|
||||
case 5:
|
||||
CurrentDom = (!editId && taxableItems && taxableItems.toString() !== "1" && taxableItems.toString() !== "489") ?
|
||||
<LedgerSalaryAdjustmentRules {...this.props} saveSalarySobId={saveSalarySobId}
|
||||
onSaveParams={(adjustRules) => this.setState({ adjustRules })}/> :
|
||||
<IncomeTaxFields {...this.props} saveSalarySobId={saveSalarySobId}
|
||||
onSetTaxreportrule={(incomeTaxFields, selectedKey) => this.setState({
|
||||
incomeTaxFields,
|
||||
incomeTaxKeys: selectedKey
|
||||
})}/>;
|
||||
break;
|
||||
case 6:
|
||||
CurrentDom =
|
||||
<LedgerSalaryAdjustmentRules {...this.props} saveSalarySobId={saveSalarySobId}
|
||||
onSaveParams={(adjustRules) => this.setState({ adjustRules })}/>;
|
||||
|
|
@ -197,7 +338,7 @@ class LedgerSlide extends Component {
|
|||
};
|
||||
renderCustomOperate = () => {
|
||||
const { taxAgentStore: { showOperateBtn }, editId } = this.props;
|
||||
const { current, loading } = this.state;
|
||||
const { current, loading, taxableItems } = this.state;
|
||||
let CurrentDom = [];
|
||||
//管理员操作权限
|
||||
if (showOperateBtn) {
|
||||
|
|
@ -244,6 +385,44 @@ class LedgerSlide extends Component {
|
|||
] : [];
|
||||
break;
|
||||
case 4:
|
||||
CurrentDom = !editId ?
|
||||
[
|
||||
<Button type="ghost" onClick={this.handleClose}>完成,跳过所有步骤</Button>,
|
||||
<Button type="ghost" onClick={() => this.setState({ current: current - 1 })}>上一步</Button>,
|
||||
<Button
|
||||
type="primary"
|
||||
loading={loading}
|
||||
onClick={() => {
|
||||
this.setState({ current: current + 1 }, () => this.addupruleSave());
|
||||
}}
|
||||
>保存并进入下一步</Button>
|
||||
] : [
|
||||
<Button type="primary" loading={loading} onClick={this.addupruleSave}>保存</Button>
|
||||
];
|
||||
break;
|
||||
case 5:
|
||||
CurrentDom = !editId ?
|
||||
[
|
||||
<Button type="ghost" onClick={this.handleClose}>完成,跳过所有步骤</Button>,
|
||||
<Button type="ghost" onClick={() => this.setState({ current: current - 1 })}>上一步</Button>,
|
||||
<Button
|
||||
type="primary"
|
||||
loading={loading}
|
||||
onClick={() => {
|
||||
this.setState({ current: current + 1 }, () => this.taxreportruleSave());
|
||||
}}
|
||||
>
|
||||
{
|
||||
(!editId && taxableItems && taxableItems.toString() !== "1" && taxableItems.toString() !== "489") ?
|
||||
getLabel(555, "完成") :
|
||||
getLabel(33199, "保存并进入下一步")
|
||||
}
|
||||
</Button>
|
||||
] : [
|
||||
<Button type="primary" loading={loading} onClick={this.taxreportruleSave}>保存</Button>
|
||||
];
|
||||
break;
|
||||
case 6:
|
||||
CurrentDom = !editId ?
|
||||
[
|
||||
<Button type="ghost" onClick={() => this.setState({ current: current - 1 })}>上一步</Button>,
|
||||
|
|
@ -260,14 +439,24 @@ class LedgerSlide extends Component {
|
|||
};
|
||||
|
||||
render() {
|
||||
let tabs = [
|
||||
{ key: 0, title: getLabel(82751, "基础设置") },
|
||||
{ key: 1, title: getLabel(543467, "关联人员") },
|
||||
{ key: 2, title: getLabel(542362, "薪资项目") },
|
||||
{ key: 3, title: getLabel(543468, "回算薪资项目") },
|
||||
{ key: 4, title: getLabel(111, "累计字段对应") },
|
||||
{ key: 5, title: getLabel(111, "个税申报字段对应") },
|
||||
{ key: 6, title: getLabel(543469, "调薪计薪规则") }
|
||||
];
|
||||
const { title, visible, editId, taxAgentStore: { showOperateBtn } } = this.props;
|
||||
const { current } = this.state;
|
||||
const { current, taxableItems } = this.state;
|
||||
(taxableItems && taxableItems.toString() !== "1" && taxableItems.toString() !== "489") && (tabs = _.filter(tabs, o => o.key !== 4));
|
||||
return (
|
||||
<WeaSlideModal
|
||||
className="slideOuterWrapper"
|
||||
visible={visible}
|
||||
top={0}
|
||||
width={85}
|
||||
width={100}
|
||||
height={100}
|
||||
direction="right"
|
||||
measure="%"
|
||||
|
|
|
|||
|
|
@ -79,6 +79,11 @@ class LedgerTable extends Component {
|
|||
return <div className="optWrapper">
|
||||
<a href="javascript:void(0);" className="mr10"
|
||||
onClick={() => onEditLedger(record)}>{showOperateBtn ? "编辑" : "查看"}</a>
|
||||
{/*{*/}
|
||||
{/* showOperateBtn &&*/}
|
||||
{/* <a href="javascript:void(0);" className="mr10"*/}
|
||||
{/* onClick={() => this.handleMenuClick({ key: "delete" }, record)}>删除</a>*/}
|
||||
{/*}*/}
|
||||
{
|
||||
showOperateBtn &&
|
||||
<a href="javascript:void(0);" className="mr10"
|
||||
|
|
|
|||
|
|
@ -93,7 +93,7 @@ export default class MobilePayroll extends React.Component {
|
|||
const params = this.getUrlkey();
|
||||
const payload = {
|
||||
salaryInfoId,
|
||||
..._.omit(params, ["id", "_key", "type"])
|
||||
..._.pick(params, ["recipient"])
|
||||
};
|
||||
getMySalaryBill(payload).then(result => {
|
||||
this.setState({
|
||||
|
|
|
|||
|
|
@ -2,11 +2,11 @@ import React from "react";
|
|||
import { inject, observer } from "mobx-react";
|
||||
import { DatePicker } from "antd";
|
||||
import { WeaLocaleProvider, WeaNewScroll, WeaTop } from "ecCom";
|
||||
import { renderNoright } from "../../util"; // 渲染form数据的方法:因为多个页面都会使用,所以抽的公共方法在util中
|
||||
import CustomTab from "../../components/customTab";
|
||||
import moment from "moment";
|
||||
import PayrollModal from "./payrollModal";
|
||||
import CustomPaginationTable from "../../components/customPaginationTable";
|
||||
import Authority from "./authority";
|
||||
import "./index.less";
|
||||
|
||||
const { getLabel } = WeaLocaleProvider;
|
||||
|
|
@ -87,8 +87,8 @@ export default class MySalary extends React.Component {
|
|||
|
||||
handleTabChange = (selectedKey) => {
|
||||
if (selectedKey === "2") {
|
||||
const { mySalaryStore: { getRecordList } } = this.props;
|
||||
getRecordList();
|
||||
const { mySalaryStore: { initRecordData } } = this.props;
|
||||
initRecordData();
|
||||
}
|
||||
};
|
||||
|
||||
|
|
@ -176,21 +176,24 @@ export default class MySalary extends React.Component {
|
|||
}
|
||||
{
|
||||
this.state.selectedKey === "2" &&
|
||||
<CustomPaginationTable
|
||||
columns={recordListColumns}
|
||||
dataSource={recordListDataSource}
|
||||
total={recordListPageInfo.total}
|
||||
current={recordListPageInfo.pageNum}
|
||||
pageSize={this.historyPageInfo.pageSize}
|
||||
onPageChange={(value) => {
|
||||
this.historyPageInfo.current = value;
|
||||
this.handleHistoryPageChange();
|
||||
}}
|
||||
onShowSizeChange={(current, pageSize) => {
|
||||
this.historyPageInfo = { current, pageSize };
|
||||
this.handleHistoryPageChange();
|
||||
}}
|
||||
/>
|
||||
<Authority ecId={`${this && this.props && this.props.ecId || ""}_Authority@lulowc`}
|
||||
store={this.props.mySalaryStore}>
|
||||
<CustomPaginationTable
|
||||
columns={recordListColumns}
|
||||
dataSource={recordListDataSource}
|
||||
total={recordListPageInfo.total}
|
||||
current={recordListPageInfo.pageNum}
|
||||
pageSize={this.historyPageInfo.pageSize}
|
||||
onPageChange={(value) => {
|
||||
this.historyPageInfo.current = value;
|
||||
this.handleHistoryPageChange();
|
||||
}}
|
||||
onShowSizeChange={(current, pageSize) => {
|
||||
this.historyPageInfo = { current, pageSize };
|
||||
this.handleHistoryPageChange();
|
||||
}}
|
||||
/>
|
||||
</Authority>
|
||||
}
|
||||
</WeaNewScroll>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -133,7 +133,7 @@ export default class PayrollDetail extends React.Component {
|
|||
<Button type="ghost" onClick={() => setDetailListShowSearchAd(false)}>取消</Button>
|
||||
];
|
||||
return (
|
||||
<div className="payrollGrant">
|
||||
<div className="payrollDetail">
|
||||
<WeaTab
|
||||
searchType={["base", "advanced"]} searchsBasePlaceHolder="请输入姓名"
|
||||
buttons={[<Button type="primary" onClick={this.handleExportAll}>导出全部</Button>]}
|
||||
|
|
|
|||
|
|
@ -1,12 +1,17 @@
|
|||
.payrollGrant {
|
||||
.payrollDetail {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
height: 100%;
|
||||
background: #f6f6f6;
|
||||
|
||||
.wea-tab .wea-tab-right, .wea-input-focus {
|
||||
background: #f6f6f6;
|
||||
}
|
||||
|
||||
.titleBar {
|
||||
height: 47px;
|
||||
line-height: 47px;
|
||||
padding: 0 10px;
|
||||
padding: 0 16px;
|
||||
|
||||
.titleBarLeft {
|
||||
float: left;
|
||||
|
|
@ -19,6 +24,7 @@
|
|||
|
||||
.tableWrapper {
|
||||
flex: 1;
|
||||
padding: 0 16px;
|
||||
|
||||
.ant-spin-nested-loading, .ant-spin-container {
|
||||
height: 100%;
|
||||
|
|
|
|||
|
|
@ -595,6 +595,7 @@ export default class PayrollGrant extends React.Component {
|
|||
this.pageInfo = { current, pageSize };
|
||||
this.handleShowSizeChange(this.pageInfo);
|
||||
}}
|
||||
scroll={{ y: `calc(100vh - 236px)` }}
|
||||
/> : renderLoading()
|
||||
}
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -1,8 +1,15 @@
|
|||
.payrollGrant_new {
|
||||
background: #f6f6f6;
|
||||
height: 100%;
|
||||
|
||||
.wea-tab .wea-tab-right, .wea-input-focus {
|
||||
background: #f6f6f6;
|
||||
}
|
||||
|
||||
.titleBar {
|
||||
height: 47px;
|
||||
line-height: 47px;
|
||||
padding: 0 10px;
|
||||
padding: 0 16px;
|
||||
|
||||
.titleBarLeft {
|
||||
float: left;
|
||||
|
|
@ -14,8 +21,11 @@
|
|||
}
|
||||
|
||||
.tableWrapper {
|
||||
height: calc(100vh - 180.22px);
|
||||
overflow: auto;
|
||||
padding: 0 16px;
|
||||
|
||||
.wea-new-table {
|
||||
background: #FFF;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -117,6 +117,7 @@ export default class BaseInformForm extends React.Component {
|
|||
{
|
||||
this.state.inited &&
|
||||
<WeaSelect
|
||||
disabled={this.props.id}
|
||||
viewAttr={3}
|
||||
options={options}
|
||||
value={salarySob ? salarySob : ""}
|
||||
|
|
|
|||
|
|
@ -86,9 +86,11 @@ class SalaryItemSettings extends Component {
|
|||
}
|
||||
});
|
||||
this.setState({
|
||||
dataList: resultSalaryItemSet
|
||||
dataList: resultSalaryItemSet,
|
||||
itemShowNamesetting: _.filter(this.state.itemShowNamesetting, it => it.salaryItemId !== item.id)
|
||||
}, () => {
|
||||
this.props.onChangeSalaryItem(resultSalaryItemSet);
|
||||
this.props.onChangeSalaryItemShowNamesetting(this.state.itemShowNamesetting);
|
||||
});
|
||||
};
|
||||
handleCloseModal = () => {
|
||||
|
|
|
|||
|
|
@ -94,7 +94,7 @@ export default class ComputerTemplate extends React.Component {
|
|||
<div className="sobItemWrapper">
|
||||
{
|
||||
salaryItemSet.length > 0 &&
|
||||
salaryItemSet.map((group, index) => {
|
||||
_.filter(salaryItemSet, it => (!_.isNil(it) && !_.isEmpty(it))).map((group, index) => {
|
||||
return <div className="sobItem">
|
||||
<div className="descript-title">{group.groupName}</div>
|
||||
<div className="descriptions-view">
|
||||
|
|
|
|||
|
|
@ -75,7 +75,7 @@ export default class PhoneTemplate extends React.Component {
|
|||
<div className="sobItemWrapper">
|
||||
{
|
||||
salaryItemSet.length > 0 &&
|
||||
salaryItemSet.map((group, index) => (
|
||||
_.filter(salaryItemSet, it => (!_.isNil(it) && !_.isEmpty(it))).map((group, index) => (
|
||||
<div className="sobItem">
|
||||
<div className="descript-title">{group.groupName}</div>
|
||||
<div className="descriptions-view">
|
||||
|
|
|
|||
|
|
@ -11,15 +11,16 @@ class AllWithoutPay extends Component {
|
|||
message.warning("未选择条目");
|
||||
return;
|
||||
}
|
||||
API.gotoStop(selectedRowKeys).then(({ status, errormsg }) => {
|
||||
API.gotoStop(selectedRowKeys).then(({ status, data, errormsg }) => {
|
||||
if (status) {
|
||||
message.success("操作成功!");
|
||||
const { msg } = data;
|
||||
message.info(msg || "操作成功!");
|
||||
refreshList();
|
||||
} else {
|
||||
message.error(errormsg || "操作失败!");
|
||||
}
|
||||
});
|
||||
}else{
|
||||
} else {
|
||||
const { pageInfo } = this.props;
|
||||
if (pageInfo.total === 0) {
|
||||
message.warning("您没有需要处理的待停薪人员!");
|
||||
|
|
@ -31,7 +32,7 @@ class AllWithoutPay extends Component {
|
|||
onOk: () => {
|
||||
API.allGotoStop({}).then(({ status, data, errormsg }) => {
|
||||
if (status) {
|
||||
const { msg }= data;
|
||||
const { msg } = data;
|
||||
message.info(msg || "操作成功!");
|
||||
refreshList();
|
||||
} else {
|
||||
|
|
|
|||
|
|
@ -3,6 +3,7 @@ import ImportModal from "../../../components/importModal";
|
|||
import * as API from "../../../apis/payrollFiles";
|
||||
import { Menu, Modal } from "antd";
|
||||
import "../index.less";
|
||||
import { convertToUrlString } from "../../../util/url";
|
||||
|
||||
class ImportMenu extends Component {
|
||||
constructor(props) {
|
||||
|
|
@ -114,7 +115,7 @@ class ImportMenu extends Component {
|
|||
};
|
||||
|
||||
render() {
|
||||
const { importType, refreshList, isExtEmp } = this.props;
|
||||
const { importType, refreshList, isExtEmp, searchItemsValue = {} } = this.props;
|
||||
const { importParams, previewColumns, previewDataSource } = this.state;
|
||||
let params = "";
|
||||
if (importParams.importType === "init" || importParams.importType === "salaryItemAdjust") {
|
||||
|
|
@ -153,8 +154,7 @@ class ImportMenu extends Component {
|
|||
}}
|
||||
previewImport={(params) => this.salaryArchivePreview(params)}
|
||||
importFile={(params) => this.handleImportFile(params)}
|
||||
templateLink={
|
||||
"/api/bs/hrmsalary/salaryArchive/downloadTemplate?importType=" + params
|
||||
templateLink={`/api/bs/hrmsalary/salaryArchive/downloadTemplate?importType=${params}&${convertToUrlString(searchItemsValue)}`
|
||||
}
|
||||
visiable={importParams.visible}
|
||||
onCancel={() => {
|
||||
|
|
|
|||
|
|
@ -30,8 +30,8 @@ import AllWithoutPay from "./components/allWithoutPay";
|
|||
import BatchSuspendsPay from "./components/batchSuspendsPay";
|
||||
import SlideModalTitle from "../../components/slideModalTitle";
|
||||
import SalaryFileViewSlide from "../salaryFile/saralyFileViewSlide";
|
||||
import ChangeSalaryModal from "../salaryFile/changeSalaryModal";
|
||||
import { sysinfo } from "../../apis/ruleconfig";
|
||||
import SalaryArchiveEditAdjLogRecord from "../salaryFile/salaryArchiveEditAdjLogRecord";
|
||||
import "./index.less";
|
||||
|
||||
const getLabel = WeaLocaleProvider.getLabel;
|
||||
|
|
@ -77,7 +77,9 @@ class Index extends Component {
|
|||
subcompanyIds: ""
|
||||
},
|
||||
salaryAdjustmentInfo: {},
|
||||
changeSalaryVisible: false,
|
||||
adjLogRecordDialog: {
|
||||
visible: false, title: "", id: "", salaryArchiveId: ""
|
||||
},
|
||||
noPayDate: "",
|
||||
slideParams: {
|
||||
visible: false,
|
||||
|
|
@ -433,6 +435,7 @@ class Index extends Component {
|
|||
<Dropdown overlay={
|
||||
<ImportMenu
|
||||
importType={importType}
|
||||
searchItemsValue={searchItemsValue}
|
||||
refreshList={() => {
|
||||
this.query();
|
||||
this.setState({ selectedRowKeys: [] });
|
||||
|
|
@ -523,6 +526,7 @@ class Index extends Component {
|
|||
<Dropdown overlay={
|
||||
<ImportMenu
|
||||
isExtEmp importType={importType}
|
||||
searchItemsValue={searchItemsValue}
|
||||
refreshList={() => {
|
||||
this.query();
|
||||
this.setState({ selectedRowKeys: [] });
|
||||
|
|
@ -622,7 +626,12 @@ class Index extends Component {
|
|||
}
|
||||
if (showOperateBtn && (selectedKey === "fixed" || selectedKey === "ext")) {
|
||||
arrList.push(<Button type="primary" onClick={() => {
|
||||
this.setState({ changeSalaryVisible: true });
|
||||
this.setState({
|
||||
adjLogRecordDialog: {
|
||||
...this.state.adjLogRecordDialog,
|
||||
visible: true, title: getLabel(542686, "调薪"), salaryArchiveId: this.state.slideParams.id
|
||||
}
|
||||
});
|
||||
}}>调薪</Button>);
|
||||
}
|
||||
selectedKey !== "stop" && arrList.push(<Button type="primary" onClick={this.handleSave}>保存</Button>);
|
||||
|
|
@ -717,7 +726,7 @@ class Index extends Component {
|
|||
pageInfo,
|
||||
showSearchAd,
|
||||
slideParams,
|
||||
changeSalaryVisible,
|
||||
adjLogRecordDialog,
|
||||
paysetParams,
|
||||
extEmpsWitch
|
||||
} = this.state;
|
||||
|
|
@ -834,6 +843,7 @@ class Index extends Component {
|
|||
<div style={{ display: "none" }}>
|
||||
<ImportMenu
|
||||
ref={(dom) => this.importRef = dom}
|
||||
searchItemsValue={this.state.searchItemsValue}
|
||||
refreshList={() => {
|
||||
this.query();
|
||||
this.setState({ selectedRowKeys: [] });
|
||||
|
|
@ -881,15 +891,14 @@ class Index extends Component {
|
|||
}}
|
||||
/>
|
||||
)}
|
||||
{changeSalaryVisible && (
|
||||
<ChangeSalaryModal
|
||||
currentId={slideParams.id}
|
||||
visible={changeSalaryVisible}
|
||||
onCancel={() => {
|
||||
this.setState({ changeSalaryVisible: false });
|
||||
}}
|
||||
/>
|
||||
)}
|
||||
<SalaryArchiveEditAdjLogRecord
|
||||
{...adjLogRecordDialog}
|
||||
onCancel={() => this.setState({
|
||||
adjLogRecordDialog: {
|
||||
adjLogRecordDialog, visible: false, title: "", id: "", salaryArchiveId: ""
|
||||
}
|
||||
})}
|
||||
/>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -152,6 +152,195 @@ export const condition = [
|
|||
defaultshow: true
|
||||
}
|
||||
];
|
||||
export const shareCondition = [
|
||||
{
|
||||
items: [
|
||||
{
|
||||
colSpan: 1,
|
||||
checkbox: false,
|
||||
checkboxValue: false,
|
||||
conditionType: "SELECT",
|
||||
domkey: ["reportIds"],
|
||||
fieldcol: 12,
|
||||
label: "分享报表",
|
||||
lanId: 111,
|
||||
labelcol: 6,
|
||||
options: [],
|
||||
multiple: true,
|
||||
rules: "required|string",
|
||||
viewAttr: 3
|
||||
},
|
||||
{
|
||||
colSpan: 1,
|
||||
checkbox: false,
|
||||
checkboxValue: false,
|
||||
conditionType: "INPUT",
|
||||
domkey: ["pushTitle"],
|
||||
fieldcol: 18,
|
||||
label: "主题",
|
||||
lanId: 111,
|
||||
labelcol: 6,
|
||||
rules: "required|string",
|
||||
viewAttr: 3
|
||||
},
|
||||
{
|
||||
browserConditionParam: {
|
||||
completeParams: {},
|
||||
conditionDataParams: {},
|
||||
dataParams: {},
|
||||
destDataParams: {},
|
||||
hasAddBtn: false,
|
||||
hasAdvanceSerach: true,
|
||||
idSeparator: ",",
|
||||
isAutoComplete: 1,
|
||||
isDetail: 0,
|
||||
isMultCheckbox: false,
|
||||
isSingle: false,
|
||||
linkUrl: "",
|
||||
pageSize: 10,
|
||||
quickSearchName: "",
|
||||
replaceDatas: [],
|
||||
type: "17",
|
||||
viewAttr: 3
|
||||
},
|
||||
colSpan: 1,
|
||||
conditionType: "BROWSER",
|
||||
domkey: ["sharedBy"],
|
||||
fieldcol: 14,
|
||||
isQuickSearch: false,
|
||||
label: "被分享人",
|
||||
lanId: 111,
|
||||
labelcol: 6,
|
||||
rules: "required|string",
|
||||
viewAttr: 3
|
||||
},
|
||||
{
|
||||
colSpan: 2,
|
||||
conditionType: "DATEPICKER",
|
||||
domkey: ["startTime"],
|
||||
fieldcol: 12,
|
||||
label: "报表查看有效开始时间",
|
||||
lanId: 111,
|
||||
labelcol: 6,
|
||||
value: "",
|
||||
viewAttr: 2
|
||||
},
|
||||
{
|
||||
colSpan: 2,
|
||||
conditionType: "DATEPICKER",
|
||||
domkey: ["endTime"],
|
||||
fieldcol: 12,
|
||||
label: "报表查看有效结束时间",
|
||||
lanId: 111,
|
||||
labelcol: 6,
|
||||
value: "",
|
||||
viewAttr: 2
|
||||
},
|
||||
{
|
||||
colSpan: 1,
|
||||
checkbox: false,
|
||||
checkboxValue: false,
|
||||
conditionType: "INPUT",
|
||||
domkey: ["mark"],
|
||||
fieldcol: 18,
|
||||
label: "分享说明",
|
||||
lanId: 111,
|
||||
labelcol: 6,
|
||||
viewAttr: 2
|
||||
}
|
||||
// {
|
||||
// colSpan: 1,
|
||||
// conditionType: "SWITCH",
|
||||
// domkey: ["remind"],
|
||||
// fieldcol: 12,
|
||||
// isQuickSearch: false,
|
||||
// label: "已查看提醒",
|
||||
// lanId: 111,
|
||||
// labelcol: 6,
|
||||
// viewAttr: 2
|
||||
// }
|
||||
],
|
||||
title: "",
|
||||
defaultshow: true
|
||||
}
|
||||
];
|
||||
export const sharePersonCondition = [
|
||||
{
|
||||
items: [
|
||||
{
|
||||
browserConditionParam: {
|
||||
completeParams: {},
|
||||
conditionDataParams: {},
|
||||
dataParams: {},
|
||||
destDataParams: {},
|
||||
hasAddBtn: false,
|
||||
hasAdvanceSerach: true,
|
||||
idSeparator: ",",
|
||||
isAutoComplete: 1,
|
||||
isDetail: 0,
|
||||
isMultCheckbox: false,
|
||||
isSingle: false,
|
||||
linkUrl: "",
|
||||
pageSize: 10,
|
||||
quickSearchName: "",
|
||||
replaceDatas: [],
|
||||
type: "17",
|
||||
viewAttr: 3
|
||||
},
|
||||
colSpan: 1,
|
||||
conditionType: "BROWSER",
|
||||
domkey: ["sharedBy"],
|
||||
fieldcol: 14,
|
||||
isQuickSearch: false,
|
||||
label: "被分享人",
|
||||
lanId: 111,
|
||||
labelcol: 6,
|
||||
rules: "required|string",
|
||||
viewAttr: 3
|
||||
}
|
||||
],
|
||||
title: "",
|
||||
defaultshow: true
|
||||
}
|
||||
];
|
||||
export const shareLogCondition = [
|
||||
{
|
||||
items: [
|
||||
{
|
||||
colSpan: 1,
|
||||
conditionType: "INPUT",
|
||||
domkey: ["reportName"],
|
||||
fieldcol: 12,
|
||||
label: "分享报表",
|
||||
lanId: 111,
|
||||
labelcol: 6,
|
||||
viewAttr: 1
|
||||
},
|
||||
{
|
||||
colSpan: 1,
|
||||
conditionType: "INPUT",
|
||||
domkey: ["effectiveTime"],
|
||||
fieldcol: 12,
|
||||
label: "报表查看有效时间",
|
||||
lanId: 111,
|
||||
labelcol: 6,
|
||||
viewAttr: 1
|
||||
},
|
||||
{
|
||||
colSpan: 1,
|
||||
conditionType: "INPUT",
|
||||
domkey: ["remark"],
|
||||
fieldcol: 12,
|
||||
label: "分享说明",
|
||||
lanId: 111,
|
||||
labelcol: 6,
|
||||
viewAttr: 1
|
||||
}
|
||||
],
|
||||
title: "",
|
||||
defaultshow: true
|
||||
}
|
||||
];
|
||||
|
||||
const colorList = ["#709DF7", "#73DEB3", "#7585A2", "#F7C739", "#5FC3E3", "#AEE279", "#FF7F81"];
|
||||
export const mapBarOptions = (params) => ({
|
||||
|
|
@ -292,7 +481,7 @@ export const mapBarOptions = (params) => ({
|
|||
{
|
||||
type: "slider",
|
||||
show: true,
|
||||
bottom: 20,
|
||||
bottom: 20
|
||||
}
|
||||
]
|
||||
});
|
||||
|
|
|
|||
|
|
@ -269,7 +269,7 @@ class CustomStatisticsItemsModal extends Component {
|
|||
render() {
|
||||
const { loading, columns, dataSource, formData } = this.state;
|
||||
const { itemName, itemValue, itemValueSpan } = formData;
|
||||
const { statisticsItemId } = this.props;
|
||||
const { statisticsItemId, isShare } = this.props;
|
||||
const cols = _.map(columns, it => {
|
||||
const { text, column } = it;
|
||||
if (column === "ruleName" || column === "ratio" || column === "m2m" || column === "y2y") {
|
||||
|
|
@ -278,6 +278,7 @@ class CustomStatisticsItemsModal extends Component {
|
|||
...it,
|
||||
title: <span>
|
||||
<WeaCheckbox
|
||||
disabled={isShare}
|
||||
value={_.every(dataSource, child => !!child[`${key}Value`])}
|
||||
onChange={val => this.handleChangeColumnAllChecked(`${key}Value`, val)}
|
||||
/>
|
||||
|
|
@ -286,6 +287,7 @@ class CustomStatisticsItemsModal extends Component {
|
|||
render: (txt, record) => {
|
||||
return <span>
|
||||
<WeaCheckbox
|
||||
disabled={isShare}
|
||||
value={record[`${key}Value`].toString()}
|
||||
onChange={val => this.handleChangeColumnCheckBox(`${key}Value`, val, record.id)}
|
||||
/>
|
||||
|
|
@ -305,6 +307,7 @@ class CustomStatisticsItemsModal extends Component {
|
|||
</span>,
|
||||
render: (txt, record) => {
|
||||
return !!record["m2mValue"] && <IntervalSettingsComp
|
||||
isShare={isShare}
|
||||
LowerLimit={record[`${column.replace("Limit", "")}LowerLimit`]}
|
||||
UpperLimit={record[`${column.replace("Limit", "")}UpperLimit`]}
|
||||
onChange={(type, val) => this.handleChangeColumnM2MValue(`${column.replace("Limit", "")}${type === "min" ? "LowerLimit" : "UpperLimit"}`, val, record.id)}
|
||||
|
|
@ -321,6 +324,7 @@ class CustomStatisticsItemsModal extends Component {
|
|||
</span>,
|
||||
render: (txt, record) => {
|
||||
return !!record["y2yValue"] && <IntervalSettingsComp
|
||||
isShare={isShare}
|
||||
LowerLimit={record[`${column.replace("Limit", "")}LowerLimit`]}
|
||||
UpperLimit={record[`${column.replace("Limit", "")}UpperLimit`]}
|
||||
onChange={(type, val) => this.handleChangeColumnM2MValue(`${column.replace("Limit", "")}${type === "min" ? "LowerLimit" : "UpperLimit"}`, val, record.id)}
|
||||
|
|
@ -335,8 +339,10 @@ class CustomStatisticsItemsModal extends Component {
|
|||
title={
|
||||
<div className="itemsTitle">
|
||||
<span>{statisticsItemId ? getLabel(111, "编辑自定义统计项目") : getLabel(111, "新建自定义统计项目")}</span>
|
||||
<Button type="primary" loading={loading}
|
||||
onClick={this.handleSaveStatisticalItems}>{getLabel(111, "保存")}</Button>
|
||||
{
|
||||
!isShare && <Button type="primary" loading={loading}
|
||||
onClick={this.handleSaveStatisticalItems}>{getLabel(111, "保存")}</Button>
|
||||
}
|
||||
</div>
|
||||
}
|
||||
style={{ width: 900, height: 450 }}
|
||||
|
|
@ -348,7 +354,7 @@ class CustomStatisticsItemsModal extends Component {
|
|||
<WeaBrowser
|
||||
title={getLabel(111, "统计项目")}
|
||||
type={162}
|
||||
viewAttr={3}
|
||||
viewAttr={!isShare ? 3 : 1}
|
||||
isSingle={false}
|
||||
value={itemValue}
|
||||
replaceDatas={itemValue ? _.map(itemValue.split(","), (it, idx) => ({
|
||||
|
|
@ -381,7 +387,7 @@ class CustomStatisticsItemsModal extends Component {
|
|||
</WeaFormItem>
|
||||
<WeaFormItem label={getLabel(111, "统计项名称")} labelCol={{ span: 6 }} wrapperCol={{ span: 18 }}>
|
||||
<WeaError tipPosition="bottom" ref="nameError" error={getLabel(111, "此项必填")}>
|
||||
<WeaInput value={itemName} viewAttr={3}
|
||||
<WeaInput value={itemName} viewAttr={!isShare ? 3 : 1}
|
||||
onChange={itemName => this.setState({ formData: { ...formData, itemName } })}/>
|
||||
</WeaError>
|
||||
</WeaFormItem>
|
||||
|
|
@ -406,11 +412,11 @@ export default CustomStatisticsItemsModal;
|
|||
* Date: 2023/4/23
|
||||
*/
|
||||
const IntervalSettingsComp = (props) => {
|
||||
const { LowerLimit, UpperLimit, onChange } = props;
|
||||
const { LowerLimit, UpperLimit, onChange, isShare } = props;
|
||||
return <div className="intervalSettingsCompWrapper">
|
||||
<WeaInputNumber value={LowerLimit} precision={2} onChange={val => onChange("min", val)}/>
|
||||
<WeaInputNumber value={LowerLimit} precision={2} onChange={val => onChange("min", val)} disabled={isShare}/>
|
||||
<span className="increaseTitle">{`% <${getLabel(111, "增幅")}<`}</span>
|
||||
<WeaInputNumber value={UpperLimit} precision={2} onChange={val => onChange("max", val)}/>
|
||||
<WeaInputNumber value={UpperLimit} precision={2} onChange={val => onChange("max", val)} disabled={isShare}/>
|
||||
<span className="pecentTitle">%</span>
|
||||
</div>;
|
||||
};
|
||||
|
|
|
|||
|
|
@ -63,3 +63,134 @@
|
|||
height: 100%;
|
||||
}
|
||||
}
|
||||
|
||||
.shareDialogWrapper {
|
||||
.wea-dialog-body {
|
||||
background: #f6f6f6;
|
||||
overflow-y: hidden;
|
||||
}
|
||||
|
||||
.wea-search-group {
|
||||
border: 1px solid #e5e5e5;
|
||||
border-bottom: none;
|
||||
background: #FFF;
|
||||
}
|
||||
|
||||
.wea-search-group, .wea-content, .wea-form-cell {
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
.wea-form-item {
|
||||
padding: 8px 16px;
|
||||
border-bottom: 1px solid #e5e5e5;
|
||||
}
|
||||
|
||||
.wea-select, .ant-select, .ant-select-selection {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.wea-select .wea-select-input .arrow {
|
||||
position: absolute;
|
||||
right: 4px;
|
||||
top: 8px;
|
||||
color: #666;
|
||||
}
|
||||
|
||||
.wea-select .wdb {
|
||||
word-break: break-all !important;
|
||||
word-wrap: break-word !important;
|
||||
}
|
||||
|
||||
.wea-select .wea-select-input {
|
||||
height: 30px;
|
||||
white-space: nowrap;
|
||||
min-width: 100px;
|
||||
max-width: 345px;
|
||||
width: 100%;
|
||||
display: inline-block;
|
||||
padding: 4px 17px 4px 4px;
|
||||
position: relative;
|
||||
min-height: 30px;
|
||||
border: 1px solid #d9d9d9;
|
||||
-webkit-user-select: none;
|
||||
-moz-user-select: none;
|
||||
-ms-user-select: none;
|
||||
user-select: none;
|
||||
-o-text-overflow: ellipsis;
|
||||
text-overflow: ellipsis;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.shareLogGroupWrapper {
|
||||
margin-top: 16px;
|
||||
|
||||
.logtitleHeader {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
|
||||
.right {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.shareRecordWrapper {
|
||||
z-index: 111;
|
||||
|
||||
.wea-slide-modal-title {
|
||||
height: auto !important;
|
||||
line-height: normal !important;
|
||||
}
|
||||
|
||||
.titleDialog {
|
||||
display: flex;
|
||||
padding: 10px 16px 10px 0;
|
||||
position: relative;
|
||||
background-color: #FFF;
|
||||
border-bottom: 1px solid #e5e5e5;
|
||||
|
||||
.titleCol {
|
||||
flex: 1;
|
||||
|
||||
.titleLeftBox {
|
||||
display: flex;
|
||||
height: 100%;
|
||||
align-items: center;
|
||||
padding-left: 16px;
|
||||
|
||||
.titleIcon {
|
||||
color: #fff;
|
||||
margin: 0;
|
||||
width: 40px;
|
||||
height: 40px;
|
||||
line-height: 40px;
|
||||
font-size: 22px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
background: #F14A2D;
|
||||
border-radius: 50%;
|
||||
}
|
||||
|
||||
.title {
|
||||
font-size: 14px;
|
||||
color: #333;
|
||||
padding-left: 6px;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.ant-table-tbody {
|
||||
& > tr {
|
||||
& > td {
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -35,8 +35,8 @@ class PovitpivotChartModal extends Component {
|
|||
|
||||
componentWillReceiveProps(nextProps, nextContext) {
|
||||
if (nextProps.visible !== this.props.visible && nextProps.visible) {
|
||||
const { id, dimensionId, dimensionValue } = nextProps;
|
||||
this.getDataPerspective({ id, dimensionId, dimensionValue });
|
||||
const { id, dimensionId, dimensionValue, isShare } = nextProps;
|
||||
this.getDataPerspective({ id, dimensionId, dimensionValue, isShare });
|
||||
} else {
|
||||
this.setState({
|
||||
dataSource: [],
|
||||
|
|
@ -63,13 +63,11 @@ class PovitpivotChartModal extends Component {
|
|||
});
|
||||
} else if (type === "turn") {
|
||||
if (id === "PAGEINFO") {
|
||||
const { id, dimensionId, dimensionValue } = this.props;
|
||||
const { id, dimensionId, dimensionValue, isShare } = this.props;
|
||||
const { pageNum: current, size: pageSize } = params;
|
||||
this.setState({ pageInfo: { ...pageInfo, current, pageSize } }, () =>
|
||||
this.getDataPerspective({
|
||||
id,
|
||||
dimensionId,
|
||||
dimensionValue
|
||||
id, dimensionId, dimensionValue, isShare
|
||||
}));
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue