Bläddra i källkod

修改付款列表付款详情接口sql(状态查询条件)

LiFei 3 år sedan
förälder
incheckning
e01209a812

+ 13 - 11
happy-cloud-wisdom/happy-cloud-wisdom-biz/src/main/java/org/jeecg/modules/hlwpayment/mapper/xml/HlwPaymentDetailMapper.xml

@@ -414,17 +414,19 @@
 			<if test="hlwPaymentDetail.paymentId != null">
 				and a.payment_id = #{hlwPaymentDetail.paymentId}
 			</if>
-			<choose>
-				<when test="hlwPaymentDetail.status =='-1'.toString()">
-					and a.status is null
-				</when>
-				<when test="hlwPaymentDetail.status =='99'.toString()">
-					and (a.status = 1 or a.status = 2)
-				</when>
-				<otherwise>
-					and a.status = #{hlwPaymentDetail.status}
-				</otherwise>
-			</choose>
+			<if test="hlwPaymentDetail.status!=null">
+				<choose>
+					<when test="hlwPaymentDetail.status =='-1'.toString()">
+						and a.status is null
+					</when>
+					<when test="hlwPaymentDetail.status =='99'.toString()">
+						and (a.status = 1 or a.status = 2)
+					</when>
+					<otherwise>
+						and a.status = #{hlwPaymentDetail.status}
+					</otherwise>
+				</choose>
+			</if>
 			<if test="hlwPaymentDetail.userCode != null and hlwPaymentDetail.userCode != ''">
 				and hu.user_code = #{hlwPaymentDetail.userCode}
 			</if>

+ 13 - 11
happy-cloud-wisdom/happy-cloud-wisdom-biz/src/main/java/org/jeecg/modules/hlwpayment/mapper/xml/HlwPaymentMapper.xml

@@ -422,17 +422,19 @@
 			<if test="hlwPayment.companyName != null and hlwPayment.companyName !=''">
 				and com.company_name like concat(concat('%',#{hlwPayment.companyName}),'%')
 			</if>
-			<choose>
-				<when test="hlwPayment.status =='-1'.toString()">
-					and a.status is null
-				</when>
-				<when test="hlwPayment.status =='99'.toString()">
-					and (a.status = 1 or a.status = 2)
-				</when>
-				<otherwise>
-					and a.status = #{hlwPayment.status}
-				</otherwise>
-			</choose>
+			<if test="hlwPayment.status!=null">
+				<choose>
+					<when test="hlwPayment.status =='-1'.toString()">
+						and a.status is null
+					</when>
+					<when test="hlwPayment.status =='99'.toString()">
+						and (a.status = 1 or a.status = 2)
+					</when>
+					<otherwise>
+						and a.status = #{hlwPayment.status}
+					</otherwise>
+				</choose>
+			</if>
 			<if test="hlwPayment.invoiceCategoryName != null and hlwPayment.invoiceCategoryName !=''">
 				and hi.invoice_category_name like concat('%',#{hlwPayment.invoiceCategoryName},'%')
 			</if>