left join t_salary_standard s on s.id = a.SALARY_FORM_ID
left join hrms.t_settle_domain d on d.id = a.SETTLE_DEPART_ID
left join hrms.t_customer_info i on i.id = d.CUSTOMER_ID
left join t_salary_employee e on e.id = a.EMP_ID
left join t_salary_account_item relaySalary on relaySalary.SALARY_ACCOUNT_ID = a.id and relaySalary.JAVA_FIED_NAME='relaySalary'
left join t_salary_account_item exemptionPersionTax on exemptionPersionTax.SALARY_ACCOUNT_ID = a.id and exemptionPersionTax.JAVA_FIED_NAME='exemptionPersionTax'
left join t_salary_account_item costReduction on costReduction.SALARY_ACCOUNT_ID = a.id and costReduction.JAVA_FIED_NAME='costReduction'
...
...
@@ -256,8 +264,7 @@
left join t_salary_account_item annualBonusTax on annualBonusTax.SALARY_ACCOUNT_ID = a.id and annualBonusTax.JAVA_FIED_NAME='annualBonusTax'
left join t_salary_account_item annualBonus on annualBonus.SALARY_ACCOUNT_ID = a.id and annualBonus.JAVA_FIED_NAME='annualBonus'
where
a.SETTLEMENT_MONTH = #{lastMonth} and a.DELETE_FLAG = 0 and a.SALARY_TYPE != '7' and a.SALARY_TYPE != '3'
and s.DELETE_FLAG = 0
a.SETTLEMENT_MONTH = #{lastMonth} and a.DELETE_FLAG = 0 and a.FORM_TYPE != '7' and a.FORM_TYPE != '3' and s.DELETE_FLAG = 0
GROUP BY a.EMP_IDCARD,a.INVOICE_TITLE,a.SETTLEMENT_MONTH)