Browse Source

解决查询库区仓容为0查不出来

lfy 2 weeks ago
parent
commit
7ee0edd8e2

+ 3 - 3
delivery-module-core/delivery-module-core-biz/src/main/resources/mapper/dwxx/DwxxMapper.xml

@@ -81,7 +81,7 @@
81
                 and ck.xzqhdm like #{pageReqVO.areaCode}
81
                 and ck.xzqhdm like #{pageReqVO.areaCode}
82
             </if>
82
             </if>
83
             <if test="pageReqVO.kqStart!=null and pageReqVO.kqEnd!=null ">
83
             <if test="pageReqVO.kqStart!=null and pageReqVO.kqEnd!=null ">
84
-                and t1.sjcrNum between #{pageReqVO.kqStart} and #{pageReqVO.kqEnd}
84
+                and IFNULL(t1.sjcrNum, 0)between #{pageReqVO.kqStart} and #{pageReqVO.kqEnd}
85
             </if>
85
             </if>
86
             <if test="pageReqVO.kqStart!=null  and pageReqVO.kqEnd==null ">
86
             <if test="pageReqVO.kqStart!=null  and pageReqVO.kqEnd==null ">
87
                 and t1.sjcrNum <![CDATA[>=]]>  #{pageReqVO.kqStart}
87
                 and t1.sjcrNum <![CDATA[>=]]>  #{pageReqVO.kqStart}
@@ -162,7 +162,7 @@
162
                 </otherwise>
162
                 </otherwise>
163
             </choose>
163
             </choose>
164
             <if test="pageReqVO.kqStart!=null  and pageReqVO.kqEnd!=null">
164
             <if test="pageReqVO.kqStart!=null  and pageReqVO.kqEnd!=null">
165
-                and t1.sjcrNum between #{pageReqVO.kqStart} and #{pageReqVO.kqEnd}
165
+                and IFNULL(t1.sjcrNum, 0) between #{pageReqVO.kqStart} and #{pageReqVO.kqEnd}
166
             </if>
166
             </if>
167
             <if test="pageReqVO.kqStart!=null  and pageReqVO.kqEnd==null">
167
             <if test="pageReqVO.kqStart!=null  and pageReqVO.kqEnd==null">
168
                 and t1.sjcrNum <![CDATA[>=]]>  #{pageReqVO.kqStart}
168
                 and t1.sjcrNum <![CDATA[>=]]>  #{pageReqVO.kqStart}
@@ -280,7 +280,7 @@
280
                 </otherwise>
280
                 </otherwise>
281
             </choose>
281
             </choose>
282
             <if test="pageReqVO.kqStart!=null and pageReqVO.kqEnd!=null">
282
             <if test="pageReqVO.kqStart!=null and pageReqVO.kqEnd!=null">
283
-                and t1.sjcrNum between #{pageReqVO.kqStart} and #{pageReqVO.kqEnd}
283
+                and IFNULL(t1.sjcrNum, 0) between #{pageReqVO.kqStart} and #{pageReqVO.kqEnd}
284
             </if>
284
             </if>
285
             <if test="pageReqVO.kqStart!=null and pageReqVO.kqEnd==null ">
285
             <if test="pageReqVO.kqStart!=null and pageReqVO.kqEnd==null ">
286
                 and t1.sjcrNum <![CDATA[>=]]>  #{pageReqVO.kqStart}
286
                 and t1.sjcrNum <![CDATA[>=]]>  #{pageReqVO.kqStart}