Merge branch 'release/3.0.2.2504.01' into custom/易迪希医药科技(嘉兴)有限公司

This commit is contained in:
钱涛 2025-10-22 10:12:32 +08:00
commit 414dfd3132
2 changed files with 14 additions and 6 deletions

View File

@ -6,5 +6,5 @@ and employee_id not in
where tax_agent_id =id and delete_type = 0)
update hrsa_tax_agent_emp set delete_type = 3
update hrsa_tax_agent_emp set delete_type = 3 where delete_type = 0
where tax_agent_id=id and delete_type = 0 and employee_id not in (select employee_id from hrsa_salary_archive where tax_agent_id =id and delete_type = 0)

View File

@ -18,7 +18,8 @@ update hrsa_salary_archive set delete_type=3 where tax_agent_id=扣缴义务人
二、删除停薪员工档案
update hrsa_salary_archive set delete_type=3 where run_status in ('STOP_FROM_PENDING','STOP_FROM_SUSPEND')
update hrsa_salary_archive set delete_type=3 where delete_type=0 and run_status in ('STOP_FROM_PENDING','STOP_FROM_SUSPEND')
update hrsa_salary_archive_item set delete_type=3 where delete_type=0
二、删除停薪员工社保档案
update hrsa_insurance_base_info set delete_type=3 where run_status in ('4','5')
@ -28,10 +29,10 @@ update hrsa_insurance_base_info set delete_type=3 where run_status in ('4','5')
--删除社保福利档案
update hrsa_insurance_base_info set delete_type=3 WHERE employee_id = ? and payment_organization =?
update hrsa_social_archives set delete_type=3 WHERE employee_id = ? and payment_organization =?
update hrsa_fund_archives set delete_type=3 WHERE employee_id = ? and payment_organization =?
update hrsa_other_archives set delete_type=3 WHERE employee_id = ? and payment_organization =?
update hrsa_insurance_base_info set delete_type=3 WHERE delete_type=0 and employee_id = ? and payment_organization =?
update hrsa_social_archives set delete_type=3 WHERE delete_type=0 and employee_id = ? and payment_organization =?
update hrsa_fund_archives set delete_type=3 WHERE delete_type=0 and employee_id = ? and payment_organization =?
update hrsa_other_archives set delete_type=3 WHERE delete_type=0 and employee_id = ? and payment_organization =?
-- 删除薪资档案
update hrsa_salary_archive set delete_type=3 where employee_id = ? and tax_agent_id=?
@ -45,4 +46,11 @@ update hrsa_other_archives set delete_type=3;
update hrsa_tax_agent_emp set delete_type=3;
-- 删除核算记录和工资单信息
update hrsa_salary_acct_record set delete_type=3 where delete_type=0;
update hrsa_salary_acct_emp set delete_type=3 where delete_type=0;
update hrsa_salary_acct_result set delete_type=3 where delete_type=0;
update hrsa_salary_send set delete_type=3 where delete_type=0;
update hrsa_salary_send_info set delete_type=3 where delete_type=0;