Browse Source

Revert "公司级实体类变更"

[user3] 3 years atrás
parent
commit
850c5e4703

+ 12 - 12
src/main/resources/mappings/modules/ruralprojectrecords/RuralProjectRecordsDao.xml

@@ -2255,12 +2255,12 @@
 			a.del_flag=0
 		    and a.status = 5
 			and a.office_id in(select id  from sys_office where id = #{officeId} or parent_ids like concat('%',#{officeId},'%'))
-		    <if test="grade != null and grade != ''">
+		    <if test="grade == '1'.toString() or grade == '2'.toString()">
 				and a.submit_money = #{grade}
 				and a.create_date >= #{beginDate}
 				and a.create_date &lt;= #{endDate}
 			</if>
-			<if test="recordState != null and recordState != ''">
+			<if test="recordState == '5'.toString() ">
 				and a.record_state = 5
 				and a.over_record_status = 0
 				and prr.status = 5
@@ -2268,7 +2268,7 @@
 				and prr.accomplish_date >= #{beginDate}
 				and prr.accomplish_date &lt;= #{endDate}
 			</if>
-			<if test="reportedState != null and reportedState != ''">
+			<if test="reportedState == '5'.toString() ">
 				and a.reported_state = 5
 				and a.over_due_status = 0
 				and rprr.report_status = 5
@@ -2416,12 +2416,12 @@
 			a.del_flag=0
 			and a.status = 5
 			and a.office_id in(select id  from sys_office where id = #{officeId} or parent_ids like concat('%',#{officeId},'%'))
-			<if test="grade != null and grade != ''">
+			<if test="grade == '1'.toString() or grade == '2'.toString()">
 				and a.submit_money = #{grade}
 				and a.create_date >= #{beginDate}
 				and a.create_date &lt;= #{endDate}
 			</if>
-			<if test="recordState != null and recordState != ''">
+			<if test="recordState == '5'.toString() ">
 				and a.record_state = 5
 				and a.over_record_status = 0
 				and prr.status = 5
@@ -2429,7 +2429,7 @@
 				and prr.accomplish_date >= #{beginDate}
 				and prr.accomplish_date &lt;= #{endDate}
 			</if>
-			<if test="reportedState != null and reportedState != ''">
+			<if test="reportedState == '5'.toString() ">
 				and a.reported_state = 5
 				and a.over_due_status = 0
 				and rprr.report_status = 5
@@ -2907,12 +2907,12 @@
 			and a.status = 5
 			and a.office_id in(select id  from sys_office where id = #{statementCompanyComprehensiveInfo.officeId} or parent_ids like concat('%',#{statementCompanyComprehensiveInfo.officeId},'%'))
 		    and a.create_by = #{statementCompanyComprehensiveInfo.userId}
-			<if test="grade != null and grade != ''">
+			<if test="grade == '1'.toString() or grade == '2'.toString() ">
 				and a.submit_money = #{grade}
 				and a.create_date >= #{beginDate}
 				and a.create_date &lt;= #{endDate}
 			</if>
-			<if test="recordState != null and recordState != ''">
+			<if test="recordState == '5'.toString() ">
 				and a.record_state = 5
 				and a.over_record_status = 0
 				and prr.status = 5
@@ -2920,7 +2920,7 @@
 				and prr.accomplish_date >= #{beginDate}
 				and prr.accomplish_date &lt;= #{endDate}
 			</if>
-			<if test="reportedState != null and reportedState != ''">
+			<if test="reportedState == '5'.toString() ">
 				and a.reported_state = 5
 				and a.over_due_status = 0
 				and rprr.report_status = 5
@@ -3069,12 +3069,12 @@
 			and a.status = 5
 			and a.office_id in(select id  from sys_office where id = #{statementCompanyComprehensiveInfo.officeId} or parent_ids like concat('%',#{statementCompanyComprehensiveInfo.officeId},'%'))
 			and a.create_by = #{statementCompanyComprehensiveInfo.userId}
-			<if test="grade != null and grade != ''">
+			<if test="grade == '1'.toString() or grade == '2'.toString() ">
 				and a.submit_money = #{grade}
 				and a.create_date >= #{beginDate}
 				and a.create_date &lt;= #{endDate}
 			</if>
-			<if test="recordState != null and recordState != ''">
+			<if test="recordState == '5'.toString() ">
 				and a.record_state = 5
 				and a.over_record_status = 0
 				and prr.status = 5
@@ -3082,7 +3082,7 @@
 				and prr.accomplish_date >= #{beginDate}
 				and prr.accomplish_date &lt;= #{endDate}
 			</if>
-			<if test="reportedState != null and reportedState != ''">
+			<if test="reportedState == '5'.toString() ">
 				and a.reported_state = 5
 				and a.over_due_status = 0
 				and rprr.report_status = 5

+ 16 - 16
src/main/resources/mappings/modules/workcontractinfo/WorkContractInfoDao.xml

@@ -1516,7 +1516,7 @@
 			and a.office_id in(select id  from sys_office where id = #{officeIdd} or parent_ids like concat('%',#{officeIdd},'%'))
 
 			<choose>
-				<when test="contractRecordState != null and contractRecordState != ''">
+				<when test="contractRecordState == '5'.toString() ">
 					and a.contract_record_state = 5
 					and a.over_due_status = 0
 					and wcr.accomplish_date >= #{beginDate}
@@ -1609,7 +1609,7 @@
 			and a.office_id in(select id  from sys_office where id = #{officeIdd} or parent_ids like concat('%',#{officeIdd},'%'))
 
 			<choose>
-				<when test="contractRecordState != null and contractRecordState != ''">
+				<when test="contractRecordState == '5'.toString() ">
 					and a.contract_record_state = 5
 					and a.over_due_status = 0
 					and wcr.accomplish_date >= #{beginDate}
@@ -1751,10 +1751,10 @@
 		a.describe_content AS "describeContent",
 		o.name as "createUserOfficeName"
 		FROM statement_data_info sdi
-		<if test="statementCompanyComprehensiveInfo.field3 != null and statementCompanyComprehensiveInfo.field3 != ''">
+		<if test="statementCompanyComprehensiveInfo.field3 == '5'.toString() ">
 			left join work_contract_info a on a.id = sdi.field1
 		</if>
-		<if test="statementCompanyComprehensiveInfo.field4 != null and statementCompanyComprehensiveInfo.field4 != ''">
+		<if test="statementCompanyComprehensiveInfo.field4 == '5'.toString() ">
 			left join work_contract_info a on a.id = sdi.field2
 		</if>
 		<include refid="workContractInfoJoins"/>
@@ -1769,11 +1769,11 @@
 			and a.office_id in(select id  from sys_office where id = #{statementCompanyComprehensiveInfo.officeId} or parent_ids like concat('%',#{statementCompanyComprehensiveInfo.officeId},'%'))
 			and a.over_due_status = 1
 
-			<if test="statementCompanyComprehensiveInfo.field3 != null and statementCompanyComprehensiveInfo.field3 != ''">
+			<if test="statementCompanyComprehensiveInfo.field3 == '5'.toString() ">
 				and a.contract_record_state != 7
 			</if>
 
-			<if test="statementCompanyComprehensiveInfo.field4 != null and statementCompanyComprehensiveInfo.field4 != ''">
+			<if test="statementCompanyComprehensiveInfo.field4 == '5'.toString() ">
 				and a.contract_record_state = 7
 				and wcr.accomplish_date >= #{beginDate}
 				and wcr.accomplish_date &lt;= #{endDate}
@@ -1858,10 +1858,10 @@
 			and big_date_type = #{bigDateType}
 			and small_date_type = #{smallDateType}
 			and office_id = #{officeId}
-			<if test="field3 != null and field3 != ''">
+			<if test="field3 == '5'.toString() ">
 				and field1 IS NOT NULL and field1 != ''
 			</if>
-			<if test="field4 != null and field4 != ''">
+			<if test="field4 == '5'.toString() ">
 				and field2 IS NOT NULL and field2 != ''
 			</if>
 		</where>
@@ -1946,7 +1946,7 @@
 			and a.create_by = #{statementCompanyComprehensiveInfo.userId}
 
 			<choose>
-				<when test="contractRecordState != null and contractRecordState != ''">
+				<when test="contractRecordState == '5'.toString() ">
 					and a.contract_record_state = 5
 					and a.over_due_status = 0
 					and wcr.accomplish_date >= #{beginDate}
@@ -2040,7 +2040,7 @@
 			and a.create_by = #{statementCompanyComprehensiveInfo.userId}
 
 			<choose>
-				<when test="contractRecordState != null and contractRecordState != ''">
+				<when test="contractRecordState == '5'.toString() ">
 					and a.contract_record_state = 5
 					and a.over_due_status = 0
 					and wcr.accomplish_date >= #{beginDate}
@@ -2182,10 +2182,10 @@
 		a.describe_content AS "describeContent",
 		o.name as "createUserOfficeName"
 		FROM statement_office_data_info sodi
-		<if test="statementCompanyComprehensiveInfo.field3 != null and statementCompanyComprehensiveInfo.field3 != ''">
+		<if test="statementCompanyComprehensiveInfo.field3 == '5'.toString() ">
 			left join work_contract_info a on a.id = sodi.field1
 		</if>
-		<if test="statementCompanyComprehensiveInfo.field4 != null and statementCompanyComprehensiveInfo.field4 != ''">
+		<if test="statementCompanyComprehensiveInfo.field4 == '5'.toString() ">
 			left join work_contract_info a on a.id = sodi.field2
 		</if>
 		<include refid="workContractInfoJoins"/>
@@ -2201,11 +2201,11 @@
 			and a.office_id in(select id  from sys_office where id = #{officeIdd} or parent_ids like concat('%',#{officeIdd},'%'))
 			and a.over_due_status = 1
 
-			<if test="statementCompanyComprehensiveInfo.field3 != null and statementCompanyComprehensiveInfo.field3 != ''">
+			<if test="statementCompanyComprehensiveInfo.field3 == '5'.toString() ">
 				and a.contract_record_state != 7
 			</if>
 
-			<if test="statementCompanyComprehensiveInfo.field4 != null and statementCompanyComprehensiveInfo.field4 != ''">
+			<if test="statementCompanyComprehensiveInfo.field4 == '5'.toString() ">
 				and a.contract_record_state = 7
 				and wcr.accomplish_date >= #{beginDate}
 				and wcr.accomplish_date &lt;= #{endDate}
@@ -2291,10 +2291,10 @@
 			and small_date_type = #{smallDateType}
 			and office_id = #{officeId}
 			and user_id = #{userId}
-			<if test="field3 != null and field3 != ''">
+			<if test="field3 == '5'.toString() ">
 				and field1 IS NOT NULL and field1 != ''
 			</if>
-			<if test="field4 != null and field4 != ''">
+			<if test="field4 == '5'.toString() ">
 				and field2 IS NOT NULL and field2 != ''
 			</if>
 		</where>

+ 8 - 8
src/main/resources/mappings/modules/workinvoice/WorkInvoiceDao.xml

@@ -1681,11 +1681,11 @@
 			a.del_flag=0
 			and a.invoice_state = 5
 			and a.office_id in(select id  from sys_office where id = #{officeIdd} or parent_ids like concat('%',#{officeIdd},'%'))
-			<if test="newlyAdded != null and newlyAdded != ''">
+			<if test="newlyAdded == '5'.toString() ">
 				and a.invoice_date >= #{beginDate}
 				and a.invoice_date &lt;= #{endDate}
 			</if>
-			<if test="collectionThisMonth != null and collectionThisMonth != ''">
+			<if test="collectionThisMonth == '5'.toString() ">
 				and wid.del_flag=0
 				and a.receipt_money = '1'
 				and a.receipt_money_date >= #{beginDate}
@@ -1832,11 +1832,11 @@
 			a.del_flag=0
 			and a.invoice_state = 5
 			and a.office_id in(select id  from sys_office where id = #{officeIdd} or parent_ids like concat('%',#{officeIdd},'%'))
-			<if test="newlyAdded != null and newlyAdded != ''">
+			<if test="newlyAdded == '5'.toString() ">
 				and a.invoice_date >= #{beginDate}
 				and a.invoice_date &lt;= #{endDate}
 			</if>
-			<if test="collectionThisMonth != null and collectionThisMonth != ''">
+			<if test="collectionThisMonth == '5'.toString() ">
 				and wid.del_flag=0
 				and a.receipt_money = '1'
 				and a.receipt_money_date >= #{beginDate}
@@ -1985,11 +1985,11 @@
 			and a.invoice_state = 5
 			and a.office_id in(select id  from sys_office where id = #{officeIdd} or parent_ids like concat('%',#{officeIdd},'%'))
 			and a.create_by = #{statementCompanyComprehensiveInfo.userId}
-			<if test="newlyAdded != null and newlyAdded != ''">
+			<if test="newlyAdded == '5'.toString() ">
 				and a.invoice_date >= #{beginDate}
 				and a.invoice_date &lt;= #{endDate}
 			</if>
-			<if test="collectionThisMonth != null and collectionThisMonth != ''">
+			<if test="collectionThisMonth == '5'.toString() ">
 				and wid.del_flag=0
 				and a.receipt_money = '1'
 				and a.receipt_money_date >= #{beginDate}
@@ -2143,11 +2143,11 @@
 			and a.invoice_state = 5
 			and a.office_id in(select id  from sys_office where id = #{officeIdd} or parent_ids like concat('%',#{officeIdd},'%'))
 			and a.create_by = #{statementCompanyComprehensiveInfo.userId}
-			<if test="newlyAdded != null and newlyAdded != ''">
+			<if test="newlyAdded == '5'.toString() ">
 				and a.invoice_date >= #{beginDate}
 				and a.invoice_date &lt;= #{endDate}
 			</if>
-			<if test="collectionThisMonth != null and collectionThisMonth != ''">
+			<if test="collectionThisMonth == '5'.toString() ">
 				and wid.del_flag=0
 				and a.receipt_money = '1'
 				and a.receipt_money_date >= #{beginDate}