Merge branch 'release/2.7.4.2304.02' into feature/公式
This commit is contained in:
commit
40cd70e2a3
|
|
@ -0,0 +1,166 @@
|
||||||
|
ALTER TABLE hrsa_other_deduction ADD COLUMN private_pension varchar(255) NULL;
|
||||||
|
|
||||||
|
ALTER TABLE hrsa_add_up_situation ADD COLUMN add_up_private_pension varchar(255) NULL;
|
||||||
|
|
||||||
|
INSERT INTO hrsa_sys_salary_item(id, name, code, system_type, category, item_type, use_default, use_in_employee_salary, rounding_mode, pattern, value_type, datasource, formula_id, description, can_edit, can_delete, creator, delete_type, tenant_key, create_time, update_time, data_type) VALUES (746777981115629605, '个人养老金', 'privatePension', 1, 2, 12, 0, 0, 2, 2, 2, 8, 1680746056549, '', 0, 1, 0, 0, 'all_teams', '2022-03-28 10:33:01', '2022-05-10 15:54:31', 'number');
|
||||||
|
|
||||||
|
INSERT INTO hrsa_sys_salary_item(id, name, code, system_type, category, item_type, use_default, use_in_employee_salary, rounding_mode, pattern, value_type, datasource, formula_id, description, can_edit, can_delete, creator, delete_type, tenant_key, create_time, update_time, data_type) VALUES (746777981115629698, '累计个人养老金', 'addUpPrivatePension', 1, 2, 12, 0, 0, 2, 2, 2, 8, 1681201555316, '', 0, 1, 0, 0, 'all_teams', '2022-03-28 10:33:01', '2022-05-10 15:54:31', 'number');
|
||||||
|
|
||||||
|
INSERT INTO hrsa_formula(id, name, description, module, use_for, reference_type, return_type, validate_type, extend_param, formula, formulaRunScript, creator, delete_type, create_time, update_time) VALUES (1680746056549, '公式1', '备注', 'salary', 'salaryitem', 'formula', 'number', 'number', '{\"sqlReturnKey\":\"\",\"openDecrypt\":\"0\",\"datasource\":{\"datasourceId\":\"\"}}', '{其他免税扣除.个人养老金}', 'otherDeduction_privatePension', 92, 0, '2023-04-06 09:54:16', '2023-04-06 09:54:16');
|
||||||
|
INSERT INTO hrsa_formula_var(id, name, formula_id, field_id, field_name, field_type, source, order_index, creator, delete_type, create_time, update_time) VALUES (1680746056577, '个人养老金', 1680746056549, 'otherDeduction_privatePension', '{其他免税扣除.个人养老金}', 'number', 'otherDeduction', 0, 92, 0, '2023-04-06 09:54:16', '2023-04-06 09:54:16');
|
||||||
|
|
||||||
|
INSERT INTO hrsa_formula(id, name, description, module, use_for, reference_type, return_type, validate_type, extend_param, formula, formulaRunScript, creator, delete_type, create_time, update_time) VALUES (1681201555316, '公式1', '备注', 'salary', 'salaryitem', 'formula', 'number', 'number', '{\"sqlReturnKey\":\"\",\"openDecrypt\":\"0\",\"datasource\":{\"datasourceId\":\"\"}}', '{薪资项目.个人养老金}+{往期累计情况.累计个人养老金}', 'salaryItem_privatePension+addUpSituation_addUpPrivatePension', 92, 0, '2023-04-11 16:25:55', '2023-04-11 16:25:55');
|
||||||
|
INSERT INTO hrsa_formula_var(id, name, formula_id, field_id, field_name, field_type, source, order_index, creator, delete_type, create_time, update_time) VALUES (1681201555332, '个人养老金', 1681201555316, 'salaryItem_privatePension', '{薪资项目.个人养老金}', 'number', 'salaryItem', 0, 92, 0, '2023-04-11 16:25:55', '2023-04-11 16:25:55');
|
||||||
|
INSERT INTO hrsa_formula_var(id, name, formula_id, field_id, field_name, field_type, source, order_index, creator, delete_type, create_time, update_time) VALUES (1681201555338, '累计个人养老金', 1681201555316, 'addUpSituation_addUpPrivatePension', '{往期累计情况.累计个人养老金}', 'number', 'addUpSituation', 1, 92, 0, '2023-04-11 16:25:55', '2023-04-11 16:25:55');
|
||||||
|
|
||||||
|
INSERT INTO hrsa_salary_sob_default_item(id, income_category, sys_salary_item_id, can_edit, can_delete, creator, create_time, update_time, delete_type, tenant_key, sob_default_item_group_id, sorted_index) VALUES (733975748932845610, 1, 746777981115629605, 1, 0, 0, '2022-03-18 16:30:21', '2022-03-18 16:59:24', 0, 'all_teams', 703433961629614110, 10);
|
||||||
|
|
||||||
|
INSERT INTO hrsa_salary_sob_default_item(id, income_category, sys_salary_item_id, can_edit, can_delete, creator, create_time, update_time, delete_type, tenant_key, sob_default_item_group_id, sorted_index) VALUES (733975748932845611, 1, 746777981115629698, 1, 0, 0, '2022-03-18 16:30:21', '2022-03-18 16:59:24', 0, 'all_teams', 703433961629614110, 11);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
ALTER TABLE hrsa_other_deduction ADD [private_pension] varchar(255) NULL
|
||||||
|
GO
|
||||||
|
|
||||||
|
ALTER TABLE hrsa_add_up_situation ADD [add_up_private_pension] varchar(255) NULL
|
||||||
|
GO
|
||||||
|
|
||||||
|
INSERT INTO hrsa_sys_salary_item(id, name, code, system_type, category, item_type, use_default, use_in_employee_salary, rounding_mode, pattern, value_type, datasource, formula_id, description, can_edit, can_delete, creator, delete_type, tenant_key, create_time, update_time, data_type) VALUES (746777981115629605, '个人养老金', 'privatePension', 1, 2, 12, 0, 0, 2, 2, 2, 8, 1680746056549, '', 0, 1, 0, 0, 'all_teams', '2022-03-28 10:33:01', '2022-05-10 15:54:31', 'number')
|
||||||
|
GO
|
||||||
|
|
||||||
|
INSERT INTO hrsa_sys_salary_item(id, name, code, system_type, category, item_type, use_default, use_in_employee_salary, rounding_mode, pattern, value_type, datasource, formula_id, description, can_edit, can_delete, creator, delete_type, tenant_key, create_time, update_time, data_type) VALUES (746777981115629698, '累计个人养老金', 'addUpPrivatePension', 1, 2, 12, 0, 0, 2, 2, 2, 8, 1681201555316, '', 0, 1, 0, 0, 'all_teams', '2022-03-28 10:33:01', '2022-05-10 15:54:31', 'number')
|
||||||
|
GO
|
||||||
|
|
||||||
|
INSERT INTO hrsa_formula(id, name, description, module, use_for, reference_type, return_type, validate_type, extend_param, formula, formulaRunScript, creator, delete_type, create_time, update_time) VALUES (1680746056549, '公式1', '备注', 'salary', 'salaryitem', 'formula', 'number', 'number', '{\"sqlReturnKey\":\"\",\"openDecrypt\":\"0\",\"datasource\":{\"datasourceId\":\"\"}}', '{其他免税扣除.个人养老金}', 'otherDeduction_privatePension', 92, 0, '2023-04-06 09:54:16', '2023-04-06 09:54:16')
|
||||||
|
GO
|
||||||
|
INSERT INTO hrsa_formula_var(id, name, formula_id, field_id, field_name, field_type, source, order_index, creator, delete_type, create_time, update_time) VALUES (1680746056577, '个人养老金', 1680746056549, 'otherDeduction_privatePension', '{其他免税扣除.个人养老金}', 'number', 'otherDeduction', 0, 92, 0, '2023-04-06 09:54:16', '2023-04-06 09:54:16')
|
||||||
|
GO
|
||||||
|
|
||||||
|
INSERT INTO hrsa_formula(id, name, description, module, use_for, reference_type, return_type, validate_type, extend_param, formula, formulaRunScript, creator, delete_type, create_time, update_time) VALUES (1681201555316, '公式1', '备注', 'salary', 'salaryitem', 'formula', 'number', 'number', '{\"sqlReturnKey\":\"\",\"openDecrypt\":\"0\",\"datasource\":{\"datasourceId\":\"\"}}', '{薪资项目.个人养老金}+{往期累计情况.累计个人养老金}', 'salaryItem_privatePension+addUpSituation_addUpPrivatePension', 92, 0, '2023-04-11 16:25:55', '2023-04-11 16:25:55')
|
||||||
|
GO
|
||||||
|
INSERT INTO hrsa_formula_var(id, name, formula_id, field_id, field_name, field_type, source, order_index, creator, delete_type, create_time, update_time) VALUES (1681201555332, '个人养老金', 1681201555316, 'salaryItem_privatePension', '{薪资项目.个人养老金}', 'number', 'salaryItem', 0, 92, 0, '2023-04-11 16:25:55', '2023-04-11 16:25:55')
|
||||||
|
GO
|
||||||
|
INSERT INTO hrsa_formula_var(id, name, formula_id, field_id, field_name, field_type, source, order_index, creator, delete_type, create_time, update_time) VALUES (1681201555338, '累计个人养老金', 1681201555316, 'addUpSituation_addUpPrivatePension', '{往期累计情况.累计个人养老金}', 'number', 'addUpSituation', 1, 92, 0, '2023-04-11 16:25:55', '2023-04-11 16:25:55')
|
||||||
|
GO
|
||||||
|
|
||||||
|
INSERT INTO hrsa_salary_sob_default_item(id, income_category, sys_salary_item_id, can_edit, can_delete, creator, create_time, update_time, delete_type, tenant_key, sob_default_item_group_id, sorted_index) VALUES (733975748932845610, 1, 746777981115629605, 1, 0, 0, '2022-03-18 16:30:21', '2022-03-18 16:59:24', 0, 'all_teams', 703433961629614110, 10)
|
||||||
|
GO
|
||||||
|
|
||||||
|
INSERT INTO hrsa_salary_sob_default_item(id, income_category, sys_salary_item_id, can_edit, can_delete, creator, create_time, update_time, delete_type, tenant_key, sob_default_item_group_id, sorted_index) VALUES (733975748932845611, 1, 746777981115629698, 1, 0, 0, '2022-03-18 16:30:21', '2022-03-18 16:59:24', 0, 'all_teams', 703433961629614110, 11)
|
||||||
|
GO
|
||||||
|
|
||||||
|
|
||||||
|
ALTER TABLE hrsa_other_deduction ADD (
|
||||||
|
private_pension varchar2(255) NULL
|
||||||
|
)
|
||||||
|
/
|
||||||
|
|
||||||
|
ALTER TABLE hrsa_add_up_situation ADD (
|
||||||
|
add_up_private_pension varchar2(255) NULL
|
||||||
|
)
|
||||||
|
/
|
||||||
|
|
||||||
|
INSERT INTO hrsa_sys_salary_item(id, name, code, system_type, category, item_type, use_default, use_in_employee_salary, rounding_mode, pattern, value_type, datasource, formula_id, description, can_edit, can_delete, creator, delete_type, tenant_key, create_time, update_time, data_type) VALUES (746777981115629605, '个人养老金', 'privatePension', 1, 2, 12, 0, 0, 2, 2, 2, 8, 1680746056549, '', 0, 1, 0, 0, 'all_teams', to_date('2022-05-10 16:03:02','yyyy-MM-dd HH24:mi:ss'), to_date('2022-05-10 16:03:02','yyyy-MM-dd HH24:mi:ss'), 'number')
|
||||||
|
/
|
||||||
|
|
||||||
|
INSERT INTO hrsa_sys_salary_item(id, name, code, system_type, category, item_type, use_default, use_in_employee_salary, rounding_mode, pattern, value_type, datasource, formula_id, description, can_edit, can_delete, creator, delete_type, tenant_key, create_time, update_time, data_type) VALUES (746777981115629698, '累计个人养老金', 'addUpPrivatePension', 1, 2, 12, 0, 0, 2, 2, 2, 8, 1681201555316, '', 0, 1, 0, 0, 'all_teams', to_date('2022-05-10 16:03:02','yyyy-MM-dd HH24:mi:ss'), to_date('2022-05-10 16:03:02','yyyy-MM-dd HH24:mi:ss'), 'number')
|
||||||
|
/
|
||||||
|
|
||||||
|
INSERT INTO hrsa_formula(id, name, description, module, use_for, reference_type, return_type, validate_type, extend_param, formula, formulaRunScript, creator, delete_type, create_time, update_time) VALUES (1680746056549, '公式1', '备注', 'salary', 'salaryitem', 'formula', 'number', 'number', '{\"sqlReturnKey\":\"\",\"openDecrypt\":\"0\",\"datasource\":{\"datasourceId\":\"\"}}', '{其他免税扣除.个人养老金}', 'otherDeduction_privatePension', 92, 0, to_date('2022-05-10 16:03:02','yyyy-MM-dd HH24:mi:ss'), to_date('2022-05-10 16:03:02','yyyy-MM-dd HH24:mi:ss'))
|
||||||
|
/
|
||||||
|
INSERT INTO hrsa_formula_var(id, name, formula_id, field_id, field_name, field_type, source, order_index, creator, delete_type, create_time, update_time) VALUES (1680746056577, '个人养老金', 1680746056549, 'otherDeduction_privatePension', '{其他免税扣除.个人养老金}', 'number', 'otherDeduction', 0, 92, 0, to_date('2022-05-10 16:03:02','yyyy-MM-dd HH24:mi:ss'), to_date('2022-05-10 16:03:02','yyyy-MM-dd HH24:mi:ss'))
|
||||||
|
/
|
||||||
|
|
||||||
|
INSERT INTO hrsa_formula(id, name, description, module, use_for, reference_type, return_type, validate_type, extend_param, formula, formulaRunScript, creator, delete_type, create_time, update_time) VALUES (1681201555316, '公式1', '备注', 'salary', 'salaryitem', 'formula', 'number', 'number', '{\"sqlReturnKey\":\"\",\"openDecrypt\":\"0\",\"datasource\":{\"datasourceId\":\"\"}}', '{薪资项目.个人养老金}+{往期累计情况.累计个人养老金}', 'salaryItem_privatePension+addUpSituation_addUpPrivatePension', 92, 0, to_date('2022-05-10 16:03:02','yyyy-MM-dd HH24:mi:ss'), to_date('2022-05-10 16:03:02','yyyy-MM-dd HH24:mi:ss'))
|
||||||
|
/
|
||||||
|
INSERT INTO hrsa_formula_var(id, name, formula_id, field_id, field_name, field_type, source, order_index, creator, delete_type, create_time, update_time) VALUES (1681201555332, '个人养老金', 1681201555316, 'salaryItem_privatePension', '{薪资项目.个人养老金}', 'number', 'salaryItem', 0, 92, 0, to_date('2022-05-10 16:03:02','yyyy-MM-dd HH24:mi:ss'), to_date('2022-05-10 16:03:02','yyyy-MM-dd HH24:mi:ss'))
|
||||||
|
/
|
||||||
|
INSERT INTO hrsa_formula_var(id, name, formula_id, field_id, field_name, field_type, source, order_index, creator, delete_type, create_time, update_time) VALUES (1681201555338, '累计个人养老金', 1681201555316, 'addUpSituation_addUpPrivatePension', '{往期累计情况.累计个人养老金}', 'number', 'addUpSituation', 1, 92, 0, to_date('2022-05-10 16:03:02','yyyy-MM-dd HH24:mi:ss'), to_date('2022-05-10 16:03:02','yyyy-MM-dd HH24:mi:ss'))
|
||||||
|
/
|
||||||
|
|
||||||
|
INSERT INTO hrsa_salary_sob_default_item(id, income_category, sys_salary_item_id, can_edit, can_delete, creator, create_time, update_time, delete_type, tenant_key, sob_default_item_group_id, sorted_index) VALUES (733975748932845610, 1, 746777981115629605, 1, 0, 0, to_date('2022-05-10 16:03:02','yyyy-MM-dd HH24:mi:ss'), to_date('2022-05-10 16:03:02','yyyy-MM-dd HH24:mi:ss'), 0, 'all_teams', 703433961629614110, 10)
|
||||||
|
/
|
||||||
|
|
||||||
|
INSERT INTO hrsa_salary_sob_default_item(id, income_category, sys_salary_item_id, can_edit, can_delete, creator, create_time, update_time, delete_type, tenant_key, sob_default_item_group_id, sorted_index) VALUES (733975748932845611, 1, 746777981115629698, 1, 0, 0, to_date('2022-05-10 16:03:02','yyyy-MM-dd HH24:mi:ss'), to_date('2022-05-10 16:03:02','yyyy-MM-dd HH24:mi:ss'), 0, 'all_teams', 703433961629614110, 11)
|
||||||
|
/
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
INSERT INTO hrsa_formula(id, name, description, module, use_for, reference_type, return_type, validate_type, extend_param, formula, formulaRunScript, creator, delete_type, create_time, update_time) VALUES (1681265757380, '公式1', '备注', 'salary', 'salaryitem', 'formula', 'number', 'number', '{\"datasource\":{\"datasourceId\":\"\"}}', '{薪资项目.当前累计应税收入合计}-{薪资项目.当前累计专项扣除合计}-{薪资项目.当前累计专项附加扣除合计}-{薪资项目.当前累计其他扣除合计}-{薪资项目.当前累计减除费用}-{薪资项目.当前累计准备扣除的捐赠额}-{薪资项目.累计个人养老金}', 'salaryItem_addUpIncome-salaryItem_addUpSpecialDeduction-salaryItem_addUpSpeAddiDeduction-salaryItem_addUpOtherDeduction-salaryItem_addUpSubtraction-salaryItem_addUpAllowedDonation-salaryItem_addUpPrivatePension', 92, 0, '2023-04-12 10:15:57', '2023-04-12 10:15:57');
|
||||||
|
|
||||||
|
INSERT INTO hrsa_formula_var(id, name, formula_id, field_id, field_name, field_type, source, order_index, creator, delete_type, create_time, update_time) VALUES (1681265757404, '当前累计准备扣除的捐赠额', 1681265757380, 'salaryItem_addUpAllowedDonation', '{薪资项目.当前累计准备扣除的捐赠额}', 'number', 'salaryItem', 5, 92, 0, '2023-04-12 10:15:57', '2023-04-12 10:15:57');
|
||||||
|
INSERT INTO hrsa_formula_var(id, name, formula_id, field_id, field_name, field_type, source, order_index, creator, delete_type, create_time, update_time) VALUES (1681265757408, '当前累计减除费用', 1681265757380, 'salaryItem_addUpSubtraction', '{薪资项目.当前累计减除费用}', 'number', 'salaryItem', 4, 92, 0, '2023-04-12 10:15:57', '2023-04-12 10:15:57');
|
||||||
|
INSERT INTO hrsa_formula_var(id, name, formula_id, field_id, field_name, field_type, source, order_index, creator, delete_type, create_time, update_time) VALUES (1681265757413, '当前累计其他扣除合计', 1681265757380, 'salaryItem_addUpOtherDeduction', '{薪资项目.当前累计其他扣除合计}', 'number', 'salaryItem', 3, 92, 0, '2023-04-12 10:15:57', '2023-04-12 10:15:57');
|
||||||
|
INSERT INTO hrsa_formula_var(id, name, formula_id, field_id, field_name, field_type, source, order_index, creator, delete_type, create_time, update_time) VALUES (1681265757417, '当前累计专项附加扣除合计', 1681265757380, 'salaryItem_addUpSpeAddiDeduction', '{薪资项目.当前累计专项附加扣除合计}', 'number', 'salaryItem', 2, 92, 0, '2023-04-12 10:15:57', '2023-04-12 10:15:57');
|
||||||
|
INSERT INTO hrsa_formula_var(id, name, formula_id, field_id, field_name, field_type, source, order_index, creator, delete_type, create_time, update_time) VALUES (1681265757421, '当前累计专项扣除合计', 1681265757380, 'salaryItem_addUpSpecialDeduction', '{薪资项目.当前累计专项扣除合计}', 'number', 'salaryItem', 1, 92, 0, '2023-04-12 10:15:57', '2023-04-12 10:15:57');
|
||||||
|
INSERT INTO hrsa_formula_var(id, name, formula_id, field_id, field_name, field_type, source, order_index, creator, delete_type, create_time, update_time) VALUES (1681265757424, '当前累计应税收入合计', 1681265757380, 'salaryItem_addUpIncome', '{薪资项目.当前累计应税收入合计}', 'number', 'salaryItem', 0, 92, 0, '2023-04-12 10:15:57', '2023-04-12 10:15:57');
|
||||||
|
INSERT INTO hrsa_formula_var(id, name, formula_id, field_id, field_name, field_type, source, order_index, creator, delete_type, create_time, update_time) VALUES (1681265757428, '累计个人养老金', 1681265757380, 'salaryItem_addUpPrivatePension', '{薪资项目.累计个人养老金}', 'number', 'salaryItem', 6, 92, 0, '2023-04-12 10:15:57', '2023-04-12 10:15:57');
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
INSERT INTO hrsa_formula(id, name, description, module, use_for, reference_type, return_type, validate_type, extend_param, formula, formulaRunScript, creator, delete_type, create_time, update_time) VALUES (1681265757380, '公式1', '备注', 'salary', 'salaryitem', 'formula', 'number', 'number', '{\"datasource\":{\"datasourceId\":\"\"}}', '{薪资项目.当前累计应税收入合计}-{薪资项目.当前累计专项扣除合计}-{薪资项目.当前累计专项附加扣除合计}-{薪资项目.当前累计其他扣除合计}-{薪资项目.当前累计减除费用}-{薪资项目.当前累计准备扣除的捐赠额}-{薪资项目.累计个人养老金}', 'salaryItem_addUpIncome-salaryItem_addUpSpecialDeduction-salaryItem_addUpSpeAddiDeduction-salaryItem_addUpOtherDeduction-salaryItem_addUpSubtraction-salaryItem_addUpAllowedDonation-salaryItem_addUpPrivatePension', 92, 0, '2023-04-12 10:15:57', '2023-04-12 10:15:57')
|
||||||
|
GO
|
||||||
|
|
||||||
|
INSERT INTO hrsa_formula_var(id, name, formula_id, field_id, field_name, field_type, source, order_index, creator, delete_type, create_time, update_time) VALUES (1681265757404, '当前累计准备扣除的捐赠额', 1681265757380, 'salaryItem_addUpAllowedDonation', '{薪资项目.当前累计准备扣除的捐赠额}', 'number', 'salaryItem', 5, 92, 0, '2023-04-12 10:15:57', '2023-04-12 10:15:57')
|
||||||
|
GO
|
||||||
|
INSERT INTO hrsa_formula_var(id, name, formula_id, field_id, field_name, field_type, source, order_index, creator, delete_type, create_time, update_time) VALUES (1681265757408, '当前累计减除费用', 1681265757380, 'salaryItem_addUpSubtraction', '{薪资项目.当前累计减除费用}', 'number', 'salaryItem', 4, 92, 0, '2023-04-12 10:15:57', '2023-04-12 10:15:57')
|
||||||
|
GO
|
||||||
|
INSERT INTO hrsa_formula_var(id, name, formula_id, field_id, field_name, field_type, source, order_index, creator, delete_type, create_time, update_time) VALUES (1681265757413, '当前累计其他扣除合计', 1681265757380, 'salaryItem_addUpOtherDeduction', '{薪资项目.当前累计其他扣除合计}', 'number', 'salaryItem', 3, 92, 0, '2023-04-12 10:15:57', '2023-04-12 10:15:57')
|
||||||
|
GO
|
||||||
|
INSERT INTO hrsa_formula_var(id, name, formula_id, field_id, field_name, field_type, source, order_index, creator, delete_type, create_time, update_time) VALUES (1681265757417, '当前累计专项附加扣除合计', 1681265757380, 'salaryItem_addUpSpeAddiDeduction', '{薪资项目.当前累计专项附加扣除合计}', 'number', 'salaryItem', 2, 92, 0, '2023-04-12 10:15:57', '2023-04-12 10:15:57')
|
||||||
|
GO
|
||||||
|
INSERT INTO hrsa_formula_var(id, name, formula_id, field_id, field_name, field_type, source, order_index, creator, delete_type, create_time, update_time) VALUES (1681265757421, '当前累计专项扣除合计', 1681265757380, 'salaryItem_addUpSpecialDeduction', '{薪资项目.当前累计专项扣除合计}', 'number', 'salaryItem', 1, 92, 0, '2023-04-12 10:15:57', '2023-04-12 10:15:57')
|
||||||
|
GO
|
||||||
|
INSERT INTO hrsa_formula_var(id, name, formula_id, field_id, field_name, field_type, source, order_index, creator, delete_type, create_time, update_time) VALUES (1681265757424, '当前累计应税收入合计', 1681265757380, 'salaryItem_addUpIncome', '{薪资项目.当前累计应税收入合计}', 'number', 'salaryItem', 0, 92, 0, '2023-04-12 10:15:57', '2023-04-12 10:15:57')
|
||||||
|
GO
|
||||||
|
INSERT INTO hrsa_formula_var(id, name, formula_id, field_id, field_name, field_type, source, order_index, creator, delete_type, create_time, update_time) VALUES (1681265757428, '累计个人养老金', 1681265757380, 'salaryItem_addUpPrivatePension', '{薪资项目.累计个人养老金}', 'number', 'salaryItem', 6, 92, 0, '2023-04-12 10:15:57', '2023-04-12 10:15:57')
|
||||||
|
GO
|
||||||
|
|
||||||
|
|
||||||
|
INSERT INTO hrsa_formula(id, name, description, module, use_for, reference_type, return_type, validate_type, extend_param, formula, formulaRunScript, creator, delete_type, create_time, update_time) VALUES (1681265757380, '公式1', '备注', 'salary', 'salaryitem', 'formula', 'number', 'number', '{\"datasource\":{\"datasourceId\":\"\"}}', '{薪资项目.当前累计应税收入合计}-{薪资项目.当前累计专项扣除合计}-{薪资项目.当前累计专项附加扣除合计}-{薪资项目.当前累计其他扣除合计}-{薪资项目.当前累计减除费用}-{薪资项目.当前累计准备扣除的捐赠额}-{薪资项目.累计个人养老金}', 'salaryItem_addUpIncome-salaryItem_addUpSpecialDeduction-salaryItem_addUpSpeAddiDeduction-salaryItem_addUpOtherDeduction-salaryItem_addUpSubtraction-salaryItem_addUpAllowedDonation-salaryItem_addUpPrivatePension', 92, 0, to_date('2022-05-10 16:03:02','yyyy-MM-dd HH24:mi:ss'), to_date('2022-05-10 16:03:02','yyyy-MM-dd HH24:mi:ss'))
|
||||||
|
/
|
||||||
|
|
||||||
|
INSERT INTO hrsa_formula_var(id, name, formula_id, field_id, field_name, field_type, source, order_index, creator, delete_type, create_time, update_time) VALUES (1681265757404, '当前累计准备扣除的捐赠额', 1681265757380, 'salaryItem_addUpAllowedDonation', '{薪资项目.当前累计准备扣除的捐赠额}', 'number', 'salaryItem', 5, 92, 0, to_date('2022-05-10 16:03:02','yyyy-MM-dd HH24:mi:ss'), to_date('2022-05-10 16:03:02','yyyy-MM-dd HH24:mi:ss'))
|
||||||
|
/
|
||||||
|
INSERT INTO hrsa_formula_var(id, name, formula_id, field_id, field_name, field_type, source, order_index, creator, delete_type, create_time, update_time) VALUES (1681265757408, '当前累计减除费用', 1681265757380, 'salaryItem_addUpSubtraction', '{薪资项目.当前累计减除费用}', 'number', 'salaryItem', 4, 92, 0, to_date('2022-05-10 16:03:02','yyyy-MM-dd HH24:mi:ss'), to_date('2022-05-10 16:03:02','yyyy-MM-dd HH24:mi:ss'))
|
||||||
|
/
|
||||||
|
INSERT INTO hrsa_formula_var(id, name, formula_id, field_id, field_name, field_type, source, order_index, creator, delete_type, create_time, update_time) VALUES (1681265757413, '当前累计其他扣除合计', 1681265757380, 'salaryItem_addUpOtherDeduction', '{薪资项目.当前累计其他扣除合计}', 'number', 'salaryItem', 3, 92, 0, to_date('2022-05-10 16:03:02','yyyy-MM-dd HH24:mi:ss'), to_date('2022-05-10 16:03:02','yyyy-MM-dd HH24:mi:ss'))
|
||||||
|
/
|
||||||
|
INSERT INTO hrsa_formula_var(id, name, formula_id, field_id, field_name, field_type, source, order_index, creator, delete_type, create_time, update_time) VALUES (1681265757417, '当前累计专项附加扣除合计', 1681265757380, 'salaryItem_addUpSpeAddiDeduction', '{薪资项目.当前累计专项附加扣除合计}', 'number', 'salaryItem', 2, 92, 0, to_date('2022-05-10 16:03:02','yyyy-MM-dd HH24:mi:ss'), to_date('2022-05-10 16:03:02','yyyy-MM-dd HH24:mi:ss'))
|
||||||
|
/
|
||||||
|
INSERT INTO hrsa_formula_var(id, name, formula_id, field_id, field_name, field_type, source, order_index, creator, delete_type, create_time, update_time) VALUES (1681265757421, '当前累计专项扣除合计', 1681265757380, 'salaryItem_addUpSpecialDeduction', '{薪资项目.当前累计专项扣除合计}', 'number', 'salaryItem', 1, 92, 0, to_date('2022-05-10 16:03:02','yyyy-MM-dd HH24:mi:ss'), to_date('2022-05-10 16:03:02','yyyy-MM-dd HH24:mi:ss'))
|
||||||
|
/
|
||||||
|
INSERT INTO hrsa_formula_var(id, name, formula_id, field_id, field_name, field_type, source, order_index, creator, delete_type, create_time, update_time) VALUES (1681265757424, '当前累计应税收入合计', 1681265757380, 'salaryItem_addUpIncome', '{薪资项目.当前累计应税收入合计}', 'number', 'salaryItem', 0, 92, 0, to_date('2022-05-10 16:03:02','yyyy-MM-dd HH24:mi:ss'), to_date('2022-05-10 16:03:02','yyyy-MM-dd HH24:mi:ss'))
|
||||||
|
/
|
||||||
|
INSERT INTO hrsa_formula_var(id, name, formula_id, field_id, field_name, field_type, source, order_index, creator, delete_type, create_time, update_time) VALUES (1681265757428, '累计个人养老金', 1681265757380, 'salaryItem_addUpPrivatePension', '{薪资项目.累计个人养老金}', 'number', 'salaryItem', 6, 92, 0, to_date('2022-05-10 16:03:02','yyyy-MM-dd HH24:mi:ss'), to_date('2022-05-10 16:03:02','yyyy-MM-dd HH24:mi:ss'))
|
||||||
|
/
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
update hrsa_sys_salary_item set formula_id = 1681265757380 where name = '当前累计应纳税所得额' ;
|
||||||
|
update hrsa_salary_item set formula_id = 1681265757380 where name = '当前累计应纳税所得额';
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
update hrsa_sys_salary_item set formula_id = 1681265757380 where name = '当前累计应纳税所得额'
|
||||||
|
GO
|
||||||
|
update hrsa_salary_item set formula_id = 1681265757380 where name = '当前累计应纳税所得额'
|
||||||
|
GO
|
||||||
|
|
||||||
|
update hrsa_sys_salary_item set formula_id = 1681265757380 where name = '当前累计应纳税所得额'
|
||||||
|
/
|
||||||
|
update hrsa_salary_item set formula_id = 1681265757380 where name = '当前累计应纳税所得额'
|
||||||
|
/
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -1,3 +1,3 @@
|
||||||
update hrsa_formula set formula = 'if({薪资项目.当前累计应纳税所得额}<=36000){0;}else if({薪资项目.当前累计应纳税所得额}<=144000){2520;}else if({薪资项目.当前累计应纳税所得额}<=300000){16920;}else if({薪资项目.当前累计应纳税所得额}<=420000){31920;}else if({薪资项目.当前累计应纳税所得额}<=660000){52920;}else if({薪资项目.当前累计应纳税所得额}<=960000){85920;}else{181920;}' where id = 1651742702735 ;
|
update hrsa_formula set formula = '' where id = 1651742702735 ;
|
||||||
|
|
||||||
update hrsa_formula set formulaRunScript = 'if(salaryItem_addUpTaxableIncome<=36000){0;}else if(salaryItem_addUpTaxableIncome<=144000){2520;}else if(salaryItem_addUpTaxableIncome<=300000){16920;}else if(salaryItem_addUpTaxableIncome<=420000){31920;}else if(salaryItem_addUpTaxableIncome<=660000){52920;}else if(salaryItem_addUpTaxableIncome<=960000){85920;}else{181920;}' where id = 1651742702735 ;
|
update hrsa_formula set formulaRunScript = '' where id = 1651742702735 ;
|
||||||
|
|
@ -0,0 +1,9 @@
|
||||||
|
package com.api.salary.web;
|
||||||
|
|
||||||
|
|
||||||
|
import javax.ws.rs.Path;
|
||||||
|
|
||||||
|
@Path("/bs/hrmsalary/maintainer")
|
||||||
|
public class MaintainerController extends com.engine.salary.maintainer.MaintainerController{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -148,14 +148,14 @@ public class SIAccountBiz extends Service {
|
||||||
public PageInfo<InsuranceAccountDetailPO> listCommonPage(InsuranceAccountDetailParam queryParam) {
|
public PageInfo<InsuranceAccountDetailPO> listCommonPage(InsuranceAccountDetailParam queryParam) {
|
||||||
queryParam.setPaymentStatus(PaymentStatusEnum.COMMON.getValue());
|
queryParam.setPaymentStatus(PaymentStatusEnum.COMMON.getValue());
|
||||||
|
|
||||||
//过滤出需要核算的人员,即福利档案基础信息表中runStatus为正在缴纳和待减员的人员
|
// //过滤出需要核算的人员,即福利档案基础信息表中runStatus为正在缴纳和待减员的人员
|
||||||
List<InsuranceArchivesBaseInfoPO> baseInfoPOList = getInsuranceBaseInfoMapper().listAll();
|
// List<InsuranceArchivesBaseInfoPO> baseInfoPOList = getInsuranceBaseInfoMapper().listAll();
|
||||||
List<Long> canAccountIds = baseInfoPOList.stream()
|
// List<Long> canAccountIds = baseInfoPOList.stream()
|
||||||
.filter(f->f.getPaymentOrganization().toString().equals(queryParam.getPaymentOrganization())
|
// .filter(f->f.getPaymentOrganization().toString().equals(queryParam.getPaymentOrganization())
|
||||||
&& (f.getRunStatus().equals(EmployeeStatusEnum.PAYING.getValue()) || f.getRunStatus().equals(EmployeeStatusEnum.STAY_DEL.getValue())))
|
// && (f.getRunStatus().equals(EmployeeStatusEnum.PAYING.getValue()) || f.getRunStatus().equals(EmployeeStatusEnum.STAY_DEL.getValue())))
|
||||||
.map(InsuranceArchivesBaseInfoPO::getEmployeeId)
|
// .map(InsuranceArchivesBaseInfoPO::getEmployeeId)
|
||||||
.collect(Collectors.toList());
|
// .collect(Collectors.toList());
|
||||||
queryParam.setEmployeeIds(canAccountIds);
|
// queryParam.setEmployeeIds(canAccountIds);
|
||||||
//排序配置
|
//排序配置
|
||||||
OrderRuleVO orderRule = getSalarySysConfService(user).orderRule();
|
OrderRuleVO orderRule = getSalarySysConfService(user).orderRule();
|
||||||
queryParam.setOrderRule(orderRule);
|
queryParam.setOrderRule(orderRule);
|
||||||
|
|
@ -226,8 +226,8 @@ public class SIAccountBiz extends Service {
|
||||||
List<Long> employeeIds = getInsuranceAccountDetailMapper().selectEmpByPaymentOrg(paymentOrganization);
|
List<Long> employeeIds = getInsuranceAccountDetailMapper().selectEmpByPaymentOrg(paymentOrganization);
|
||||||
// employeeIds = employeeIds.stream().filter(employeeIdsInTaxAgent::contains).collect(Collectors.toList());
|
// employeeIds = employeeIds.stream().filter(employeeIdsInTaxAgent::contains).collect(Collectors.toList());
|
||||||
if (CollectionUtils.isEmpty(employeeIds)) {
|
if (CollectionUtils.isEmpty(employeeIds)) {
|
||||||
List<InsuranceAccountBatchPO> list = Lists.newArrayList(getInsuranceAccountBatchMapper().getByBillMonth(param.getBillMonth(), paymentOrganization));
|
List<InsuranceAccountDetailPO> list = Lists.newArrayList(getInsuranceAccountDetailMapper().queryNormalListByBillMonth(param.getBillMonth(), paymentOrganization));
|
||||||
encryptUtil.decryptList(list, InsuranceAccountBatchPO.class);
|
encryptUtil.decryptList(list, InsuranceAccountDetailPO.class);
|
||||||
if (CollectionUtils.isNotEmpty(list)) {
|
if (CollectionUtils.isNotEmpty(list)) {
|
||||||
list.stream().forEach(f -> {
|
list.stream().forEach(f -> {
|
||||||
getInsuranceAccountDetailMapper().deleteById(f.getId());
|
getInsuranceAccountDetailMapper().deleteById(f.getId());
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,48 @@
|
||||||
|
package com.engine.salary.biz;
|
||||||
|
|
||||||
|
import com.engine.salary.entity.hrm.SubCompanyInfo;
|
||||||
|
import org.apache.commons.lang3.StringUtils;
|
||||||
|
import weaver.conn.RecordSet;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
public class SubCompanyBiz {
|
||||||
|
|
||||||
|
public List<SubCompanyInfo> list() {
|
||||||
|
List<SubCompanyInfo> returnList = new ArrayList<>();
|
||||||
|
|
||||||
|
RecordSet rs = new RecordSet();
|
||||||
|
rs.executeQuery("select id, subcompanyname from HrmsubCompany");
|
||||||
|
while (rs.next()) {
|
||||||
|
returnList.add(
|
||||||
|
SubCompanyInfo.builder()
|
||||||
|
.id(Long.valueOf(rs.getString(1)))
|
||||||
|
.name(rs.getString(2)).build()
|
||||||
|
);
|
||||||
|
}
|
||||||
|
return returnList;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取所有上级分部
|
||||||
|
*
|
||||||
|
* @param subId
|
||||||
|
* @param returnList
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
public List<String> getSupSubCompanyLists(String subId, List<String> returnList) {
|
||||||
|
RecordSet rs = new RecordSet();
|
||||||
|
rs.executeSql("select supsubcomid from HrmsubCompany where id=" + subId);
|
||||||
|
while (rs.next()) {
|
||||||
|
String supsubcomid = rs.getString(1);
|
||||||
|
if (!StringUtils.equals(supsubcomid, "0")) {
|
||||||
|
returnList.add(supsubcomid);
|
||||||
|
getSupSubCompanyLists(supsubcomid, returnList);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return returnList;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -1,11 +1,7 @@
|
||||||
package com.engine.salary.cache;
|
package com.engine.salary.cache;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @description: 用于定义本服务内部使用的缓存key
|
* 用于定义本服务内部使用的缓存key
|
||||||
* @author: xiajun
|
|
||||||
* @modified By: xiajun
|
|
||||||
* @date: Created in 12/13/21 11:12 AM
|
|
||||||
* @version:v1.0
|
|
||||||
*/
|
*/
|
||||||
public class SalaryCacheKey {
|
public class SalaryCacheKey {
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,38 @@
|
||||||
|
package com.engine.salary.common;
|
||||||
|
|
||||||
|
import java.util.HashMap;
|
||||||
|
import java.util.Map;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 薪酬上下文
|
||||||
|
* <p>Copyright: Copyright (c) 2022</p>
|
||||||
|
* <p>Company: 泛微软件</p>
|
||||||
|
*
|
||||||
|
* @author qiantao
|
||||||
|
* @version 1.0
|
||||||
|
**/
|
||||||
|
public class SalaryContext {
|
||||||
|
public static ThreadLocal<SalaryContext> context = new ThreadLocal<SalaryContext>();
|
||||||
|
|
||||||
|
private Map<String, Object> map = new HashMap<>();
|
||||||
|
|
||||||
|
public static SalaryContext get() {
|
||||||
|
if (null == context.get()) {
|
||||||
|
context.set(new SalaryContext());
|
||||||
|
}
|
||||||
|
return context.get();
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setValue(String key, Object value) {
|
||||||
|
map.put(key, value);
|
||||||
|
}
|
||||||
|
|
||||||
|
public Object getValue(String key) {
|
||||||
|
return map.get(key);
|
||||||
|
}
|
||||||
|
|
||||||
|
public void removeContext() {
|
||||||
|
context.remove();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -112,6 +112,11 @@ public class TaxDeclarationDataIndexConstant {
|
||||||
*/
|
*/
|
||||||
public static final String ADD_UP_INFANT_CARE = "addUpInfantCare";
|
public static final String ADD_UP_INFANT_CARE = "addUpInfantCare";
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 累计个人养老金
|
||||||
|
*/
|
||||||
|
public static final String ADD_UP_PRIVATE_PENSION = "addUpPrivatePension";
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 累计专项附加扣除
|
* 累计专项附加扣除
|
||||||
*/
|
*/
|
||||||
|
|
|
||||||
|
|
@ -16,7 +16,6 @@ import java.lang.reflect.Field;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.Arrays;
|
import java.util.Arrays;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Map;
|
|
||||||
import java.util.stream.Collectors;
|
import java.util.stream.Collectors;
|
||||||
|
|
||||||
@Slf4j
|
@Slf4j
|
||||||
|
|
@ -90,7 +89,6 @@ public class EncryptUtil {
|
||||||
try {
|
try {
|
||||||
List<Field> fieldList = getFields(clazz);
|
List<Field> fieldList = getFields(clazz);
|
||||||
if (CollectionUtils.isNotEmpty(fieldList)) {
|
if (CollectionUtils.isNotEmpty(fieldList)) {
|
||||||
List<Map<String, String>> values = new ArrayList<>();
|
|
||||||
for (T data : dataList) {
|
for (T data : dataList) {
|
||||||
for (Field field : fieldList) {
|
for (Field field : fieldList) {
|
||||||
field.setAccessible(true);
|
field.setAccessible(true);
|
||||||
|
|
|
||||||
|
|
@ -1,49 +0,0 @@
|
||||||
package com.engine.salary.encrypt.archive;
|
|
||||||
|
|
||||||
import com.engine.salary.encrypt.AESEncryptUtil;
|
|
||||||
import com.engine.salary.entity.salaryarchive.po.SalaryArchiveItemPO;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* hrsa_salary_archive_item: 加解密
|
|
||||||
* 字段:
|
|
||||||
* item_value
|
|
||||||
*/
|
|
||||||
@Deprecated
|
|
||||||
public class SalaryArchiveItemPOEncrypt {
|
|
||||||
public static List<SalaryArchiveItemPO> encryptSalaryArchiveItemPOList(List<SalaryArchiveItemPO> list) {
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setItemValue(AESEncryptUtil.encrypt(item.getItemValue()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static List<SalaryArchiveItemPO> decryptSalaryArchiveItemPOList(List<SalaryArchiveItemPO> list) {
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setItemValue(AESEncryptUtil.decrypt(item.getItemValue()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static SalaryArchiveItemPO encryptSalaryArchiveItemPO(SalaryArchiveItemPO item) {
|
|
||||||
if(item == null) {
|
|
||||||
return item; }
|
|
||||||
item.setItemValue(AESEncryptUtil.encrypt(item.getItemValue()));
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static SalaryArchiveItemPO decryptSalaryArchiveItemPO(SalaryArchiveItemPO item) {
|
|
||||||
if(item == null) {
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
item.setItemValue(AESEncryptUtil.decrypt(item.getItemValue()));
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
@ -1,20 +0,0 @@
|
||||||
package com.engine.salary.encrypt.archive;
|
|
||||||
|
|
||||||
import com.engine.salary.encrypt.AESEncryptUtil;
|
|
||||||
import com.engine.salary.entity.salaryarchive.dto.SalaryItemAdjustRecordListDTO;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
@Deprecated
|
|
||||||
public class SalaryItemAdjustRecordListDTOEncrypt {
|
|
||||||
public static List<SalaryItemAdjustRecordListDTO> decryptSalaryItemAdjustRecordListDTOList(List<SalaryItemAdjustRecordListDTO> list) {
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setAdjustBefore(AESEncryptUtil.decrypt(item.getAdjustBefore()));
|
|
||||||
item.setAdjustAfter(AESEncryptUtil.decrypt(item.getAdjustAfter()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
@ -1,78 +0,0 @@
|
||||||
package com.engine.salary.encrypt.datacollection;
|
|
||||||
|
|
||||||
import com.engine.salary.encrypt.AESEncryptUtil;
|
|
||||||
import com.engine.salary.entity.datacollection.AddUpDeduction;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* hrsa_add_up_deduction: 数据加解密
|
|
||||||
* 字段:
|
|
||||||
* add_up_child_education
|
|
||||||
* add_up_continuing_education
|
|
||||||
* add_up_housing_loan_interest
|
|
||||||
* add_up_housing_rent
|
|
||||||
* add_up_support_elderly
|
|
||||||
* add_up_illness_medical
|
|
||||||
* add_up_infant_care
|
|
||||||
*/
|
|
||||||
@Deprecated
|
|
||||||
public class AddUpDeductionEncrypt {
|
|
||||||
@Deprecated
|
|
||||||
public static List<AddUpDeduction> encryptAddUpDeductionList(List<AddUpDeduction> list) {
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setAddUpChildEducation(AESEncryptUtil.encrypt(item.getAddUpChildEducation()));
|
|
||||||
item.setAddUpContinuingEducation(AESEncryptUtil.encrypt(item.getAddUpContinuingEducation()));
|
|
||||||
item.setAddUpHousingLoanInterest(AESEncryptUtil.encrypt(item.getAddUpHousingLoanInterest()));
|
|
||||||
item.setAddUpHousingRent(AESEncryptUtil.encrypt(item.getAddUpHousingRent()));
|
|
||||||
item.setAddUpSupportElderly(AESEncryptUtil.encrypt(item.getAddUpSupportElderly()));
|
|
||||||
item.setAddUpIllnessMedical(AESEncryptUtil.encrypt(item.getAddUpIllnessMedical()));
|
|
||||||
item.setAddUpInfantCare(AESEncryptUtil.encrypt(item.getAddUpInfantCare()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Deprecated
|
|
||||||
public static List<AddUpDeduction> decryptAddUpDeductionList(List<AddUpDeduction> list) {
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setAddUpChildEducation(AESEncryptUtil.decrypt(item.getAddUpChildEducation()));
|
|
||||||
item.setAddUpContinuingEducation(AESEncryptUtil.decrypt(item.getAddUpContinuingEducation()));
|
|
||||||
item.setAddUpHousingLoanInterest(AESEncryptUtil.decrypt(item.getAddUpHousingLoanInterest()));
|
|
||||||
item.setAddUpHousingRent(AESEncryptUtil.decrypt(item.getAddUpHousingRent()));
|
|
||||||
item.setAddUpSupportElderly(AESEncryptUtil.decrypt(item.getAddUpSupportElderly()));
|
|
||||||
item.setAddUpIllnessMedical(AESEncryptUtil.decrypt(item.getAddUpIllnessMedical()));
|
|
||||||
item.setAddUpInfantCare(AESEncryptUtil.decrypt(item.getAddUpInfantCare()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Deprecated
|
|
||||||
public static AddUpDeduction encryptAddUpDeduction(AddUpDeduction item) {
|
|
||||||
if(item == null) {
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
item.setAddUpChildEducation(AESEncryptUtil.encrypt(item.getAddUpChildEducation()));
|
|
||||||
item.setAddUpContinuingEducation(AESEncryptUtil.encrypt(item.getAddUpContinuingEducation()));
|
|
||||||
item.setAddUpHousingLoanInterest(AESEncryptUtil.encrypt(item.getAddUpHousingLoanInterest()));
|
|
||||||
item.setAddUpHousingRent(AESEncryptUtil.encrypt(item.getAddUpHousingRent()));
|
|
||||||
item.setAddUpSupportElderly(AESEncryptUtil.encrypt(item.getAddUpSupportElderly()));
|
|
||||||
item.setAddUpIllnessMedical(AESEncryptUtil.encrypt(item.getAddUpIllnessMedical()));
|
|
||||||
item.setAddUpInfantCare(AESEncryptUtil.encrypt(item.getAddUpInfantCare()));
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Deprecated
|
|
||||||
public static AddUpDeduction decryptAddUpDeduction(AddUpDeduction item) {
|
|
||||||
if(item == null) {
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
item.setAddUpChildEducation(AESEncryptUtil.decrypt(item.getAddUpChildEducation()));
|
|
||||||
item.setAddUpContinuingEducation(AESEncryptUtil.decrypt(item.getAddUpContinuingEducation()));
|
|
||||||
item.setAddUpHousingLoanInterest(AESEncryptUtil.decrypt(item.getAddUpHousingLoanInterest()));
|
|
||||||
item.setAddUpHousingRent(AESEncryptUtil.decrypt(item.getAddUpHousingRent()));
|
|
||||||
item.setAddUpSupportElderly(AESEncryptUtil.decrypt(item.getAddUpSupportElderly()));
|
|
||||||
item.setAddUpIllnessMedical(AESEncryptUtil.decrypt(item.getAddUpIllnessMedical()));
|
|
||||||
item.setAddUpInfantCare(AESEncryptUtil.decrypt(item.getAddUpInfantCare()));
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
@ -1,55 +0,0 @@
|
||||||
package com.engine.salary.encrypt.datacollection;
|
|
||||||
|
|
||||||
import com.engine.salary.encrypt.AESEncryptUtil;
|
|
||||||
import com.engine.salary.entity.datacollection.dto.AddUpDeductionRecordDTO;
|
|
||||||
|
|
||||||
import java.util.ArrayList;
|
|
||||||
import java.util.List;
|
|
||||||
import java.util.stream.Collectors;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* hrsa_add_up_deduction: 数据加解密
|
|
||||||
* 字段:
|
|
||||||
* add_up_child_education
|
|
||||||
* add_up_continuing_education
|
|
||||||
* add_up_housing_loan_interest
|
|
||||||
* add_up_housing_rent
|
|
||||||
* add_up_support_elderly
|
|
||||||
*/
|
|
||||||
@Deprecated
|
|
||||||
public class AddUpDeductionRecordStrDTOEncrypt {
|
|
||||||
public static List<AddUpDeductionRecordDTO> decryptAddUpDeductionRecordDTO(List<AddUpDeductionRecordDTO> list) {
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return new ArrayList<>();
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setAddUpChildEducation(AESEncryptUtil.decrypt(item.getAddUpChildEducation()));
|
|
||||||
item.setAddUpContinuingEducation(AESEncryptUtil.decrypt(item.getAddUpContinuingEducation()));
|
|
||||||
item.setAddUpHousingLoanInterest(AESEncryptUtil.decrypt(item.getAddUpHousingLoanInterest()));
|
|
||||||
item.setAddUpHousingRent(AESEncryptUtil.decrypt(item.getAddUpHousingRent()));
|
|
||||||
item.setAddUpSupportElderly(AESEncryptUtil.decrypt(item.getAddUpSupportElderly()));
|
|
||||||
item.setAddUpIllnessMedical(AESEncryptUtil.decrypt(item.getAddUpIllnessMedical()));
|
|
||||||
item.setAddUpInfantCare(AESEncryptUtil.decrypt(item.getAddUpInfantCare()));
|
|
||||||
});
|
|
||||||
return list.stream().map(item -> {
|
|
||||||
return AddUpDeductionRecordDTO.builder()
|
|
||||||
.id(item.getId())
|
|
||||||
.employeeId(item.getEmployeeId())
|
|
||||||
.username(item.getUsername())
|
|
||||||
.declareMonth(item.getDeclareMonth())
|
|
||||||
.taxAgentName(item.getTaxAgentName())
|
|
||||||
.taxAgentId(item.getTaxAgentId())
|
|
||||||
.departmentName(item.getDepartmentName())
|
|
||||||
.mobile(item.getMobile())
|
|
||||||
.jobNum(item.getJobNum())
|
|
||||||
.addUpChildEducation(item.getAddUpChildEducation())
|
|
||||||
.addUpContinuingEducation(item.getAddUpContinuingEducation())
|
|
||||||
.addUpHousingLoanInterest(item.getAddUpHousingLoanInterest())
|
|
||||||
.addUpHousingRent(item.getAddUpHousingRent())
|
|
||||||
.addUpSupportElderly(item.getAddUpSupportElderly())
|
|
||||||
.addUpIllnessMedical(item.getAddUpIllnessMedical())
|
|
||||||
.addUpInfantCare(item.getAddUpInfantCare())
|
|
||||||
.build();
|
|
||||||
}).collect(Collectors.toList());
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
@ -1,35 +0,0 @@
|
||||||
package com.engine.salary.encrypt.datacollection;
|
|
||||||
|
|
||||||
import com.engine.salary.encrypt.AESEncryptUtil;
|
|
||||||
import com.engine.salary.entity.datacollection.dto.AddUpDeductionDTO;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* hrsa_add_up_deduction: 数据加解密
|
|
||||||
* 字段:
|
|
||||||
* add_up_child_education
|
|
||||||
* add_up_continuing_education
|
|
||||||
* add_up_housing_loan_interest
|
|
||||||
* add_up_housing_rent
|
|
||||||
* add_up_support_elderly
|
|
||||||
*/
|
|
||||||
@Deprecated
|
|
||||||
public class AddUpDeductionStrDTOEncrypt {
|
|
||||||
public static void decryptAddUpDeductionList(List<AddUpDeductionDTO> list) {
|
|
||||||
if (list == null || list.size() == 0) {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setAddUpChildEducation(AESEncryptUtil.decrypt(item.getAddUpChildEducation()));
|
|
||||||
item.setAddUpContinuingEducation(AESEncryptUtil.decrypt(item.getAddUpContinuingEducation()));
|
|
||||||
item.setAddUpHousingLoanInterest(AESEncryptUtil.decrypt(item.getAddUpHousingLoanInterest()));
|
|
||||||
item.setAddUpHousingRent(AESEncryptUtil.decrypt(item.getAddUpHousingRent()));
|
|
||||||
item.setAddUpSupportElderly(AESEncryptUtil.decrypt(item.getAddUpSupportElderly()));
|
|
||||||
item.setAddUpIllnessMedical(AESEncryptUtil.decrypt(item.getAddUpIllnessMedical()));
|
|
||||||
item.setAddUpInfantCare(AESEncryptUtil.decrypt(item.getAddUpInfantCare()));
|
|
||||||
});
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
@ -1,81 +0,0 @@
|
||||||
package com.engine.salary.encrypt.datacollection;
|
|
||||||
|
|
||||||
import com.engine.salary.encrypt.AESEncryptUtil;
|
|
||||||
import com.engine.salary.entity.datacollection.dto.AddUpSituationDTO;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* hrsa_add_up_situation: 加解密
|
|
||||||
* 字段:
|
|
||||||
* add_up_income
|
|
||||||
* add_up_subtraction
|
|
||||||
* add_up_social_security_total
|
|
||||||
* add_up_accumulation_fund_total
|
|
||||||
* add_up_child_education
|
|
||||||
* add_up_continuing_education
|
|
||||||
* add_up_housing_loan_interest
|
|
||||||
* add_up_housing_rent
|
|
||||||
* add_up_support_elderly
|
|
||||||
* add_up_enterprise_and_other
|
|
||||||
* add_up_other_deduction
|
|
||||||
* add_up_tax_exempt_income
|
|
||||||
* add_up_allowed_donation
|
|
||||||
* add_up_advance_tax
|
|
||||||
*/
|
|
||||||
@Deprecated
|
|
||||||
public class AddUpSituationDTOEncrypt {
|
|
||||||
public static List<AddUpSituationDTO> encryptAddUpSituationDTOList(List<AddUpSituationDTO> list) {
|
|
||||||
if (list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setAddUpIncome(AESEncryptUtil.encrypt(item.getAddUpIncome()));
|
|
||||||
item.setAddUpSubtraction(AESEncryptUtil.encrypt(item.getAddUpSubtraction()));
|
|
||||||
item.setAddUpSocialSecurityTotal(AESEncryptUtil.encrypt(item.getAddUpSocialSecurityTotal()));
|
|
||||||
item.setAddUpAccumulationFundTotal(AESEncryptUtil.encrypt(item.getAddUpAccumulationFundTotal()));
|
|
||||||
item.setAddUpChildEducation(AESEncryptUtil.encrypt(item.getAddUpChildEducation()));
|
|
||||||
item.setAddUpContinuingEducation(AESEncryptUtil.encrypt(item.getAddUpContinuingEducation()));
|
|
||||||
item.setAddUpHousingLoanInterest(AESEncryptUtil.encrypt(item.getAddUpHousingLoanInterest()));
|
|
||||||
item.setAddUpHousingRent(AESEncryptUtil.encrypt(item.getAddUpHousingRent()));
|
|
||||||
item.setAddUpSupportElderly(AESEncryptUtil.encrypt(item.getAddUpSupportElderly()));
|
|
||||||
item.setAddUpEnterpriseAndOther(AESEncryptUtil.encrypt(item.getAddUpEnterpriseAndOther()));
|
|
||||||
item.setAddUpTaxExemptIncome(AESEncryptUtil.encrypt(item.getAddUpTaxExemptIncome()));
|
|
||||||
item.setAddUpAllowedDonation(AESEncryptUtil.encrypt(item.getAddUpAllowedDonation()));
|
|
||||||
item.setAddUpAdvanceTax(AESEncryptUtil.encrypt(item.getAddUpAdvanceTax()));
|
|
||||||
|
|
||||||
item.setAddUpIllnessMedical(AESEncryptUtil.encrypt(item.getAddUpIllnessMedical()));
|
|
||||||
item.setAddUpOtherDeduction(AESEncryptUtil.encrypt(item.getAddUpOtherDeduction()));
|
|
||||||
item.setAddUpTaxSavings(AESEncryptUtil.encrypt(item.getAddUpTaxSavings()));
|
|
||||||
item.setAddUpInfantCare(AESEncryptUtil.encrypt(item.getAddUpInfantCare()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static List<AddUpSituationDTO> decryptAddUpSituationDTOList(List<AddUpSituationDTO> list) {
|
|
||||||
if (list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setAddUpIncome(AESEncryptUtil.decrypt(item.getAddUpIncome()));
|
|
||||||
item.setAddUpSubtraction(AESEncryptUtil.decrypt(item.getAddUpSubtraction()));
|
|
||||||
item.setAddUpSocialSecurityTotal(AESEncryptUtil.decrypt(item.getAddUpSocialSecurityTotal()));
|
|
||||||
item.setAddUpAccumulationFundTotal(AESEncryptUtil.decrypt(item.getAddUpAccumulationFundTotal()));
|
|
||||||
item.setAddUpChildEducation(AESEncryptUtil.decrypt(item.getAddUpChildEducation()));
|
|
||||||
item.setAddUpContinuingEducation(AESEncryptUtil.decrypt(item.getAddUpContinuingEducation()));
|
|
||||||
item.setAddUpHousingLoanInterest(AESEncryptUtil.decrypt(item.getAddUpHousingLoanInterest()));
|
|
||||||
item.setAddUpHousingRent(AESEncryptUtil.decrypt(item.getAddUpHousingRent()));
|
|
||||||
item.setAddUpSupportElderly(AESEncryptUtil.decrypt(item.getAddUpSupportElderly()));
|
|
||||||
item.setAddUpEnterpriseAndOther(AESEncryptUtil.decrypt(item.getAddUpEnterpriseAndOther()));
|
|
||||||
item.setAddUpTaxExemptIncome(AESEncryptUtil.decrypt(item.getAddUpTaxExemptIncome()));
|
|
||||||
item.setAddUpAllowedDonation(AESEncryptUtil.decrypt(item.getAddUpAllowedDonation()));
|
|
||||||
item.setAddUpAdvanceTax(AESEncryptUtil.decrypt(item.getAddUpAdvanceTax()));
|
|
||||||
|
|
||||||
item.setAddUpIllnessMedical(AESEncryptUtil.decrypt(item.getAddUpIllnessMedical()));
|
|
||||||
item.setAddUpOtherDeduction(AESEncryptUtil.decrypt(item.getAddUpOtherDeduction()));
|
|
||||||
item.setAddUpTaxSavings(AESEncryptUtil.decrypt(item.getAddUpTaxSavings()));
|
|
||||||
item.setAddUpInfantCare(AESEncryptUtil.decrypt(item.getAddUpInfantCare()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
@ -1,132 +0,0 @@
|
||||||
package com.engine.salary.encrypt.datacollection;
|
|
||||||
|
|
||||||
import com.engine.salary.encrypt.AESEncryptUtil;
|
|
||||||
import com.engine.salary.entity.datacollection.AddUpSituation;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* hrsa_add_up_situation: 加解密
|
|
||||||
* 字段:
|
|
||||||
* add_up_income
|
|
||||||
* add_up_subtraction
|
|
||||||
* add_up_social_security_total
|
|
||||||
* add_up_accumulation_fund_total
|
|
||||||
* add_up_child_education
|
|
||||||
* add_up_continuing_education
|
|
||||||
* add_up_housing_loan_interest
|
|
||||||
* add_up_housing_rent
|
|
||||||
* add_up_support_elderly
|
|
||||||
* add_up_enterprise_and_other
|
|
||||||
* add_up_other_deduction
|
|
||||||
* add_up_tax_exempt_income
|
|
||||||
* add_up_allowed_donation
|
|
||||||
* add_up_advance_tax
|
|
||||||
*/
|
|
||||||
@Deprecated
|
|
||||||
public class AddUpSituationEncrypt {
|
|
||||||
public static List<AddUpSituation> encryptAddUpSituationList(List<AddUpSituation> list) {
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setAddUpIncome(AESEncryptUtil.encrypt(item.getAddUpIncome()));
|
|
||||||
item.setAddUpSubtraction(AESEncryptUtil.encrypt(item.getAddUpSubtraction()));
|
|
||||||
item.setAddUpSocialSecurityTotal(AESEncryptUtil.encrypt(item.getAddUpSocialSecurityTotal()));
|
|
||||||
item.setAddUpAccumulationFundTotal(AESEncryptUtil.encrypt(item.getAddUpAccumulationFundTotal()));
|
|
||||||
item.setAddUpChildEducation(AESEncryptUtil.encrypt(item.getAddUpChildEducation()));
|
|
||||||
item.setAddUpContinuingEducation(AESEncryptUtil.encrypt(item.getAddUpContinuingEducation()));
|
|
||||||
item.setAddUpHousingLoanInterest(AESEncryptUtil.encrypt(item.getAddUpHousingLoanInterest()));
|
|
||||||
item.setAddUpHousingRent(AESEncryptUtil.encrypt(item.getAddUpHousingRent()));
|
|
||||||
item.setAddUpSupportElderly(AESEncryptUtil.encrypt(item.getAddUpSupportElderly()));
|
|
||||||
item.setAddUpEnterpriseAndOther(AESEncryptUtil.encrypt(item.getAddUpEnterpriseAndOther()));
|
|
||||||
item.setAddUpTaxExemptIncome(AESEncryptUtil.encrypt(item.getAddUpTaxExemptIncome()));
|
|
||||||
item.setAddUpAllowedDonation(AESEncryptUtil.encrypt(item.getAddUpAllowedDonation()));
|
|
||||||
item.setAddUpAdvanceTax(AESEncryptUtil.encrypt(item.getAddUpAdvanceTax()));
|
|
||||||
|
|
||||||
item.setAddUpIllnessMedical(AESEncryptUtil.encrypt(item.getAddUpIllnessMedical()));
|
|
||||||
item.setAddUpOtherDeduction(AESEncryptUtil.encrypt(item.getAddUpOtherDeduction()));
|
|
||||||
item.setAddUpTaxSavings(AESEncryptUtil.encrypt(item.getAddUpTaxSavings()));
|
|
||||||
item.setAddUpInfantCare(AESEncryptUtil.encrypt(item.getAddUpInfantCare()));
|
|
||||||
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static List<AddUpSituation> decryptAddUpSituationList(List<AddUpSituation> list) {
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setAddUpIncome(AESEncryptUtil.decrypt(item.getAddUpIncome()));
|
|
||||||
item.setAddUpSubtraction(AESEncryptUtil.decrypt(item.getAddUpSubtraction()));
|
|
||||||
item.setAddUpSocialSecurityTotal(AESEncryptUtil.decrypt(item.getAddUpSocialSecurityTotal()));
|
|
||||||
item.setAddUpAccumulationFundTotal(AESEncryptUtil.decrypt(item.getAddUpAccumulationFundTotal()));
|
|
||||||
item.setAddUpChildEducation(AESEncryptUtil.decrypt(item.getAddUpChildEducation()));
|
|
||||||
item.setAddUpContinuingEducation(AESEncryptUtil.decrypt(item.getAddUpContinuingEducation()));
|
|
||||||
item.setAddUpHousingLoanInterest(AESEncryptUtil.decrypt(item.getAddUpHousingLoanInterest()));
|
|
||||||
item.setAddUpHousingRent(AESEncryptUtil.decrypt(item.getAddUpHousingRent()));
|
|
||||||
item.setAddUpSupportElderly(AESEncryptUtil.decrypt(item.getAddUpSupportElderly()));
|
|
||||||
item.setAddUpEnterpriseAndOther(AESEncryptUtil.decrypt(item.getAddUpEnterpriseAndOther()));
|
|
||||||
item.setAddUpTaxExemptIncome(AESEncryptUtil.decrypt(item.getAddUpTaxExemptIncome()));
|
|
||||||
item.setAddUpAllowedDonation(AESEncryptUtil.decrypt(item.getAddUpAllowedDonation()));
|
|
||||||
item.setAddUpAdvanceTax(AESEncryptUtil.decrypt(item.getAddUpAdvanceTax()));
|
|
||||||
|
|
||||||
item.setAddUpIllnessMedical(AESEncryptUtil.decrypt(item.getAddUpIllnessMedical()));
|
|
||||||
item.setAddUpOtherDeduction(AESEncryptUtil.decrypt(item.getAddUpOtherDeduction()));
|
|
||||||
item.setAddUpTaxSavings(AESEncryptUtil.decrypt(item.getAddUpTaxSavings()));
|
|
||||||
item.setAddUpInfantCare(AESEncryptUtil.decrypt(item.getAddUpInfantCare()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static AddUpSituation encryptAddUpSituation(AddUpSituation item) {
|
|
||||||
if(item == null) {
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
item.setAddUpIncome(AESEncryptUtil.encrypt(item.getAddUpIncome()));
|
|
||||||
item.setAddUpSubtraction(AESEncryptUtil.encrypt(item.getAddUpSubtraction()));
|
|
||||||
item.setAddUpSocialSecurityTotal(AESEncryptUtil.encrypt(item.getAddUpSocialSecurityTotal()));
|
|
||||||
item.setAddUpAccumulationFundTotal(AESEncryptUtil.encrypt(item.getAddUpAccumulationFundTotal()));
|
|
||||||
item.setAddUpChildEducation(AESEncryptUtil.encrypt(item.getAddUpChildEducation()));
|
|
||||||
item.setAddUpContinuingEducation(AESEncryptUtil.encrypt(item.getAddUpContinuingEducation()));
|
|
||||||
item.setAddUpHousingLoanInterest(AESEncryptUtil.encrypt(item.getAddUpHousingLoanInterest()));
|
|
||||||
item.setAddUpHousingRent(AESEncryptUtil.encrypt(item.getAddUpHousingRent()));
|
|
||||||
item.setAddUpSupportElderly(AESEncryptUtil.encrypt(item.getAddUpSupportElderly()));
|
|
||||||
item.setAddUpEnterpriseAndOther(AESEncryptUtil.encrypt(item.getAddUpEnterpriseAndOther()));
|
|
||||||
item.setAddUpTaxExemptIncome(AESEncryptUtil.encrypt(item.getAddUpTaxExemptIncome()));
|
|
||||||
item.setAddUpAllowedDonation(AESEncryptUtil.encrypt(item.getAddUpAllowedDonation()));
|
|
||||||
item.setAddUpAdvanceTax(AESEncryptUtil.encrypt(item.getAddUpAdvanceTax()));
|
|
||||||
|
|
||||||
item.setAddUpIllnessMedical(AESEncryptUtil.encrypt(item.getAddUpIllnessMedical()));
|
|
||||||
item.setAddUpOtherDeduction(AESEncryptUtil.encrypt(item.getAddUpOtherDeduction()));
|
|
||||||
item.setAddUpTaxSavings(AESEncryptUtil.encrypt(item.getAddUpTaxSavings()));
|
|
||||||
item.setAddUpInfantCare(AESEncryptUtil.encrypt(item.getAddUpInfantCare()));
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static AddUpSituation decryptAddUpSituation(AddUpSituation item) {
|
|
||||||
if(item == null) {
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
item.setAddUpIncome(AESEncryptUtil.decrypt(item.getAddUpIncome()));
|
|
||||||
item.setAddUpSubtraction(AESEncryptUtil.decrypt(item.getAddUpSubtraction()));
|
|
||||||
item.setAddUpSocialSecurityTotal(AESEncryptUtil.decrypt(item.getAddUpSocialSecurityTotal()));
|
|
||||||
item.setAddUpAccumulationFundTotal(AESEncryptUtil.decrypt(item.getAddUpAccumulationFundTotal()));
|
|
||||||
item.setAddUpChildEducation(AESEncryptUtil.decrypt(item.getAddUpChildEducation()));
|
|
||||||
item.setAddUpContinuingEducation(AESEncryptUtil.decrypt(item.getAddUpContinuingEducation()));
|
|
||||||
item.setAddUpHousingLoanInterest(AESEncryptUtil.decrypt(item.getAddUpHousingLoanInterest()));
|
|
||||||
item.setAddUpHousingRent(AESEncryptUtil.decrypt(item.getAddUpHousingRent()));
|
|
||||||
item.setAddUpSupportElderly(AESEncryptUtil.decrypt(item.getAddUpSupportElderly()));
|
|
||||||
item.setAddUpEnterpriseAndOther(AESEncryptUtil.decrypt(item.getAddUpEnterpriseAndOther()));
|
|
||||||
item.setAddUpTaxExemptIncome(AESEncryptUtil.decrypt(item.getAddUpTaxExemptIncome()));
|
|
||||||
item.setAddUpAllowedDonation(AESEncryptUtil.decrypt(item.getAddUpAllowedDonation()));
|
|
||||||
item.setAddUpAdvanceTax(AESEncryptUtil.decrypt(item.getAddUpAdvanceTax()));
|
|
||||||
|
|
||||||
item.setAddUpIllnessMedical(AESEncryptUtil.encrypt(item.getAddUpIllnessMedical()));
|
|
||||||
item.setAddUpOtherDeduction(AESEncryptUtil.encrypt(item.getAddUpOtherDeduction()));
|
|
||||||
item.setAddUpTaxSavings(AESEncryptUtil.encrypt(item.getAddUpTaxSavings()));
|
|
||||||
item.setAddUpInfantCare(AESEncryptUtil.encrypt(item.getAddUpInfantCare()));
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
@ -1,64 +0,0 @@
|
||||||
package com.engine.salary.encrypt.datacollection;
|
|
||||||
|
|
||||||
import com.engine.salary.encrypt.AESEncryptUtil;
|
|
||||||
import com.engine.salary.entity.datacollection.dto.AddUpSituationRecordDTO;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
@Deprecated
|
|
||||||
public class AddUpSituationRecordDTOEncrypt {
|
|
||||||
public static List<AddUpSituationRecordDTO> encryptAddUpSituationRecordDTOList(List<AddUpSituationRecordDTO> list) {
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setAddUpIncome(AESEncryptUtil.encrypt(item.getAddUpIncome()));
|
|
||||||
item.setAddUpSubtraction(AESEncryptUtil.encrypt(item.getAddUpSubtraction()));
|
|
||||||
item.setAddUpSocialSecurityTotal(AESEncryptUtil.encrypt(item.getAddUpSocialSecurityTotal()));
|
|
||||||
item.setAddUpAccumulationFundTotal(AESEncryptUtil.encrypt(item.getAddUpAccumulationFundTotal()));
|
|
||||||
item.setAddUpChildEducation(AESEncryptUtil.encrypt(item.getAddUpChildEducation()));
|
|
||||||
item.setAddUpContinuingEducation(AESEncryptUtil.encrypt(item.getAddUpContinuingEducation()));
|
|
||||||
item.setAddUpHousingLoanInterest(AESEncryptUtil.encrypt(item.getAddUpHousingLoanInterest()));
|
|
||||||
item.setAddUpHousingRent(AESEncryptUtil.encrypt(item.getAddUpHousingRent()));
|
|
||||||
item.setAddUpSupportElderly(AESEncryptUtil.encrypt(item.getAddUpSupportElderly()));
|
|
||||||
|
|
||||||
item.setAddUpIllnessMedical(AESEncryptUtil.encrypt(item.getAddUpIllnessMedical()));
|
|
||||||
item.setAddUpOtherDeduction(AESEncryptUtil.encrypt(item.getAddUpOtherDeduction()));
|
|
||||||
item.setAddUpTaxSavings(AESEncryptUtil.encrypt(item.getAddUpTaxSavings()));
|
|
||||||
item.setAddUpInfantCare(AESEncryptUtil.encrypt(item.getAddUpInfantCare()));
|
|
||||||
|
|
||||||
item.setAddUpEnterpriseAndOther(AESEncryptUtil.encrypt(item.getAddUpEnterpriseAndOther()));
|
|
||||||
item.setAddUpTaxExemptIncome(AESEncryptUtil.encrypt(item.getAddUpTaxExemptIncome()));
|
|
||||||
item.setAddUpAllowedDonation(AESEncryptUtil.encrypt(item.getAddUpAllowedDonation()));
|
|
||||||
item.setAddUpAdvanceTax(AESEncryptUtil.encrypt(item.getAddUpAdvanceTax()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static List<AddUpSituationRecordDTO> decryptAddUpSituationRecordDTOList(List<AddUpSituationRecordDTO> list) {
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setAddUpIncome(AESEncryptUtil.decrypt(item.getAddUpIncome()));
|
|
||||||
item.setAddUpSubtraction(AESEncryptUtil.decrypt(item.getAddUpSubtraction()));
|
|
||||||
item.setAddUpSocialSecurityTotal(AESEncryptUtil.decrypt(item.getAddUpSocialSecurityTotal()));
|
|
||||||
item.setAddUpAccumulationFundTotal(AESEncryptUtil.decrypt(item.getAddUpAccumulationFundTotal()));
|
|
||||||
item.setAddUpChildEducation(AESEncryptUtil.decrypt(item.getAddUpChildEducation()));
|
|
||||||
item.setAddUpContinuingEducation(AESEncryptUtil.decrypt(item.getAddUpContinuingEducation()));
|
|
||||||
item.setAddUpHousingLoanInterest(AESEncryptUtil.decrypt(item.getAddUpHousingLoanInterest()));
|
|
||||||
item.setAddUpHousingRent(AESEncryptUtil.decrypt(item.getAddUpHousingRent()));
|
|
||||||
item.setAddUpSupportElderly(AESEncryptUtil.decrypt(item.getAddUpSupportElderly()));
|
|
||||||
item.setAddUpEnterpriseAndOther(AESEncryptUtil.decrypt(item.getAddUpEnterpriseAndOther()));
|
|
||||||
item.setAddUpTaxExemptIncome(AESEncryptUtil.decrypt(item.getAddUpTaxExemptIncome()));
|
|
||||||
item.setAddUpAllowedDonation(AESEncryptUtil.decrypt(item.getAddUpAllowedDonation()));
|
|
||||||
item.setAddUpAdvanceTax(AESEncryptUtil.decrypt(item.getAddUpAdvanceTax()));
|
|
||||||
|
|
||||||
item.setAddUpIllnessMedical(AESEncryptUtil.decrypt(item.getAddUpIllnessMedical()));
|
|
||||||
item.setAddUpOtherDeduction(AESEncryptUtil.decrypt(item.getAddUpOtherDeduction()));
|
|
||||||
item.setAddUpTaxSavings(AESEncryptUtil.decrypt(item.getAddUpTaxSavings()));
|
|
||||||
item.setAddUpInfantCare(AESEncryptUtil.decrypt(item.getAddUpInfantCare()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
@ -1,66 +0,0 @@
|
||||||
package com.engine.salary.encrypt.datacollection;
|
|
||||||
|
|
||||||
import com.engine.salary.encrypt.AESEncryptUtil;
|
|
||||||
import com.engine.salary.entity.datacollection.dto.OtherDeductionListDTO;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* hrsa_other_deduction: 加解密
|
|
||||||
* 字段:
|
|
||||||
* business_healthy_insurance
|
|
||||||
* tax_delay_endowment_insurance
|
|
||||||
* other_deduction
|
|
||||||
* deduction_allowed_donation
|
|
||||||
*/
|
|
||||||
@Deprecated
|
|
||||||
public class OtherDeductionListDTOEncrypt {
|
|
||||||
public static List<OtherDeductionListDTO> encryptOtherDeductionListDTOList(List<OtherDeductionListDTO> list) {
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setBusinessHealthyInsurance(AESEncryptUtil.encrypt(item.getBusinessHealthyInsurance()));
|
|
||||||
item.setTaxDelayEndowmentInsurance(AESEncryptUtil.encrypt(item.getTaxDelayEndowmentInsurance()));
|
|
||||||
item.setOtherDeduction(AESEncryptUtil.encrypt(item.getOtherDeduction()));
|
|
||||||
item.setDeductionAllowedDonation(AESEncryptUtil.encrypt(item.getDeductionAllowedDonation()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static List<OtherDeductionListDTO> decryptOtherDeductionListDTOList(List<OtherDeductionListDTO> list) {
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setBusinessHealthyInsurance(AESEncryptUtil.decrypt(item.getBusinessHealthyInsurance()));
|
|
||||||
item.setTaxDelayEndowmentInsurance(AESEncryptUtil.decrypt(item.getTaxDelayEndowmentInsurance()));
|
|
||||||
item.setOtherDeduction(AESEncryptUtil.decrypt(item.getOtherDeduction()));
|
|
||||||
item.setDeductionAllowedDonation(AESEncryptUtil.decrypt(item.getDeductionAllowedDonation()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static OtherDeductionListDTO encryptOtherDeductionListDTO(OtherDeductionListDTO item) {
|
|
||||||
if(item == null) {
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
item.setBusinessHealthyInsurance(AESEncryptUtil.encrypt(item.getBusinessHealthyInsurance()));
|
|
||||||
item.setTaxDelayEndowmentInsurance(AESEncryptUtil.encrypt(item.getTaxDelayEndowmentInsurance()));
|
|
||||||
item.setOtherDeduction(AESEncryptUtil.encrypt(item.getOtherDeduction()));
|
|
||||||
item.setDeductionAllowedDonation(AESEncryptUtil.encrypt(item.getDeductionAllowedDonation()));
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static OtherDeductionListDTO decryptOtherDeductionListDTO(OtherDeductionListDTO item) {
|
|
||||||
if(item == null) {
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
item.setBusinessHealthyInsurance(AESEncryptUtil.decrypt(item.getBusinessHealthyInsurance()));
|
|
||||||
item.setTaxDelayEndowmentInsurance(AESEncryptUtil.decrypt(item.getTaxDelayEndowmentInsurance()));
|
|
||||||
item.setOtherDeduction(AESEncryptUtil.decrypt(item.getOtherDeduction()));
|
|
||||||
item.setDeductionAllowedDonation(AESEncryptUtil.decrypt(item.getDeductionAllowedDonation()));
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
@ -1,56 +0,0 @@
|
||||||
package com.engine.salary.encrypt.datacollection;
|
|
||||||
|
|
||||||
import com.engine.salary.encrypt.AESEncryptUtil;
|
|
||||||
import com.engine.salary.entity.datacollection.po.OtherDeductionPO;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
@Deprecated
|
|
||||||
public class OtherDeductionPOEncrypt {
|
|
||||||
public static List<OtherDeductionPO> encryptOtherDeductionPOList(List<OtherDeductionPO> list) {
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setBusinessHealthyInsurance(AESEncryptUtil.encrypt(item.getBusinessHealthyInsurance()));
|
|
||||||
item.setTaxDelayEndowmentInsurance(AESEncryptUtil.encrypt(item.getTaxDelayEndowmentInsurance()));
|
|
||||||
item.setOtherDeduction(AESEncryptUtil.encrypt(item.getOtherDeduction()));
|
|
||||||
item.setDeductionAllowedDonation(AESEncryptUtil.encrypt(item.getDeductionAllowedDonation()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static List<OtherDeductionPO> decryptOtherDeductionPOList(List<OtherDeductionPO> list) {
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setBusinessHealthyInsurance(AESEncryptUtil.decrypt(item.getBusinessHealthyInsurance()));
|
|
||||||
item.setTaxDelayEndowmentInsurance(AESEncryptUtil.decrypt(item.getTaxDelayEndowmentInsurance()));
|
|
||||||
item.setOtherDeduction(AESEncryptUtil.decrypt(item.getOtherDeduction()));
|
|
||||||
item.setDeductionAllowedDonation(AESEncryptUtil.decrypt(item.getDeductionAllowedDonation()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static OtherDeductionPO encryptOtherDeductionPO(OtherDeductionPO item) {
|
|
||||||
if(item == null) {
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
item.setBusinessHealthyInsurance(AESEncryptUtil.encrypt(item.getBusinessHealthyInsurance()));
|
|
||||||
item.setTaxDelayEndowmentInsurance(AESEncryptUtil.encrypt(item.getTaxDelayEndowmentInsurance()));
|
|
||||||
item.setOtherDeduction(AESEncryptUtil.encrypt(item.getOtherDeduction()));
|
|
||||||
item.setDeductionAllowedDonation(AESEncryptUtil.encrypt(item.getDeductionAllowedDonation()));
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static OtherDeductionPO decryptOtherDeductionPO(OtherDeductionPO item) {
|
|
||||||
if(item == null) {
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
item.setBusinessHealthyInsurance(AESEncryptUtil.decrypt(item.getBusinessHealthyInsurance()));
|
|
||||||
item.setTaxDelayEndowmentInsurance(AESEncryptUtil.decrypt(item.getTaxDelayEndowmentInsurance()));
|
|
||||||
item.setOtherDeduction(AESEncryptUtil.decrypt(item.getOtherDeduction()));
|
|
||||||
item.setDeductionAllowedDonation(AESEncryptUtil.decrypt(item.getDeductionAllowedDonation()));
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
@ -1,65 +0,0 @@
|
||||||
package com.engine.salary.encrypt.datacollection;
|
|
||||||
|
|
||||||
import com.engine.salary.encrypt.AESEncryptUtil;
|
|
||||||
import com.engine.salary.entity.datacollection.dto.OtherDeductionRecordDTO;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* hrsa_other_deduction: 加解密
|
|
||||||
* 字段:
|
|
||||||
* business_healthy_insurance
|
|
||||||
* tax_delay_endowment_insurance
|
|
||||||
* other_deduction
|
|
||||||
* deduction_allowed_donation
|
|
||||||
*/
|
|
||||||
@Deprecated
|
|
||||||
public class OtherDeductionRecordDTOEncrypt {
|
|
||||||
public static List<OtherDeductionRecordDTO> encryptOtherDeductionRecordDTOList(List<OtherDeductionRecordDTO> list) {
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setBusinessHealthyInsurance(AESEncryptUtil.encrypt(item.getBusinessHealthyInsurance()));
|
|
||||||
item.setTaxDelayEndowmentInsurance(AESEncryptUtil.encrypt(item.getTaxDelayEndowmentInsurance()));
|
|
||||||
item.setOtherDeduction(AESEncryptUtil.encrypt(item.getOtherDeduction()));
|
|
||||||
item.setDeductionAllowedDonation(AESEncryptUtil.encrypt(item.getDeductionAllowedDonation()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static List<OtherDeductionRecordDTO> decryptOtherDeductionRecordDTOList(List<OtherDeductionRecordDTO> list) {
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setBusinessHealthyInsurance(AESEncryptUtil.decrypt(item.getBusinessHealthyInsurance()));
|
|
||||||
item.setTaxDelayEndowmentInsurance(AESEncryptUtil.decrypt(item.getTaxDelayEndowmentInsurance()));
|
|
||||||
item.setOtherDeduction(AESEncryptUtil.decrypt(item.getOtherDeduction()));
|
|
||||||
item.setDeductionAllowedDonation(AESEncryptUtil.decrypt(item.getDeductionAllowedDonation()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static OtherDeductionRecordDTO encryptOtherDeductionRecordDTO(OtherDeductionRecordDTO item) {
|
|
||||||
if(item == null) {
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
item.setBusinessHealthyInsurance(AESEncryptUtil.encrypt(item.getBusinessHealthyInsurance()));
|
|
||||||
item.setTaxDelayEndowmentInsurance(AESEncryptUtil.encrypt(item.getTaxDelayEndowmentInsurance()));
|
|
||||||
item.setOtherDeduction(AESEncryptUtil.encrypt(item.getOtherDeduction()));
|
|
||||||
item.setDeductionAllowedDonation(AESEncryptUtil.encrypt(item.getDeductionAllowedDonation()));
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static OtherDeductionRecordDTO decryptOtherDeductionRecordDTO(OtherDeductionRecordDTO item) {
|
|
||||||
if(item == null) {
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
item.setBusinessHealthyInsurance(AESEncryptUtil.decrypt(item.getBusinessHealthyInsurance()));
|
|
||||||
item.setTaxDelayEndowmentInsurance(AESEncryptUtil.decrypt(item.getTaxDelayEndowmentInsurance()));
|
|
||||||
item.setOtherDeduction(AESEncryptUtil.decrypt(item.getOtherDeduction()));
|
|
||||||
item.setDeductionAllowedDonation(AESEncryptUtil.decrypt(item.getDeductionAllowedDonation()));
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
@ -1,94 +0,0 @@
|
||||||
package com.engine.salary.encrypt.datacollection;
|
|
||||||
|
|
||||||
import com.engine.salary.encrypt.AESEncryptUtil;
|
|
||||||
|
|
||||||
import java.lang.reflect.Field;
|
|
||||||
import java.util.Arrays;
|
|
||||||
import java.util.List;
|
|
||||||
import java.util.stream.Collectors;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* hrsa_special_add_deduction: 加解密
|
|
||||||
* 字段:
|
|
||||||
* children_education
|
|
||||||
* continuing_education
|
|
||||||
* housing_loan_interest
|
|
||||||
* housing_rent
|
|
||||||
* supporting_elder
|
|
||||||
* serious_illness_treatment
|
|
||||||
* infant_care
|
|
||||||
*/
|
|
||||||
@Deprecated
|
|
||||||
public class SpecialAddDeductionEncrypt {
|
|
||||||
private static final List<String> FIELDS = Arrays.asList(
|
|
||||||
"childrenEducation", "continuingEducation", "supportingElder", "housingLoanInterest",
|
|
||||||
"housingRent", "seriousIllnessTreatment", "infantCare");
|
|
||||||
|
|
||||||
public static <T> T encrypt(T obj) {
|
|
||||||
if (obj == null) {
|
|
||||||
return obj;
|
|
||||||
}
|
|
||||||
if(obj instanceof List) {
|
|
||||||
return encrypt(obj);
|
|
||||||
}
|
|
||||||
Class<?> clazz = obj.getClass();
|
|
||||||
Field[] fields = clazz.getDeclaredFields();
|
|
||||||
for (Field field : fields) {
|
|
||||||
field.setAccessible(true);
|
|
||||||
if (FIELDS.contains(field.getName())) {
|
|
||||||
try {
|
|
||||||
Object o = field.get(obj);
|
|
||||||
if (o instanceof String) {
|
|
||||||
Object value = AESEncryptUtil.encrypt((String)o);
|
|
||||||
field.set(obj, value);
|
|
||||||
}
|
|
||||||
} catch (IllegalAccessException e) {
|
|
||||||
//ignore
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return obj;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static <T> List<T> encrypt(List<T> list) {
|
|
||||||
if (list == null || list.isEmpty()) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
return list.stream().map(SpecialAddDeductionEncrypt::encrypt)
|
|
||||||
.collect(Collectors.toList());
|
|
||||||
}
|
|
||||||
|
|
||||||
public static <T> T decrypt(T obj) {
|
|
||||||
if (obj == null) {
|
|
||||||
return obj;
|
|
||||||
}
|
|
||||||
if(obj instanceof List) {
|
|
||||||
return encrypt(obj);
|
|
||||||
}
|
|
||||||
Class<?> clazz = obj.getClass();
|
|
||||||
Field[] fields = clazz.getDeclaredFields();
|
|
||||||
for (Field field : fields) {
|
|
||||||
field.setAccessible(true);
|
|
||||||
if (FIELDS.contains(field.getName())) {
|
|
||||||
try {
|
|
||||||
Object o = field.get(obj);
|
|
||||||
if (o instanceof String) {
|
|
||||||
Object value = AESEncryptUtil.decrypt((String)o);
|
|
||||||
field.set(obj, value);
|
|
||||||
}
|
|
||||||
} catch (IllegalAccessException e) {
|
|
||||||
//ignore
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return obj;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static <T> List<T> decrypt(List<T> list) {
|
|
||||||
if (list == null || list.isEmpty()) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
return list.stream().map(SpecialAddDeductionEncrypt::decrypt)
|
|
||||||
.collect(Collectors.toList());
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
@ -1,35 +0,0 @@
|
||||||
package com.engine.salary.encrypt.report;
|
|
||||||
|
|
||||||
import com.engine.salary.encrypt.AESEncryptUtil;
|
|
||||||
import com.engine.salary.entity.report.po.SalaryAcctResultReportPO;
|
|
||||||
|
|
||||||
import java.util.Collection;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 薪资核算报表
|
|
||||||
*/
|
|
||||||
@Deprecated
|
|
||||||
public class SalaryAcctResultReportPOEncrypt {
|
|
||||||
|
|
||||||
public static Collection<SalaryAcctResultReportPO> encryptList(Collection<SalaryAcctResultReportPO> list) {
|
|
||||||
if (list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setEmployeeId(AESEncryptUtil.encrypt(item.getEmployeeId()));
|
|
||||||
item.setSalaryAcctEmpId(AESEncryptUtil.encrypt(item.getSalaryAcctEmpId()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static Collection<SalaryAcctResultReportPO> decryptList(Collection<SalaryAcctResultReportPO> list) {
|
|
||||||
if (list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setEmployeeId(AESEncryptUtil.decrypt(item.getEmployeeId()));
|
|
||||||
item.setSalaryAcctEmpId(AESEncryptUtil.decrypt(item.getSalaryAcctEmpId()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
@ -1,67 +0,0 @@
|
||||||
package com.engine.salary.encrypt.salaryacct;
|
|
||||||
|
|
||||||
import com.engine.salary.encrypt.AESEncryptUtil;
|
|
||||||
import com.engine.salary.entity.salaryacct.po.ExcelAcctResultPO;
|
|
||||||
|
|
||||||
import java.util.Collection;
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
@Deprecated
|
|
||||||
public class ExcelAcctResultPOEncrypt {
|
|
||||||
|
|
||||||
public static Collection<ExcelAcctResultPO> encryptList(Collection<ExcelAcctResultPO> list) {
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setResultValue(AESEncryptUtil.encrypt(item.getResultValue()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static Collection<ExcelAcctResultPO> decryptList(Collection<ExcelAcctResultPO> list) {
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setResultValue(AESEncryptUtil.decrypt(item.getResultValue()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static List<ExcelAcctResultPO> encryptList(List<ExcelAcctResultPO> list) {
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setResultValue(AESEncryptUtil.encrypt(item.getResultValue()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static List<ExcelAcctResultPO> decryptList(List<ExcelAcctResultPO> list) {
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setResultValue(AESEncryptUtil.decrypt(item.getResultValue()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static ExcelAcctResultPO encryptItem(ExcelAcctResultPO item) {
|
|
||||||
if(item == null) {
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
item.setResultValue(AESEncryptUtil.encrypt(item.getResultValue()));
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static ExcelAcctResultPO decryptItem(ExcelAcctResultPO item) {
|
|
||||||
if(item == null) {
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
item.setResultValue(AESEncryptUtil.decrypt(item.getResultValue()));
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
@ -1,52 +0,0 @@
|
||||||
package com.engine.salary.encrypt.salaryacct;
|
|
||||||
|
|
||||||
import com.engine.salary.encrypt.AESEncryptUtil;
|
|
||||||
import com.engine.salary.entity.salaryacct.po.SalaryAcctResultPO;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
@Deprecated
|
|
||||||
public class SalaryAcctResultPOEncrypt {
|
|
||||||
|
|
||||||
@Deprecated
|
|
||||||
public static List<SalaryAcctResultPO> encryptList(List<SalaryAcctResultPO> list) {
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setResultValue(AESEncryptUtil.encrypt(item.getResultValue()));
|
|
||||||
item.setOriginResultValue(AESEncryptUtil.encrypt(item.getOriginResultValue()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Deprecated
|
|
||||||
public static List<SalaryAcctResultPO> decryptList(List<SalaryAcctResultPO> list) {
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setResultValue(AESEncryptUtil.decrypt(item.getResultValue()));
|
|
||||||
item.setOriginResultValue(AESEncryptUtil.decrypt(item.getOriginResultValue()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Deprecated
|
|
||||||
public static SalaryAcctResultPO encryptItem(SalaryAcctResultPO item) {
|
|
||||||
if(item == null) {
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
item.setResultValue(AESEncryptUtil.encrypt(item.getResultValue()));
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Deprecated
|
|
||||||
public static SalaryAcctResultPO decryptItem(SalaryAcctResultPO item) {
|
|
||||||
if(item == null) {
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
item.setResultValue(AESEncryptUtil.decrypt(item.getResultValue()));
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
@ -1,112 +0,0 @@
|
||||||
package com.engine.salary.encrypt.siaccount;
|
|
||||||
|
|
||||||
import com.engine.salary.encrypt.AESEncryptUtil;
|
|
||||||
import com.engine.salary.entity.siaccount.po.ExcelInsuranceDetailPO;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* hrsa_excel_bill_detail: 加解密
|
|
||||||
* 字段:
|
|
||||||
* social_payment_base_string
|
|
||||||
* fund_payment_base_string
|
|
||||||
* other_payment_base_string
|
|
||||||
* social_per_json
|
|
||||||
* social_per_sum
|
|
||||||
* fund_per_json
|
|
||||||
* fund_per_sum
|
|
||||||
* other_per_json
|
|
||||||
* other_per_sum
|
|
||||||
* per_sum
|
|
||||||
* social_com_json
|
|
||||||
* social_com_sum
|
|
||||||
* fund_com_json
|
|
||||||
* fund_com_sum
|
|
||||||
* other_com_json
|
|
||||||
* other_com_sum
|
|
||||||
* com_sum
|
|
||||||
* social_sum
|
|
||||||
* fund_sum
|
|
||||||
* other_sum
|
|
||||||
* total
|
|
||||||
*/
|
|
||||||
@Deprecated
|
|
||||||
public class ExcelInsuranceDetailPOEncrypt {
|
|
||||||
public static List<ExcelInsuranceDetailPO> encryptInsuranceAccountDetailPOList(List<ExcelInsuranceDetailPO> list) {
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setSocialPaymentBaseString(AESEncryptUtil.encrypt(item.getSocialPaymentBaseString()));
|
|
||||||
item.setFundPaymentBaseString(AESEncryptUtil.encrypt(item.getFundPaymentBaseString()));
|
|
||||||
item.setOtherPaymentBaseString(AESEncryptUtil.encrypt(item.getOtherPaymentBaseString()));
|
|
||||||
item.setSocialPerJson(AESEncryptUtil.encrypt(item.getSocialPerJson()));
|
|
||||||
item.setSocialPerSum(AESEncryptUtil.encrypt(item.getSocialPerSum()));
|
|
||||||
item.setFundPerJson(AESEncryptUtil.encrypt(item.getFundPerJson()));
|
|
||||||
item.setFundPerSum(AESEncryptUtil.encrypt(item.getFundPerSum()));
|
|
||||||
item.setOtherPerJson(AESEncryptUtil.encrypt(item.getOtherPerJson()));
|
|
||||||
item.setOtherPerSum(AESEncryptUtil.encrypt(item.getOtherPerSum()));
|
|
||||||
item.setPerSum(AESEncryptUtil.encrypt(item.getPerSum()));
|
|
||||||
item.setSocialComJson(AESEncryptUtil.encrypt(item.getSocialComJson()));
|
|
||||||
item.setSocialComSum(AESEncryptUtil.encrypt(item.getSocialComSum()));
|
|
||||||
item.setComSum(AESEncryptUtil.encrypt(item.getComSum()));
|
|
||||||
item.setSocialSum(AESEncryptUtil.encrypt(item.getSocialSum()));
|
|
||||||
item.setFundSum(AESEncryptUtil.encrypt(item.getFundSum()));
|
|
||||||
item.setOtherSum(AESEncryptUtil.encrypt(item.getOtherSum()));
|
|
||||||
item.setTotal(AESEncryptUtil.encrypt(item.getTotal()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static List<ExcelInsuranceDetailPO> decryptInsuranceAccountDetailPOList(List<ExcelInsuranceDetailPO> list) {
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setSocialPaymentBaseString(AESEncryptUtil.decrypt(item.getSocialPaymentBaseString()));
|
|
||||||
item.setFundPaymentBaseString(AESEncryptUtil.decrypt(item.getFundPaymentBaseString()));
|
|
||||||
item.setOtherPaymentBaseString(AESEncryptUtil.decrypt(item.getOtherPaymentBaseString()));
|
|
||||||
item.setSocialPerJson(AESEncryptUtil.decrypt(item.getSocialPerJson()));
|
|
||||||
item.setSocialPerSum(AESEncryptUtil.decrypt(item.getSocialPerSum()));
|
|
||||||
item.setFundPerJson(AESEncryptUtil.decrypt(item.getFundPerJson()));
|
|
||||||
item.setFundPerSum(AESEncryptUtil.decrypt(item.getFundPerSum()));
|
|
||||||
item.setOtherPerJson(AESEncryptUtil.decrypt(item.getOtherPerJson()));
|
|
||||||
item.setOtherPerSum(AESEncryptUtil.decrypt(item.getOtherPerSum()));
|
|
||||||
item.setPerSum(AESEncryptUtil.decrypt(item.getPerSum()));
|
|
||||||
item.setSocialComJson(AESEncryptUtil.decrypt(item.getSocialComJson()));
|
|
||||||
item.setSocialComSum(AESEncryptUtil.decrypt(item.getSocialComSum()));
|
|
||||||
item.setComSum(AESEncryptUtil.decrypt(item.getComSum()));
|
|
||||||
item.setSocialSum(AESEncryptUtil.decrypt(item.getSocialSum()));
|
|
||||||
item.setFundSum(AESEncryptUtil.decrypt(item.getFundSum()));
|
|
||||||
item.setOtherSum(AESEncryptUtil.decrypt(item.getOtherSum()));
|
|
||||||
item.setTotal(AESEncryptUtil.decrypt(item.getTotal()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static ExcelInsuranceDetailPO decryptItem(ExcelInsuranceDetailPO item) {
|
|
||||||
if(item == null) {
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
item.setSocialPaymentBaseString(AESEncryptUtil.decrypt(item.getSocialPaymentBaseString()));
|
|
||||||
item.setFundPaymentBaseString(AESEncryptUtil.decrypt(item.getFundPaymentBaseString()));
|
|
||||||
item.setOtherPaymentBaseString(AESEncryptUtil.decrypt(item.getOtherPaymentBaseString()));
|
|
||||||
item.setSocialPerJson(AESEncryptUtil.decrypt(item.getSocialPerJson()));
|
|
||||||
item.setSocialPerSum(AESEncryptUtil.decrypt(item.getSocialPerSum()));
|
|
||||||
item.setFundPerJson(AESEncryptUtil.decrypt(item.getFundPerJson()));
|
|
||||||
item.setFundPerSum(AESEncryptUtil.decrypt(item.getFundPerSum()));
|
|
||||||
item.setOtherPerJson(AESEncryptUtil.decrypt(item.getOtherPerJson()));
|
|
||||||
item.setOtherPerSum(AESEncryptUtil.decrypt(item.getOtherPerSum()));
|
|
||||||
item.setPerSum(AESEncryptUtil.decrypt(item.getPerSum()));
|
|
||||||
item.setSocialComJson(AESEncryptUtil.decrypt(item.getSocialComJson()));
|
|
||||||
item.setSocialComSum(AESEncryptUtil.decrypt(item.getSocialComSum()));
|
|
||||||
item.setComSum(AESEncryptUtil.decrypt(item.getComSum()));
|
|
||||||
item.setSocialSum(AESEncryptUtil.decrypt(item.getSocialSum()));
|
|
||||||
item.setFundSum(AESEncryptUtil.decrypt(item.getFundSum()));
|
|
||||||
item.setOtherSum(AESEncryptUtil.decrypt(item.getOtherSum()));
|
|
||||||
item.setTotal(AESEncryptUtil.decrypt(item.getTotal()));
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
@ -1,136 +0,0 @@
|
||||||
package com.engine.salary.encrypt.siaccount;
|
|
||||||
|
|
||||||
import com.engine.salary.encrypt.AESEncryptUtil;
|
|
||||||
import com.engine.salary.entity.siaccount.po.InsuranceAccountDetailPO;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* hrsa_bill_detail: 加解密
|
|
||||||
* 字段:
|
|
||||||
* social_payment_base_string
|
|
||||||
* fund_payment_base_string
|
|
||||||
* other_payment_base_string
|
|
||||||
* social_per_json
|
|
||||||
* social_per_sum
|
|
||||||
* fund_per_json
|
|
||||||
* fund_per_sum
|
|
||||||
* other_per_json
|
|
||||||
* other_per_sum
|
|
||||||
* per_sum
|
|
||||||
* social_com_json
|
|
||||||
* social_com_sum
|
|
||||||
* fund_com_json
|
|
||||||
* fund_com_sum
|
|
||||||
* other_com_json
|
|
||||||
* other_com_sum
|
|
||||||
* com_sum
|
|
||||||
* social_sum
|
|
||||||
* fund_sum
|
|
||||||
* other_sum
|
|
||||||
* total
|
|
||||||
*/
|
|
||||||
@Deprecated
|
|
||||||
public class InsuranceAccountDetailPOEncrypt {
|
|
||||||
public static List<InsuranceAccountDetailPO> encryptInsuranceAccountDetailPOList(List<InsuranceAccountDetailPO> list) {
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setSocialPaymentBaseString(AESEncryptUtil.encrypt(item.getSocialPaymentBaseString()));
|
|
||||||
item.setFundPaymentBaseString(AESEncryptUtil.encrypt(item.getFundPaymentBaseString()));
|
|
||||||
item.setOtherPaymentBaseString(AESEncryptUtil.encrypt(item.getOtherPaymentBaseString()));
|
|
||||||
item.setSocialPerJson(AESEncryptUtil.encrypt(item.getSocialPerJson()));
|
|
||||||
item.setSocialPerSum(AESEncryptUtil.encrypt(item.getSocialPerSum()));
|
|
||||||
item.setFundPerJson(AESEncryptUtil.encrypt(item.getFundPerJson()));
|
|
||||||
item.setFundPerSum(AESEncryptUtil.encrypt(item.getFundPerSum()));
|
|
||||||
item.setOtherPerJson(AESEncryptUtil.encrypt(item.getOtherPerJson()));
|
|
||||||
item.setOtherPerSum(AESEncryptUtil.encrypt(item.getOtherPerSum()));
|
|
||||||
item.setPerSum(AESEncryptUtil.encrypt(item.getPerSum()));
|
|
||||||
item.setSocialComJson(AESEncryptUtil.encrypt(item.getSocialComJson()));
|
|
||||||
item.setSocialComSum(AESEncryptUtil.encrypt(item.getSocialComSum()));
|
|
||||||
item.setComSum(AESEncryptUtil.encrypt(item.getComSum()));
|
|
||||||
item.setSocialSum(AESEncryptUtil.encrypt(item.getSocialSum()));
|
|
||||||
item.setFundSum(AESEncryptUtil.encrypt(item.getFundSum()));
|
|
||||||
item.setOtherSum(AESEncryptUtil.encrypt(item.getOtherSum()));
|
|
||||||
item.setTotal(AESEncryptUtil.encrypt(item.getTotal()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static List<InsuranceAccountDetailPO> decryptInsuranceAccountDetailPOList(List<InsuranceAccountDetailPO> list) {
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setSocialPaymentBaseString(AESEncryptUtil.decrypt(item.getSocialPaymentBaseString()));
|
|
||||||
item.setFundPaymentBaseString(AESEncryptUtil.decrypt(item.getFundPaymentBaseString()));
|
|
||||||
item.setOtherPaymentBaseString(AESEncryptUtil.decrypt(item.getOtherPaymentBaseString()));
|
|
||||||
item.setSocialPerJson(AESEncryptUtil.decrypt(item.getSocialPerJson()));
|
|
||||||
item.setSocialPerSum(AESEncryptUtil.decrypt(item.getSocialPerSum()));
|
|
||||||
item.setFundPerJson(AESEncryptUtil.decrypt(item.getFundPerJson()));
|
|
||||||
item.setFundPerSum(AESEncryptUtil.decrypt(item.getFundPerSum()));
|
|
||||||
item.setOtherPerJson(AESEncryptUtil.decrypt(item.getOtherPerJson()));
|
|
||||||
item.setOtherPerSum(AESEncryptUtil.decrypt(item.getOtherPerSum()));
|
|
||||||
item.setPerSum(AESEncryptUtil.decrypt(item.getPerSum()));
|
|
||||||
item.setSocialComJson(AESEncryptUtil.decrypt(item.getSocialComJson()));
|
|
||||||
item.setSocialComSum(AESEncryptUtil.decrypt(item.getSocialComSum()));
|
|
||||||
item.setComSum(AESEncryptUtil.decrypt(item.getComSum()));
|
|
||||||
item.setSocialSum(AESEncryptUtil.decrypt(item.getSocialSum()));
|
|
||||||
item.setFundSum(AESEncryptUtil.decrypt(item.getFundSum()));
|
|
||||||
item.setOtherSum(AESEncryptUtil.decrypt(item.getOtherSum()));
|
|
||||||
item.setTotal(AESEncryptUtil.decrypt(item.getTotal()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static InsuranceAccountDetailPO decryptItem(InsuranceAccountDetailPO item) {
|
|
||||||
if(item == null) {
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
item.setSocialPaymentBaseString(AESEncryptUtil.decrypt(item.getSocialPaymentBaseString()));
|
|
||||||
item.setFundPaymentBaseString(AESEncryptUtil.decrypt(item.getFundPaymentBaseString()));
|
|
||||||
item.setOtherPaymentBaseString(AESEncryptUtil.decrypt(item.getOtherPaymentBaseString()));
|
|
||||||
item.setSocialPerJson(AESEncryptUtil.decrypt(item.getSocialPerJson()));
|
|
||||||
item.setSocialPerSum(AESEncryptUtil.decrypt(item.getSocialPerSum()));
|
|
||||||
item.setFundPerJson(AESEncryptUtil.decrypt(item.getFundPerJson()));
|
|
||||||
item.setFundPerSum(AESEncryptUtil.decrypt(item.getFundPerSum()));
|
|
||||||
item.setOtherPerJson(AESEncryptUtil.decrypt(item.getOtherPerJson()));
|
|
||||||
item.setOtherPerSum(AESEncryptUtil.decrypt(item.getOtherPerSum()));
|
|
||||||
item.setPerSum(AESEncryptUtil.decrypt(item.getPerSum()));
|
|
||||||
item.setSocialComJson(AESEncryptUtil.decrypt(item.getSocialComJson()));
|
|
||||||
item.setSocialComSum(AESEncryptUtil.decrypt(item.getSocialComSum()));
|
|
||||||
item.setComSum(AESEncryptUtil.decrypt(item.getComSum()));
|
|
||||||
item.setSocialSum(AESEncryptUtil.decrypt(item.getSocialSum()));
|
|
||||||
item.setFundSum(AESEncryptUtil.decrypt(item.getFundSum()));
|
|
||||||
item.setOtherSum(AESEncryptUtil.decrypt(item.getOtherSum()));
|
|
||||||
item.setTotal(AESEncryptUtil.decrypt(item.getTotal()));
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static InsuranceAccountDetailPO encryptItem(InsuranceAccountDetailPO item) {
|
|
||||||
if(item == null) {
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
item.setSocialPaymentBaseString(AESEncryptUtil.encrypt(item.getSocialPaymentBaseString()));
|
|
||||||
item.setFundPaymentBaseString(AESEncryptUtil.encrypt(item.getFundPaymentBaseString()));
|
|
||||||
item.setOtherPaymentBaseString(AESEncryptUtil.encrypt(item.getOtherPaymentBaseString()));
|
|
||||||
item.setSocialPerJson(AESEncryptUtil.encrypt(item.getSocialPerJson()));
|
|
||||||
item.setSocialPerSum(AESEncryptUtil.encrypt(item.getSocialPerSum()));
|
|
||||||
item.setFundPerJson(AESEncryptUtil.encrypt(item.getFundPerJson()));
|
|
||||||
item.setFundPerSum(AESEncryptUtil.encrypt(item.getFundPerSum()));
|
|
||||||
item.setOtherPerJson(AESEncryptUtil.encrypt(item.getOtherPerJson()));
|
|
||||||
item.setOtherPerSum(AESEncryptUtil.encrypt(item.getOtherPerSum()));
|
|
||||||
item.setPerSum(AESEncryptUtil.encrypt(item.getPerSum()));
|
|
||||||
item.setSocialComJson(AESEncryptUtil.encrypt(item.getSocialComJson()));
|
|
||||||
item.setSocialComSum(AESEncryptUtil.encrypt(item.getSocialComSum()));
|
|
||||||
item.setComSum(AESEncryptUtil.encrypt(item.getComSum()));
|
|
||||||
item.setSocialSum(AESEncryptUtil.encrypt(item.getSocialSum()));
|
|
||||||
item.setFundSum(AESEncryptUtil.encrypt(item.getFundSum()));
|
|
||||||
item.setOtherSum(AESEncryptUtil.encrypt(item.getOtherSum()));
|
|
||||||
item.setTotal(AESEncryptUtil.encrypt(item.getTotal()));
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
@ -1,86 +0,0 @@
|
||||||
package com.engine.salary.encrypt.siaccount;
|
|
||||||
|
|
||||||
import com.engine.salary.encrypt.AESEncryptUtil;
|
|
||||||
import com.engine.salary.entity.siaccount.po.InsuranceAccountDetailTempPO;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* hrsa_bill_detail: 加解密
|
|
||||||
* 字段:
|
|
||||||
* social_payment_base_string
|
|
||||||
* fund_payment_base_string
|
|
||||||
* other_payment_base_string
|
|
||||||
* social_per_json
|
|
||||||
* social_per_sum
|
|
||||||
* fund_per_json
|
|
||||||
* fund_per_sum
|
|
||||||
* other_per_json
|
|
||||||
* other_per_sum
|
|
||||||
* per_sum
|
|
||||||
* social_com_json
|
|
||||||
* social_com_sum
|
|
||||||
* fund_com_json
|
|
||||||
* fund_com_sum
|
|
||||||
* other_com_json
|
|
||||||
* other_com_sum
|
|
||||||
* com_sum
|
|
||||||
* social_sum
|
|
||||||
* fund_sum
|
|
||||||
* other_sum
|
|
||||||
* total
|
|
||||||
*/
|
|
||||||
@Deprecated
|
|
||||||
public class InsuranceAccountDetailTempPOEncrypt {
|
|
||||||
public static List<InsuranceAccountDetailTempPO> encryptInsuranceAccountDetailTempPOList(List<InsuranceAccountDetailTempPO> list) {
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setSocialPaymentBaseString(AESEncryptUtil.encrypt(item.getSocialPaymentBaseString()));
|
|
||||||
item.setFundPaymentBaseString(AESEncryptUtil.encrypt(item.getFundPaymentBaseString()));
|
|
||||||
item.setOtherPaymentBaseString(AESEncryptUtil.encrypt(item.getOtherPaymentBaseString()));
|
|
||||||
item.setSocialPerJson(AESEncryptUtil.encrypt(item.getSocialPerJson()));
|
|
||||||
item.setSocialPerSum(AESEncryptUtil.encrypt(item.getSocialPerSum()));
|
|
||||||
item.setFundPerJson(AESEncryptUtil.encrypt(item.getFundPerJson()));
|
|
||||||
item.setFundPerSum(AESEncryptUtil.encrypt(item.getFundPerSum()));
|
|
||||||
item.setOtherPerJson(AESEncryptUtil.encrypt(item.getOtherPerJson()));
|
|
||||||
item.setOtherPerSum(AESEncryptUtil.encrypt(item.getOtherPerSum()));
|
|
||||||
item.setPerSum(AESEncryptUtil.encrypt(item.getPerSum()));
|
|
||||||
item.setSocialComJson(AESEncryptUtil.encrypt(item.getSocialComJson()));
|
|
||||||
item.setSocialComSum(AESEncryptUtil.encrypt(item.getSocialComSum()));
|
|
||||||
item.setComSum(AESEncryptUtil.encrypt(item.getComSum()));
|
|
||||||
item.setSocialSum(AESEncryptUtil.encrypt(item.getSocialSum()));
|
|
||||||
item.setFundSum(AESEncryptUtil.encrypt(item.getFundSum()));
|
|
||||||
item.setOtherSum(AESEncryptUtil.encrypt(item.getOtherSum()));
|
|
||||||
item.setTotal(AESEncryptUtil.encrypt(item.getTotal()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static List<InsuranceAccountDetailTempPO> decryptInsuranceAccountDetailTempPOList(List<InsuranceAccountDetailTempPO> list) {
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setSocialPaymentBaseString(AESEncryptUtil.decrypt(item.getSocialPaymentBaseString()));
|
|
||||||
item.setFundPaymentBaseString(AESEncryptUtil.decrypt(item.getFundPaymentBaseString()));
|
|
||||||
item.setOtherPaymentBaseString(AESEncryptUtil.decrypt(item.getOtherPaymentBaseString()));
|
|
||||||
item.setSocialPerJson(AESEncryptUtil.decrypt(item.getSocialPerJson()));
|
|
||||||
item.setSocialPerSum(AESEncryptUtil.decrypt(item.getSocialPerSum()));
|
|
||||||
item.setFundPerJson(AESEncryptUtil.decrypt(item.getFundPerJson()));
|
|
||||||
item.setFundPerSum(AESEncryptUtil.decrypt(item.getFundPerSum()));
|
|
||||||
item.setOtherPerJson(AESEncryptUtil.decrypt(item.getOtherPerJson()));
|
|
||||||
item.setOtherPerSum(AESEncryptUtil.decrypt(item.getOtherPerSum()));
|
|
||||||
item.setPerSum(AESEncryptUtil.decrypt(item.getPerSum()));
|
|
||||||
item.setSocialComJson(AESEncryptUtil.decrypt(item.getSocialComJson()));
|
|
||||||
item.setSocialComSum(AESEncryptUtil.decrypt(item.getSocialComSum()));
|
|
||||||
item.setComSum(AESEncryptUtil.decrypt(item.getComSum()));
|
|
||||||
item.setSocialSum(AESEncryptUtil.decrypt(item.getSocialSum()));
|
|
||||||
item.setFundSum(AESEncryptUtil.decrypt(item.getFundSum()));
|
|
||||||
item.setOtherSum(AESEncryptUtil.decrypt(item.getOtherSum()));
|
|
||||||
item.setTotal(AESEncryptUtil.decrypt(item.getTotal()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
@ -1,61 +0,0 @@
|
||||||
package com.engine.salary.encrypt.siaccount;
|
|
||||||
|
|
||||||
import com.engine.salary.encrypt.AESEncryptUtil;
|
|
||||||
import com.engine.salary.entity.siaccount.po.InsuranceAccountBatchPO;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* hrsa_bill_batch 加解密
|
|
||||||
* 字段:
|
|
||||||
* other_pay
|
|
||||||
* social_pay
|
|
||||||
* fund_pay
|
|
||||||
*/
|
|
||||||
@Deprecated
|
|
||||||
public class SiAccountEncrypt {
|
|
||||||
@Deprecated
|
|
||||||
public static List<InsuranceAccountBatchPO> encryptInsuranceAccountBatchList(List<InsuranceAccountBatchPO> list) {
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setOtherPay(AESEncryptUtil.encrypt(item.getOtherPay()));
|
|
||||||
item.setSocialPay(AESEncryptUtil.encrypt(item.getSocialPay()));
|
|
||||||
item.setFundPay(AESEncryptUtil.encrypt(item.getFundPay()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Deprecated
|
|
||||||
public static List<InsuranceAccountBatchPO> decryptInsuranceAccountBatchList(List<InsuranceAccountBatchPO> list) {
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setOtherPay(AESEncryptUtil.decrypt(item.getOtherPay()));
|
|
||||||
item.setSocialPay(AESEncryptUtil.decrypt(item.getSocialPay()));
|
|
||||||
item.setFundPay(AESEncryptUtil.decrypt(item.getFundPay()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Deprecated
|
|
||||||
public static InsuranceAccountBatchPO encryptInsuranceAccountBatch(InsuranceAccountBatchPO item) {
|
|
||||||
if(item == null) {
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
item.setOtherPay(AESEncryptUtil.encrypt(item.getOtherPay()));
|
|
||||||
item.setSocialPay(AESEncryptUtil.encrypt(item.getSocialPay()));
|
|
||||||
item.setFundPay(AESEncryptUtil.encrypt(item.getFundPay()));
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Deprecated
|
|
||||||
public static InsuranceAccountBatchPO decryptInsuranceAccountBatch(InsuranceAccountBatchPO item) {
|
|
||||||
if(item == null) {
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
item.setOtherPay(AESEncryptUtil.decrypt(item.getOtherPay()));
|
|
||||||
item.setSocialPay(AESEncryptUtil.decrypt(item.getSocialPay()));
|
|
||||||
item.setFundPay(AESEncryptUtil.decrypt(item.getFundPay()));
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
@ -1,45 +0,0 @@
|
||||||
package com.engine.salary.encrypt.siarchives;
|
|
||||||
|
|
||||||
import com.engine.salary.encrypt.AESEncryptUtil;
|
|
||||||
import com.engine.salary.entity.siarchives.po.InsuranceArchivesFundSchemePO;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
@Deprecated
|
|
||||||
public class InsuranceArchivesFundSchemePOEncrypt {
|
|
||||||
public static List<InsuranceArchivesFundSchemePO> encryptList(List<InsuranceArchivesFundSchemePO> list) {
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setFundPaymentBaseString(AESEncryptUtil.encrypt(item.getFundPaymentBaseString()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static List<InsuranceArchivesFundSchemePO> decryptList(List<InsuranceArchivesFundSchemePO> list) {
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setFundPaymentBaseString(AESEncryptUtil.decrypt(item.getFundPaymentBaseString()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static InsuranceArchivesFundSchemePO encryptItem(InsuranceArchivesFundSchemePO item) {
|
|
||||||
if(item == null) {
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
item.setFundPaymentBaseString(AESEncryptUtil.encrypt(item.getFundPaymentBaseString()));
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static InsuranceArchivesFundSchemePO decryptItem(InsuranceArchivesFundSchemePO item) {
|
|
||||||
if(item == null) {
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
item.setFundPaymentBaseString(AESEncryptUtil.decrypt(item.getFundPaymentBaseString()));
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
@ -1,45 +0,0 @@
|
||||||
package com.engine.salary.encrypt.siarchives;
|
|
||||||
|
|
||||||
import com.engine.salary.encrypt.AESEncryptUtil;
|
|
||||||
import com.engine.salary.entity.siarchives.po.InsuranceArchivesOtherSchemePO;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
@Deprecated
|
|
||||||
public class InsuranceArchivesOtherSchemePOEncrypt {
|
|
||||||
public static List<InsuranceArchivesOtherSchemePO> encryptList(List<InsuranceArchivesOtherSchemePO> list) {
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setOtherPaymentBaseString(AESEncryptUtil.encrypt(item.getOtherPaymentBaseString()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static List<InsuranceArchivesOtherSchemePO> decryptList(List<InsuranceArchivesOtherSchemePO> list) {
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setOtherPaymentBaseString(AESEncryptUtil.decrypt(item.getOtherPaymentBaseString()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static InsuranceArchivesOtherSchemePO encryptItem(InsuranceArchivesOtherSchemePO item) {
|
|
||||||
if(item == null) {
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
item.setOtherPaymentBaseString(AESEncryptUtil.encrypt(item.getOtherPaymentBaseString()));
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static InsuranceArchivesOtherSchemePO decryptItem(InsuranceArchivesOtherSchemePO item) {
|
|
||||||
if(item == null) {
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
item.setOtherPaymentBaseString(AESEncryptUtil.decrypt(item.getOtherPaymentBaseString()));
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
@ -1,45 +0,0 @@
|
||||||
package com.engine.salary.encrypt.siarchives;
|
|
||||||
|
|
||||||
import com.engine.salary.encrypt.AESEncryptUtil;
|
|
||||||
import com.engine.salary.entity.siarchives.po.InsuranceArchivesSocialSchemePO;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
@Deprecated
|
|
||||||
public class InsuranceArchivesSocialSchemePOEncrypt {
|
|
||||||
public static List<InsuranceArchivesSocialSchemePO> encryptList(List<InsuranceArchivesSocialSchemePO> list) {
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setSocialPaymentBaseString(AESEncryptUtil.encrypt(item.getSocialPaymentBaseString()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static List<InsuranceArchivesSocialSchemePO> decryptList(List<InsuranceArchivesSocialSchemePO> list) {
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setSocialPaymentBaseString(AESEncryptUtil.decrypt(item.getSocialPaymentBaseString()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static InsuranceArchivesSocialSchemePO encryptItem(InsuranceArchivesSocialSchemePO item) {
|
|
||||||
if(item == null) {
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
item.setSocialPaymentBaseString(AESEncryptUtil.encrypt(item.getSocialPaymentBaseString()));
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static InsuranceArchivesSocialSchemePO decryptItem(InsuranceArchivesSocialSchemePO item) {
|
|
||||||
if(item == null) {
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
item.setSocialPaymentBaseString(AESEncryptUtil.decrypt(item.getSocialPaymentBaseString()));
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
@ -1,86 +0,0 @@
|
||||||
package com.engine.salary.encrypt.siexport;
|
|
||||||
|
|
||||||
import com.engine.salary.encrypt.AESEncryptUtil;
|
|
||||||
import com.engine.salary.entity.siexport.po.AccountExportPO;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* hrsa_bill_detail: 加解密
|
|
||||||
* 字段:
|
|
||||||
* social_payment_base_string
|
|
||||||
* fund_payment_base_string
|
|
||||||
* other_payment_base_string
|
|
||||||
* social_per_json
|
|
||||||
* social_per_sum
|
|
||||||
* fund_per_json
|
|
||||||
* fund_per_sum
|
|
||||||
* other_per_json
|
|
||||||
* other_per_sum
|
|
||||||
* per_sum
|
|
||||||
* social_com_json
|
|
||||||
* social_com_sum
|
|
||||||
* fund_com_json
|
|
||||||
* fund_com_sum
|
|
||||||
* other_com_json
|
|
||||||
* other_com_sum
|
|
||||||
* com_sum
|
|
||||||
* social_sum
|
|
||||||
* fund_sum
|
|
||||||
* other_sum
|
|
||||||
* total
|
|
||||||
*/
|
|
||||||
@Deprecated
|
|
||||||
public class AccountExportPOEncrypt {
|
|
||||||
public static List<AccountExportPO> encryptAccountExportPOList(List<AccountExportPO> list) {
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setSocialPaymentBaseString(AESEncryptUtil.encrypt(item.getSocialPaymentBaseString()));
|
|
||||||
item.setFundPaymentBaseString(AESEncryptUtil.encrypt(item.getFundPaymentBaseString()));
|
|
||||||
item.setOtherPaymentBaseString(AESEncryptUtil.encrypt(item.getOtherPaymentBaseString()));
|
|
||||||
item.setSocialPerJson(AESEncryptUtil.encrypt(item.getSocialPerJson()));
|
|
||||||
item.setSocialPerSum(AESEncryptUtil.encrypt(item.getSocialPerSum()));
|
|
||||||
item.setFundPerJson(AESEncryptUtil.encrypt(item.getFundPerJson()));
|
|
||||||
item.setFundPerSum(AESEncryptUtil.encrypt(item.getFundPerSum()));
|
|
||||||
item.setOtherPerJson(AESEncryptUtil.encrypt(item.getOtherPerJson()));
|
|
||||||
item.setOtherPerSum(AESEncryptUtil.encrypt(item.getOtherPerSum()));
|
|
||||||
item.setPerSum(AESEncryptUtil.encrypt(item.getPerSum()));
|
|
||||||
item.setSocialComJson(AESEncryptUtil.encrypt(item.getSocialComJson()));
|
|
||||||
item.setSocialComSum(AESEncryptUtil.encrypt(item.getSocialComSum()));
|
|
||||||
item.setComSum(AESEncryptUtil.encrypt(item.getComSum()));
|
|
||||||
item.setSocialSum(AESEncryptUtil.encrypt(item.getSocialSum()));
|
|
||||||
item.setFundSum(AESEncryptUtil.encrypt(item.getFundSum()));
|
|
||||||
item.setOtherSum(AESEncryptUtil.encrypt(item.getOtherSum()));
|
|
||||||
item.setTotal(AESEncryptUtil.encrypt(item.getTotal()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static List<AccountExportPO> decryptAccountExportPOList(List<AccountExportPO> list) {
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setSocialPaymentBaseString(AESEncryptUtil.decrypt(item.getSocialPaymentBaseString()));
|
|
||||||
item.setFundPaymentBaseString(AESEncryptUtil.decrypt(item.getFundPaymentBaseString()));
|
|
||||||
item.setOtherPaymentBaseString(AESEncryptUtil.decrypt(item.getOtherPaymentBaseString()));
|
|
||||||
item.setSocialPerJson(AESEncryptUtil.decrypt(item.getSocialPerJson()));
|
|
||||||
item.setSocialPerSum(AESEncryptUtil.decrypt(item.getSocialPerSum()));
|
|
||||||
item.setFundPerJson(AESEncryptUtil.decrypt(item.getFundPerJson()));
|
|
||||||
item.setFundPerSum(AESEncryptUtil.decrypt(item.getFundPerSum()));
|
|
||||||
item.setOtherPerJson(AESEncryptUtil.decrypt(item.getOtherPerJson()));
|
|
||||||
item.setOtherPerSum(AESEncryptUtil.decrypt(item.getOtherPerSum()));
|
|
||||||
item.setPerSum(AESEncryptUtil.decrypt(item.getPerSum()));
|
|
||||||
item.setSocialComJson(AESEncryptUtil.decrypt(item.getSocialComJson()));
|
|
||||||
item.setSocialComSum(AESEncryptUtil.decrypt(item.getSocialComSum()));
|
|
||||||
item.setComSum(AESEncryptUtil.decrypt(item.getComSum()));
|
|
||||||
item.setSocialSum(AESEncryptUtil.decrypt(item.getSocialSum()));
|
|
||||||
item.setFundSum(AESEncryptUtil.decrypt(item.getFundSum()));
|
|
||||||
item.setOtherSum(AESEncryptUtil.decrypt(item.getOtherSum()));
|
|
||||||
item.setTotal(AESEncryptUtil.decrypt(item.getTotal()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
@ -1,86 +0,0 @@
|
||||||
package com.engine.salary.encrypt.siexport;
|
|
||||||
|
|
||||||
import com.engine.salary.encrypt.AESEncryptUtil;
|
|
||||||
import com.engine.salary.entity.siexport.po.ExcelAccountExportPO;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* hrsa_excel_bill_detail: 加解密
|
|
||||||
* 字段:
|
|
||||||
* social_payment_base_string
|
|
||||||
* fund_payment_base_string
|
|
||||||
* other_payment_base_string
|
|
||||||
* social_per_json
|
|
||||||
* social_per_sum
|
|
||||||
* fund_per_json
|
|
||||||
* fund_per_sum
|
|
||||||
* other_per_json
|
|
||||||
* other_per_sum
|
|
||||||
* per_sum
|
|
||||||
* social_com_json
|
|
||||||
* social_com_sum
|
|
||||||
* fund_com_json
|
|
||||||
* fund_com_sum
|
|
||||||
* other_com_json
|
|
||||||
* other_com_sum
|
|
||||||
* com_sum
|
|
||||||
* social_sum
|
|
||||||
* fund_sum
|
|
||||||
* other_sum
|
|
||||||
* total
|
|
||||||
*/
|
|
||||||
@Deprecated
|
|
||||||
public class ExcelAccountExportPOEncrypt {
|
|
||||||
public static List<ExcelAccountExportPO> encryptExcelAccountExportPOList(List<ExcelAccountExportPO> list) {
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setSocialPaymentBaseString(AESEncryptUtil.encrypt(item.getSocialPaymentBaseString()));
|
|
||||||
item.setFundPaymentBaseString(AESEncryptUtil.encrypt(item.getFundPaymentBaseString()));
|
|
||||||
item.setOtherPaymentBaseString(AESEncryptUtil.encrypt(item.getOtherPaymentBaseString()));
|
|
||||||
item.setSocialPerJson(AESEncryptUtil.encrypt(item.getSocialPerJson()));
|
|
||||||
item.setSocialPerSum(AESEncryptUtil.encrypt(item.getSocialPerSum()));
|
|
||||||
item.setFundPerJson(AESEncryptUtil.encrypt(item.getFundPerJson()));
|
|
||||||
item.setFundPerSum(AESEncryptUtil.encrypt(item.getFundPerSum()));
|
|
||||||
item.setOtherPerJson(AESEncryptUtil.encrypt(item.getOtherPerJson()));
|
|
||||||
item.setOtherPerSum(AESEncryptUtil.encrypt(item.getOtherPerSum()));
|
|
||||||
item.setPerSum(AESEncryptUtil.encrypt(item.getPerSum()));
|
|
||||||
item.setSocialComJson(AESEncryptUtil.encrypt(item.getSocialComJson()));
|
|
||||||
item.setSocialComSum(AESEncryptUtil.encrypt(item.getSocialComSum()));
|
|
||||||
item.setComSum(AESEncryptUtil.encrypt(item.getComSum()));
|
|
||||||
item.setSocialSum(AESEncryptUtil.encrypt(item.getSocialSum()));
|
|
||||||
item.setFundSum(AESEncryptUtil.encrypt(item.getFundSum()));
|
|
||||||
item.setOtherSum(AESEncryptUtil.encrypt(item.getOtherSum()));
|
|
||||||
item.setTotal(AESEncryptUtil.encrypt(item.getTotal()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static List<ExcelAccountExportPO> decryptExcelAccountExportPOList(List<ExcelAccountExportPO> list) {
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setSocialPaymentBaseString(AESEncryptUtil.decrypt(item.getSocialPaymentBaseString()));
|
|
||||||
item.setFundPaymentBaseString(AESEncryptUtil.decrypt(item.getFundPaymentBaseString()));
|
|
||||||
item.setOtherPaymentBaseString(AESEncryptUtil.decrypt(item.getOtherPaymentBaseString()));
|
|
||||||
item.setSocialPerJson(AESEncryptUtil.decrypt(item.getSocialPerJson()));
|
|
||||||
item.setSocialPerSum(AESEncryptUtil.decrypt(item.getSocialPerSum()));
|
|
||||||
item.setFundPerJson(AESEncryptUtil.decrypt(item.getFundPerJson()));
|
|
||||||
item.setFundPerSum(AESEncryptUtil.decrypt(item.getFundPerSum()));
|
|
||||||
item.setOtherPerJson(AESEncryptUtil.decrypt(item.getOtherPerJson()));
|
|
||||||
item.setOtherPerSum(AESEncryptUtil.decrypt(item.getOtherPerSum()));
|
|
||||||
item.setPerSum(AESEncryptUtil.decrypt(item.getPerSum()));
|
|
||||||
item.setSocialComJson(AESEncryptUtil.decrypt(item.getSocialComJson()));
|
|
||||||
item.setSocialComSum(AESEncryptUtil.decrypt(item.getSocialComSum()));
|
|
||||||
item.setComSum(AESEncryptUtil.decrypt(item.getComSum()));
|
|
||||||
item.setSocialSum(AESEncryptUtil.decrypt(item.getSocialSum()));
|
|
||||||
item.setFundSum(AESEncryptUtil.decrypt(item.getFundSum()));
|
|
||||||
item.setOtherSum(AESEncryptUtil.decrypt(item.getOtherSum()));
|
|
||||||
item.setTotal(AESEncryptUtil.decrypt(item.getTotal()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
@ -1,54 +0,0 @@
|
||||||
package com.engine.salary.encrypt.sischeme;
|
|
||||||
|
|
||||||
import com.engine.salary.encrypt.AESEncryptUtil;
|
|
||||||
import com.engine.salary.entity.sischeme.po.InsuranceSchemeDetailPO;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
@Deprecated
|
|
||||||
public class InsuranceSchemeDetailPOEncrypt {
|
|
||||||
public static List<InsuranceSchemeDetailPO> encryptList(List<InsuranceSchemeDetailPO> list) {
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setLowerLimit(AESEncryptUtil.encrypt(item.getLowerLimit()));
|
|
||||||
item.setFixedCost(AESEncryptUtil.encrypt(item.getFixedCost()));
|
|
||||||
item.setUpperLimit(AESEncryptUtil.encrypt(item.getUpperLimit()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static List<InsuranceSchemeDetailPO> decryptList(List<InsuranceSchemeDetailPO> list) {
|
|
||||||
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setLowerLimit(AESEncryptUtil.decrypt(item.getLowerLimit()));
|
|
||||||
item.setFixedCost(AESEncryptUtil.decrypt(item.getFixedCost()));
|
|
||||||
item.setUpperLimit(AESEncryptUtil.decrypt(item.getUpperLimit()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static InsuranceSchemeDetailPO encryptItem(InsuranceSchemeDetailPO item) {
|
|
||||||
if(item == null) {
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
item.setLowerLimit(AESEncryptUtil.encrypt(item.getLowerLimit()));
|
|
||||||
item.setFixedCost(AESEncryptUtil.encrypt(item.getFixedCost()));
|
|
||||||
item.setUpperLimit(AESEncryptUtil.encrypt(item.getUpperLimit()));
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static InsuranceSchemeDetailPO decryptItem(InsuranceSchemeDetailPO item) {
|
|
||||||
if(item == null) {
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
item.setLowerLimit(AESEncryptUtil.decrypt(item.getLowerLimit()));
|
|
||||||
item.setFixedCost(AESEncryptUtil.decrypt(item.getFixedCost()));
|
|
||||||
item.setUpperLimit(AESEncryptUtil.decrypt(item.getUpperLimit()));
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
@ -1,36 +0,0 @@
|
||||||
package com.engine.salary.encrypt.taxdeclaration;
|
|
||||||
|
|
||||||
import com.engine.salary.encrypt.AESEncryptUtil;
|
|
||||||
import com.engine.salary.entity.taxdeclaration.po.TaxDeclarationDetailPO;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* hrsa_tax_declaration_detail: 加解密
|
|
||||||
* 字段:
|
|
||||||
* field_value
|
|
||||||
*/
|
|
||||||
|
|
||||||
@Deprecated
|
|
||||||
public class TaxDeclarationDetailEncrypt {
|
|
||||||
public static List<TaxDeclarationDetailPO> encryptTaxDeclarationDetailList(List<TaxDeclarationDetailPO> list) {
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setFieldValue(AESEncryptUtil.encrypt(item.getFieldValue()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static List<TaxDeclarationDetailPO> decryptTaxDeclarationDetailList(List<TaxDeclarationDetailPO> list) {
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setFieldValue(AESEncryptUtil.decrypt(item.getFieldValue()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
@ -1,54 +0,0 @@
|
||||||
package com.engine.salary.encrypt.taxdeclaration;
|
|
||||||
|
|
||||||
import com.engine.salary.encrypt.AESEncryptUtil;
|
|
||||||
import com.engine.salary.entity.taxdeclaration.po.TaxDeclarationDetailPO;
|
|
||||||
|
|
||||||
import java.util.Collection;
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* hrsa_tax_declaration_detail: 加解密
|
|
||||||
* 字段:
|
|
||||||
* field_value
|
|
||||||
*/
|
|
||||||
@Deprecated
|
|
||||||
public class TaxDeclarationDetailPOEncrypt {
|
|
||||||
public static List<TaxDeclarationDetailPO> encryptTaxDeclarationDetailPOList(List<TaxDeclarationDetailPO> list) {
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setFieldValue(AESEncryptUtil.encrypt(item.getFieldValue()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static Collection<TaxDeclarationDetailPO> encryptTaxDeclarationDetailPOList(Collection<TaxDeclarationDetailPO> list) {
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setFieldValue(AESEncryptUtil.encrypt(item.getFieldValue()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static List<TaxDeclarationDetailPO> decryptTaxDeclarationDetailPOList(List<TaxDeclarationDetailPO> list) {
|
|
||||||
if(list == null || list.size() == 0) {
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
list.forEach(item -> {
|
|
||||||
item.setFieldValue(AESEncryptUtil.decrypt(item.getFieldValue()));
|
|
||||||
});
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
public static TaxDeclarationDetailPO encryptTaxDeclarationDetailPOItem(TaxDeclarationDetailPO item) {
|
|
||||||
if(item == null) {
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
item.setFieldValue(AESEncryptUtil.decrypt(item.getFieldValue()));
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
@ -126,6 +126,13 @@ public class AddUpSituation {
|
||||||
@Encrypt
|
@Encrypt
|
||||||
private String addUpInfantCare;
|
private String addUpInfantCare;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 累计婴幼儿照护
|
||||||
|
*/
|
||||||
|
@SalaryFormulaVar(defaultLabel = "累计个人养老金", labelId = 117732, dataType = "number")
|
||||||
|
@Encrypt
|
||||||
|
private String addUpPrivatePension;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 累计企业(职业)年金及其他福利
|
* 累计企业(职业)年金及其他福利
|
||||||
*/
|
*/
|
||||||
|
|
|
||||||
|
|
@ -204,6 +204,13 @@ public class AddUpSituationDTO {
|
||||||
@Encrypt
|
@Encrypt
|
||||||
private String addUpInfantCare;
|
private String addUpInfantCare;
|
||||||
|
|
||||||
|
//累计个人养老金
|
||||||
|
@ExcelProperty(index = 24)
|
||||||
|
@SalaryTableColumn(text = "累计个人养老金", width = "10%", column = "addUpPrivatePension")
|
||||||
|
@TableTitle(title = "累计个人养老金", dataIndex = "addUpPrivatePension", key = "addUpPrivatePension")
|
||||||
|
@Encrypt
|
||||||
|
private String addUpPrivatePension;
|
||||||
|
|
||||||
@SalaryTableColumn(text = "操作", width = "20%", column = "operate")
|
@SalaryTableColumn(text = "操作", width = "20%", column = "operate")
|
||||||
@TableTitle(title = "操作", dataIndex = "operate", key = "operate")
|
@TableTitle(title = "操作", dataIndex = "operate", key = "operate")
|
||||||
private String operate;
|
private String operate;
|
||||||
|
|
|
||||||
|
|
@ -170,4 +170,10 @@ public class AddUpSituationRecordDTO {
|
||||||
@TableTitle(title = "累计婴幼儿照护", dataIndex = "addUpInfantCare", key = "addUpInfantCare")
|
@TableTitle(title = "累计婴幼儿照护", dataIndex = "addUpInfantCare", key = "addUpInfantCare")
|
||||||
@Encrypt
|
@Encrypt
|
||||||
private String addUpInfantCare;
|
private String addUpInfantCare;
|
||||||
|
|
||||||
|
@ExcelProperty(index = 23)
|
||||||
|
@SalaryTableColumn(text = "累计个人养老金", width = "10%", column = "addUpPrivatePension")
|
||||||
|
@TableTitle(title = "累计个人养老金", dataIndex = "addUpPrivatePension", key = "addUpPrivatePension")
|
||||||
|
@Encrypt
|
||||||
|
private String addUpPrivatePension;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -108,6 +108,12 @@ public class OtherDeductionListDTO {
|
||||||
@Encrypt
|
@Encrypt
|
||||||
private String deductionAllowedDonation;
|
private String deductionAllowedDonation;
|
||||||
|
|
||||||
|
@ExcelProperty(index = 11)
|
||||||
|
@SalaryTableColumn(text = "个人养老金", width = "10%", column = "privatePension")
|
||||||
|
@TableTitle(title = "个人养老金", dataIndex = "privatePension", key = "privatePension")
|
||||||
|
@Encrypt
|
||||||
|
private String privatePension;
|
||||||
|
|
||||||
@SalaryTableColumn(text = "操作", width = "20%", column = "operate")
|
@SalaryTableColumn(text = "操作", width = "20%", column = "operate")
|
||||||
@TableTitle(title = "操作", dataIndex = "operate", key = "operate")
|
@TableTitle(title = "操作", dataIndex = "operate", key = "operate")
|
||||||
private String operate;
|
private String operate;
|
||||||
|
|
|
||||||
|
|
@ -93,4 +93,9 @@ public class OtherDeductionRecordDTO {
|
||||||
@TableTitle(title = "准予扣除的捐赠额", dataIndex = "deductionAllowedDonation", key = "deductionAllowedDonation")
|
@TableTitle(title = "准予扣除的捐赠额", dataIndex = "deductionAllowedDonation", key = "deductionAllowedDonation")
|
||||||
@Encrypt
|
@Encrypt
|
||||||
private String deductionAllowedDonation;
|
private String deductionAllowedDonation;
|
||||||
|
|
||||||
|
@SalaryTableColumn(text = "个人养老金", width = "10%", column = "privatePension")
|
||||||
|
@TableTitle(title = "个人养老金", dataIndex = "privatePension", key = "privatePension")
|
||||||
|
@Encrypt
|
||||||
|
private String privatePension;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -95,4 +95,7 @@ public class AddUpSituationParam {
|
||||||
//累计婴幼儿照护
|
//累计婴幼儿照护
|
||||||
private String addUpInfantCare;
|
private String addUpInfantCare;
|
||||||
|
|
||||||
|
//累计个人养老金
|
||||||
|
private String addUpPrivatePension;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -56,5 +56,8 @@ public class OtherDeductionParam {
|
||||||
// 准予扣除的捐赠额
|
// 准予扣除的捐赠额
|
||||||
private String deductionAllowedDonation;
|
private String deductionAllowedDonation;
|
||||||
|
|
||||||
|
//个人养老金
|
||||||
|
private String privatePension;
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -68,6 +68,13 @@ public class OtherDeductionPO {
|
||||||
@Encrypt
|
@Encrypt
|
||||||
private String deductionAllowedDonation;
|
private String deductionAllowedDonation;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 个人养老金
|
||||||
|
*/
|
||||||
|
@SalaryFormulaVar(defaultLabel = "个人养老金", labelId = 91240, dataType = "number")
|
||||||
|
@Encrypt
|
||||||
|
private String privatePension;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 创建时间
|
* 创建时间
|
||||||
*/
|
*/
|
||||||
|
|
|
||||||
|
|
@ -18,10 +18,7 @@ import com.engine.salary.util.page.Column;
|
||||||
import com.google.common.collect.Lists;
|
import com.google.common.collect.Lists;
|
||||||
import com.google.common.collect.Maps;
|
import com.google.common.collect.Maps;
|
||||||
|
|
||||||
import java.util.Collections;
|
import java.util.*;
|
||||||
import java.util.HashMap;
|
|
||||||
import java.util.List;
|
|
||||||
import java.util.Map;
|
|
||||||
import java.util.function.Function;
|
import java.util.function.Function;
|
||||||
import java.util.stream.Collectors;
|
import java.util.stream.Collectors;
|
||||||
|
|
||||||
|
|
@ -44,13 +41,20 @@ public class InsuranceComparisonResultBO {
|
||||||
* 构建福利核算结果列表的表头(线下对比)
|
* 构建福利核算结果列表的表头(线下对比)
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public static List<Column> buildTableColumns4ComparisonResult() {
|
public static List<Column> buildTableColumns4ComparisonResult(Set<Long> insuranceBaseSet, Set<Long> insurancePerPaySet, Set<Long> insuranceComPaySet) {
|
||||||
|
|
||||||
List<ICategoryPO> listAll = MapperProxyFactory.getProxy(ICategoryMapper.class).listAll();
|
List<ICategoryPO> listAll = MapperProxyFactory.getProxy(ICategoryMapper.class).listAll();
|
||||||
List<ICategoryPO> socialWelfareList = listAll.stream().filter(e -> e.getWelfareType() == 1).collect(Collectors.toList());
|
List<ICategoryPO> socialWelfareList = listAll.stream().filter(e -> e.getWelfareType() == 1 && e.getIsUse() == 1 && insuranceBaseSet.contains(e.getId())).collect(Collectors.toList());
|
||||||
List<ICategoryPO> fundWelfareList = listAll.stream().filter(e -> e.getWelfareType() == 2).collect(Collectors.toList());
|
List<ICategoryPO> fundWelfareList = listAll.stream().filter(e -> e.getWelfareType() == 2 && e.getIsUse() == 1 && insuranceBaseSet.contains(e.getId())).collect(Collectors.toList());
|
||||||
List<ICategoryPO> otherWelfareList = listAll.stream().filter(e -> e.getWelfareType() == 3).collect(Collectors.toList());
|
List<ICategoryPO> otherWelfareList = listAll.stream().filter(e -> e.getWelfareType() == 3 && e.getIsUse() == 1 && insuranceBaseSet.contains(e.getId())).collect(Collectors.toList());
|
||||||
|
|
||||||
|
List<ICategoryPO> socialWelPerList = listAll.stream().filter(e -> e.getWelfareType() == 1 && e.getIsUse() == 1 && insurancePerPaySet.contains(e.getId())).collect(Collectors.toList());
|
||||||
|
List<ICategoryPO> fundWelPerList = listAll.stream().filter(e -> e.getWelfareType() == 2 && e.getIsUse() == 1 && insurancePerPaySet.contains(e.getId())).collect(Collectors.toList());
|
||||||
|
List<ICategoryPO> otherWelPerList = listAll.stream().filter(e -> e.getWelfareType() == 3 && e.getIsUse() == 1 && insurancePerPaySet.contains(e.getId())).collect(Collectors.toList());
|
||||||
|
|
||||||
|
List<ICategoryPO> socialWelComList = listAll.stream().filter(e -> e.getWelfareType() == 1 && e.getIsUse() == 1 && insuranceComPaySet.contains(e.getId())).collect(Collectors.toList());
|
||||||
|
List<ICategoryPO> fundWelComList = listAll.stream().filter(e -> e.getWelfareType() == 2 && e.getIsUse() == 1 && insuranceComPaySet.contains(e.getId())).collect(Collectors.toList());
|
||||||
|
List<ICategoryPO> otherWelComList = listAll.stream().filter(e -> e.getWelfareType() == 3 && e.getIsUse() == 1 && insuranceComPaySet.contains(e.getId())).collect(Collectors.toList());
|
||||||
List<Column> columns = Lists.newArrayList();
|
List<Column> columns = Lists.newArrayList();
|
||||||
// 员工信息字段
|
// 员工信息字段
|
||||||
columns.add(new Column("姓名", "userName", "userName"));
|
columns.add(new Column("姓名", "userName", "userName"));
|
||||||
|
|
@ -80,33 +84,33 @@ public class InsuranceComparisonResultBO {
|
||||||
}
|
}
|
||||||
|
|
||||||
//社保个人(生育保险个人、工伤保险个人、失业保险个人、养老保险个人、医疗保险个人)
|
//社保个人(生育保险个人、工伤保险个人、失业保险个人、养老保险个人、医疗保险个人)
|
||||||
for (ICategoryPO po : socialWelfareList) {
|
for (ICategoryPO po : socialWelPerList) {
|
||||||
columns.add(new Column(po.getInsuranceName() + "个人", po.getId() + "socialPer", po.getId() + "socialPer"));
|
columns.add(new Column(po.getInsuranceName() + "个人", po.getId() + "socialPer", po.getId() + "socialPer"));
|
||||||
}
|
}
|
||||||
columns.add(new Column("社保个人合计", "socialPerSum", "socialPerSum"));
|
columns.add(new Column("社保个人合计", "socialPerSum", "socialPerSum"));
|
||||||
//住房公积金个人、补充住房公积金个人
|
//住房公积金个人、补充住房公积金个人
|
||||||
for (ICategoryPO po : fundWelfareList) {
|
for (ICategoryPO po : fundWelPerList) {
|
||||||
columns.add(new Column(po.getInsuranceName() + "个人", po.getId() + "fundPer", po.getId() + "fundPer"));
|
columns.add(new Column(po.getInsuranceName() + "个人", po.getId() + "fundPer", po.getId() + "fundPer"));
|
||||||
}
|
}
|
||||||
columns.add(new Column("公积金个人合计", "fundPerSum", "fundPerSum"));
|
columns.add(new Column("公积金个人合计", "fundPerSum", "fundPerSum"));
|
||||||
//其他个人(比如企业年金个人)
|
//其他个人(比如企业年金个人)
|
||||||
for (ICategoryPO po : otherWelfareList) {
|
for (ICategoryPO po : otherWelPerList) {
|
||||||
columns.add(new Column(po.getInsuranceName() + "个人", po.getId() + "otherPer", po.getId() + "otherPer"));
|
columns.add(new Column(po.getInsuranceName() + "个人", po.getId() + "otherPer", po.getId() + "otherPer"));
|
||||||
}
|
}
|
||||||
columns.add(new Column("其他福利个人合计", "otherPerSum", "otherPerSum"));
|
columns.add(new Column("其他福利个人合计", "otherPerSum", "otherPerSum"));
|
||||||
columns.add(new Column("个人合计", "perSum", "perSum"));
|
columns.add(new Column("个人合计", "perSum", "perSum"));
|
||||||
//社保单位(生育保险单位、工伤保险单位、失业保险单位、养老保险单位、医疗保险单位)
|
//社保单位(生育保险单位、工伤保险单位、失业保险单位、养老保险单位、医疗保险单位)
|
||||||
for (ICategoryPO po : socialWelfareList) {
|
for (ICategoryPO po : socialWelComList) {
|
||||||
columns.add(new Column(po.getInsuranceName() + "单位", po.getId() + "socialCom", po.getId() + "socialCom"));
|
columns.add(new Column(po.getInsuranceName() + "单位", po.getId() + "socialCom", po.getId() + "socialCom"));
|
||||||
}
|
}
|
||||||
columns.add(new Column("社保单位合计", "socialComSum", "socialComSum"));
|
columns.add(new Column("社保单位合计", "socialComSum", "socialComSum"));
|
||||||
//住房公积金单位、补充住房公积金单位
|
//住房公积金单位、补充住房公积金单位
|
||||||
for (ICategoryPO po : fundWelfareList) {
|
for (ICategoryPO po : fundWelComList) {
|
||||||
columns.add(new Column(po.getInsuranceName() + "单位", po.getId() + "fundCom", po.getId() + "fundCom"));
|
columns.add(new Column(po.getInsuranceName() + "单位", po.getId() + "fundCom", po.getId() + "fundCom"));
|
||||||
}
|
}
|
||||||
columns.add(new Column("公积金单位合计", "fundComSum", "fundComSum"));
|
columns.add(new Column("公积金单位合计", "fundComSum", "fundComSum"));
|
||||||
//其他单位(比如企业年金单位)
|
//其他单位(比如企业年金单位)
|
||||||
for (ICategoryPO po : otherWelfareList) {
|
for (ICategoryPO po : otherWelComList) {
|
||||||
columns.add(new Column(po.getInsuranceName() + "单位", po.getId() + "otherCom", po.getId() + "otherCom"));
|
columns.add(new Column(po.getInsuranceName() + "单位", po.getId() + "otherCom", po.getId() + "otherCom"));
|
||||||
}
|
}
|
||||||
columns.add(new Column("其他福利单位合计", "otherComSum", "otherComSum"));
|
columns.add(new Column("其他福利单位合计", "otherComSum", "otherComSum"));
|
||||||
|
|
@ -123,7 +127,7 @@ public class InsuranceComparisonResultBO {
|
||||||
* 构建福利核算线下对比结果
|
* 构建福利核算线下对比结果
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public static List<Map<String, Object>> buildComparisonTableData(List<AccountExportPO> accountExportPOS, List<ExcelAccountExportPO> excelAccountExportPOS) {
|
public static List<Map<String, Object>> buildComparisonTableData(List<AccountExportPO> accountExportPOS, List<ExcelAccountExportPO> excelAccountExportPOS, Map<Long, String> schemeIdNameMap) {
|
||||||
|
|
||||||
Map<String, List<ExcelAccountExportPO>> excelResultMap = SalaryEntityUtil.group2Map(excelAccountExportPOS, ExcelAccountExportPO::getWorkcode);
|
Map<String, List<ExcelAccountExportPO>> excelResultMap = SalaryEntityUtil.group2Map(excelAccountExportPOS, ExcelAccountExportPO::getWorkcode);
|
||||||
// Map<String, List<AccountExportPO>> acctResultMap = SalaryEntityUtil.group2Map(accountExportPOS, AccountExportPO::getWorkcode);
|
// Map<String, List<AccountExportPO>> acctResultMap = SalaryEntityUtil.group2Map(accountExportPOS, AccountExportPO::getWorkcode);
|
||||||
|
|
@ -162,6 +166,11 @@ public class InsuranceComparisonResultBO {
|
||||||
map.put("supplementFundAccount", accountExportPO.getSupplementFundAccount());
|
map.put("supplementFundAccount", accountExportPO.getSupplementFundAccount());
|
||||||
map.put("supplementFundAccount" + DATA_TYPE_SUFFIX, SalaryDataTypeEnum.STRING.getValue());
|
map.put("supplementFundAccount" + DATA_TYPE_SUFFIX, SalaryDataTypeEnum.STRING.getValue());
|
||||||
|
|
||||||
|
//福利方案名称
|
||||||
|
map.put("socialSchemeName", schemeIdNameMap.get(accountExportPO.getSocialSchemeId()));
|
||||||
|
map.put("fundSchemeName", schemeIdNameMap.get(accountExportPO.getFundSchemeId()));
|
||||||
|
map.put("otherSchemeName", schemeIdNameMap.get(accountExportPO.getOtherSchemeId()));
|
||||||
|
|
||||||
//线下值
|
//线下值
|
||||||
List<ExcelAccountExportPO> excelResultValueList = excelResultMap.get(accountExportPO.getWorkcode());
|
List<ExcelAccountExportPO> excelResultValueList = excelResultMap.get(accountExportPO.getWorkcode());
|
||||||
ExcelAccountExportPO excelAccountExportPO = new ExcelAccountExportPO();
|
ExcelAccountExportPO excelAccountExportPO = new ExcelAccountExportPO();
|
||||||
|
|
|
||||||
|
|
@ -50,7 +50,7 @@ public class TaxDeclarationBO {
|
||||||
List<DataCollectionEmployee> simpleEmployees,
|
List<DataCollectionEmployee> simpleEmployees,
|
||||||
List<TaxAgentPO> taxAgents) {
|
List<TaxAgentPO> taxAgents) {
|
||||||
if (CollectionUtils.isEmpty(simpleEmployees)) {
|
if (CollectionUtils.isEmpty(simpleEmployees)) {
|
||||||
return Collections.emptyList();
|
simpleEmployees = new ArrayList<>();
|
||||||
}
|
}
|
||||||
Map<Long, String> taxAgentNameMap = SalaryEntityUtil.convert2Map(taxAgents, TaxAgentPO::getId,
|
Map<Long, String> taxAgentNameMap = SalaryEntityUtil.convert2Map(taxAgents, TaxAgentPO::getId,
|
||||||
TaxAgentPO::getName);
|
TaxAgentPO::getName);
|
||||||
|
|
@ -245,6 +245,9 @@ public class TaxDeclarationBO {
|
||||||
// 累计婴幼儿照护
|
// 累计婴幼儿照护
|
||||||
BigDecimal addUpInfantCare = findValue(TaxDeclarationDataIndexConstant.ADD_UP_INFANT_CARE, resultMap, salaryItemMap);
|
BigDecimal addUpInfantCare = findValue(TaxDeclarationDataIndexConstant.ADD_UP_INFANT_CARE, resultMap, salaryItemMap);
|
||||||
valueMap.put(TaxDeclarationDataIndexConstant.ADD_UP_INFANT_CARE, addUpInfantCare.toPlainString());
|
valueMap.put(TaxDeclarationDataIndexConstant.ADD_UP_INFANT_CARE, addUpInfantCare.toPlainString());
|
||||||
|
// 累计个人养老金
|
||||||
|
BigDecimal addUpPrivatePension = findValue(TaxDeclarationDataIndexConstant.ADD_UP_PRIVATE_PENSION, resultMap, salaryItemMap);
|
||||||
|
valueMap.put(TaxDeclarationDataIndexConstant.ADD_UP_PRIVATE_PENSION, addUpPrivatePension.toPlainString());
|
||||||
// 企业(职业)年金
|
// 企业(职业)年金
|
||||||
BigDecimal annuity = findValue(TaxDeclarationDataIndexConstant.ANNUITY, resultMap, salaryItemMap);
|
BigDecimal annuity = findValue(TaxDeclarationDataIndexConstant.ANNUITY, resultMap, salaryItemMap);
|
||||||
valueMap.put(TaxDeclarationDataIndexConstant.ANNUITY, annuity.toPlainString());
|
valueMap.put(TaxDeclarationDataIndexConstant.ANNUITY, annuity.toPlainString());
|
||||||
|
|
@ -412,6 +415,8 @@ public class TaxDeclarationBO {
|
||||||
BigDecimal addUpIllnessMedical = findAddUpValue(TaxDeclarationDataIndexConstant.ADD_UP_ILLNESS_MEDICAL, resultMap, salaryItemMap);
|
BigDecimal addUpIllnessMedical = findAddUpValue(TaxDeclarationDataIndexConstant.ADD_UP_ILLNESS_MEDICAL, resultMap, salaryItemMap);
|
||||||
// 累计婴幼儿照护
|
// 累计婴幼儿照护
|
||||||
BigDecimal addUpInfantCare = findAddUpValue(TaxDeclarationDataIndexConstant.ADD_UP_INFANT_CARE, resultMap, salaryItemMap);
|
BigDecimal addUpInfantCare = findAddUpValue(TaxDeclarationDataIndexConstant.ADD_UP_INFANT_CARE, resultMap, salaryItemMap);
|
||||||
|
// 累计个人养老金
|
||||||
|
BigDecimal addUpPrivatePension = findAddUpValue(TaxDeclarationDataIndexConstant.ADD_UP_PRIVATE_PENSION, resultMap, salaryItemMap);
|
||||||
// 累计企业(职业)年金及其他福利
|
// 累计企业(职业)年金及其他福利
|
||||||
BigDecimal addUpEnterpriseAndOther = findAddUpValue(TaxDeclarationDataIndexConstant.ADD_UP_ENTERPRISE_AND_OTHER, resultMap, salaryItemMap);
|
BigDecimal addUpEnterpriseAndOther = findAddUpValue(TaxDeclarationDataIndexConstant.ADD_UP_ENTERPRISE_AND_OTHER, resultMap, salaryItemMap);
|
||||||
// 累计其他免税扣除
|
// 累计其他免税扣除
|
||||||
|
|
@ -452,6 +457,7 @@ public class TaxDeclarationBO {
|
||||||
.addUpSupportElderly(addUpSupportElderly.toPlainString())
|
.addUpSupportElderly(addUpSupportElderly.toPlainString())
|
||||||
.addUpIllnessMedical(addUpIllnessMedical.toPlainString())
|
.addUpIllnessMedical(addUpIllnessMedical.toPlainString())
|
||||||
.addUpInfantCare(addUpInfantCare.toPlainString())
|
.addUpInfantCare(addUpInfantCare.toPlainString())
|
||||||
|
.addUpPrivatePension(addUpPrivatePension.toPlainString())
|
||||||
.addUpOtherDeduction(addUpOtherDeduction.toPlainString())
|
.addUpOtherDeduction(addUpOtherDeduction.toPlainString())
|
||||||
.addUpTaxExemptIncome(addUpTaxFreeIncome.toPlainString())
|
.addUpTaxExemptIncome(addUpTaxFreeIncome.toPlainString())
|
||||||
.addUpAllowedDonation(addUpAllowedDonation.toPlainString())
|
.addUpAllowedDonation(addUpAllowedDonation.toPlainString())
|
||||||
|
|
@ -715,7 +721,6 @@ public class TaxDeclarationBO {
|
||||||
|
|
||||||
private static String findStringValue(String fieldCode, Map<Long, List<SalaryAcctResultPO>> resultMap, Map<String, Long> salaryItemMap) {
|
private static String findStringValue(String fieldCode, Map<Long, List<SalaryAcctResultPO>> resultMap, Map<String, Long> salaryItemMap) {
|
||||||
return resultMap.getOrDefault(salaryItemMap.getOrDefault(fieldCode, 0L), Collections.emptyList()).stream()
|
return resultMap.getOrDefault(salaryItemMap.getOrDefault(fieldCode, 0L), Collections.emptyList()).stream()
|
||||||
.filter(f -> StringUtils.isNotBlank(f.getResultValue()))
|
|
||||||
.map(SalaryAcctResultPO::getResultValue)
|
.map(SalaryAcctResultPO::getResultValue)
|
||||||
.findFirst().orElse("");
|
.findFirst().orElse("");
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -61,6 +61,7 @@ public class TaxDeclarationDetailBO {
|
||||||
.addUpSupportElderly(fieldCodeKeyFieldValueMap.get(TaxDeclarationDataIndexConstant.ADD_UP_SUPPORT_ELDERLY))
|
.addUpSupportElderly(fieldCodeKeyFieldValueMap.get(TaxDeclarationDataIndexConstant.ADD_UP_SUPPORT_ELDERLY))
|
||||||
.addUpIllnessMedical(fieldCodeKeyFieldValueMap.get(TaxDeclarationDataIndexConstant.ADD_UP_ILLNESS_MEDICAL))
|
.addUpIllnessMedical(fieldCodeKeyFieldValueMap.get(TaxDeclarationDataIndexConstant.ADD_UP_ILLNESS_MEDICAL))
|
||||||
.addUpInfantCare(fieldCodeKeyFieldValueMap.get(TaxDeclarationDataIndexConstant.ADD_UP_INFANT_CARE))
|
.addUpInfantCare(fieldCodeKeyFieldValueMap.get(TaxDeclarationDataIndexConstant.ADD_UP_INFANT_CARE))
|
||||||
|
.addUpPrivatePension(fieldCodeKeyFieldValueMap.get(TaxDeclarationDataIndexConstant.ADD_UP_PRIVATE_PENSION))
|
||||||
.annuity(fieldCodeKeyFieldValueMap.get(TaxDeclarationDataIndexConstant.ANNUITY))
|
.annuity(fieldCodeKeyFieldValueMap.get(TaxDeclarationDataIndexConstant.ANNUITY))
|
||||||
.commercialHealthInsurance(fieldCodeKeyFieldValueMap.get(TaxDeclarationDataIndexConstant.COMMERCIAL_HEALTH_INSURANCE))
|
.commercialHealthInsurance(fieldCodeKeyFieldValueMap.get(TaxDeclarationDataIndexConstant.COMMERCIAL_HEALTH_INSURANCE))
|
||||||
.taxDeferredEndowmentInsurance(fieldCodeKeyFieldValueMap.get(TaxDeclarationDataIndexConstant.TAX_DEFERRED_ENDOWMENT_INSURANCE))
|
.taxDeferredEndowmentInsurance(fieldCodeKeyFieldValueMap.get(TaxDeclarationDataIndexConstant.TAX_DEFERRED_ENDOWMENT_INSURANCE))
|
||||||
|
|
|
||||||
|
|
@ -97,10 +97,14 @@ public class TaxDeclarationWageListDTO {
|
||||||
@TableTitle(title = "累计大病医疗", dataIndex = "addUpIllnessMedical", key = "addUpIllnessMedical")
|
@TableTitle(title = "累计大病医疗", dataIndex = "addUpIllnessMedical", key = "addUpIllnessMedical")
|
||||||
private String addUpIllnessMedical;
|
private String addUpIllnessMedical;
|
||||||
|
|
||||||
@SalaryTableColumn(text = "累计婴幼儿照护", width = "10%", column = "addUpInfantCare")
|
@SalaryTableColumn(text = "累计3岁以下婴幼儿照护", width = "10%", column = "addUpInfantCare")
|
||||||
@TableTitle(title = "累计婴幼儿照护", dataIndex = "addUpInfantCare", key = "addUpInfantCare")
|
@TableTitle(title = "累计3岁以下婴幼儿照护", dataIndex = "addUpInfantCare", key = "addUpInfantCare")
|
||||||
private String addUpInfantCare;
|
private String addUpInfantCare;
|
||||||
|
|
||||||
|
@SalaryTableColumn(text = "累计个人养老金", width = "10%", column = "addUpPrivatePension")
|
||||||
|
@TableTitle(title = "累计个人养老金", dataIndex = "addUpPrivatePension", key = "addUpPrivatePension")
|
||||||
|
private String addUpPrivatePension;
|
||||||
|
|
||||||
@SalaryTableColumn(text = "企业(职业)年金", width = "10%", column = "annuity")
|
@SalaryTableColumn(text = "企业(职业)年金", width = "10%", column = "annuity")
|
||||||
@TableTitle(title = "企业(职业)年金", dataIndex = "annuity", key = "annuity")
|
@TableTitle(title = "企业(职业)年金", dataIndex = "annuity", key = "annuity")
|
||||||
private String annuity;
|
private String annuity;
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,78 @@
|
||||||
|
package com.engine.salary.maintainer;
|
||||||
|
|
||||||
|
import com.engine.common.util.ServiceUtil;
|
||||||
|
import com.engine.salary.maintainer.datacollection.AddUpSituationManager;
|
||||||
|
import com.engine.salary.maintainer.salaryacct.SalaryAcctManager;
|
||||||
|
import com.engine.salary.maintainer.salaryacct.SalaryAcctSupplementParam;
|
||||||
|
import com.engine.salary.util.ResponseResult;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import weaver.hrm.HrmUserVarify;
|
||||||
|
import weaver.hrm.User;
|
||||||
|
|
||||||
|
import javax.servlet.http.HttpServletRequest;
|
||||||
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
import javax.ws.rs.GET;
|
||||||
|
import javax.ws.rs.Path;
|
||||||
|
import javax.ws.rs.Produces;
|
||||||
|
import javax.ws.rs.core.Context;
|
||||||
|
import javax.ws.rs.core.MediaType;
|
||||||
|
import java.util.Map;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 累计专项附加扣除
|
||||||
|
* <p>Copyright: Copyright (c) 2022</p>
|
||||||
|
* <p>Company: 泛微软件</p>
|
||||||
|
*
|
||||||
|
* @author qiantao
|
||||||
|
* @version 1.0
|
||||||
|
**/
|
||||||
|
@Slf4j
|
||||||
|
public class MaintainerController {
|
||||||
|
|
||||||
|
private SalaryAcctManager getSalaryAcctManager(User user) {
|
||||||
|
return ServiceUtil.getService(SalaryAcctManager.class, user);
|
||||||
|
}
|
||||||
|
|
||||||
|
private AddUpSituationManager getAddUpSituationManager(User user) {
|
||||||
|
return ServiceUtil.getService(AddUpSituationManager.class, user);
|
||||||
|
}
|
||||||
|
|
||||||
|
//---------------------------薪资核算 start ------------------------------------
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 补充核算
|
||||||
|
*
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@GET
|
||||||
|
@Path("/acct/supplement")
|
||||||
|
@Produces(MediaType.APPLICATION_JSON)
|
||||||
|
public String supplementAcctRecord(@Context HttpServletRequest request, @Context HttpServletResponse response) {
|
||||||
|
SalaryAcctSupplementParam queryParam = SalaryAcctSupplementParam.builder()
|
||||||
|
.salaryAcctRecordId(Long.parseLong(request.getParameter("salaryAcctRecordId")))
|
||||||
|
.salaryItemStrIds(request.getParameter("salaryItemStrIds")).build();
|
||||||
|
User user = HrmUserVarify.getUser(request, response);
|
||||||
|
return new ResponseResult<SalaryAcctSupplementParam, Map<String, Object>>(user).run(getSalaryAcctManager(user)::supplementAcctRecord, queryParam);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
//---------------------------薪资核算 end ------------------------------------
|
||||||
|
|
||||||
|
|
||||||
|
//---------------------------数据采集 往期累计情况 start ------------------------------------
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 恢复所有已申报的往期累计数据
|
||||||
|
*
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@GET
|
||||||
|
@Path("/addupsituation/recover")
|
||||||
|
@Produces(MediaType.APPLICATION_JSON)
|
||||||
|
public String recoverAddUpSituationHistoryData(@Context HttpServletRequest request, @Context HttpServletResponse response) {
|
||||||
|
User user = HrmUserVarify.getUser(request, response);
|
||||||
|
return new ResponseResult<Map<String, Object>, Boolean>(user).run(getAddUpSituationManager(user)::recoverAddUpHistoryData);
|
||||||
|
}
|
||||||
|
//---------------------------数据采集 往期累计情况 end ------------------------------------
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,66 @@
|
||||||
|
package com.engine.salary.maintainer.datacollection;
|
||||||
|
|
||||||
|
import com.engine.common.util.ServiceUtil;
|
||||||
|
import com.engine.core.impl.Service;
|
||||||
|
import com.engine.salary.entity.taxdeclaration.param.TaxDeclarationSaveParam;
|
||||||
|
import com.engine.salary.entity.taxdeclaration.po.TaxDeclarationPO;
|
||||||
|
import com.engine.salary.mapper.taxdeclaration.TaxDeclarationMapper;
|
||||||
|
import com.engine.salary.service.TaxDeclarationService;
|
||||||
|
import com.engine.salary.service.impl.TaxDeclarationServiceImpl;
|
||||||
|
import com.engine.salary.util.SalaryDateUtil;
|
||||||
|
import com.engine.salary.util.SalaryEntityUtil;
|
||||||
|
import com.engine.salary.util.db.MapperProxyFactory;
|
||||||
|
import weaver.general.BaseBean;
|
||||||
|
|
||||||
|
import java.text.SimpleDateFormat;
|
||||||
|
import java.time.LocalDate;
|
||||||
|
import java.time.YearMonth;
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.Map;
|
||||||
|
import java.util.stream.Collectors;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @author Harryxzy
|
||||||
|
* @date 2023/04/23 17:23
|
||||||
|
* @description 往期累计情况维护类
|
||||||
|
*/
|
||||||
|
public class AddUpSituationManager extends Service {
|
||||||
|
|
||||||
|
private TaxDeclarationMapper getTaxDeclarationMapper() {
|
||||||
|
return MapperProxyFactory.getProxy(TaxDeclarationMapper.class);
|
||||||
|
}
|
||||||
|
|
||||||
|
private TaxDeclarationService getTaxDeclarationService() {
|
||||||
|
return ServiceUtil.getService(TaxDeclarationServiceImpl.class, user);
|
||||||
|
}
|
||||||
|
|
||||||
|
public boolean recoverAddUpHistoryData() {
|
||||||
|
// 获取已有的个税申报表记录
|
||||||
|
List<TaxDeclarationPO> taxDeclarationList = getTaxDeclarationMapper().listSome(new TaxDeclarationPO());
|
||||||
|
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM");
|
||||||
|
Map<Long, String> taxDeclarationMap = SalaryEntityUtil.convert2Map(taxDeclarationList, TaxDeclarationPO::getId, PO->PO.getTaxAgentId()+"-"+sdf.format(PO.getSalaryMonth()));
|
||||||
|
BaseBean bb = new BaseBean();
|
||||||
|
List<Long> taxDeclarationIds = taxDeclarationList.stream().map(TaxDeclarationPO::getId).collect(Collectors.toList());
|
||||||
|
bb.writeLog("往期累计数据恢复DataIds:"+ taxDeclarationIds);
|
||||||
|
bb.writeLog("往期累计数据恢复DataMap:"+ taxDeclarationMap);
|
||||||
|
boolean result = true;
|
||||||
|
// 循环调用生成申报单接口
|
||||||
|
for(int i =0; i < taxDeclarationList.size(); i++){
|
||||||
|
TaxDeclarationPO po = taxDeclarationList.get(i);
|
||||||
|
bb.writeLog("开始删除生成:"+po.getTaxAgentId()+"-"+po.getSalaryMonth());
|
||||||
|
// 删除记录
|
||||||
|
int delete = getTaxDeclarationMapper().deleteByIdZj(po.getId());
|
||||||
|
LocalDate localDate = SalaryDateUtil.dateToLocalDate(po.getSalaryMonth());
|
||||||
|
// 调用生成申报单接口
|
||||||
|
YearMonth yearMonth = YearMonth.of(localDate.getYear(),localDate.getMonth());
|
||||||
|
try {
|
||||||
|
getTaxDeclarationService().save(TaxDeclarationSaveParam.builder().salaryMonth(yearMonth).taxAgentId(po.getTaxAgentId()).build());
|
||||||
|
}catch (Exception e){
|
||||||
|
bb.writeLog("错误:"+e);
|
||||||
|
result = false;
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,353 @@
|
||||||
|
package com.engine.salary.maintainer.salaryacct;
|
||||||
|
|
||||||
|
import com.engine.common.util.ServiceUtil;
|
||||||
|
import com.engine.core.impl.Service;
|
||||||
|
import com.engine.salary.entity.datacollection.DataCollectionEmployee;
|
||||||
|
import com.engine.salary.entity.datacollection.dto.AttendQuoteFieldListDTO;
|
||||||
|
import com.engine.salary.entity.salaryacct.bo.SalaryAcctCalculateBO;
|
||||||
|
import com.engine.salary.entity.salaryacct.bo.SalaryAcctCalculatePriorityBO;
|
||||||
|
import com.engine.salary.entity.salaryacct.dto.SalaryAcctProgressDTO;
|
||||||
|
import com.engine.salary.entity.salaryacct.po.SalaryAcctEmployeePO;
|
||||||
|
import com.engine.salary.entity.salaryacct.po.SalaryAcctRecordPO;
|
||||||
|
import com.engine.salary.entity.salaryacct.po.SalaryAcctResultPO;
|
||||||
|
import com.engine.salary.entity.salaryacct.po.SalaryAcctResultTempPO;
|
||||||
|
import com.engine.salary.entity.salaryformula.ExpressFormula;
|
||||||
|
import com.engine.salary.entity.salaryitem.po.SalaryItemPO;
|
||||||
|
import com.engine.salary.entity.salarysob.dto.SalarySobCycleDTO;
|
||||||
|
import com.engine.salary.entity.salarysob.po.SalarySobAdjustRulePO;
|
||||||
|
import com.engine.salary.entity.salarysob.po.SalarySobBackItemPO;
|
||||||
|
import com.engine.salary.entity.salarysob.po.SalarySobItemPO;
|
||||||
|
import com.engine.salary.entity.salarysob.po.SalarySobPO;
|
||||||
|
import com.engine.salary.exception.SalaryRunTimeException;
|
||||||
|
import com.engine.salary.mapper.salaryacct.SalaryAcctResultMapper;
|
||||||
|
import com.engine.salary.service.*;
|
||||||
|
import com.engine.salary.service.impl.*;
|
||||||
|
import com.engine.salary.util.SalaryEntityUtil;
|
||||||
|
import com.engine.salary.util.SalaryI18nUtil;
|
||||||
|
import com.engine.salary.util.db.MapperProxyFactory;
|
||||||
|
import com.engine.salary.util.valid.ValidUtil;
|
||||||
|
import com.google.common.collect.Lists;
|
||||||
|
import com.weaver.util.threadPool.ThreadPoolUtil;
|
||||||
|
import com.weaver.util.threadPool.constant.ModulePoolEnum;
|
||||||
|
import com.weaver.util.threadPool.entity.LocalRunnable;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.apache.commons.collections4.CollectionUtils;
|
||||||
|
import org.apache.commons.collections4.MapUtils;
|
||||||
|
import org.apache.commons.lang.math.NumberUtils;
|
||||||
|
import org.apache.commons.lang3.StringUtils;
|
||||||
|
import org.springframework.beans.BeanUtils;
|
||||||
|
import org.springframework.jdbc.datasource.DataSourceTransactionManager;
|
||||||
|
import weaver.hrm.User;
|
||||||
|
|
||||||
|
import java.math.BigDecimal;
|
||||||
|
import java.util.*;
|
||||||
|
import java.util.concurrent.BlockingDeque;
|
||||||
|
import java.util.concurrent.CountDownLatch;
|
||||||
|
import java.util.concurrent.LinkedBlockingDeque;
|
||||||
|
import java.util.stream.Collectors;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 薪资核算维护类
|
||||||
|
* <p>Copyright: Copyright (c) 2022</p>
|
||||||
|
* <p>Company: 泛微软件</p>
|
||||||
|
*
|
||||||
|
* @author qiantao
|
||||||
|
* @version 1.0
|
||||||
|
**/
|
||||||
|
@Slf4j
|
||||||
|
public class SalaryAcctManager extends Service {
|
||||||
|
private SalaryAcctResultMapper getSalaryAcctResultMapper() {
|
||||||
|
return MapperProxyFactory.getProxy(SalaryAcctResultMapper.class);
|
||||||
|
}
|
||||||
|
|
||||||
|
private SalaryAcctEmployeeService getSalaryAcctEmployeeService(User user) {
|
||||||
|
return ServiceUtil.getService(SalaryAcctEmployeeServiceImpl.class, user);
|
||||||
|
}
|
||||||
|
|
||||||
|
private SalaryAcctResultService getSalaryAcctResultService(User user) {
|
||||||
|
return ServiceUtil.getService(SalaryAcctResultServiceImpl.class, user);
|
||||||
|
}
|
||||||
|
|
||||||
|
private SalarySobItemService getSalarySobItemService(User user) {
|
||||||
|
return ServiceUtil.getService(SalarySobItemServiceImpl.class, user);
|
||||||
|
}
|
||||||
|
|
||||||
|
private SalaryItemService getSalaryItemService(User user) {
|
||||||
|
return ServiceUtil.getService(SalaryItemServiceImpl.class, user);
|
||||||
|
}
|
||||||
|
|
||||||
|
private SalarySobEmpFieldService getSalarySobEmpFieldService(User user) {
|
||||||
|
return ServiceUtil.getService(SalarySobEmpFieldServiceImpl.class, user);
|
||||||
|
}
|
||||||
|
|
||||||
|
private SalarySobService getSalarySobService(User user) {
|
||||||
|
return ServiceUtil.getService(SalarySobServiceImpl.class, user);
|
||||||
|
}
|
||||||
|
|
||||||
|
private SalaryAcctRecordService getSalaryAcctRecordService(User user) {
|
||||||
|
return ServiceUtil.getService(SalaryAcctRecordServiceImpl.class, user);
|
||||||
|
}
|
||||||
|
|
||||||
|
private TaxAgentService getTaxAgentService(User user) {
|
||||||
|
return ServiceUtil.getService(TaxAgentServiceImpl.class, user);
|
||||||
|
}
|
||||||
|
|
||||||
|
private SalaryEmployeeService getSalaryEmployeeService(User user) {
|
||||||
|
return ServiceUtil.getService(SalaryEmployeeServiceImpl.class, user);
|
||||||
|
}
|
||||||
|
|
||||||
|
private SalaryFormulaService getSalaryFormulaService(User user) {
|
||||||
|
return ServiceUtil.getService(SalaryFormulaServiceImpl.class, user);
|
||||||
|
}
|
||||||
|
|
||||||
|
private SalarySobAdjustRuleService getSalarySobAdjustRuleService(User user) {
|
||||||
|
return ServiceUtil.getService(SalarySobAdjustRuleServiceImpl.class, user);
|
||||||
|
}
|
||||||
|
|
||||||
|
private SalarySobItemHideService getSalarySobItemHideService(User user) {
|
||||||
|
return ServiceUtil.getService(SalarySobItemHideServiceImpl.class, user);
|
||||||
|
}
|
||||||
|
|
||||||
|
private SalaryAcctCalculateService getSalaryAcctCalculateService(User user) {
|
||||||
|
return ServiceUtil.getService(SalaryAcctCalculateServiceImpl.class, user);
|
||||||
|
}
|
||||||
|
|
||||||
|
private SalaryAcctProgressService getSalaryAcctProgressService(User user) {
|
||||||
|
return ServiceUtil.getService(SalaryAcctProgressServiceImpl.class, user);
|
||||||
|
}
|
||||||
|
|
||||||
|
private DataSourceTransactionManager dataSourceTransactionManager;
|
||||||
|
|
||||||
|
private SalaryAcctResultTempService getSalaryAcctResultTempService(User user) {
|
||||||
|
return ServiceUtil.getService(SalaryAcctResultTempServiceImpl.class, user);
|
||||||
|
}
|
||||||
|
// private LoggerTemplate salaryAcctRecordLoggerTemplate;
|
||||||
|
|
||||||
|
private SIAccountService getSIAccountService(User user) {
|
||||||
|
return ServiceUtil.getService(SIAccountServiceImpl.class, user);
|
||||||
|
}
|
||||||
|
|
||||||
|
private AttendQuoteFieldService getAttendQuoteFieldService(User user) {
|
||||||
|
return ServiceUtil.getService(AttendQuoteFieldServiceImpl.class, user);
|
||||||
|
}
|
||||||
|
|
||||||
|
private SalaryAcctReportService getSalaryAcctReportService(User user) {
|
||||||
|
return ServiceUtil.getService(SalaryAcctReportServiceImpl.class, user);
|
||||||
|
}
|
||||||
|
|
||||||
|
private SalarySobItemGroupService getSalarySobItemGroupService(User user) {
|
||||||
|
return ServiceUtil.getService(SalarySobItemGroupServiceImpl.class, user);
|
||||||
|
}
|
||||||
|
|
||||||
|
private SalarySobBackItemService getSalarySobBackItemService(User user) {
|
||||||
|
return ServiceUtil.getService(SalarySobBackItemServiceImpl.class, user);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 补充核算
|
||||||
|
* 核算已归档后,需要重新核算某一项
|
||||||
|
*/
|
||||||
|
public void supplementAcctRecord(SalaryAcctSupplementParam param) {
|
||||||
|
ValidUtil.doValidator(param);
|
||||||
|
|
||||||
|
List<Long> salaryItemIds = Arrays.stream(param.getSalaryItemStrIds().split(",")).map(Long::valueOf).collect(Collectors.toList());
|
||||||
|
param.setSalaryItemIds(salaryItemIds);
|
||||||
|
|
||||||
|
if(CollectionUtils.isEmpty(salaryItemIds)){
|
||||||
|
throw new SalaryRunTimeException("薪资项目为空!");
|
||||||
|
}
|
||||||
|
|
||||||
|
calculate(param);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 补算
|
||||||
|
*
|
||||||
|
* @param calculateParam 薪资核算的参数
|
||||||
|
*/
|
||||||
|
public void calculate(SalaryAcctSupplementParam calculateParam) {
|
||||||
|
log.info("补算开始{}", calculateParam);
|
||||||
|
|
||||||
|
//当前登陆人员
|
||||||
|
DataCollectionEmployee simpleEmployee = new DataCollectionEmployee();
|
||||||
|
simpleEmployee.setEmployeeId((long) user.getUID());
|
||||||
|
|
||||||
|
// 检查是否正在核算中
|
||||||
|
SalaryAcctProgressDTO salaryAcctProgressDTO = getSalaryAcctProgressService(user).getProgress("SUPPLEMENT_ACCT_PROGRESS_" + calculateParam.getSalaryAcctRecordId());
|
||||||
|
if (Objects.nonNull(salaryAcctProgressDTO) && salaryAcctProgressDTO.isStatus() && Optional.ofNullable(salaryAcctProgressDTO.getProgress()).orElse(BigDecimal.ZERO).compareTo(BigDecimal.ONE) < 0) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
// 初始化进度
|
||||||
|
SalaryAcctProgressDTO initProgress = new SalaryAcctProgressDTO()
|
||||||
|
.setTitle(SalaryI18nUtil.getI18nLabel(97515, "核算中"))
|
||||||
|
.setTitleLabelId(97515L)
|
||||||
|
.setTotalQuantity(NumberUtils.INTEGER_ONE)
|
||||||
|
.setCalculatedQuantity(NumberUtils.INTEGER_ZERO)
|
||||||
|
.setProgress(BigDecimal.ZERO)
|
||||||
|
.setStatus(true)
|
||||||
|
.setMessage(StringUtils.EMPTY);
|
||||||
|
getSalaryAcctProgressService(user).initProgress("SUPPLEMENT_ACCT_PROGRESS_" + calculateParam.getSalaryAcctRecordId(), initProgress);
|
||||||
|
new Thread() {
|
||||||
|
public void run() {
|
||||||
|
calculate(calculateParam, simpleEmployee);
|
||||||
|
}
|
||||||
|
}.start();
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
public void calculate(SalaryAcctSupplementParam calculateParam, DataCollectionEmployee simpleEmployee) {
|
||||||
|
try {
|
||||||
|
// 1、查询薪资核算记录
|
||||||
|
SalaryAcctRecordPO salaryAcctRecordPO = getSalaryAcctRecordService(user).getById(calculateParam.getSalaryAcctRecordId());
|
||||||
|
if (Objects.isNull(salaryAcctRecordPO)) {
|
||||||
|
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(98747, "薪资核算记录不存在或已被删除"));
|
||||||
|
}
|
||||||
|
//查询对应账套
|
||||||
|
SalarySobPO salarySobPO = getSalarySobService(user).getById(salaryAcctRecordPO.getSalarySobId());
|
||||||
|
if (Objects.isNull(salarySobPO)) {
|
||||||
|
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(98747, "薪资账套不存在或已被删除"));
|
||||||
|
}
|
||||||
|
// 2、查询薪资核算记录的薪资周期、考勤周期等
|
||||||
|
SalarySobCycleDTO salarySobCycleDTO = getSalaryAcctRecordService(user).getSalarySobCycleById(calculateParam.getSalaryAcctRecordId());
|
||||||
|
// 3、查询薪资核算记录所用薪资账套的薪资项目副本
|
||||||
|
List<SalarySobItemPO> salarySobItemPOS = getSalarySobItemService(user).listBySalarySobId(salaryAcctRecordPO.getSalarySobId());
|
||||||
|
if (CollectionUtils.isEmpty(salarySobItemPOS)) {
|
||||||
|
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(99151, "当前所用的薪资账套未选择任何薪资项目,无法核算"));
|
||||||
|
}
|
||||||
|
// 回算薪资项目
|
||||||
|
List<SalarySobBackItemPO> salarySobBackItems = Collections.emptyList();
|
||||||
|
if (Objects.equals(salaryAcctRecordPO.getBackCalcStatus(), 1)) {
|
||||||
|
salarySobBackItems = getSalarySobBackItemService(user).listBySalarySobId(salaryAcctRecordPO.getSalarySobId());
|
||||||
|
}
|
||||||
|
// 4、查询当前租户的所有薪资项目
|
||||||
|
List<SalaryItemPO> salaryItemPOS = getSalaryItemService(user).listAll();
|
||||||
|
// 5、查询薪资核算记录所用薪资账套的调薪计薪规则
|
||||||
|
List<SalarySobAdjustRulePO> salarySobAdjustRulePOS = getSalarySobAdjustRuleService(user).listBySalarySobId(salaryAcctRecordPO.getSalarySobId());
|
||||||
|
// 6、查询社保福利的所有字段
|
||||||
|
Map<String, String> welfareColumns = getSIAccountService(user).welfareColumns();
|
||||||
|
// 7、查询考勤引用的所有字段
|
||||||
|
List<AttendQuoteFieldListDTO> attendQuoteFieldListDTOS = getAttendQuoteFieldService(user).listAll();
|
||||||
|
|
||||||
|
//核算锁定值
|
||||||
|
List<Long> lockSalaryItemIds = salaryAcctRecordPO.getLockSalaryItemIds();
|
||||||
|
Map<String, SalaryAcctResultPO> acctResults = new HashMap<>();
|
||||||
|
if (CollectionUtils.isNotEmpty(lockSalaryItemIds)) {
|
||||||
|
List<SalaryAcctResultPO> acctResultPOS = getSalaryAcctResultService(user).listBySalaryAcctRecordIds(Collections.singleton(calculateParam.getSalaryAcctRecordId()));
|
||||||
|
acctResults = Optional.ofNullable(acctResultPOS)
|
||||||
|
.orElse(new ArrayList<>())
|
||||||
|
.stream()
|
||||||
|
.filter(po -> lockSalaryItemIds.contains(po.getSalaryItemId()))
|
||||||
|
.collect(Collectors.toMap(po -> po.getSalaryItemId() + "_" + po.getSalaryAcctEmpId(), a -> a, (a, b) -> a));
|
||||||
|
}
|
||||||
|
|
||||||
|
// 8、查询公式详情
|
||||||
|
Set<Long> formulaIds = SalaryEntityUtil.properties(salarySobItemPOS, SalarySobItemPO::getFormulaId);
|
||||||
|
formulaIds.addAll(SalaryEntityUtil.properties(salaryItemPOS, SalaryItemPO::getFormulaId));
|
||||||
|
formulaIds.addAll(SalaryEntityUtil.properties(salarySobBackItems, SalarySobBackItemPO::getFormulaId));
|
||||||
|
List<ExpressFormula> expressFormulas = getSalaryFormulaService(user).listExpressFormula(formulaIds);
|
||||||
|
// 本次运算的回算薪资项目所涉及的变量
|
||||||
|
Set<String> issuedFieldIds = new HashSet<>();
|
||||||
|
// 9、计算薪资项目的运算优先级
|
||||||
|
List<List<Long>> salarySobItemsWithPriority = SalaryAcctCalculatePriorityBO.calculatePriority(salarySobItemPOS, salaryItemPOS, expressFormulas, salarySobBackItems, issuedFieldIds);
|
||||||
|
// 10、根据id查询其他合并计税的薪资核算记录
|
||||||
|
List<SalaryAcctRecordPO> otherSalaryAcctRecordPOS = getSalaryAcctRecordService(user).listById4OtherConsolidatedTax(salaryAcctRecordPO.getId());
|
||||||
|
// 11、查询本次核算人员
|
||||||
|
List<SalaryAcctEmployeePO> salaryAcctEmployeePOS = getSalaryAcctEmployeeService(user).listBySalaryAcctRecordId(salaryAcctRecordPO.getId());
|
||||||
|
if (CollectionUtils.isEmpty(salaryAcctEmployeePOS)) {
|
||||||
|
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(103378, "薪资核算人员不能为空"));
|
||||||
|
}
|
||||||
|
// 11.1、初始化进度
|
||||||
|
SalaryAcctProgressDTO initProgress = new SalaryAcctProgressDTO().setTitle(SalaryI18nUtil.getI18nLabel(97515, "核算中")).setTitleLabelId(97515L).setTotalQuantity(salaryAcctEmployeePOS.size() * 2 + 1).setCalculatedQuantity(0).setProgress(BigDecimal.ZERO).setStatus(true).setMessage(StringUtils.EMPTY);
|
||||||
|
getSalaryAcctProgressService(user).initProgress("SUPPLEMENT_ACCT_PROGRESS_" + calculateParam.getSalaryAcctRecordId(), initProgress);
|
||||||
|
// 12、对薪资核算人员进行拆分
|
||||||
|
List<List<SalaryAcctEmployeePO>> partition = Lists.partition(salaryAcctEmployeePOS, 5000);
|
||||||
|
// 12.1、监控子线程的任务执行
|
||||||
|
CountDownLatch childMonitor = new CountDownLatch(partition.size());
|
||||||
|
// 12.2、记录子线程的执行结果
|
||||||
|
BlockingDeque<SalaryAcctCalculateBO.Result> calculateResults = new LinkedBlockingDeque<>(partition.size());
|
||||||
|
// 12.3、生成本次运算的key
|
||||||
|
String calculateKey = UUID.randomUUID().toString();
|
||||||
|
// 12.4、多线程运算,运算结果存放在临时表中
|
||||||
|
for (List<SalaryAcctEmployeePO> acctEmployeePOS : partition) {
|
||||||
|
SalaryAcctCalculateBO salaryAcctCalculateBO = new SalaryAcctCalculateBO()
|
||||||
|
.setSalaryAcctRecordPO(salaryAcctRecordPO)
|
||||||
|
.setSalarySobPO(salarySobPO)
|
||||||
|
.setSalarySobCycleDTO(salarySobCycleDTO)
|
||||||
|
.setOtherSalaryAcctRecordPOS(otherSalaryAcctRecordPOS)
|
||||||
|
.setSalaryAcctLockResultPOS(MapUtils.emptyIfNull(acctResults))
|
||||||
|
.setLockSalaryItemIds(lockSalaryItemIds)
|
||||||
|
.setSalarySobItemPOS(salarySobItemPOS)
|
||||||
|
.setSalaryItemIdWithPriorityList(salarySobItemsWithPriority)
|
||||||
|
.setExpressFormulas(expressFormulas)
|
||||||
|
.setSalaryItemPOS(salaryItemPOS)
|
||||||
|
.setSalarySobAdjustRulePOS(salarySobAdjustRulePOS)
|
||||||
|
.setWelfareColumns(MapUtils.emptyIfNull(welfareColumns))
|
||||||
|
.setAttendQuoteFieldListDTOS(attendQuoteFieldListDTOS)
|
||||||
|
.setSalaryAcctEmployeePOS(acctEmployeePOS)
|
||||||
|
.setIssuedFieldIds(issuedFieldIds)
|
||||||
|
.setChildMonitor(childMonitor)
|
||||||
|
.setResults(calculateResults)
|
||||||
|
.setCalculateKey(calculateKey);
|
||||||
|
List<SalarySobBackItemPO> finalSalarySobBackItems = salarySobBackItems;
|
||||||
|
LocalRunnable localRunnable = new LocalRunnable() {
|
||||||
|
@Override
|
||||||
|
public void execute() {
|
||||||
|
getSalaryAcctCalculateService(user).calculate(salaryAcctCalculateBO, simpleEmployee, finalSalarySobBackItems);
|
||||||
|
}
|
||||||
|
};
|
||||||
|
ThreadPoolUtil.fixedPoolExecute(ModulePoolEnum.HRM, "salaryAcctCalculateV2", localRunnable);
|
||||||
|
}
|
||||||
|
// 13、等待所有子线程执行完毕
|
||||||
|
childMonitor.await();
|
||||||
|
// 14、判断子线程执行结果
|
||||||
|
boolean allSuccess = calculateResults.stream().allMatch(SalaryAcctCalculateBO.Result::isStatus);
|
||||||
|
if (!allSuccess) {
|
||||||
|
// 薪资核算实现的线程的错误信息
|
||||||
|
String errorMsg = calculateResults.stream().filter(result -> !result.isStatus()).map(SalaryAcctCalculateBO.Result::getErrMsg).collect(Collectors.joining("|"));
|
||||||
|
getSalaryAcctProgressService(user).fail("SUPPLEMENT_ACCT_PROGRESS_" + calculateParam.getSalaryAcctRecordId(), errorMsg);
|
||||||
|
// 删除薪资核算临时存储表中的数据
|
||||||
|
getSalaryAcctResultTempService(user).deleteByCalculateKey(calculateKey);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
// 15、处理核算结果临时表数据
|
||||||
|
handleSalaryAcctResultTemp(calculateParam, calculateKey);
|
||||||
|
|
||||||
|
getSalaryAcctProgressService(user).finish("SUPPLEMENT_ACCT_PROGRESS_" + calculateParam.getSalaryAcctRecordId(), true);
|
||||||
|
|
||||||
|
} catch (Exception e) {
|
||||||
|
log.info("薪资核算出错:{}", e.getMessage(), e);
|
||||||
|
getSalaryAcctProgressService(user).fail("SUPPLEMENT_ACCT_PROGRESS_" + calculateParam.getSalaryAcctRecordId(), SalaryI18nUtil.getI18nLabel(99642, "薪资核算出错") + ": " + e.getMessage());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 处理薪资核算临时存储表中的数据
|
||||||
|
*
|
||||||
|
* @param calculateParam
|
||||||
|
* @param calculateKey
|
||||||
|
*/
|
||||||
|
private void handleSalaryAcctResultTemp(SalaryAcctSupplementParam calculateParam, String calculateKey) {
|
||||||
|
// 查询薪资核算结果的临时存储
|
||||||
|
List<SalaryAcctResultTempPO> salaryAcctResultTempPOS = getSalaryAcctResultTempService(user).listByCalculateKey(calculateKey);
|
||||||
|
// 删除原来的薪资核算结果
|
||||||
|
List<Long> salaryItemIds = calculateParam.getSalaryItemIds();
|
||||||
|
getSalaryAcctResultMapper().deleteBySalaryAcctRecordIdAndSalaryItemIds(calculateParam.getSalaryAcctRecordId(), salaryItemIds);
|
||||||
|
// 保存薪资的薪资核算结果
|
||||||
|
List<SalaryAcctResultPO> salaryAcctResultPOS = salaryAcctResultTempPOS.stream().filter(salaryAcctResultTempPO -> salaryItemIds.contains(salaryAcctResultTempPO.getSalaryItemId())).map(e -> {
|
||||||
|
SalaryAcctResultPO salaryAcctResult = new SalaryAcctResultPO();
|
||||||
|
BeanUtils.copyProperties(e, salaryAcctResult);
|
||||||
|
return salaryAcctResult;
|
||||||
|
}).collect(Collectors.toList());
|
||||||
|
getSalaryAcctResultService(user).batchSave(salaryAcctResultPOS);
|
||||||
|
//保存核算报表数据
|
||||||
|
// List<SalaryAcctResultReportPO> salaryAcctResultReportPOS = SalaryAcctResultReportBO.convert2ReportPO(salaryAcctResultTempPOS, calculateParam.getEmps());
|
||||||
|
// getSalaryAcctReportService(user).batchSave(salaryAcctResultReportPOS);
|
||||||
|
// 删除薪资核算临时存储表中的数据
|
||||||
|
getSalaryAcctResultTempService(user).deleteByCalculateKey(calculateKey);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,33 @@
|
||||||
|
package com.engine.salary.maintainer.salaryacct;
|
||||||
|
|
||||||
|
import com.engine.salary.util.valid.DataCheck;
|
||||||
|
import lombok.AllArgsConstructor;
|
||||||
|
import lombok.Builder;
|
||||||
|
import lombok.Data;
|
||||||
|
import lombok.NoArgsConstructor;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 薪资补充核算的参数
|
||||||
|
* <p>Copyright: Copyright (c) 2022</p>
|
||||||
|
* <p>Company: 泛微软件</p>
|
||||||
|
*
|
||||||
|
* @author qiantao
|
||||||
|
* @version 1.0
|
||||||
|
**/
|
||||||
|
@Data
|
||||||
|
@Builder
|
||||||
|
@NoArgsConstructor
|
||||||
|
@AllArgsConstructor
|
||||||
|
public class SalaryAcctSupplementParam {
|
||||||
|
|
||||||
|
@DataCheck(require = true,message = "参数错误,薪资核算记录ID不能为空")
|
||||||
|
private Long salaryAcctRecordId;
|
||||||
|
|
||||||
|
@DataCheck(require = true,message = "参数错误,薪资项目ID不能为空")
|
||||||
|
private String salaryItemStrIds;
|
||||||
|
|
||||||
|
private List<Long> salaryItemIds;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -19,6 +19,7 @@
|
||||||
<result column="add_up_illness_medical" property="addUpIllnessMedical"/>
|
<result column="add_up_illness_medical" property="addUpIllnessMedical"/>
|
||||||
<result column="add_up_tax_savings" property="addUpTaxSavings"/>
|
<result column="add_up_tax_savings" property="addUpTaxSavings"/>
|
||||||
<result column="add_up_infant_care" property="addUpInfantCare"/>
|
<result column="add_up_infant_care" property="addUpInfantCare"/>
|
||||||
|
<result column="add_up_private_pension" property="addUpPrivatePension"/>
|
||||||
<result column="create_time" property="createTime"/>
|
<result column="create_time" property="createTime"/>
|
||||||
<result column="creator" property="creator"/>
|
<result column="creator" property="creator"/>
|
||||||
<result column="delete_type" property="deleteType"/>
|
<result column="delete_type" property="deleteType"/>
|
||||||
|
|
@ -62,6 +63,7 @@
|
||||||
, t.add_up_illness_medical
|
, t.add_up_illness_medical
|
||||||
, t.add_up_tax_savings
|
, t.add_up_tax_savings
|
||||||
, t.add_up_infant_care
|
, t.add_up_infant_care
|
||||||
|
, t.add_up_private_pension
|
||||||
</sql>
|
</sql>
|
||||||
|
|
||||||
<!--批量删除-->
|
<!--批量删除-->
|
||||||
|
|
@ -118,6 +120,7 @@
|
||||||
t1.add_up_support_elderly,
|
t1.add_up_support_elderly,
|
||||||
t1.add_up_illness_medical,
|
t1.add_up_illness_medical,
|
||||||
t1.add_up_infant_care,
|
t1.add_up_infant_care,
|
||||||
|
t1.add_up_private_pension,
|
||||||
t1.add_up_enterprise_and_other,
|
t1.add_up_enterprise_and_other,
|
||||||
t1.add_up_other_deduction,
|
t1.add_up_other_deduction,
|
||||||
t1.add_up_tax_exempt_income,
|
t1.add_up_tax_exempt_income,
|
||||||
|
|
@ -434,7 +437,8 @@
|
||||||
tenant_key,
|
tenant_key,
|
||||||
add_up_tax_savings,
|
add_up_tax_savings,
|
||||||
add_up_illness_medical,
|
add_up_illness_medical,
|
||||||
add_up_infant_care
|
add_up_infant_care,
|
||||||
|
add_up_private_pension
|
||||||
)
|
)
|
||||||
VALUES
|
VALUES
|
||||||
<foreach collection="collection" item="item" separator=",">
|
<foreach collection="collection" item="item" separator=",">
|
||||||
|
|
@ -463,7 +467,8 @@
|
||||||
#{item.tenantKey},
|
#{item.tenantKey},
|
||||||
#{item.addUpTaxSavings},
|
#{item.addUpTaxSavings},
|
||||||
#{item.addUpIllnessMedical},
|
#{item.addUpIllnessMedical},
|
||||||
#{item.addUpInfantCare}
|
#{item.addUpInfantCare},
|
||||||
|
#{item.addUpPrivatePension}
|
||||||
)
|
)
|
||||||
</foreach>
|
</foreach>
|
||||||
</insert>
|
</insert>
|
||||||
|
|
@ -493,7 +498,8 @@
|
||||||
tenant_key,
|
tenant_key,
|
||||||
add_up_tax_savings,
|
add_up_tax_savings,
|
||||||
add_up_illness_medical,
|
add_up_illness_medical,
|
||||||
add_up_infant_care
|
add_up_infant_care,
|
||||||
|
add_up_private_pension
|
||||||
)
|
)
|
||||||
|
|
||||||
<foreach collection="collection" item="item" separator="union all">
|
<foreach collection="collection" item="item" separator="union all">
|
||||||
|
|
@ -522,7 +528,8 @@
|
||||||
#{item.tenantKey,jdbcType=VARCHAR},
|
#{item.tenantKey,jdbcType=VARCHAR},
|
||||||
#{item.addUpTaxSavings,jdbcType=VARCHAR},
|
#{item.addUpTaxSavings,jdbcType=VARCHAR},
|
||||||
#{item.addUpIllnessMedical,jdbcType=VARCHAR},
|
#{item.addUpIllnessMedical,jdbcType=VARCHAR},
|
||||||
#{item.addUpInfantCare,jdbcType=VARCHAR}
|
#{item.addUpInfantCare,jdbcType=VARCHAR},
|
||||||
|
#{item.addUpPrivatePension,jdbcType=VARCHAR}
|
||||||
from dual
|
from dual
|
||||||
</foreach>
|
</foreach>
|
||||||
</insert>
|
</insert>
|
||||||
|
|
@ -553,7 +560,8 @@
|
||||||
tenant_key,
|
tenant_key,
|
||||||
add_up_tax_savings,
|
add_up_tax_savings,
|
||||||
add_up_illness_medical,
|
add_up_illness_medical,
|
||||||
add_up_infant_care
|
add_up_infant_care,
|
||||||
|
add_up_private_pension
|
||||||
)
|
)
|
||||||
VALUES
|
VALUES
|
||||||
(
|
(
|
||||||
|
|
@ -581,7 +589,8 @@
|
||||||
#{item.tenantKey},
|
#{item.tenantKey},
|
||||||
#{item.addUpTaxSavings},
|
#{item.addUpTaxSavings},
|
||||||
#{item.addUpIllnessMedical},
|
#{item.addUpIllnessMedical},
|
||||||
#{item.addUpInfantCare}
|
#{item.addUpInfantCare},
|
||||||
|
#{item.addUpPrivatePension}
|
||||||
)
|
)
|
||||||
</foreach>
|
</foreach>
|
||||||
</insert>
|
</insert>
|
||||||
|
|
@ -708,6 +717,13 @@
|
||||||
</if>
|
</if>
|
||||||
</foreach>
|
</foreach>
|
||||||
</trim>
|
</trim>
|
||||||
|
<trim prefix="add_up_private_pension =case" suffix="end,">
|
||||||
|
<foreach collection="collection" item="item" index="index">
|
||||||
|
<if test="item.addUpPrivatePension!=null">
|
||||||
|
when id=#{item.id} then #{item.addUpPrivatePension}
|
||||||
|
</if>
|
||||||
|
</foreach>
|
||||||
|
</trim>
|
||||||
</trim>
|
</trim>
|
||||||
where
|
where
|
||||||
id in
|
id in
|
||||||
|
|
|
||||||
|
|
@ -172,9 +172,12 @@
|
||||||
c.id as jobtitleId,
|
c.id as jobtitleId,
|
||||||
e.companystartdate as companystartdate,
|
e.companystartdate as companystartdate,
|
||||||
e.mobile as mobile,
|
e.mobile as mobile,
|
||||||
e.enddate as dismissdate
|
e.enddate as dismissdate,
|
||||||
|
sc.SUBCOMPANYNAME as subcompanyName,
|
||||||
|
sc.id as subcompanyid
|
||||||
from hrmresource e
|
from hrmresource e
|
||||||
left join hrmdepartment d on e.departmentid = d.id
|
left join hrmdepartment d on e.departmentid = d.id
|
||||||
|
left join HrmSubCompany sc on e.SUBCOMPANYID1=sc.id
|
||||||
left join hrmjobtitles c on e.jobtitle = c.id
|
left join hrmjobtitles c on e.jobtitle = c.id
|
||||||
where e.status not in (7)
|
where e.status not in (7)
|
||||||
and (e.accounttype is null or e.accounttype = 0)
|
and (e.accounttype is null or e.accounttype = 0)
|
||||||
|
|
|
||||||
|
|
@ -15,6 +15,7 @@
|
||||||
<result column="creator" property="creator"/>
|
<result column="creator" property="creator"/>
|
||||||
<result column="delete_type" property="deleteType"/>
|
<result column="delete_type" property="deleteType"/>
|
||||||
<result column="tenant_key" property="tenantKey"/>
|
<result column="tenant_key" property="tenantKey"/>
|
||||||
|
<result column="private_pension" property="privatePension"/>
|
||||||
</resultMap>
|
</resultMap>
|
||||||
|
|
||||||
<!-- 表字段 -->
|
<!-- 表字段 -->
|
||||||
|
|
@ -34,6 +35,7 @@
|
||||||
, t.creator
|
, t.creator
|
||||||
, t.delete_type
|
, t.delete_type
|
||||||
, t.tenant_key
|
, t.tenant_key
|
||||||
|
, t.private_pension
|
||||||
</sql>
|
</sql>
|
||||||
|
|
||||||
<!--批量删除-->
|
<!--批量删除-->
|
||||||
|
|
@ -77,7 +79,8 @@
|
||||||
t1.business_healthy_insurance,
|
t1.business_healthy_insurance,
|
||||||
t1.tax_delay_endowment_insurance,
|
t1.tax_delay_endowment_insurance,
|
||||||
t1.other_deduction,
|
t1.other_deduction,
|
||||||
t1.deduction_allowed_donation
|
t1.deduction_allowed_donation,
|
||||||
|
t1.private_pension
|
||||||
</sql>
|
</sql>
|
||||||
|
|
||||||
<sql id="paramSql">
|
<sql id="paramSql">
|
||||||
|
|
@ -332,6 +335,7 @@
|
||||||
tax_delay_endowment_insurance,
|
tax_delay_endowment_insurance,
|
||||||
other_deduction,
|
other_deduction,
|
||||||
deduction_allowed_donation,
|
deduction_allowed_donation,
|
||||||
|
private_pension,
|
||||||
create_time,
|
create_time,
|
||||||
update_time,
|
update_time,
|
||||||
creator,
|
creator,
|
||||||
|
|
@ -347,6 +351,7 @@
|
||||||
#{item.taxDelayEndowmentInsurance},
|
#{item.taxDelayEndowmentInsurance},
|
||||||
#{item.otherDeduction},
|
#{item.otherDeduction},
|
||||||
#{item.deductionAllowedDonation},
|
#{item.deductionAllowedDonation},
|
||||||
|
#{item.privatePension},
|
||||||
#{item.createTime},
|
#{item.createTime},
|
||||||
#{item.updateTime},
|
#{item.updateTime},
|
||||||
#{item.creator},
|
#{item.creator},
|
||||||
|
|
@ -363,6 +368,7 @@
|
||||||
tax_delay_endowment_insurance,
|
tax_delay_endowment_insurance,
|
||||||
other_deduction,
|
other_deduction,
|
||||||
deduction_allowed_donation,
|
deduction_allowed_donation,
|
||||||
|
private_pension,
|
||||||
create_time,
|
create_time,
|
||||||
update_time,
|
update_time,
|
||||||
creator,
|
creator,
|
||||||
|
|
@ -378,6 +384,7 @@
|
||||||
#{item.taxDelayEndowmentInsurance,jdbcType=VARCHAR},
|
#{item.taxDelayEndowmentInsurance,jdbcType=VARCHAR},
|
||||||
#{item.otherDeduction,jdbcType=VARCHAR},
|
#{item.otherDeduction,jdbcType=VARCHAR},
|
||||||
#{item.deductionAllowedDonation,jdbcType=VARCHAR},
|
#{item.deductionAllowedDonation,jdbcType=VARCHAR},
|
||||||
|
#{item.privatePension,jdbcType=VARCHAR},
|
||||||
#{item.createTime,jdbcType=DATE},
|
#{item.createTime,jdbcType=DATE},
|
||||||
#{item.updateTime,jdbcType=DATE},
|
#{item.updateTime,jdbcType=DATE},
|
||||||
#{item.creator,jdbcType=DOUBLE},
|
#{item.creator,jdbcType=DOUBLE},
|
||||||
|
|
@ -395,6 +402,7 @@
|
||||||
tax_delay_endowment_insurance,
|
tax_delay_endowment_insurance,
|
||||||
other_deduction,
|
other_deduction,
|
||||||
deduction_allowed_donation,
|
deduction_allowed_donation,
|
||||||
|
private_pension,
|
||||||
create_time,
|
create_time,
|
||||||
update_time,
|
update_time,
|
||||||
creator,
|
creator,
|
||||||
|
|
@ -409,6 +417,7 @@
|
||||||
#{item.taxDelayEndowmentInsurance},
|
#{item.taxDelayEndowmentInsurance},
|
||||||
#{item.otherDeduction},
|
#{item.otherDeduction},
|
||||||
#{item.deductionAllowedDonation},
|
#{item.deductionAllowedDonation},
|
||||||
|
#{item.privatePension},
|
||||||
#{item.createTime},
|
#{item.createTime},
|
||||||
#{item.updateTime},
|
#{item.updateTime},
|
||||||
#{item.creator},
|
#{item.creator},
|
||||||
|
|
@ -448,6 +457,13 @@
|
||||||
</if>
|
</if>
|
||||||
</foreach>
|
</foreach>
|
||||||
</trim>
|
</trim>
|
||||||
|
<trim prefix="private_pension =case" suffix="end,">
|
||||||
|
<foreach collection="collection" item="item" index="index">
|
||||||
|
<if test="item.privatePension!=null">
|
||||||
|
when id=#{item.id} then #{item.privatePension}
|
||||||
|
</if>
|
||||||
|
</foreach>
|
||||||
|
</trim>
|
||||||
</trim>
|
</trim>
|
||||||
where
|
where
|
||||||
id in
|
id in
|
||||||
|
|
|
||||||
|
|
@ -96,7 +96,7 @@ public interface SalaryAcctResultMapper {
|
||||||
void deleteBySalaryAcctEmpIds(@Param("salaryAcctEmpIds") Collection<Long> salaryAcctEmpIds);
|
void deleteBySalaryAcctEmpIds(@Param("salaryAcctEmpIds") Collection<Long> salaryAcctEmpIds);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 根据薪资核算id、薪资项目id删除薪资核算结果
|
* 根据薪资核算人员id、薪资项目id删除薪资核算结果
|
||||||
*
|
*
|
||||||
* @param salaryAcctEmpIds
|
* @param salaryAcctEmpIds
|
||||||
* @param salaryItemIds
|
* @param salaryItemIds
|
||||||
|
|
@ -104,6 +104,14 @@ public interface SalaryAcctResultMapper {
|
||||||
void deleteByAcctEmpIdsAndSalaryItemIds(@Param("salaryAcctEmpIds") Collection<Long> salaryAcctEmpIds,
|
void deleteByAcctEmpIdsAndSalaryItemIds(@Param("salaryAcctEmpIds") Collection<Long> salaryAcctEmpIds,
|
||||||
@Param("salaryItemIds") Collection<Long> salaryItemIds);
|
@Param("salaryItemIds") Collection<Long> salaryItemIds);
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* @param salaryAcctRecordId
|
||||||
|
* @param salaryItemIds
|
||||||
|
*/
|
||||||
|
void deleteBySalaryAcctRecordIdAndSalaryItemIds(@Param("salaryAcctRecordId") Long salaryAcctRecordId,
|
||||||
|
@Param("salaryItemIds") Collection<Long> salaryItemIds);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 根据薪资核算id删除薪资核算结果
|
* 根据薪资核算id删除薪资核算结果
|
||||||
*
|
*
|
||||||
|
|
|
||||||
|
|
@ -535,6 +535,16 @@
|
||||||
</foreach>
|
</foreach>
|
||||||
</delete>
|
</delete>
|
||||||
|
|
||||||
|
<delete id="deleteBySalaryAcctRecordIdAndSalaryItemIds">
|
||||||
|
DELETE FROM hrsa_salary_acct_result
|
||||||
|
WHERE delete_type = 0
|
||||||
|
AND salary_acct_record_id =#{salaryAcctRecordId}
|
||||||
|
AND salary_item_id IN
|
||||||
|
<foreach collection="salaryItemIds" open="(" item="salaryItemId" separator="," close=")">
|
||||||
|
#{salaryItemId}
|
||||||
|
</foreach>
|
||||||
|
</delete>
|
||||||
|
|
||||||
<delete id="deleteByIds">
|
<delete id="deleteByIds">
|
||||||
DELETE FROM hrsa_salary_acct_result
|
DELETE FROM hrsa_salary_acct_result
|
||||||
WHERE delete_type = 0
|
WHERE delete_type = 0
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,6 @@
|
||||||
package com.engine.salary.mapper.taxdeclaration;
|
package com.engine.salary.mapper.taxdeclaration;
|
||||||
|
|
||||||
import com.engine.salary.entity.taxdeclaration.po.TaxDeclarationPO;
|
import com.engine.salary.entity.taxdeclaration.po.TaxDeclarationPO;
|
||||||
import org.apache.ibatis.annotations.Mapper;
|
|
||||||
import org.apache.ibatis.annotations.Param;
|
import org.apache.ibatis.annotations.Param;
|
||||||
|
|
||||||
import java.util.Collection;
|
import java.util.Collection;
|
||||||
|
|
@ -41,4 +40,5 @@ public interface TaxDeclarationMapper {
|
||||||
*/
|
*/
|
||||||
void deleteByIds(@Param("ids") Collection<Long> ids);
|
void deleteByIds(@Param("ids") Collection<Long> ids);
|
||||||
|
|
||||||
|
int deleteByIdZj(Long id);
|
||||||
}
|
}
|
||||||
|
|
@ -32,6 +32,14 @@
|
||||||
,t.income_category
|
,t.income_category
|
||||||
</sql>
|
</sql>
|
||||||
|
|
||||||
|
<update id="deleteByIdZj">
|
||||||
|
UPDATE hrsa_tax_declaration
|
||||||
|
SET delete_type = 3
|
||||||
|
WHERE delete_type = 0
|
||||||
|
AND id = #{id}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
|
||||||
<!-- 根据主键获取单条记录 -->
|
<!-- 根据主键获取单条记录 -->
|
||||||
<select id="getById" resultMap="BaseResultMap" parameterType="Long">
|
<select id="getById" resultMap="BaseResultMap" parameterType="Long">
|
||||||
SELECT
|
SELECT
|
||||||
|
|
|
||||||
|
|
@ -2,6 +2,7 @@ package com.engine.salary.service;
|
||||||
|
|
||||||
|
|
||||||
import com.engine.salary.entity.salaryformula.po.FormulaVar;
|
import com.engine.salary.entity.salaryformula.po.FormulaVar;
|
||||||
|
import com.engine.salary.enums.salaryformula.ReferenceTypeEnum;
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
|
@ -15,6 +16,8 @@ public interface RemoteExcelService {
|
||||||
|
|
||||||
List<Map<String,Object>> fieldGroupList(Map<String, Object> extendParam);
|
List<Map<String,Object>> fieldGroupList(Map<String, Object> extendParam);
|
||||||
|
|
||||||
|
Map<String,List<FormulaVar>> allFieldList(ReferenceTypeEnum referenceTypeEnum);
|
||||||
|
|
||||||
|
|
||||||
// ExcelPage<FormulaDataSource> dataSourceList(String categoryId, ExcelPage<FormulaDataSource> page, Map<String, Object> extendParam, DataCollectionEmployee employee);
|
// ExcelPage<FormulaDataSource> dataSourceList(String categoryId, ExcelPage<FormulaDataSource> page, Map<String, Object> extendParam, DataCollectionEmployee employee);
|
||||||
//
|
//
|
||||||
|
|
|
||||||
|
|
@ -244,7 +244,7 @@ public interface SIAccountService {
|
||||||
/**
|
/**
|
||||||
* 导出“福利核算-线下对比导入模板”
|
* 导出“福利核算-线下对比导入模板”
|
||||||
*/
|
*/
|
||||||
XSSFWorkbook exportComparisonWelfareTemplate(InsuranceAcctDetailImportTemplateParam param);
|
XSSFWorkbook exportComparisonWelfareTemplate(InsuranceAccountDetailParam param);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 将通过“福利核算-线下对比导入”模板导入的数据更新到hrsa_excel_bill_detail表中
|
* 将通过“福利核算-线下对比导入”模板导入的数据更新到hrsa_excel_bill_detail表中
|
||||||
|
|
|
||||||
|
|
@ -275,7 +275,7 @@ public class AddUpSituationServiceImpl extends Service implements AddUpSituation
|
||||||
// excel标题
|
// excel标题
|
||||||
final List<String> title = Arrays.asList("姓名", "个税扣缴义务人", "部门", "手机号", "工号", "证件号码", "入职日期", "累计收入额", "累计减除费用",
|
final List<String> title = Arrays.asList("姓名", "个税扣缴义务人", "部门", "手机号", "工号", "证件号码", "入职日期", "累计收入额", "累计减除费用",
|
||||||
"累计社保个人合计", "累计公积金个人合计", "累计子女教育", "累计继续教育", "累计住房贷款利息", "累计住房租金", "累计赡养老人",
|
"累计社保个人合计", "累计公积金个人合计", "累计子女教育", "累计继续教育", "累计住房贷款利息", "累计住房租金", "累计赡养老人",
|
||||||
"累计大病医疗", "累计企业(职业)年金及其他福利", "累计其他扣除", "累计免税收入", "累计准予扣除的捐赠额", "累计减免税额", "累计已预扣预缴税额", "累计婴幼儿照护");
|
"累计大病医疗", "累计企业(职业)年金及其他福利", "累计其他扣除", "累计免税收入", "累计准予扣除的捐赠额", "累计减免税额", "累计已预扣预缴税额", "累计婴幼儿照护","累计个人养老金");
|
||||||
|
|
||||||
//排序配置
|
//排序配置
|
||||||
OrderRuleVO orderRule = getSalarySysConfService(user).orderRule();
|
OrderRuleVO orderRule = getSalarySysConfService(user).orderRule();
|
||||||
|
|
@ -318,6 +318,7 @@ public class AddUpSituationServiceImpl extends Service implements AddUpSituation
|
||||||
cellList.add(String.valueOf(dto.getAddUpTaxSavings()));
|
cellList.add(String.valueOf(dto.getAddUpTaxSavings()));
|
||||||
cellList.add(String.valueOf(dto.getAddUpAdvanceTax()));
|
cellList.add(String.valueOf(dto.getAddUpAdvanceTax()));
|
||||||
cellList.add(String.valueOf(dto.getAddUpInfantCare()));
|
cellList.add(String.valueOf(dto.getAddUpInfantCare()));
|
||||||
|
cellList.add(String.valueOf(dto.getAddUpPrivatePension()));
|
||||||
return cellList;
|
return cellList;
|
||||||
}).collect(Collectors.toList()))
|
}).collect(Collectors.toList()))
|
||||||
.orElse(Collections.emptyList());
|
.orElse(Collections.emptyList());
|
||||||
|
|
@ -340,7 +341,7 @@ public class AddUpSituationServiceImpl extends Service implements AddUpSituation
|
||||||
//excel标题
|
//excel标题
|
||||||
List<String> title = Arrays.asList("姓名", "税款所属期", "个税扣缴义务人", "部门", "手机号", "工号", "累计收入额", "累计减除费用", "累计社保个人合计",
|
List<String> title = Arrays.asList("姓名", "税款所属期", "个税扣缴义务人", "部门", "手机号", "工号", "累计收入额", "累计减除费用", "累计社保个人合计",
|
||||||
"累计公积金个人合计", "累计子女教育", "累计继续教育", "累计住房贷款利息", "累计住房租金", "累计赡养老人", "累计大病医疗", "累计企业(职业)年金及其他福利",
|
"累计公积金个人合计", "累计子女教育", "累计继续教育", "累计住房贷款利息", "累计住房租金", "累计赡养老人", "累计大病医疗", "累计企业(职业)年金及其他福利",
|
||||||
"累计其他扣除", "累计免税收入", "累计准予扣除的捐赠额", "累计减免税额", "累计已预扣预缴税额", "累计婴幼儿照护");
|
"累计其他扣除", "累计免税收入", "累计准予扣除的捐赠额", "累计减免税额", "累计已预扣预缴税额", "累计婴幼儿照护","累计个人养老金");
|
||||||
|
|
||||||
SimpleDateFormat formatter = new SimpleDateFormat("yyyy-MM");
|
SimpleDateFormat formatter = new SimpleDateFormat("yyyy-MM");
|
||||||
//查询详细信息
|
//查询详细信息
|
||||||
|
|
@ -381,6 +382,7 @@ public class AddUpSituationServiceImpl extends Service implements AddUpSituation
|
||||||
cellList.add(Util.null2String(dto.getAddUpTaxSavings()));
|
cellList.add(Util.null2String(dto.getAddUpTaxSavings()));
|
||||||
cellList.add(Util.null2String(dto.getAddUpAdvanceTax()));
|
cellList.add(Util.null2String(dto.getAddUpAdvanceTax()));
|
||||||
cellList.add(Util.null2String(dto.getAddUpInfantCare()));
|
cellList.add(Util.null2String(dto.getAddUpInfantCare()));
|
||||||
|
cellList.add(Util.null2String(dto.getAddUpPrivatePension()));
|
||||||
return cellList;
|
return cellList;
|
||||||
}).collect(Collectors.toList()))
|
}).collect(Collectors.toList()))
|
||||||
.orElse(Collections.emptyList());
|
.orElse(Collections.emptyList());
|
||||||
|
|
@ -457,7 +459,8 @@ public class AddUpSituationServiceImpl extends Service implements AddUpSituation
|
||||||
SalaryI18nUtil.getI18nLabel(86703, "累计准予扣除的捐赠额"),
|
SalaryI18nUtil.getI18nLabel(86703, "累计准予扣除的捐赠额"),
|
||||||
SalaryI18nUtil.getI18nLabel(105478, "累计减免税额"),
|
SalaryI18nUtil.getI18nLabel(105478, "累计减免税额"),
|
||||||
SalaryI18nUtil.getI18nLabel(86702, "累计已预扣预缴税额"),
|
SalaryI18nUtil.getI18nLabel(86702, "累计已预扣预缴税额"),
|
||||||
SalaryI18nUtil.getI18nLabel(86702, "累计婴幼儿照护")
|
SalaryI18nUtil.getI18nLabel(86702, "累计婴幼儿照护"),
|
||||||
|
SalaryI18nUtil.getI18nLabel(86702, "累计个人养老金")
|
||||||
};
|
};
|
||||||
// 2.表头
|
// 2.表头
|
||||||
List<Object> headerList = Arrays.asList(header);
|
List<Object> headerList = Arrays.asList(header);
|
||||||
|
|
@ -535,6 +538,7 @@ public class AddUpSituationServiceImpl extends Service implements AddUpSituation
|
||||||
excelComments.add(new ExcelComment(21, 0, 26, 2, SalaryI18nUtil.getI18nLabel(100344, "输入数字")));
|
excelComments.add(new ExcelComment(21, 0, 26, 2, SalaryI18nUtil.getI18nLabel(100344, "输入数字")));
|
||||||
excelComments.add(new ExcelComment(22, 0, 27, 2, SalaryI18nUtil.getI18nLabel(100344, "输入数字")));
|
excelComments.add(new ExcelComment(22, 0, 27, 2, SalaryI18nUtil.getI18nLabel(100344, "输入数字")));
|
||||||
excelComments.add(new ExcelComment(23, 0, 28, 2, SalaryI18nUtil.getI18nLabel(100344, "输入数字")));
|
excelComments.add(new ExcelComment(23, 0, 28, 2, SalaryI18nUtil.getI18nLabel(100344, "输入数字")));
|
||||||
|
excelComments.add(new ExcelComment(24, 0, 29, 2, SalaryI18nUtil.getI18nLabel(100344, "输入数字")));
|
||||||
|
|
||||||
return ExcelUtil.genWorkbookV2(rows, sheetName, excelComments);
|
return ExcelUtil.genWorkbookV2(rows, sheetName, excelComments);
|
||||||
}
|
}
|
||||||
|
|
@ -569,7 +573,7 @@ public class AddUpSituationServiceImpl extends Service implements AddUpSituation
|
||||||
InputStream fileInputStream = null;
|
InputStream fileInputStream = null;
|
||||||
try {
|
try {
|
||||||
fileInputStream = ImageFileManager.getInputStreamById(Integer.valueOf(imageId));
|
fileInputStream = ImageFileManager.getInputStreamById(Integer.valueOf(imageId));
|
||||||
List<AddUpSituationDTO> excelDates = ExcelParseHelper.parse2Map(fileInputStream, AddUpSituationDTO.class, 0, 1, 24, "template.xlsx");
|
List<AddUpSituationDTO> excelDates = ExcelParseHelper.parse2Map(fileInputStream, AddUpSituationDTO.class, 0, 1, 25, "template.xlsx");
|
||||||
apidatas.put("preview", excelDates);
|
apidatas.put("preview", excelDates);
|
||||||
} finally {
|
} finally {
|
||||||
IOUtils.closeQuietly(fileInputStream);
|
IOUtils.closeQuietly(fileInputStream);
|
||||||
|
|
@ -624,7 +628,7 @@ public class AddUpSituationServiceImpl extends Service implements AddUpSituation
|
||||||
try {
|
try {
|
||||||
fileInputStream = ImageFileManager.getInputStreamById(Integer.parseInt(imageId));
|
fileInputStream = ImageFileManager.getInputStreamById(Integer.parseInt(imageId));
|
||||||
|
|
||||||
List<AddUpSituationDTO> excelDates = ExcelParseHelper.parse2Map(fileInputStream, AddUpSituationDTO.class, 0, 1, 24, "template.xlsx");
|
List<AddUpSituationDTO> excelDates = ExcelParseHelper.parse2Map(fileInputStream, AddUpSituationDTO.class, 0, 1, 25, "template.xlsx");
|
||||||
|
|
||||||
int total = excelDates.size();
|
int total = excelDates.size();
|
||||||
int index = 0;
|
int index = 0;
|
||||||
|
|
@ -801,6 +805,7 @@ public class AddUpSituationServiceImpl extends Service implements AddUpSituation
|
||||||
po.setAddUpIllnessMedical(dto.getAddUpIllnessMedical());
|
po.setAddUpIllnessMedical(dto.getAddUpIllnessMedical());
|
||||||
po.setAddUpTaxSavings(dto.getAddUpTaxSavings());
|
po.setAddUpTaxSavings(dto.getAddUpTaxSavings());
|
||||||
po.setAddUpInfantCare(dto.getAddUpInfantCare());
|
po.setAddUpInfantCare(dto.getAddUpInfantCare());
|
||||||
|
po.setAddUpPrivatePension(dto.getAddUpPrivatePension());
|
||||||
|
|
||||||
if (errorSum == 0) {
|
if (errorSum == 0) {
|
||||||
successCount += 1;
|
successCount += 1;
|
||||||
|
|
@ -893,7 +898,9 @@ public class AddUpSituationServiceImpl extends Service implements AddUpSituation
|
||||||
.addUpEnterpriseAndOther(addUpSituationParam.getAddUpEnterpriseAndOther()).addUpOtherDeduction(addUpSituationParam.getAddUpOtherDeduction())
|
.addUpEnterpriseAndOther(addUpSituationParam.getAddUpEnterpriseAndOther()).addUpOtherDeduction(addUpSituationParam.getAddUpOtherDeduction())
|
||||||
.addUpTaxExemptIncome(addUpSituationParam.getAddUpTaxExemptIncome()).addUpAllowedDonation(addUpSituationParam.getAddUpAllowedDonation())
|
.addUpTaxExemptIncome(addUpSituationParam.getAddUpTaxExemptIncome()).addUpAllowedDonation(addUpSituationParam.getAddUpAllowedDonation())
|
||||||
.addUpTaxSavings(addUpSituationParam.getAddUpTaxSavings()).addUpAdvanceTax(addUpSituationParam.getAddUpAdvanceTax())
|
.addUpTaxSavings(addUpSituationParam.getAddUpTaxSavings()).addUpAdvanceTax(addUpSituationParam.getAddUpAdvanceTax())
|
||||||
.addUpInfantCare(addUpSituationParam.getAddUpInfantCare()).build();
|
.addUpInfantCare(addUpSituationParam.getAddUpInfantCare())
|
||||||
|
.addUpPrivatePension(addUpSituationParam.getAddUpPrivatePension())
|
||||||
|
.build();
|
||||||
updateList.add(build);
|
updateList.add(build);
|
||||||
biz.batchUpdate(updateList);
|
biz.batchUpdate(updateList);
|
||||||
}
|
}
|
||||||
|
|
@ -1029,6 +1036,7 @@ public class AddUpSituationServiceImpl extends Service implements AddUpSituation
|
||||||
po.setAddUpIllnessMedical(addUpSituationParam.getAddUpIllnessMedical());
|
po.setAddUpIllnessMedical(addUpSituationParam.getAddUpIllnessMedical());
|
||||||
po.setAddUpTaxSavings(addUpSituationParam.getAddUpTaxSavings());
|
po.setAddUpTaxSavings(addUpSituationParam.getAddUpTaxSavings());
|
||||||
po.setAddUpInfantCare(addUpSituationParam.getAddUpInfantCare());
|
po.setAddUpInfantCare(addUpSituationParam.getAddUpInfantCare());
|
||||||
|
po.setAddUpPrivatePension(addUpSituationParam.getAddUpPrivatePension());
|
||||||
insertList.add(po);
|
insertList.add(po);
|
||||||
|
|
||||||
//入库
|
//入库
|
||||||
|
|
|
||||||
|
|
@ -99,8 +99,8 @@ public class OtherDeductionServiceImpl extends Service implements OtherDeduction
|
||||||
//申报月份
|
//申报月份
|
||||||
List<String> declareMonth = queryParam.getDeclareMonth();
|
List<String> declareMonth = queryParam.getDeclareMonth();
|
||||||
if (CollectionUtils.isNotEmpty(declareMonth)) {
|
if (CollectionUtils.isNotEmpty(declareMonth)) {
|
||||||
queryParam.setDeclareMonth(declareMonth.stream().map(e -> e + "-01 00:00:00").collect(Collectors.toList()));
|
queryParam.setDeclareMonth(declareMonth.stream().filter(StringUtils::isNotBlank).map(e -> e + "-01 00:00:00").collect(Collectors.toList()));
|
||||||
queryParam.setDeclareMonthDate(declareMonth.stream().map(e -> e + "-01 00:00:00").map(SalaryDateUtil::dateStrToLocalTime).collect(Collectors.toList()));
|
queryParam.setDeclareMonthDate(declareMonth.stream().filter(StringUtils::isNotBlank).map(e -> e + "-01 00:00:00").map(SalaryDateUtil::dateStrToLocalTime).collect(Collectors.toList()));
|
||||||
}
|
}
|
||||||
|
|
||||||
//排序配置
|
//排序配置
|
||||||
|
|
@ -162,7 +162,7 @@ public class OtherDeductionServiceImpl extends Service implements OtherDeduction
|
||||||
InputStream fileInputStream = null;
|
InputStream fileInputStream = null;
|
||||||
try {
|
try {
|
||||||
fileInputStream = ImageFileManager.getInputStreamById(Integer.parseInt(imageId));
|
fileInputStream = ImageFileManager.getInputStreamById(Integer.parseInt(imageId));
|
||||||
List<OtherDeductionListDTO> OtherDeductions = ExcelParseHelper.parse2Map(fileInputStream, OtherDeductionListDTO.class, 0, 1, 11, "OtherDeductionTemplate.xlsx");
|
List<OtherDeductionListDTO> OtherDeductions = ExcelParseHelper.parse2Map(fileInputStream, OtherDeductionListDTO.class, 0, 1, 12, "OtherDeductionTemplate.xlsx");
|
||||||
apidatas.put("preview", OtherDeductions);
|
apidatas.put("preview", OtherDeductions);
|
||||||
} finally {
|
} finally {
|
||||||
IOUtils.closeQuietly(fileInputStream);
|
IOUtils.closeQuietly(fileInputStream);
|
||||||
|
|
@ -198,7 +198,7 @@ public class OtherDeductionServiceImpl extends Service implements OtherDeduction
|
||||||
InputStream fileInputStream = null;
|
InputStream fileInputStream = null;
|
||||||
try {
|
try {
|
||||||
fileInputStream = ImageFileManager.getInputStreamById(Integer.parseInt(imageId));
|
fileInputStream = ImageFileManager.getInputStreamById(Integer.parseInt(imageId));
|
||||||
List<OtherDeductionListDTO> OtherDeductions = ExcelParseHelper.parse2Map(fileInputStream, OtherDeductionListDTO.class, 0, 1, 11, "OtherDeductionTemplate.xlsx");
|
List<OtherDeductionListDTO> OtherDeductions = ExcelParseHelper.parse2Map(fileInputStream, OtherDeductionListDTO.class, 0, 1, 12, "OtherDeductionTemplate.xlsx");
|
||||||
|
|
||||||
int total = OtherDeductions.size();
|
int total = OtherDeductions.size();
|
||||||
int index = 0;
|
int index = 0;
|
||||||
|
|
@ -330,19 +330,11 @@ public class OtherDeductionServiceImpl extends Service implements OtherDeduction
|
||||||
//准予扣除的捐赠额
|
//准予扣除的捐赠额
|
||||||
String deductionAllowedDonation = dto.getDeductionAllowedDonation();
|
String deductionAllowedDonation = dto.getDeductionAllowedDonation();
|
||||||
po.setDeductionAllowedDonation(deductionAllowedDonation);
|
po.setDeductionAllowedDonation(deductionAllowedDonation);
|
||||||
|
//个人养老金
|
||||||
|
String privatePension = dto.getPrivatePension();
|
||||||
|
po.setPrivatePension(privatePension);
|
||||||
|
|
||||||
|
|
||||||
//fixme 分权判断
|
|
||||||
// if (openDevolution) {
|
|
||||||
// OtherDeductionPO finalPoE = po;
|
|
||||||
// Optional<TaxAgentManageRangeEmployeeDTO.TaxAgentEmployee> optionalTaxAgentEmp = taxAgentEmployees.stream().filter(f -> f.getEmployeeId().equals(finalPoE.getEmployeeId())).findFirst();
|
|
||||||
// if (!optionalTaxAgentEmp.isPresent()) {
|
|
||||||
// Map<String, String> errorMessageMap = Maps.newHashMap();
|
|
||||||
// errorMessageMap.put("message", rowIndex + "该条数据不在个税扣缴义务人人员范围内,不可导入");
|
|
||||||
// errorData.add(errorMessageMap);
|
|
||||||
// errorSum += 1;
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// 判断是否有核算过
|
// 判断是否有核算过
|
||||||
if (CollectionUtils.isNotEmpty(salaryAcctEmployees)) {
|
if (CollectionUtils.isNotEmpty(salaryAcctEmployees)) {
|
||||||
OtherDeductionPO finalPo = po;
|
OtherDeductionPO finalPo = po;
|
||||||
|
|
@ -421,7 +413,7 @@ public class OtherDeductionServiceImpl extends Service implements OtherDeduction
|
||||||
private List<List<String>> getExcelRowList(OtherDeductionQueryParam param) {
|
private List<List<String>> getExcelRowList(OtherDeductionQueryParam param) {
|
||||||
long employeeId = user.getUID();
|
long employeeId = user.getUID();
|
||||||
//excel标题
|
//excel标题
|
||||||
List<String> title = Arrays.asList("姓名", "个税扣缴义务人", "部门", "手机号", "工号", "证件号码", "入职日期", "商业健康保险", "税延养老保险", "其他", "准予扣除的捐赠额");
|
List<String> title = Arrays.asList("姓名", "个税扣缴义务人", "部门", "手机号", "工号", "证件号码", "入职日期", "商业健康保险", "税延养老保险", "其他", "准予扣除的捐赠额", "个人养老金");
|
||||||
//排序配置
|
//排序配置
|
||||||
OrderRuleVO orderRule = getSalarySysConfService(user).orderRule();
|
OrderRuleVO orderRule = getSalarySysConfService(user).orderRule();
|
||||||
param.setOrderRule(orderRule);
|
param.setOrderRule(orderRule);
|
||||||
|
|
@ -460,6 +452,7 @@ public class OtherDeductionServiceImpl extends Service implements OtherDeduction
|
||||||
cellList.add(Util.null2String(dto.getTaxDelayEndowmentInsurance()));
|
cellList.add(Util.null2String(dto.getTaxDelayEndowmentInsurance()));
|
||||||
cellList.add(Util.null2String(dto.getOtherDeduction()));
|
cellList.add(Util.null2String(dto.getOtherDeduction()));
|
||||||
cellList.add(Util.null2String(dto.getDeductionAllowedDonation()));
|
cellList.add(Util.null2String(dto.getDeductionAllowedDonation()));
|
||||||
|
cellList.add(Util.null2String(dto.getPrivatePension()));
|
||||||
return cellList;
|
return cellList;
|
||||||
}).collect(Collectors.toList()))
|
}).collect(Collectors.toList()))
|
||||||
.orElse(Collections.emptyList());
|
.orElse(Collections.emptyList());
|
||||||
|
|
@ -523,7 +516,7 @@ public class OtherDeductionServiceImpl extends Service implements OtherDeduction
|
||||||
*/
|
*/
|
||||||
private List<List<String>> getExcelRowDetailList(OtherDeductionQueryParam param) {
|
private List<List<String>> getExcelRowDetailList(OtherDeductionQueryParam param) {
|
||||||
//excel标题
|
//excel标题
|
||||||
List<String> title = Arrays.asList("姓名", "申报月份", "个税扣缴义务人", "部门", "手机号", "工号", "商业健康保险", "税延养老保险", "其他", "准予扣除的捐赠额");
|
List<String> title = Arrays.asList("姓名", "申报月份", "个税扣缴义务人", "部门", "手机号", "工号", "商业健康保险", "税延养老保险", "其他", "准予扣除的捐赠额","个人养老金");
|
||||||
|
|
||||||
SimpleDateFormat formatter = new SimpleDateFormat("yyyy-MM");
|
SimpleDateFormat formatter = new SimpleDateFormat("yyyy-MM");
|
||||||
//查询详细信息
|
//查询详细信息
|
||||||
|
|
@ -543,6 +536,7 @@ public class OtherDeductionServiceImpl extends Service implements OtherDeduction
|
||||||
cellList.add(Util.null2String(dto.getTaxDelayEndowmentInsurance()));
|
cellList.add(Util.null2String(dto.getTaxDelayEndowmentInsurance()));
|
||||||
cellList.add(Util.null2String(dto.getOtherDeduction()));
|
cellList.add(Util.null2String(dto.getOtherDeduction()));
|
||||||
cellList.add(Util.null2String(dto.getDeductionAllowedDonation()));
|
cellList.add(Util.null2String(dto.getDeductionAllowedDonation()));
|
||||||
|
cellList.add(Util.null2String(dto.getPrivatePension()));
|
||||||
return cellList;
|
return cellList;
|
||||||
}).collect(Collectors.toList()))
|
}).collect(Collectors.toList()))
|
||||||
.orElse(Collections.emptyList());
|
.orElse(Collections.emptyList());
|
||||||
|
|
@ -591,7 +585,14 @@ public class OtherDeductionServiceImpl extends Service implements OtherDeduction
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
ArrayList<OtherDeductionPO> updateList = new ArrayList<>();
|
ArrayList<OtherDeductionPO> updateList = new ArrayList<>();
|
||||||
OtherDeductionPO build = OtherDeductionPO.builder().id(otherDeductionParam.getId()).businessHealthyInsurance(otherDeductionParam.getBusinessHealthyInsurance()).taxDelayEndowmentInsurance(otherDeductionParam.getTaxDelayEndowmentInsurance()).otherDeduction(otherDeductionParam.getOtherDeduction()).deductionAllowedDonation(otherDeductionParam.getDeductionAllowedDonation()).build();
|
OtherDeductionPO build = OtherDeductionPO.builder()
|
||||||
|
.id(otherDeductionParam.getId())
|
||||||
|
.businessHealthyInsurance(otherDeductionParam.getBusinessHealthyInsurance())
|
||||||
|
.taxDelayEndowmentInsurance(otherDeductionParam.getTaxDelayEndowmentInsurance())
|
||||||
|
.otherDeduction(otherDeductionParam.getOtherDeduction())
|
||||||
|
.deductionAllowedDonation(otherDeductionParam.getDeductionAllowedDonation())
|
||||||
|
.privatePension(otherDeductionParam.getPrivatePension())
|
||||||
|
.build();
|
||||||
updateList.add(build);
|
updateList.add(build);
|
||||||
OtherDeductionBiz.batchUpdate(updateList);
|
OtherDeductionBiz.batchUpdate(updateList);
|
||||||
}
|
}
|
||||||
|
|
@ -663,18 +664,10 @@ public class OtherDeductionServiceImpl extends Service implements OtherDeduction
|
||||||
//准予扣除的捐赠额
|
//准予扣除的捐赠额
|
||||||
String deductionAllowedDonation = otherDeductionParam.getDeductionAllowedDonation();
|
String deductionAllowedDonation = otherDeductionParam.getDeductionAllowedDonation();
|
||||||
po.setDeductionAllowedDonation(deductionAllowedDonation);
|
po.setDeductionAllowedDonation(deductionAllowedDonation);
|
||||||
|
//个人养老金
|
||||||
|
String privatePension = otherDeductionParam.getPrivatePension();
|
||||||
|
po.setPrivatePension(privatePension);
|
||||||
|
|
||||||
//fixme 分权判断
|
|
||||||
// if (openDevolution) {
|
|
||||||
// OtherDeductionPO finalPoE = po;
|
|
||||||
// Optional<TaxAgentManageRangeEmployeeDTO.TaxAgentEmployee> optionalTaxAgentEmp = taxAgentEmployees.stream().filter(f -> f.getEmployeeId().equals(finalPoE.getEmployeeId())).findFirst();
|
|
||||||
// if (!optionalTaxAgentEmp.isPresent()) {
|
|
||||||
// Map<String, String> errorMessageMap = Maps.newHashMap();
|
|
||||||
// errorMessageMap.put("message", rowIndex + "该条数据不在个税扣缴义务人人员范围内,不可导入");
|
|
||||||
// errorData.add(errorMessageMap);
|
|
||||||
// errorSum += 1;
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
|
|
||||||
// 判断是否有核算过
|
// 判断是否有核算过
|
||||||
if (CollectionUtils.isNotEmpty(salaryAcctEmployees)) {
|
if (CollectionUtils.isNotEmpty(salaryAcctEmployees)) {
|
||||||
|
|
|
||||||
|
|
@ -200,6 +200,47 @@ public class RemoteExcelServiceImpl extends Service implements RemoteExcelServic
|
||||||
}).collect(Collectors.toList());
|
}).collect(Collectors.toList());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public Map<String, List<FormulaVar>> allFieldList(ReferenceTypeEnum referenceTypeEnum) {
|
||||||
|
|
||||||
|
Map<String, List<FormulaVar>> result = new HashMap<>();
|
||||||
|
|
||||||
|
//sql
|
||||||
|
if (ReferenceTypeEnum.SQL.equals(referenceTypeEnum)) {
|
||||||
|
result.put(SalarySQLReferenceEnum.EMPLOYEE_INFO.getDefaultLabel(),
|
||||||
|
convert2FormulaVar(DataCollectionEmployee.class, SalarySQLReferenceEnum.EMPLOYEE_INFO.getValue() + ""));
|
||||||
|
result.put(SalarySQLReferenceEnum.SALARY_ACCT_EMPLOYEE.getDefaultLabel(),
|
||||||
|
convert2FormulaVar(SalaryAcctEmployeePO.class, SalarySQLReferenceEnum.SALARY_ACCT_EMPLOYEE.getValue() + ""));
|
||||||
|
result.put(SalarySQLReferenceEnum.SALARY_CYCLE.getDefaultLabel(),
|
||||||
|
convert2FormulaVar(SalarySobCycleDTO.class, SalarySQLReferenceEnum.SALARY_CYCLE.getValue() + ""));
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
// 如果是其他数据源
|
||||||
|
if (ReferenceTypeEnum.FORMULA.equals(referenceTypeEnum)) {
|
||||||
|
result.put(SalaryFormulaReferenceEnum.SALARY_ITEM.getDefaultLabel(),
|
||||||
|
salaryItem2FormulaVar(SalaryFormulaReferenceEnum.SALARY_ITEM, null));
|
||||||
|
result.put(SalaryFormulaReferenceEnum.ISSUED.getDefaultLabel(),
|
||||||
|
salaryItem2FormulaVar(SalaryFormulaReferenceEnum.ISSUED, null));
|
||||||
|
result.put(SalaryFormulaReferenceEnum.SALARY_ARCHIVES.getDefaultLabel(),
|
||||||
|
salaryArchives2FormulaVar(SalaryFormulaReferenceEnum.SALARY_ARCHIVES, null));
|
||||||
|
result.put(SalaryFormulaReferenceEnum.ADD_UP_SITUATION.getDefaultLabel(),
|
||||||
|
convert2FormulaVar(AddUpSituation.class, SalaryFormulaReferenceEnum.ADD_UP_SITUATION.getValue() + ""));
|
||||||
|
result.put(SalaryFormulaReferenceEnum.ADD_UP_DEDUCTIONS.getDefaultLabel(),
|
||||||
|
convert2FormulaVar(AddUpDeduction.class, SalaryFormulaReferenceEnum.ADD_UP_DEDUCTIONS.getValue() + ""));
|
||||||
|
result.put(SalaryFormulaReferenceEnum.EMPLOYEE_INFO.getDefaultLabel(),
|
||||||
|
convert2FormulaVar(DataCollectionEmployee.class, SalaryFormulaReferenceEnum.EMPLOYEE_INFO.getValue() + ""));
|
||||||
|
result.put(SalaryFormulaReferenceEnum.OTHER_DEDUCTION.getDefaultLabel(),
|
||||||
|
convert2FormulaVar(OtherDeductionPO.class, SalaryFormulaReferenceEnum.OTHER_DEDUCTION.getValue() + ""));
|
||||||
|
result.put(SalaryFormulaReferenceEnum.WELFARE.getDefaultLabel(),
|
||||||
|
welfare2FormulaVar(SalaryFormulaReferenceEnum.WELFARE));
|
||||||
|
result.put(SalaryFormulaReferenceEnum.ATTEND.getDefaultLabel(),
|
||||||
|
attendData2FormulaVar(SalaryFormulaReferenceEnum.ATTEND));
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
// @Override
|
// @Override
|
||||||
// public ExcelPage<FormulaDataSource> dataSourceList(String categoryId, ExcelPage<FormulaDataSource> page, Map<String, Object> extendParam, DataCollectionEmployee employee) {
|
// public ExcelPage<FormulaDataSource> dataSourceList(String categoryId, ExcelPage<FormulaDataSource> page, Map<String, Object> extendParam, DataCollectionEmployee employee) {
|
||||||
// log.info("categoryId: {}, page: {}", categoryId, JsonUtil.toJsonString(page));
|
// log.info("categoryId: {}, page: {}", categoryId, JsonUtil.toJsonString(page));
|
||||||
|
|
|
||||||
|
|
@ -11,11 +11,14 @@ import com.engine.salary.entity.sicategory.po.ICategoryPO;
|
||||||
import com.engine.salary.entity.siexport.param.InsuranceExportParam;
|
import com.engine.salary.entity.siexport.param.InsuranceExportParam;
|
||||||
import com.engine.salary.entity.siexport.po.AccountExportPO;
|
import com.engine.salary.entity.siexport.po.AccountExportPO;
|
||||||
import com.engine.salary.entity.siexport.po.ExcelAccountExportPO;
|
import com.engine.salary.entity.siexport.po.ExcelAccountExportPO;
|
||||||
|
import com.engine.salary.entity.sischeme.po.InsuranceSchemeDetailPO;
|
||||||
import com.engine.salary.enums.siaccount.EmployeeStatusEnum;
|
import com.engine.salary.enums.siaccount.EmployeeStatusEnum;
|
||||||
import com.engine.salary.mapper.InsuranceExportMapper;
|
import com.engine.salary.mapper.InsuranceExportMapper;
|
||||||
import com.engine.salary.mapper.siarchives.InsuranceBaseInfoMapper;
|
import com.engine.salary.mapper.siarchives.InsuranceBaseInfoMapper;
|
||||||
import com.engine.salary.mapper.sicategory.ICategoryMapper;
|
import com.engine.salary.mapper.sicategory.ICategoryMapper;
|
||||||
|
import com.engine.salary.mapper.sischeme.InsuranceSchemeDetailMapper;
|
||||||
import com.engine.salary.service.SIAComparisonResultService;
|
import com.engine.salary.service.SIAComparisonResultService;
|
||||||
|
import com.engine.salary.service.SISchemeService;
|
||||||
import com.engine.salary.sys.entity.vo.OrderRuleVO;
|
import com.engine.salary.sys.entity.vo.OrderRuleVO;
|
||||||
import com.engine.salary.sys.service.SalarySysConfService;
|
import com.engine.salary.sys.service.SalarySysConfService;
|
||||||
import com.engine.salary.sys.service.impl.SalarySysConfServiceImpl;
|
import com.engine.salary.sys.service.impl.SalarySysConfServiceImpl;
|
||||||
|
|
@ -26,6 +29,7 @@ import com.engine.salary.util.page.PageInfo;
|
||||||
import com.engine.salary.util.page.SalaryPageUtil;
|
import com.engine.salary.util.page.SalaryPageUtil;
|
||||||
import com.engine.salary.util.valid.ValidUtil;
|
import com.engine.salary.util.valid.ValidUtil;
|
||||||
import com.google.common.collect.Lists;
|
import com.google.common.collect.Lists;
|
||||||
|
import com.wbi.util.Util;
|
||||||
import org.apache.commons.lang3.BooleanUtils;
|
import org.apache.commons.lang3.BooleanUtils;
|
||||||
import org.apache.poi.xssf.usermodel.XSSFWorkbook;
|
import org.apache.poi.xssf.usermodel.XSSFWorkbook;
|
||||||
import weaver.hrm.User;
|
import weaver.hrm.User;
|
||||||
|
|
@ -57,6 +61,14 @@ public class SIAComparisonResultServiceImpl extends Service implements SIACompar
|
||||||
return MapperProxyFactory.getProxy(ICategoryMapper.class);
|
return MapperProxyFactory.getProxy(ICategoryMapper.class);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private InsuranceSchemeDetailMapper getInsuranceSchemeDetailMapper() {
|
||||||
|
return MapperProxyFactory.getProxy(InsuranceSchemeDetailMapper.class);
|
||||||
|
}
|
||||||
|
|
||||||
|
private SISchemeService getSISchemeService(User user) {
|
||||||
|
return ServiceUtil.getService(SISchemeServiceImpl.class, user);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 根据列表查询条件查询线下对比结果(分页)
|
* 根据列表查询条件查询线下对比结果(分页)
|
||||||
*/
|
*/
|
||||||
|
|
@ -155,10 +167,35 @@ public class SIAComparisonResultServiceImpl extends Service implements SIACompar
|
||||||
//2-查询线下对比数据
|
//2-查询线下对比数据
|
||||||
List<ExcelAccountExportPO> excelAccountExportPOS = getInsuranceExportMapper().exportExcelAccount(queryParam);
|
List<ExcelAccountExportPO> excelAccountExportPOS = getInsuranceExportMapper().exportExcelAccount(queryParam);
|
||||||
encryptUtil.decryptList(excelAccountExportPOS, ExcelAccountExportPO.class);
|
encryptUtil.decryptList(excelAccountExportPOS, ExcelAccountExportPO.class);
|
||||||
|
|
||||||
|
//整理线上核算记录相关的福利方案,并以此整理需要对比的福利项类别数据
|
||||||
|
Set<Long> welfareSchemeIds = new HashSet<>();
|
||||||
|
accountExportPOS.forEach(f -> {
|
||||||
|
welfareSchemeIds.add(f.getSocialSchemeId());
|
||||||
|
welfareSchemeIds.add(f.getFundSchemeId());
|
||||||
|
welfareSchemeIds.add(f.getOtherSchemeId());
|
||||||
|
});
|
||||||
|
List<InsuranceSchemeDetailPO> insuranceSchemeDetailPos = getInsuranceSchemeDetailMapper().listAll();
|
||||||
|
List<Long> insuranceBaseIds = insuranceSchemeDetailPos.stream()
|
||||||
|
.filter(f -> welfareSchemeIds.contains(f.getPrimaryId()) && f.getIsPayment() == 1)
|
||||||
|
.map(InsuranceSchemeDetailPO::getInsuranceId)
|
||||||
|
.collect(Collectors.toList());
|
||||||
|
List<Long> insurancePerPayIds = insuranceSchemeDetailPos.stream()
|
||||||
|
.filter(f -> welfareSchemeIds.contains(f.getPrimaryId()) && f.getIsPayment() == 1 && f.getPaymentScope() == 2)
|
||||||
|
.map(InsuranceSchemeDetailPO::getInsuranceId)
|
||||||
|
.collect(Collectors.toList());
|
||||||
|
List<Long> insuranceComPayIds = insuranceSchemeDetailPos.stream()
|
||||||
|
.filter(f -> welfareSchemeIds.contains(f.getPrimaryId()) && f.getIsPayment() == 1 && f.getPaymentScope() == 1)
|
||||||
|
.map(InsuranceSchemeDetailPO::getInsuranceId)
|
||||||
|
.collect(Collectors.toList());
|
||||||
|
Set<Long> insuranceBaseSet = new HashSet<>(insuranceBaseIds);
|
||||||
|
Set<Long> insurancePerPaySet = new HashSet<>(insurancePerPayIds);
|
||||||
|
Set<Long> insuranceComPaySet = new HashSet<>(insuranceComPayIds);
|
||||||
//3-构建福利核算对比结果列表表头
|
//3-构建福利核算对比结果列表表头
|
||||||
List<Column> weaTableColumns = InsuranceComparisonResultBO.buildTableColumns4ComparisonResult();
|
List<Column> weaTableColumns = InsuranceComparisonResultBO.buildTableColumns4ComparisonResult(insuranceBaseSet, insurancePerPaySet, insuranceComPaySet);
|
||||||
//4-通过线上线下两份数据获得对比结果
|
//4-通过线上线下两份数据获得对比结果
|
||||||
List<Map<String, Object>> resultMapList = InsuranceComparisonResultBO.buildComparisonTableData(accountExportPOS, excelAccountExportPOS);
|
Map<Long, String> schemeIdNameMap = getSISchemeService(user).getSchemeIdNameMap();
|
||||||
|
List<Map<String, Object>> resultMapList = InsuranceComparisonResultBO.buildComparisonTableData(accountExportPOS, excelAccountExportPOS, schemeIdNameMap);
|
||||||
|
|
||||||
// 系统值和线下值一致的人员
|
// 系统值和线下值一致的人员
|
||||||
if (queryParam.isOnlyDiffEmployee()) {
|
if (queryParam.isOnlyDiffEmployee()) {
|
||||||
|
|
|
||||||
|
|
@ -28,6 +28,9 @@ import com.engine.salary.entity.siarchives.po.InsuranceArchivesEmployeePO;
|
||||||
import com.engine.salary.entity.siarchives.po.InsuranceArchivesFundSchemePO;
|
import com.engine.salary.entity.siarchives.po.InsuranceArchivesFundSchemePO;
|
||||||
import com.engine.salary.entity.siarchives.po.InsuranceArchivesSocialSchemePO;
|
import com.engine.salary.entity.siarchives.po.InsuranceArchivesSocialSchemePO;
|
||||||
import com.engine.salary.entity.sicategory.po.ICategoryPO;
|
import com.engine.salary.entity.sicategory.po.ICategoryPO;
|
||||||
|
import com.engine.salary.entity.siexport.param.InsuranceExportParam;
|
||||||
|
import com.engine.salary.entity.siexport.po.AccountExportPO;
|
||||||
|
import com.engine.salary.entity.sischeme.po.InsuranceSchemeDetailPO;
|
||||||
import com.engine.salary.entity.sischeme.po.InsuranceSchemePO;
|
import com.engine.salary.entity.sischeme.po.InsuranceSchemePO;
|
||||||
import com.engine.salary.entity.taxagent.po.TaxAgentPO;
|
import com.engine.salary.entity.taxagent.po.TaxAgentPO;
|
||||||
import com.engine.salary.enums.UserStatusEnum;
|
import com.engine.salary.enums.UserStatusEnum;
|
||||||
|
|
@ -35,6 +38,7 @@ import com.engine.salary.enums.siaccount.*;
|
||||||
import com.engine.salary.enums.sicategory.DeleteTypeEnum;
|
import com.engine.salary.enums.sicategory.DeleteTypeEnum;
|
||||||
import com.engine.salary.enums.sicategory.WelfareTypeEnum;
|
import com.engine.salary.enums.sicategory.WelfareTypeEnum;
|
||||||
import com.engine.salary.exception.SalaryRunTimeException;
|
import com.engine.salary.exception.SalaryRunTimeException;
|
||||||
|
import com.engine.salary.mapper.InsuranceExportMapper;
|
||||||
import com.engine.salary.mapper.siaccount.ExcelInsuranceDetailMapper;
|
import com.engine.salary.mapper.siaccount.ExcelInsuranceDetailMapper;
|
||||||
import com.engine.salary.mapper.siaccount.InsuranceAccountBatchMapper;
|
import com.engine.salary.mapper.siaccount.InsuranceAccountBatchMapper;
|
||||||
import com.engine.salary.mapper.siaccount.InsuranceAccountDetailMapper;
|
import com.engine.salary.mapper.siaccount.InsuranceAccountDetailMapper;
|
||||||
|
|
@ -43,6 +47,7 @@ import com.engine.salary.mapper.siarchives.FundSchemeMapper;
|
||||||
import com.engine.salary.mapper.siarchives.InsuranceBaseInfoMapper;
|
import com.engine.salary.mapper.siarchives.InsuranceBaseInfoMapper;
|
||||||
import com.engine.salary.mapper.siarchives.SocialSchemeMapper;
|
import com.engine.salary.mapper.siarchives.SocialSchemeMapper;
|
||||||
import com.engine.salary.mapper.sicategory.ICategoryMapper;
|
import com.engine.salary.mapper.sicategory.ICategoryMapper;
|
||||||
|
import com.engine.salary.mapper.sischeme.InsuranceSchemeDetailMapper;
|
||||||
import com.engine.salary.mapper.sischeme.InsuranceSchemeMapper;
|
import com.engine.salary.mapper.sischeme.InsuranceSchemeMapper;
|
||||||
import com.engine.salary.mapper.sys.SalarySysConfMapper;
|
import com.engine.salary.mapper.sys.SalarySysConfMapper;
|
||||||
import com.engine.salary.mapper.taxagent.TaxAgentMapper;
|
import com.engine.salary.mapper.taxagent.TaxAgentMapper;
|
||||||
|
|
@ -183,6 +188,14 @@ public class SIAccountServiceImpl extends Service implements SIAccountService {
|
||||||
return MapperProxyFactory.getProxy(InsuranceAccountInspectMapper.class);
|
return MapperProxyFactory.getProxy(InsuranceAccountInspectMapper.class);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private InsuranceExportMapper getInsuranceExportMapper() {
|
||||||
|
return MapperProxyFactory.getProxy(InsuranceExportMapper.class);
|
||||||
|
}
|
||||||
|
|
||||||
|
private InsuranceSchemeDetailMapper getInsuranceSchemeDetailMapper() {
|
||||||
|
return MapperProxyFactory.getProxy(InsuranceSchemeDetailMapper.class);
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public Map<String, Object> listPage(InsuranceAccountBatchParam queryParam) {
|
public Map<String, Object> listPage(InsuranceAccountBatchParam queryParam) {
|
||||||
Long employeeId = (long) user.getUID();
|
Long employeeId = (long) user.getUID();
|
||||||
|
|
@ -316,14 +329,14 @@ public class SIAccountServiceImpl extends Service implements SIAccountService {
|
||||||
Long employeeId = (long) user.getUID();
|
Long employeeId = (long) user.getUID();
|
||||||
Map<String, Object> datas = new HashMap<>();
|
Map<String, Object> datas = new HashMap<>();
|
||||||
|
|
||||||
//过滤出福利档案基础信息表中runStatus为正在缴纳和待减员的人员
|
// //过滤出福利档案基础信息表中runStatus为正在缴纳和待减员的人员
|
||||||
List<InsuranceArchivesBaseInfoPO> baseInfoPOList = getInsuranceBaseInfoMapper().listAll();
|
// List<InsuranceArchivesBaseInfoPO> baseInfoPOList = getInsuranceBaseInfoMapper().listAll();
|
||||||
List<Long> canAccountIds = baseInfoPOList.stream()
|
// List<Long> canAccountIds = baseInfoPOList.stream()
|
||||||
.filter(f->f.getPaymentOrganization().toString().equals(queryParam.getPaymentOrganization())
|
// .filter(f->f.getPaymentOrganization().toString().equals(queryParam.getPaymentOrganization())
|
||||||
&& (f.getRunStatus().equals(EmployeeStatusEnum.PAYING.getValue()) || f.getRunStatus().equals(EmployeeStatusEnum.STAY_DEL.getValue())))
|
// && (f.getRunStatus().equals(EmployeeStatusEnum.PAYING.getValue()) || f.getRunStatus().equals(EmployeeStatusEnum.STAY_DEL.getValue())))
|
||||||
.map(InsuranceArchivesBaseInfoPO::getEmployeeId)
|
// .map(InsuranceArchivesBaseInfoPO::getEmployeeId)
|
||||||
.collect(Collectors.toList());
|
// .collect(Collectors.toList());
|
||||||
queryParam.setEmployeeIds(canAccountIds);
|
// queryParam.setEmployeeIds(canAccountIds);
|
||||||
|
|
||||||
//补缴缴纳列表
|
//补缴缴纳列表
|
||||||
queryParam.setPaymentStatus(PaymentStatusEnum.REPAIR.getValue());
|
queryParam.setPaymentStatus(PaymentStatusEnum.REPAIR.getValue());
|
||||||
|
|
@ -1688,36 +1701,58 @@ public class SIAccountServiceImpl extends Service implements SIAccountService {
|
||||||
insuranceAccountDetailPO.setOtherComJson(JSON.toJSONString(otherComMap));
|
insuranceAccountDetailPO.setOtherComJson(JSON.toJSONString(otherComMap));
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!StringUtils.isEmpty(baseMap.getOrDefault("个人合计", "").toString())) {
|
|
||||||
insuranceAccountDetailPO.setPerSum(baseMap.get("个人合计").toString());
|
|
||||||
}
|
|
||||||
|
|
||||||
if (!StringUtils.isEmpty(baseMap.getOrDefault("社保个人合计", "").toString())) {
|
if (!StringUtils.isEmpty(baseMap.getOrDefault("社保个人合计", "").toString())) {
|
||||||
insuranceAccountDetailPO.setSocialPerSum(baseMap.get("社保个人合计").toString());
|
insuranceAccountDetailPO.setSocialPerSum(baseMap.get("社保个人合计").toString());
|
||||||
|
} else if (!socialPerMap.isEmpty()) {
|
||||||
|
insuranceAccountDetailPO.setSocialPerSum(sumOfMapValue(socialPerMap));
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!StringUtils.isEmpty(baseMap.getOrDefault("公积金个人合计", "").toString())) {
|
if (!StringUtils.isEmpty(baseMap.getOrDefault("公积金个人合计", "").toString())) {
|
||||||
insuranceAccountDetailPO.setFundPerSum(baseMap.get("公积金个人合计").toString());
|
insuranceAccountDetailPO.setFundPerSum(baseMap.get("公积金个人合计").toString());
|
||||||
|
} else if (!fundPerMap.isEmpty()) {
|
||||||
|
insuranceAccountDetailPO.setFundPerSum(sumOfMapValue(fundPerMap));
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!StringUtils.isEmpty(baseMap.getOrDefault("其他福利个人合计", "").toString())) {
|
if (!StringUtils.isEmpty(baseMap.getOrDefault("其他福利个人合计", "").toString())) {
|
||||||
insuranceAccountDetailPO.setOtherPerSum(baseMap.get("其他福利个人合计").toString());
|
insuranceAccountDetailPO.setOtherPerSum(baseMap.get("其他福利个人合计").toString());
|
||||||
|
} else if (!otherPerMap.isEmpty()) {
|
||||||
|
insuranceAccountDetailPO.setOtherPerSum(sumOfMapValue(otherPerMap));
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!StringUtils.isEmpty(baseMap.getOrDefault("单位合计", "").toString())) {
|
if (!StringUtils.isEmpty(baseMap.getOrDefault("个人合计", "").toString())) {
|
||||||
insuranceAccountDetailPO.setComSum(baseMap.get("单位合计").toString());
|
insuranceAccountDetailPO.setPerSum(baseMap.get("个人合计").toString());
|
||||||
|
} else {
|
||||||
|
insuranceAccountDetailPO.setPerSum(new BigDecimal(insuranceAccountDetailPO.getSocialPerSum() == null ? "0" : insuranceAccountDetailPO.getSocialPerSum())
|
||||||
|
.add(new BigDecimal(insuranceAccountDetailPO.getFundPerSum() == null ? "0" : insuranceAccountDetailPO.getFundPerSum()))
|
||||||
|
.add(new BigDecimal(insuranceAccountDetailPO.getOtherPerSum() == null ? "0" : insuranceAccountDetailPO.getOtherPerSum())).toString());
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!StringUtils.isEmpty(baseMap.getOrDefault("社保单位合计", "").toString())) {
|
if (!StringUtils.isEmpty(baseMap.getOrDefault("社保单位合计", "").toString())) {
|
||||||
insuranceAccountDetailPO.setSocialComSum(baseMap.get("社保单位合计").toString());
|
insuranceAccountDetailPO.setSocialComSum(baseMap.get("社保单位合计").toString());
|
||||||
|
} else if (!socialComMap.isEmpty()) {
|
||||||
|
insuranceAccountDetailPO.setSocialComSum(sumOfMapValue(socialComMap));
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!StringUtils.isEmpty(baseMap.getOrDefault("公积金单位合计", "").toString())) {
|
if (!StringUtils.isEmpty(baseMap.getOrDefault("公积金单位合计", "").toString())) {
|
||||||
insuranceAccountDetailPO.setFundComSum(baseMap.get("公积金单位合计").toString());
|
insuranceAccountDetailPO.setFundComSum(baseMap.get("公积金单位合计").toString());
|
||||||
|
} else if (!fundComMap.isEmpty()) {
|
||||||
|
insuranceAccountDetailPO.setFundComSum(sumOfMapValue(fundComMap));
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!StringUtils.isEmpty(baseMap.getOrDefault("其他福利单位合计", "").toString())) {
|
if (!StringUtils.isEmpty(baseMap.getOrDefault("其他福利单位合计", "").toString())) {
|
||||||
insuranceAccountDetailPO.setOtherComSum(baseMap.get("其他福利单位合计").toString());
|
insuranceAccountDetailPO.setOtherComSum(baseMap.get("其他福利单位合计").toString());
|
||||||
|
} else if (!otherComMap.isEmpty()) {
|
||||||
|
insuranceAccountDetailPO.setOtherComSum(sumOfMapValue(otherComMap));
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
if (!StringUtils.isEmpty(baseMap.getOrDefault("单位合计", "").toString())) {
|
||||||
|
insuranceAccountDetailPO.setComSum(baseMap.get("单位合计").toString());
|
||||||
|
} else {
|
||||||
|
insuranceAccountDetailPO.setComSum(new BigDecimal(insuranceAccountDetailPO.getSocialComSum() == null ? "0" : insuranceAccountDetailPO.getSocialComSum())
|
||||||
|
.add(new BigDecimal(insuranceAccountDetailPO.getFundComSum() == null ? "0" : insuranceAccountDetailPO.getFundComSum()))
|
||||||
|
.add(new BigDecimal(insuranceAccountDetailPO.getOtherComSum() == null ? "0" : insuranceAccountDetailPO.getOtherComSum())).toString());
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!StringUtils.isEmpty(baseMap.getOrDefault("账单月份", "").toString())) {
|
if (!StringUtils.isEmpty(baseMap.getOrDefault("账单月份", "").toString())) {
|
||||||
|
|
@ -1726,15 +1761,31 @@ public class SIAccountServiceImpl extends Service implements SIAccountService {
|
||||||
|
|
||||||
if (!StringUtils.isEmpty(baseMap.getOrDefault("社保合计", "").toString())) {
|
if (!StringUtils.isEmpty(baseMap.getOrDefault("社保合计", "").toString())) {
|
||||||
insuranceAccountDetailPO.setSocialSum(baseMap.get("社保合计").toString());
|
insuranceAccountDetailPO.setSocialSum(baseMap.get("社保合计").toString());
|
||||||
|
} else {
|
||||||
|
insuranceAccountDetailPO.setSocialSum(new BigDecimal(insuranceAccountDetailPO.getSocialComSum() == null ? "0" : insuranceAccountDetailPO.getSocialComSum())
|
||||||
|
.add(new BigDecimal(insuranceAccountDetailPO.getSocialPerSum() == null ? "0" : insuranceAccountDetailPO.getSocialPerSum()))
|
||||||
|
.toString());
|
||||||
}
|
}
|
||||||
if (!StringUtils.isEmpty(baseMap.getOrDefault("公积金合计", "").toString())) {
|
if (!StringUtils.isEmpty(baseMap.getOrDefault("公积金合计", "").toString())) {
|
||||||
insuranceAccountDetailPO.setFundSum(baseMap.get("公积金合计").toString());
|
insuranceAccountDetailPO.setFundSum(baseMap.get("公积金合计").toString());
|
||||||
|
} else {
|
||||||
|
insuranceAccountDetailPO.setFundSum(new BigDecimal(insuranceAccountDetailPO.getFundComSum() == null ? "0" : insuranceAccountDetailPO.getFundComSum())
|
||||||
|
.add(new BigDecimal(insuranceAccountDetailPO.getFundPerSum() == null ? "0" : insuranceAccountDetailPO.getFundPerSum()))
|
||||||
|
.toString());
|
||||||
}
|
}
|
||||||
if (!StringUtils.isEmpty(baseMap.getOrDefault("其他福利合计", "").toString())) {
|
if (!StringUtils.isEmpty(baseMap.getOrDefault("其他福利合计", "").toString())) {
|
||||||
insuranceAccountDetailPO.setOtherSum(baseMap.get("其他福利合计").toString());
|
insuranceAccountDetailPO.setOtherSum(baseMap.get("其他福利合计").toString());
|
||||||
|
} else {
|
||||||
|
insuranceAccountDetailPO.setOtherSum(new BigDecimal(insuranceAccountDetailPO.getOtherComSum() == null ? "0" : insuranceAccountDetailPO.getOtherComSum())
|
||||||
|
.add(new BigDecimal(insuranceAccountDetailPO.getOtherPerSum() == null ? "0" : insuranceAccountDetailPO.getOtherPerSum()))
|
||||||
|
.toString());
|
||||||
}
|
}
|
||||||
if (!StringUtils.isEmpty(baseMap.getOrDefault("合计", "").toString())) {
|
if (!StringUtils.isEmpty(baseMap.getOrDefault("合计", "").toString())) {
|
||||||
insuranceAccountDetailPO.setTotal(baseMap.get("合计").toString());
|
insuranceAccountDetailPO.setTotal(baseMap.get("合计").toString());
|
||||||
|
} else {
|
||||||
|
insuranceAccountDetailPO.setTotal(new BigDecimal(insuranceAccountDetailPO.getPerSum() == null ? "0" : insuranceAccountDetailPO.getPerSum())
|
||||||
|
.add(new BigDecimal(insuranceAccountDetailPO.getComSum() == null ? "0" : insuranceAccountDetailPO.getComSum()))
|
||||||
|
.toString());
|
||||||
}
|
}
|
||||||
|
|
||||||
//如果导入的时补缴数据,还会包含补缴月份
|
//如果导入的时补缴数据,还会包含补缴月份
|
||||||
|
|
@ -1747,6 +1798,17 @@ public class SIAccountServiceImpl extends Service implements SIAccountService {
|
||||||
return insuranceAccountDetailPO;
|
return insuranceAccountDetailPO;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* map中value值求和
|
||||||
|
*/
|
||||||
|
public String sumOfMapValue(Map<String, String> welfarePay){
|
||||||
|
BigDecimal sum = new BigDecimal("0");
|
||||||
|
for (String value : welfarePay.values()) {
|
||||||
|
sum = sum.add(new BigDecimal(value));
|
||||||
|
}
|
||||||
|
return sum.toString();
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 对比新旧两份数据,并更新数据
|
* 对比新旧两份数据,并更新数据
|
||||||
*/
|
*/
|
||||||
|
|
@ -1824,12 +1886,51 @@ public class SIAccountServiceImpl extends Service implements SIAccountService {
|
||||||
* 导出“福利核算-线下对比导入模板”
|
* 导出“福利核算-线下对比导入模板”
|
||||||
*/
|
*/
|
||||||
@Override
|
@Override
|
||||||
public XSSFWorkbook exportComparisonWelfareTemplate(InsuranceAcctDetailImportTemplateParam param) {
|
public XSSFWorkbook exportComparisonWelfareTemplate(InsuranceAccountDetailParam param) {
|
||||||
|
|
||||||
|
//查询线上福利核算记录
|
||||||
|
InsuranceExportParam insuranceExportParam = new InsuranceExportParam();
|
||||||
|
insuranceExportParam.setBillMonth(param.getBillMonth());
|
||||||
|
insuranceExportParam.setPaymentOrganization(param.getPaymentOrganization());
|
||||||
|
List<AccountExportPO> accountExportPOS = getInsuranceExportMapper().exportAccount(param.getPaymentStatus(), insuranceExportParam);
|
||||||
|
|
||||||
|
//整理线上核算记录相关的福利方案,并以此整理需要对比的福利项类别数据
|
||||||
|
Set<Long> welfareSchemeIds = new HashSet<>();
|
||||||
|
accountExportPOS.forEach(f -> {
|
||||||
|
welfareSchemeIds.add(f.getSocialSchemeId());
|
||||||
|
welfareSchemeIds.add(f.getFundSchemeId());
|
||||||
|
welfareSchemeIds.add(f.getOtherSchemeId());
|
||||||
|
});
|
||||||
|
List<InsuranceSchemeDetailPO> insuranceSchemeDetailPos = getInsuranceSchemeDetailMapper().listAll();
|
||||||
|
List<Long> insuranceBaseIds = insuranceSchemeDetailPos.stream()
|
||||||
|
.filter(f -> welfareSchemeIds.contains(f.getPrimaryId()) && f.getIsPayment() == 1)
|
||||||
|
.map(InsuranceSchemeDetailPO::getInsuranceId)
|
||||||
|
.collect(Collectors.toList());
|
||||||
|
List<Long> insurancePerPayIds = insuranceSchemeDetailPos.stream()
|
||||||
|
.filter(f -> welfareSchemeIds.contains(f.getPrimaryId()) && f.getIsPayment() == 1 && f.getPaymentScope() == 2)
|
||||||
|
.map(InsuranceSchemeDetailPO::getInsuranceId)
|
||||||
|
.collect(Collectors.toList());
|
||||||
|
List<Long> insuranceComPayIds = insuranceSchemeDetailPos.stream()
|
||||||
|
.filter(f -> welfareSchemeIds.contains(f.getPrimaryId()) && f.getIsPayment() == 1 && f.getPaymentScope() == 1)
|
||||||
|
.map(InsuranceSchemeDetailPO::getInsuranceId)
|
||||||
|
.collect(Collectors.toList());
|
||||||
|
Set<Long> insuranceBaseSet = new HashSet<>(insuranceBaseIds);
|
||||||
|
Set<Long> insurancePerPaySet = new HashSet<>(insurancePerPayIds);
|
||||||
|
Set<Long> insuranceComPaySet = new HashSet<>(insuranceComPayIds);
|
||||||
|
|
||||||
List<ICategoryPO> listAll = getICategoryMapper().listAll();
|
List<ICategoryPO> listAll = getICategoryMapper().listAll();
|
||||||
List<ICategoryPO> socialWelfareList = listAll.stream().filter(e -> e.getWelfareType() == 1).collect(Collectors.toList());
|
List<ICategoryPO> socialWelfareList = listAll.stream().filter(e -> e.getWelfareType() == 1 && e.getIsUse() == 1 && insuranceBaseSet.contains(e.getId())).collect(Collectors.toList());
|
||||||
List<ICategoryPO> fundWelfareList = listAll.stream().filter(e -> e.getWelfareType() == 2).collect(Collectors.toList());
|
List<ICategoryPO> fundWelfareList = listAll.stream().filter(e -> e.getWelfareType() == 2 && e.getIsUse() == 1 && insuranceBaseSet.contains(e.getId())).collect(Collectors.toList());
|
||||||
List<ICategoryPO> otherWelfareList = listAll.stream().filter(e -> e.getWelfareType() == 3).collect(Collectors.toList());
|
List<ICategoryPO> otherWelfareList = listAll.stream().filter(e -> e.getWelfareType() == 3 && e.getIsUse() == 1 && insuranceBaseSet.contains(e.getId())).collect(Collectors.toList());
|
||||||
|
|
||||||
|
List<ICategoryPO> socialWelPerList = listAll.stream().filter(e -> e.getWelfareType() == 1 && e.getIsUse() == 1 && insurancePerPaySet.contains(e.getId())).collect(Collectors.toList());
|
||||||
|
List<ICategoryPO> fundWelPerList = listAll.stream().filter(e -> e.getWelfareType() == 2 && e.getIsUse() == 1 && insurancePerPaySet.contains(e.getId())).collect(Collectors.toList());
|
||||||
|
List<ICategoryPO> otherWelPerList = listAll.stream().filter(e -> e.getWelfareType() == 3 && e.getIsUse() == 1 && insurancePerPaySet.contains(e.getId())).collect(Collectors.toList());
|
||||||
|
|
||||||
|
List<ICategoryPO> socialWelComList = listAll.stream().filter(e -> e.getWelfareType() == 1 && e.getIsUse() == 1 && insuranceComPaySet.contains(e.getId())).collect(Collectors.toList());
|
||||||
|
List<ICategoryPO> fundWelComList = listAll.stream().filter(e -> e.getWelfareType() == 2 && e.getIsUse() == 1 && insuranceComPaySet.contains(e.getId())).collect(Collectors.toList());
|
||||||
|
List<ICategoryPO> otherWelComList = listAll.stream().filter(e -> e.getWelfareType() == 3 && e.getIsUse() == 1 && insuranceComPaySet.contains(e.getId())).collect(Collectors.toList());
|
||||||
|
|
||||||
List<Object> headerList = Lists.newArrayList(SalaryI18nUtil.getI18nLabel(85429, "姓名"),
|
List<Object> headerList = Lists.newArrayList(SalaryI18nUtil.getI18nLabel(85429, "姓名"),
|
||||||
SalaryI18nUtil.getI18nLabel(86185, "部门"),
|
SalaryI18nUtil.getI18nLabel(86185, "部门"),
|
||||||
SalaryI18nUtil.getI18nLabel(86186, "手机号"),
|
SalaryI18nUtil.getI18nLabel(86186, "手机号"),
|
||||||
|
|
@ -1860,33 +1961,33 @@ public class SIAccountServiceImpl extends Service implements SIAccountService {
|
||||||
headerList.add(po.getInsuranceName() + "申报基数");
|
headerList.add(po.getInsuranceName() + "申报基数");
|
||||||
}
|
}
|
||||||
//社保个人(生育保险个人、工伤保险个人、失业保险个人、养老保险个人、医疗保险个人)
|
//社保个人(生育保险个人、工伤保险个人、失业保险个人、养老保险个人、医疗保险个人)
|
||||||
for (ICategoryPO po : socialWelfareList) {
|
for (ICategoryPO po : socialWelPerList) {
|
||||||
headerList.add(po.getInsuranceName() + "个人");
|
headerList.add(po.getInsuranceName() + "个人");
|
||||||
}
|
}
|
||||||
headerList.add(SalaryI18nUtil.getI18nLabel(100388, "社保个人合计"));
|
headerList.add(SalaryI18nUtil.getI18nLabel(100388, "社保个人合计"));
|
||||||
//住房公积金个人、补充住房公积金个人
|
//住房公积金个人、补充住房公积金个人
|
||||||
for (ICategoryPO po : fundWelfareList) {
|
for (ICategoryPO po : fundWelPerList) {
|
||||||
headerList.add(po.getInsuranceName() + "个人");
|
headerList.add(po.getInsuranceName() + "个人");
|
||||||
}
|
}
|
||||||
headerList.add(SalaryI18nUtil.getI18nLabel(100390, "公积金个人合计"));
|
headerList.add(SalaryI18nUtil.getI18nLabel(100390, "公积金个人合计"));
|
||||||
//其他个人(比如企业年金个人)
|
//其他个人(比如企业年金个人)
|
||||||
for (ICategoryPO po : otherWelfareList) {
|
for (ICategoryPO po : otherWelPerList) {
|
||||||
headerList.add(po.getInsuranceName() + "个人");
|
headerList.add(po.getInsuranceName() + "个人");
|
||||||
}
|
}
|
||||||
headerList.add(SalaryI18nUtil.getI18nLabel(100392, "其他福利个人合计"));
|
headerList.add(SalaryI18nUtil.getI18nLabel(100392, "其他福利个人合计"));
|
||||||
headerList.add(SalaryI18nUtil.getI18nLabel(100393, "个人合计"));
|
headerList.add(SalaryI18nUtil.getI18nLabel(100393, "个人合计"));
|
||||||
//社保单位(生育保险单位、工伤保险单位、失业保险单位、养老保险单位、医疗保险单位)
|
//社保单位(生育保险单位、工伤保险单位、失业保险单位、养老保险单位、医疗保险单位)
|
||||||
for (ICategoryPO po : socialWelfareList) {
|
for (ICategoryPO po : socialWelComList) {
|
||||||
headerList.add(po.getInsuranceName() + "单位");
|
headerList.add(po.getInsuranceName() + "单位");
|
||||||
}
|
}
|
||||||
headerList.add(SalaryI18nUtil.getI18nLabel(100394, "社保单位合计"));
|
headerList.add(SalaryI18nUtil.getI18nLabel(100394, "社保单位合计"));
|
||||||
//住房公积金单位、补充住房公积金单位
|
//住房公积金单位、补充住房公积金单位
|
||||||
for (ICategoryPO po : fundWelfareList) {
|
for (ICategoryPO po : fundWelComList) {
|
||||||
headerList.add(po.getInsuranceName() + "单位");
|
headerList.add(po.getInsuranceName() + "单位");
|
||||||
}
|
}
|
||||||
headerList.add(SalaryI18nUtil.getI18nLabel(100395, "公积金单位合计"));
|
headerList.add(SalaryI18nUtil.getI18nLabel(100395, "公积金单位合计"));
|
||||||
//其他单位(比如企业年金单位)
|
//其他单位(比如企业年金单位)
|
||||||
for (ICategoryPO po : otherWelfareList) {
|
for (ICategoryPO po : otherWelComList) {
|
||||||
headerList.add(po.getInsuranceName() + "单位");
|
headerList.add(po.getInsuranceName() + "单位");
|
||||||
}
|
}
|
||||||
headerList.add(SalaryI18nUtil.getI18nLabel(100396, "其他福利单位合计"));
|
headerList.add(SalaryI18nUtil.getI18nLabel(100396, "其他福利单位合计"));
|
||||||
|
|
@ -2859,14 +2960,14 @@ public class SIAccountServiceImpl extends Service implements SIAccountService {
|
||||||
Map<String, Object> datas = new HashMap<>();
|
Map<String, Object> datas = new HashMap<>();
|
||||||
queryParam.setPageSize(10000000);
|
queryParam.setPageSize(10000000);
|
||||||
|
|
||||||
//过滤出福利档案基础信息表中runStatus为正在缴纳和待减员的人员
|
// //过滤出福利档案基础信息表中runStatus为正在缴纳和待减员的人员
|
||||||
List<InsuranceArchivesBaseInfoPO> baseInfoPOList = getInsuranceBaseInfoMapper().listAll();
|
// List<InsuranceArchivesBaseInfoPO> baseInfoPOList = getInsuranceBaseInfoMapper().listAll();
|
||||||
List<Long> canAccountIds = baseInfoPOList.stream()
|
// List<Long> canAccountIds = baseInfoPOList.stream()
|
||||||
.filter(f->f.getPaymentOrganization().toString().equals(queryParam.getPaymentOrganization())
|
// .filter(f->f.getPaymentOrganization().toString().equals(queryParam.getPaymentOrganization())
|
||||||
&& (f.getRunStatus().equals(EmployeeStatusEnum.PAYING.getValue()) || f.getRunStatus().equals(EmployeeStatusEnum.STAY_DEL.getValue())))
|
// && (f.getRunStatus().equals(EmployeeStatusEnum.PAYING.getValue()) || f.getRunStatus().equals(EmployeeStatusEnum.STAY_DEL.getValue())))
|
||||||
.map(InsuranceArchivesBaseInfoPO::getEmployeeId)
|
// .map(InsuranceArchivesBaseInfoPO::getEmployeeId)
|
||||||
.collect(Collectors.toList());
|
// .collect(Collectors.toList());
|
||||||
queryParam.setEmployeeIds(canAccountIds);
|
// queryParam.setEmployeeIds(canAccountIds);
|
||||||
|
|
||||||
//补缴缴纳列表
|
//补缴缴纳列表
|
||||||
queryParam.setPaymentStatus(PaymentStatusEnum.REPAIR.getValue());
|
queryParam.setPaymentStatus(PaymentStatusEnum.REPAIR.getValue());
|
||||||
|
|
|
||||||
|
|
@ -980,6 +980,17 @@ public class SIArchivesServiceImpl extends Service implements SIArchivesService
|
||||||
baseInfoIdsPartition.forEach(part -> {
|
baseInfoIdsPartition.forEach(part -> {
|
||||||
nowList.addAll(getInsuranceBaseInfoMapper().listByIds(part));
|
nowList.addAll(getInsuranceBaseInfoMapper().listByIds(part));
|
||||||
});
|
});
|
||||||
|
//判断当前被操作人员是否都在对应的个税扣缴义务人下
|
||||||
|
List<TaxAgentEmployeeDTO> taxAgentManageRangeEmployees = getTaxAgentService(user).listTaxAgentAndEmployee((long) user.getUID());
|
||||||
|
|
||||||
|
boolean isNotExist = nowList.stream().anyMatch(te ->
|
||||||
|
taxAgentManageRangeEmployees.stream().noneMatch(p ->
|
||||||
|
p.getEmployeeId() != null && p.getEmployeeId().equals(te.getEmployeeId()) && p.getTaxAgentId().equals(te.getPaymentOrganization())));
|
||||||
|
|
||||||
|
if (isNotExist) {
|
||||||
|
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(116196, "个税扣缴义务人不存在或不在权限范围内,删除失败!"));
|
||||||
|
}
|
||||||
|
|
||||||
//置空社保、公积金、其他福利档案的最后缴纳月信息,并将福利档案基础信息表的状态置为“正在缴纳”
|
//置空社保、公积金、其他福利档案的最后缴纳月信息,并将福利档案基础信息表的状态置为“正在缴纳”
|
||||||
if (nowList.size() > 0) {
|
if (nowList.size() > 0) {
|
||||||
List<Long> socialIds = nowList.stream()
|
List<Long> socialIds = nowList.stream()
|
||||||
|
|
|
||||||
|
|
@ -5,7 +5,6 @@ import com.engine.core.impl.Service;
|
||||||
import com.engine.salary.cache.SalaryCacheKey;
|
import com.engine.salary.cache.SalaryCacheKey;
|
||||||
import com.engine.salary.common.LocalDateRange;
|
import com.engine.salary.common.LocalDateRange;
|
||||||
import com.engine.salary.encrypt.EncryptUtil;
|
import com.engine.salary.encrypt.EncryptUtil;
|
||||||
import com.engine.salary.encrypt.salaryacct.SalaryAcctResultPOEncrypt;
|
|
||||||
import com.engine.salary.entity.datacollection.DataCollectionEmployee;
|
import com.engine.salary.entity.datacollection.DataCollectionEmployee;
|
||||||
import com.engine.salary.entity.datacollection.dto.AttendQuoteFieldListDTO;
|
import com.engine.salary.entity.datacollection.dto.AttendQuoteFieldListDTO;
|
||||||
import com.engine.salary.entity.report.bo.SalaryAcctResultReportBO;
|
import com.engine.salary.entity.report.bo.SalaryAcctResultReportBO;
|
||||||
|
|
@ -864,7 +863,8 @@ public class SalaryAcctResultServiceImpl extends Service implements SalaryAcctRe
|
||||||
if (CollectionUtils.isEmpty(salaryAcctRecordIds) || CollectionUtils.isEmpty(salaryItemIds) ) {
|
if (CollectionUtils.isEmpty(salaryAcctRecordIds) || CollectionUtils.isEmpty(salaryItemIds) ) {
|
||||||
return Collections.emptyList();
|
return Collections.emptyList();
|
||||||
}
|
}
|
||||||
return SalaryAcctResultPOEncrypt.decryptList(getSalaryAcctResultMapper().listSome(SalaryAcctResultPO.builder().salaryAcctRecordIds(salaryAcctRecordIds).salaryItemIds(salaryItemIds).build()));
|
List<SalaryAcctResultPO> list = getSalaryAcctResultMapper().listSome(SalaryAcctResultPO.builder().salaryAcctRecordIds(salaryAcctRecordIds).salaryItemIds(salaryItemIds).build());
|
||||||
|
return encryptUtil.decryptList(list,SalaryAcctResultPO.class);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -15,6 +15,7 @@ import com.engine.salary.exception.SalaryRunTimeException;
|
||||||
import com.engine.salary.mapper.formula.FormulaMapper;
|
import com.engine.salary.mapper.formula.FormulaMapper;
|
||||||
import com.engine.salary.mapper.formula.FormulaVarMapper;
|
import com.engine.salary.mapper.formula.FormulaVarMapper;
|
||||||
import com.engine.salary.service.FormulaRunService;
|
import com.engine.salary.service.FormulaRunService;
|
||||||
|
import com.engine.salary.service.RemoteExcelService;
|
||||||
import com.engine.salary.service.SalaryFormulaService;
|
import com.engine.salary.service.SalaryFormulaService;
|
||||||
import com.engine.salary.util.db.MapperProxyFactory;
|
import com.engine.salary.util.db.MapperProxyFactory;
|
||||||
import com.engine.salary.util.valid.ValidUtil;
|
import com.engine.salary.util.valid.ValidUtil;
|
||||||
|
|
@ -31,6 +32,8 @@ import org.springframework.beans.BeanUtils;
|
||||||
import weaver.hrm.User;
|
import weaver.hrm.User;
|
||||||
|
|
||||||
import java.util.*;
|
import java.util.*;
|
||||||
|
import java.util.regex.Matcher;
|
||||||
|
import java.util.regex.Pattern;
|
||||||
import java.util.stream.Collectors;
|
import java.util.stream.Collectors;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
@ -57,6 +60,10 @@ public class SalaryFormulaServiceImpl extends Service implements SalaryFormulaSe
|
||||||
return (FormulaRunService) ServiceUtil.getService(FormulaRunServiceImpl.class, user);
|
return (FormulaRunService) ServiceUtil.getService(FormulaRunServiceImpl.class, user);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private RemoteExcelService getRemoteExcelService(User user) {
|
||||||
|
return ServiceUtil.getService(RemoteExcelServiceImpl.class, user);
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public List<ExpressFormula> listExpressFormula(Collection<Long> formulaIds) {
|
public List<ExpressFormula> listExpressFormula(Collection<Long> formulaIds) {
|
||||||
formulaIds = formulaIds.stream().filter(id -> id != null && id > 0).collect(Collectors.toList());
|
formulaIds = formulaIds.stream().filter(id -> id != null && id > 0).collect(Collectors.toList());
|
||||||
|
|
@ -113,6 +120,19 @@ public class SalaryFormulaServiceImpl extends Service implements SalaryFormulaSe
|
||||||
throw new SalaryRunTimeException("校验类型异常");
|
throw new SalaryRunTimeException("校验类型异常");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 解析公式中的参数
|
||||||
|
if (ReferenceTypeEnum.parseByValue(param.getReferenceType()) == ReferenceTypeEnum.FORMULA) {
|
||||||
|
List<FormulaVar> parameterList = parseFormulaParameters(param.getFormula(), ReferenceTypeEnum.FORMULA);
|
||||||
|
param.setParameters(parameterList);
|
||||||
|
}else if(ReferenceTypeEnum.parseByValue(param.getReferenceType()) == ReferenceTypeEnum.SQL){
|
||||||
|
List<FormulaVar> parameterList = parseFormulaParameters(param.getFormula(), ReferenceTypeEnum.SQL);
|
||||||
|
param.setParameters(parameterList);
|
||||||
|
}
|
||||||
|
int orderIndex = 0;
|
||||||
|
for(FormulaVar parameter : param.getParameters() ){
|
||||||
|
parameter.setOrderIndex(orderIndex++);
|
||||||
|
}
|
||||||
|
|
||||||
List<FormulaVar> parameters = param.getParameters();
|
List<FormulaVar> parameters = param.getParameters();
|
||||||
//防止参数名和字段名呈现一对多的问题
|
//防止参数名和字段名呈现一对多的问题
|
||||||
if (CollectionUtils.isNotEmpty(parameters)) {
|
if (CollectionUtils.isNotEmpty(parameters)) {
|
||||||
|
|
@ -196,6 +216,7 @@ public class SalaryFormulaServiceImpl extends Service implements SalaryFormulaSe
|
||||||
formulaRunScript = formulaRunScript.replace(po.getFieldName(), po.getFieldId());
|
formulaRunScript = formulaRunScript.replace(po.getFieldName(), po.getFieldId());
|
||||||
}
|
}
|
||||||
formulaPO.setFormulaRunScript(formulaRunScript);
|
formulaPO.setFormulaRunScript(formulaRunScript);
|
||||||
|
|
||||||
getFormulaMapper().insertIgnoreNull(formulaPO);
|
getFormulaMapper().insertIgnoreNull(formulaPO);
|
||||||
|
|
||||||
for (FormulaVar po : parameters) {
|
for (FormulaVar po : parameters) {
|
||||||
|
|
@ -210,6 +231,75 @@ public class SalaryFormulaServiceImpl extends Service implements SalaryFormulaSe
|
||||||
return formulaPO;
|
return formulaPO;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public List<FormulaVar> parseFormulaParameters(String formula, ReferenceTypeEnum referenceTypeEnum){
|
||||||
|
List<FormulaVar> parameters = new ArrayList<>();
|
||||||
|
// 获取公式中所有可选的变量项目
|
||||||
|
Map<String, List<FormulaVar>> allParameters = getRemoteExcelService(user).allFieldList(referenceTypeEnum);
|
||||||
|
List<String> groups = new ArrayList<>(allParameters.keySet());
|
||||||
|
StringBuilder reg =new StringBuilder("(");
|
||||||
|
for(int i =0; i < groups.size(); i++ ){
|
||||||
|
reg.append("\\{"+ groups.get(i) +"\\.");
|
||||||
|
if(i+1 != groups.size()){
|
||||||
|
reg.append("|");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
reg.append(").*?}");
|
||||||
|
// 提取公式中所有的变量
|
||||||
|
Pattern pattern = Pattern.compile(reg.toString());
|
||||||
|
Matcher matcher = pattern.matcher(formula);
|
||||||
|
List<String> vars = new ArrayList<>();
|
||||||
|
while (matcher.find()) {
|
||||||
|
String var = matcher.group(0).replaceAll("\\{", "").replaceAll("}", "");
|
||||||
|
if(StringUtils.isNotBlank(var)){
|
||||||
|
vars.add(var);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// 去重
|
||||||
|
vars = vars.stream().distinct().collect(Collectors.toList());
|
||||||
|
for(String var : vars){
|
||||||
|
String[] split = var.split("\\.");
|
||||||
|
if(split.length==2){
|
||||||
|
List<FormulaVar> formulaVars = allParameters.get(split[0]);
|
||||||
|
if(formulaVars == null){
|
||||||
|
throw new SalaryRunTimeException("保存失败,公式变量"+split[0]+"输入有误!");
|
||||||
|
}
|
||||||
|
Optional<FormulaVar> field = formulaVars.stream().filter(v -> Objects.equals(v.getName(), split[1])).findFirst();
|
||||||
|
if(field.isPresent()){
|
||||||
|
FormulaVar formulaVar = field.get();
|
||||||
|
String fieldName = "{" + split[0] + "." + split[1] +"}";
|
||||||
|
formulaVar.setFieldName(fieldName);
|
||||||
|
parameters.add(formulaVar);
|
||||||
|
}else{
|
||||||
|
throw new SalaryRunTimeException("保存失败,公式变量"+split[0]+split[1]+"输入有误!");
|
||||||
|
}
|
||||||
|
}else if(split.length > 2){
|
||||||
|
// 变量名称中包含.
|
||||||
|
List<FormulaVar> formulaVars = allParameters.get(split[0]);
|
||||||
|
if(formulaVars == null){
|
||||||
|
throw new SalaryRunTimeException("保存失败,公式变量"+split[0]+"输入有误!");
|
||||||
|
}
|
||||||
|
StringBuilder field = new StringBuilder("");
|
||||||
|
for(int i =1; i< split.length; i++){
|
||||||
|
if(i != 1){
|
||||||
|
field.append(".");
|
||||||
|
}
|
||||||
|
field = field.append(split[i]);
|
||||||
|
}
|
||||||
|
String finalField = field.toString();
|
||||||
|
Optional<FormulaVar> optional = formulaVars.stream().filter(v -> Objects.equals(v.getName(), finalField)).findFirst();
|
||||||
|
if(optional.isPresent()){
|
||||||
|
FormulaVar formulaVar = optional.get();
|
||||||
|
String fieldName = "{" + split[0] + "." + field +"}";
|
||||||
|
formulaVar.setFieldName(fieldName);
|
||||||
|
parameters.add(optional.get());
|
||||||
|
}else{
|
||||||
|
throw new SalaryRunTimeException("保存失败,公式变量"+split[0]+split[1]+"输入有误!");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return parameters;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 模拟运行公式
|
* 模拟运行公式
|
||||||
*
|
*
|
||||||
|
|
|
||||||
|
|
@ -850,11 +850,13 @@ public class SalarySysConfServiceImpl extends Service implements SalarySysConfSe
|
||||||
po.setTaxDelayEndowmentInsurance(AESEncryptUtil.closeEncryptSetting(po.getTaxDelayEndowmentInsurance()));
|
po.setTaxDelayEndowmentInsurance(AESEncryptUtil.closeEncryptSetting(po.getTaxDelayEndowmentInsurance()));
|
||||||
po.setOtherDeduction(AESEncryptUtil.closeEncryptSetting(po.getOtherDeduction()));
|
po.setOtherDeduction(AESEncryptUtil.closeEncryptSetting(po.getOtherDeduction()));
|
||||||
po.setDeductionAllowedDonation(AESEncryptUtil.closeEncryptSetting(po.getDeductionAllowedDonation()));
|
po.setDeductionAllowedDonation(AESEncryptUtil.closeEncryptSetting(po.getDeductionAllowedDonation()));
|
||||||
|
po.setPrivatePension(AESEncryptUtil.closeEncryptSetting(po.getPrivatePension()));
|
||||||
} else {
|
} else {
|
||||||
po.setBusinessHealthyInsurance(AESEncryptUtil.encrypt(po.getBusinessHealthyInsurance()));
|
po.setBusinessHealthyInsurance(AESEncryptUtil.encrypt(po.getBusinessHealthyInsurance()));
|
||||||
po.setTaxDelayEndowmentInsurance(AESEncryptUtil.encrypt(po.getTaxDelayEndowmentInsurance()));
|
po.setTaxDelayEndowmentInsurance(AESEncryptUtil.encrypt(po.getTaxDelayEndowmentInsurance()));
|
||||||
po.setOtherDeduction(AESEncryptUtil.encrypt(po.getOtherDeduction()));
|
po.setOtherDeduction(AESEncryptUtil.encrypt(po.getOtherDeduction()));
|
||||||
po.setDeductionAllowedDonation(AESEncryptUtil.encrypt(po.getDeductionAllowedDonation()));
|
po.setDeductionAllowedDonation(AESEncryptUtil.encrypt(po.getDeductionAllowedDonation()));
|
||||||
|
po.setPrivatePension(AESEncryptUtil.encrypt(po.getPrivatePension()));
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
List<List<OtherDeductionPO>> partition = Lists.partition(otherDeductionPos, 50);
|
List<List<OtherDeductionPO>> partition = Lists.partition(otherDeductionPos, 50);
|
||||||
|
|
@ -896,6 +898,7 @@ public class SalarySysConfServiceImpl extends Service implements SalarySysConfSe
|
||||||
po.setAddUpIllnessMedical(AESEncryptUtil.closeEncryptSetting(po.getAddUpIllnessMedical()));
|
po.setAddUpIllnessMedical(AESEncryptUtil.closeEncryptSetting(po.getAddUpIllnessMedical()));
|
||||||
po.setAddUpTaxSavings(AESEncryptUtil.closeEncryptSetting(po.getAddUpTaxSavings()));
|
po.setAddUpTaxSavings(AESEncryptUtil.closeEncryptSetting(po.getAddUpTaxSavings()));
|
||||||
po.setAddUpInfantCare(AESEncryptUtil.closeEncryptSetting(po.getAddUpInfantCare()));
|
po.setAddUpInfantCare(AESEncryptUtil.closeEncryptSetting(po.getAddUpInfantCare()));
|
||||||
|
po.setAddUpPrivatePension(AESEncryptUtil.closeEncryptSetting(po.getAddUpPrivatePension()));
|
||||||
} else {
|
} else {
|
||||||
po.setAddUpIncome(AESEncryptUtil.encrypt(po.getAddUpIncome()));
|
po.setAddUpIncome(AESEncryptUtil.encrypt(po.getAddUpIncome()));
|
||||||
po.setAddUpSubtraction(AESEncryptUtil.encrypt(po.getAddUpSubtraction()));
|
po.setAddUpSubtraction(AESEncryptUtil.encrypt(po.getAddUpSubtraction()));
|
||||||
|
|
@ -914,6 +917,7 @@ public class SalarySysConfServiceImpl extends Service implements SalarySysConfSe
|
||||||
po.setAddUpIllnessMedical(AESEncryptUtil.encrypt(po.getAddUpIllnessMedical()));
|
po.setAddUpIllnessMedical(AESEncryptUtil.encrypt(po.getAddUpIllnessMedical()));
|
||||||
po.setAddUpTaxSavings(AESEncryptUtil.encrypt(po.getAddUpTaxSavings()));
|
po.setAddUpTaxSavings(AESEncryptUtil.encrypt(po.getAddUpTaxSavings()));
|
||||||
po.setAddUpInfantCare(AESEncryptUtil.encrypt(po.getAddUpInfantCare()));
|
po.setAddUpInfantCare(AESEncryptUtil.encrypt(po.getAddUpInfantCare()));
|
||||||
|
po.setAddUpPrivatePension(AESEncryptUtil.encrypt(po.getAddUpPrivatePension()));
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
List<List<AddUpSituation>> partition = Lists.partition(addUpSituations, 50);
|
List<List<AddUpSituation>> partition = Lists.partition(addUpSituations, 50);
|
||||||
|
|
|
||||||
|
|
@ -29,7 +29,7 @@ public class ExcelUtil {
|
||||||
titleFont.setFontHeightInPoints((short) 15);
|
titleFont.setFontHeightInPoints((short) 15);
|
||||||
titleCellStyle.setFont(titleFont);
|
titleCellStyle.setFont(titleFont);
|
||||||
titleCellStyle.setAlignment(HorizontalAlignment.CENTER);
|
titleCellStyle.setAlignment(HorizontalAlignment.CENTER);
|
||||||
titleCellStyle.setFillForegroundColor(IndexedColors.GREEN.getIndex());//背景色
|
titleCellStyle.setFillForegroundColor(IndexedColors.GREY_25_PERCENT.getIndex());//背景色
|
||||||
titleCellStyle.setFillPattern(FillPatternType.SOLID_FOREGROUND);
|
titleCellStyle.setFillPattern(FillPatternType.SOLID_FOREGROUND);
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -78,7 +78,7 @@ public class ExcelUtil {
|
||||||
titleFont.setFontHeightInPoints((short) 15);
|
titleFont.setFontHeightInPoints((short) 15);
|
||||||
titleCellStyle.setFont(titleFont);
|
titleCellStyle.setFont(titleFont);
|
||||||
titleCellStyle.setAlignment(HorizontalAlignment.CENTER);
|
titleCellStyle.setAlignment(HorizontalAlignment.CENTER);
|
||||||
titleCellStyle.setFillForegroundColor(IndexedColors.GREEN.getIndex());//背景色
|
titleCellStyle.setFillForegroundColor(IndexedColors.GREY_25_PERCENT.getIndex());//背景色
|
||||||
titleCellStyle.setFillPattern(FillPatternType.SOLID_FOREGROUND);
|
titleCellStyle.setFillPattern(FillPatternType.SOLID_FOREGROUND);
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -138,7 +138,7 @@ public class ExcelUtil {
|
||||||
titleFont.setFontHeightInPoints((short) 15);
|
titleFont.setFontHeightInPoints((short) 15);
|
||||||
titleCellStyle.setFont(titleFont);
|
titleCellStyle.setFont(titleFont);
|
||||||
titleCellStyle.setAlignment(HorizontalAlignment.CENTER);
|
titleCellStyle.setAlignment(HorizontalAlignment.CENTER);
|
||||||
titleCellStyle.setFillForegroundColor(IndexedColors.GREEN.getIndex());//背景色
|
titleCellStyle.setFillForegroundColor(IndexedColors.GREY_25_PERCENT.getIndex());//背景色
|
||||||
titleCellStyle.setFillPattern(FillPatternType.SOLID_FOREGROUND);
|
titleCellStyle.setFillPattern(FillPatternType.SOLID_FOREGROUND);
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -206,7 +206,7 @@ public class ExcelUtil {
|
||||||
titleFont.setFontHeightInPoints((short) 15);
|
titleFont.setFontHeightInPoints((short) 15);
|
||||||
titleCellStyle.setFont(titleFont);
|
titleCellStyle.setFont(titleFont);
|
||||||
titleCellStyle.setAlignment(HorizontalAlignment.CENTER);
|
titleCellStyle.setAlignment(HorizontalAlignment.CENTER);
|
||||||
titleCellStyle.setFillForegroundColor(IndexedColors.GREEN.getIndex());//背景色
|
titleCellStyle.setFillForegroundColor(IndexedColors.GREY_25_PERCENT.getIndex());//背景色
|
||||||
titleCellStyle.setFillPattern(FillPatternType.SOLID_FOREGROUND);
|
titleCellStyle.setFillPattern(FillPatternType.SOLID_FOREGROUND);
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -28,7 +28,7 @@ public class ExcelUtilPlus {
|
||||||
titleFont.setFontHeightInPoints((short) 15);
|
titleFont.setFontHeightInPoints((short) 15);
|
||||||
titleCellStyle.setFont(titleFont);
|
titleCellStyle.setFont(titleFont);
|
||||||
titleCellStyle.setAlignment(HorizontalAlignment.CENTER);
|
titleCellStyle.setAlignment(HorizontalAlignment.CENTER);
|
||||||
titleCellStyle.setFillForegroundColor(IndexedColors.GREEN.getIndex());//背景色
|
titleCellStyle.setFillForegroundColor(IndexedColors.GREY_25_PERCENT.getIndex());//背景色
|
||||||
titleCellStyle.setFillPattern(FillPatternType.SOLID_FOREGROUND);
|
titleCellStyle.setFillPattern(FillPatternType.SOLID_FOREGROUND);
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -559,12 +559,21 @@ public class SIAccountController {
|
||||||
@Produces(MediaType.APPLICATION_OCTET_STREAM)
|
@Produces(MediaType.APPLICATION_OCTET_STREAM)
|
||||||
public Response exportComparisonWelfareTemplate(@Context HttpServletRequest request, @Context HttpServletResponse response) {
|
public Response exportComparisonWelfareTemplate(@Context HttpServletRequest request, @Context HttpServletResponse response) {
|
||||||
try {
|
try {
|
||||||
InsuranceAcctDetailImportTemplateParam param = new InsuranceAcctDetailImportTemplateParam();
|
InsuranceAccountDetailParam param = new InsuranceAccountDetailParam();
|
||||||
|
|
||||||
// String welfareNames = request.getParameter("welfareNames");
|
String billMonth = request.getParameter("billMonth");
|
||||||
// if (StringUtils.isNotBlank(welfareNames)) {
|
if (StringUtils.isNotBlank(billMonth)) {
|
||||||
// param.setWelfareNames(Arrays.stream(welfareNames.split(",")).map(String::valueOf).collect(Collectors.toList()));
|
param.setBillMonth(billMonth);
|
||||||
// }
|
}
|
||||||
|
String paymentOrganization = request.getParameter("paymentOrganization");
|
||||||
|
if (StringUtils.isNotBlank(paymentOrganization)) {
|
||||||
|
param.setPaymentOrganization(paymentOrganization);
|
||||||
|
}
|
||||||
|
|
||||||
|
String paymentStatus = request.getParameter("paymentStatus");
|
||||||
|
if (StringUtils.isNotBlank(paymentStatus)) {
|
||||||
|
param.setPaymentStatus(Integer.valueOf(paymentStatus));
|
||||||
|
}
|
||||||
|
|
||||||
User user = HrmUserVarify.getUser(request, response);
|
User user = HrmUserVarify.getUser(request, response);
|
||||||
XSSFWorkbook workbook = getService(user).exportComparisonWelfareTemplate(param);
|
XSSFWorkbook workbook = getService(user).exportComparisonWelfareTemplate(param);
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,7 @@
|
||||||
package com.engine.salary.web;
|
package com.engine.salary.web;
|
||||||
|
|
||||||
import com.engine.common.util.ServiceUtil;
|
import com.engine.common.util.ServiceUtil;
|
||||||
|
import com.engine.salary.common.SalaryContext;
|
||||||
import com.engine.salary.component.WeaFormOption;
|
import com.engine.salary.component.WeaFormOption;
|
||||||
import com.engine.salary.entity.salaryitem.dto.SalaryItemFormDTO;
|
import com.engine.salary.entity.salaryitem.dto.SalaryItemFormDTO;
|
||||||
import com.engine.salary.entity.salaryitem.dto.SalaryItemListDTO;
|
import com.engine.salary.entity.salaryitem.dto.SalaryItemListDTO;
|
||||||
|
|
@ -38,6 +39,7 @@ import java.util.Map;
|
||||||
public class SalaryItemController {
|
public class SalaryItemController {
|
||||||
|
|
||||||
private SalaryItemWrapper getSalaryItemWrapper(User user) {
|
private SalaryItemWrapper getSalaryItemWrapper(User user) {
|
||||||
|
SalaryContext.get().setValue("user",user);
|
||||||
return ServiceUtil.getService(SalaryItemWrapper.class, user);
|
return ServiceUtil.getService(SalaryItemWrapper.class, user);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -220,6 +220,9 @@ public class SalaryItemWrapper extends Service {
|
||||||
if (SalaryDataTypeEnum.parseByValue(saveParam.getDataType()) == null) {
|
if (SalaryDataTypeEnum.parseByValue(saveParam.getDataType()) == null) {
|
||||||
throw new SalaryRunTimeException("字段类型异常");
|
throw new SalaryRunTimeException("字段类型异常");
|
||||||
}
|
}
|
||||||
|
if (saveParam.getName().contains("{") || saveParam.getName().contains("}")) {
|
||||||
|
throw new SalaryRunTimeException("薪资项目名称中不得包含大括号");
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue