|
@@ -27,22 +27,25 @@
|
|
|
and w.status_flag = '3'
|
|
|
</if>
|
|
|
<if test="pcFlag == 0">
|
|
|
- and wbi.person_phone = ${phone}
|
|
|
+ and wbi.person_phone = #{phone}
|
|
|
</if>
|
|
|
</if>
|
|
|
<if test="startDate != null">
|
|
|
- AND (DATE_FORMAT(in_out_date,"%Y%m%d") >=
|
|
|
+ AND (DATE_FORMAT(w.in_out_date,"%Y%m%d") >=
|
|
|
DATE_FORMAT(#{startDate},"%Y%m%d"))
|
|
|
</if>
|
|
|
<if test="endDate != null">
|
|
|
- AND (DATE_FORMAT(in_out_date,"%Y%m%d") <=
|
|
|
+ AND (DATE_FORMAT(w.in_out_date,"%Y%m%d") <=
|
|
|
DATE_FORMAT(#{endDate},"%Y%m%d"))
|
|
|
</if>
|
|
|
<if test="baseId != null and baseId != ''">
|
|
|
- AND base_id = #{baseId}
|
|
|
+ AND w.base_id = #{baseId}
|
|
|
+ </if>
|
|
|
+ <if test="warehouseName != null and warehouseName != ''">
|
|
|
+ and w.warehouse_name = #{warehouseName}
|
|
|
</if>
|
|
|
<if test="positionId != null and positionId != ''">
|
|
|
- AND position_id = #{positionId}
|
|
|
+ AND w.position_id = #{positionId}
|
|
|
</if>
|
|
|
<if test="statusFlag != null and statusFlag != ''">
|
|
|
AND w.status_flag = #{statusFlag}
|
|
@@ -117,28 +120,31 @@
|
|
|
</if>
|
|
|
</if>
|
|
|
<if test="pcFlag != null and pcFlag != ''">
|
|
|
- <if test="pcFlag == 1">
|
|
|
- AND w.base_id = #{baseId}
|
|
|
- and w.position_id = #{positionId}
|
|
|
- and w.status_flag = '3'
|
|
|
- </if>
|
|
|
- <if test="pcFlag == 0">
|
|
|
- and wbi.person_phone = ${phone}
|
|
|
- </if>
|
|
|
+ <if test="pcFlag == 1">
|
|
|
+ AND w.base_id = #{baseId}
|
|
|
+ and w.position_id = #{positionId}
|
|
|
+ and w.status_flag = '3'
|
|
|
+ </if>
|
|
|
+ <if test="pcFlag == 0">
|
|
|
+ and wbi.person_phone = #{phone}
|
|
|
+ </if>
|
|
|
</if>
|
|
|
<if test="startDate != null">
|
|
|
- AND (DATE_FORMAT(in_out_date,"%Y%m%d") >=
|
|
|
+ AND (DATE_FORMAT(w.in_out_date,"%Y%m%d") >=
|
|
|
DATE_FORMAT(#{startDate},"%Y%m%d"))
|
|
|
</if>
|
|
|
<if test="endDate != null">
|
|
|
- AND (DATE_FORMAT(in_out_date,"%Y%m%d") <=
|
|
|
+ AND (DATE_FORMAT(w.in_out_date,"%Y%m%d") <=
|
|
|
DATE_FORMAT(#{endDate},"%Y%m%d"))
|
|
|
</if>
|
|
|
<if test="baseId != null and baseId != ''">
|
|
|
- AND base_id = #{baseId}
|
|
|
+ AND w.base_id = #{baseId}
|
|
|
+ </if>
|
|
|
+ <if test="warehouseName != null and warehouseName != ''">
|
|
|
+ and w.warehouse_name = #{warehouseName}
|
|
|
</if>
|
|
|
<if test="positionId != null and positionId != ''">
|
|
|
- AND position_id = #{positionId}
|
|
|
+ AND w.position_id = #{positionId}
|
|
|
</if>
|
|
|
<if test="statusFlag != null and statusFlag != ''">
|
|
|
AND w.status_flag = #{statusFlag}
|