| 
															
																@@ -30,6 +30,7 @@ 
															 | 
														
													
												
													
														
															| 
															 | 
															
																         a.reimbursement_day as 'reimbursementDay', 
															 | 
															
															 | 
															
																         a.reimbursement_day as 'reimbursementDay', 
															 | 
														
													
												
													
														
															| 
															 | 
															
																         a.reimbursement_amount as 'reimbursementAmount', 
															 | 
															
															 | 
															
																         a.reimbursement_amount as 'reimbursementAmount', 
															 | 
														
													
												
													
														
															| 
															 | 
															
																         a.reimbursement_type as 'reimbursementType', 
															 | 
															
															 | 
															
																         a.reimbursement_type as 'reimbursementType', 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+        a.reimbursement_fsalary as 'reimbursementFsalary', 
															 | 
														
													
												
													
														
															| 
															 | 
															
																         (case when a.reimbursement_type = '1' then '正常报销' when a.reimbursement_type = '2' then '补差' else '' end) as reimbursementTypeStr, 
															 | 
															
															 | 
															
																         (case when a.reimbursement_type = '1' then '正常报销' when a.reimbursement_type = '2' then '补差' else '' end) as reimbursementTypeStr, 
															 | 
														
													
												
													
														
															| 
															 | 
															
																         su.name as 'userName' 
															 | 
															
															 | 
															
																         su.name as 'userName' 
															 | 
														
													
												
													
														
															| 
															 | 
															
																     </sql> 
															 | 
															
															 | 
															
																     </sql> 
															 | 
														
													
												
											
												
													
														
															 | 
															
																@@ -37,7 +38,7 @@ 
															 | 
														
													
												
													
														
															| 
															 | 
															
																         left join sys_user su on su.id = a.user_id 
															 | 
															
															 | 
															
																         left join sys_user su on su.id = a.user_id 
															 | 
														
													
												
													
														
															| 
															 | 
															
																     </sql> 
															 | 
															
															 | 
															
																     </sql> 
															 | 
														
													
												
													
														
															| 
															 | 
															
																     <insert id="insertAccountantReimbursementBusiness"> 
															 | 
															
															 | 
															
																     <insert id="insertAccountantReimbursementBusiness"> 
															 | 
														
													
												
													
														
															| 
															 | 
															
																-        insert into zs_reimbursement_business_accountant_info 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+        insert into zs_reimbursement_business_info 
															 | 
														
													
												
													
														
															| 
															 | 
															
																         ( 
															 | 
															
															 | 
															
																         ( 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                     id, 
															 | 
															
															 | 
															
																                     id, 
															 | 
														
													
												
													
														
															| 
															 | 
															
																             create_by, 
															 | 
															
															 | 
															
																             create_by, 
															 | 
														
													
												
											
												
													
														
															 | 
															
																@@ -53,7 +54,9 @@ 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                 reimbursement_day, 
															 | 
															
															 | 
															
																                 reimbursement_day, 
															 | 
														
													
												
													
														
															| 
															 | 
															
																             </if> 
															 | 
															
															 | 
															
																             </if> 
															 | 
														
													
												
													
														
															| 
															 | 
															
																             reimbursement_amount, 
															 | 
															
															 | 
															
																             reimbursement_amount, 
															 | 
														
													
												
													
														
															| 
															 | 
															
																-            reimbursement_type 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+            reimbursement_type, 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+            reimbursement_fsalary, 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+            office_type 
															 | 
														
													
												
													
														
															| 
															 | 
															
																         ) 
															 | 
															
															 | 
															
																         ) 
															 | 
														
													
												
													
														
															| 
															 | 
															
																         values 
															 | 
															
															 | 
															
																         values 
															 | 
														
													
												
													
														
															| 
															 | 
															
																         ( 
															 | 
															
															 | 
															
																         ( 
															 | 
														
													
												
											
												
													
														
															 | 
															
																@@ -71,7 +74,9 @@ 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                 #{reimbursementDay}, 
															 | 
															
															 | 
															
																                 #{reimbursementDay}, 
															 | 
														
													
												
													
														
															| 
															 | 
															
																             </if> 
															 | 
															
															 | 
															
																             </if> 
															 | 
														
													
												
													
														
															| 
															 | 
															
																             #{reimbursementAmount}, 
															 | 
															
															 | 
															
																             #{reimbursementAmount}, 
															 | 
														
													
												
													
														
															| 
															 | 
															
																-            #{reimbursementType} 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+            #{reimbursementType}, 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+            #{reimbursementFsalary}, 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+            #{officeType} 
															 | 
														
													
												
													
														
															| 
															 | 
															
																         ) 
															 | 
															
															 | 
															
																         ) 
															 | 
														
													
												
													
														
															| 
															 | 
															
																     </insert> 
															 | 
															
															 | 
															
																     </insert> 
															 | 
														
													
												
													
														
															| 
															 | 
															
																  
															 | 
															
															 | 
															
																  
															 | 
														
													
												
											
												
													
														
															 | 
															
																@@ -79,8 +84,10 @@ 
															 | 
														
													
												
													
														
															| 
															 | 
															
																             resultType="com.jeeplus.test.reimbursementAccountant.domain.dto.AccountantReimbursementBusinessTwoDTO"> 
															 | 
															
															 | 
															
																             resultType="com.jeeplus.test.reimbursementAccountant.domain.dto.AccountantReimbursementBusinessTwoDTO"> 
															 | 
														
													
												
													
														
															| 
															 | 
															
																         select 
															 | 
															
															 | 
															
																         select 
															 | 
														
													
												
													
														
															| 
															 | 
															
																         <include refid="joinZsReimbursementBusinessAccountantInfoColumns"/> 
															 | 
															
															 | 
															
																         <include refid="joinZsReimbursementBusinessAccountantInfoColumns"/> 
															 | 
														
													
												
													
														
															| 
															 | 
															
																-        from zs_reimbursement_business_accountant_info a 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+        ,(select name from sys_office where id = (select substring_index(substring_index(parent_ids,',',3 ),',',-1 ) from sys_office where id = su.office_id)) as 'userOfficeName' 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+        from zs_reimbursement_business_info a 
															 | 
														
													
												
													
														
															| 
															 | 
															
																         <include refid="reimbursementUserJoinColumns"/> 
															 | 
															
															 | 
															
																         <include refid="reimbursementUserJoinColumns"/> 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+        left join sys_office so on so.id = su.office_id 
															 | 
														
													
												
													
														
															| 
															 | 
															
																         <where> 
															 | 
															
															 | 
															
																         <where> 
															 | 
														
													
												
													
														
															| 
															 | 
															
																             a.del_flag = 0 and (a.business_code_id='' or a.business_code_id=null) 
															 | 
															
															 | 
															
																             a.del_flag = 0 and (a.business_code_id='' or a.business_code_id=null) 
															 | 
														
													
												
													
														
															| 
															 | 
															
																             <if test="accountantReimbursementBusiness.year != null and accountantReimbursementBusiness.year != ''"> 
															 | 
															
															 | 
															
																             <if test="accountantReimbursementBusiness.year != null and accountantReimbursementBusiness.year != ''"> 
															 | 
														
													
												
											
												
													
														
															 | 
															
																@@ -89,6 +96,7 @@ 
															 | 
														
													
												
													
														
															| 
															 | 
															
																             <if test="accountantReimbursementBusiness.userId != null and accountantReimbursementBusiness.userId != ''"> 
															 | 
															
															 | 
															
																             <if test="accountantReimbursementBusiness.userId != null and accountantReimbursementBusiness.userId != ''"> 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                 and a.user_id = #{accountantReimbursementBusiness.userId} 
															 | 
															
															 | 
															
																                 and a.user_id = #{accountantReimbursementBusiness.userId} 
															 | 
														
													
												
													
														
															| 
															 | 
															
																             </if> 
															 | 
															
															 | 
															
																             </if> 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+            and a.office_type = #{accountantReimbursementBusiness.officeType} 
															 | 
														
													
												
													
														
															| 
															 | 
															
																         </where> 
															 | 
															
															 | 
															
																         </where> 
															 | 
														
													
												
													
														
															| 
															 | 
															
																         order by a.update_date desc,a.year desc, a.user_id asc 
															 | 
															
															 | 
															
																         order by a.update_date desc,a.year desc, a.user_id asc 
															 | 
														
													
												
													
														
															| 
															 | 
															
																     </select> 
															 | 
															
															 | 
															
																     </select> 
															 |