|
@@ -9,6 +9,17 @@
|
|
WHERE
|
|
WHERE
|
|
delete_flag = '0'
|
|
delete_flag = '0'
|
|
AND comp_id = #{compId}
|
|
AND comp_id = #{compId}
|
|
|
|
+ <if test="searchType != null and searchType != ''">
|
|
|
|
+ <if test="searchType == 2">
|
|
|
|
+ AND collection_ing_payable-collection_ed_payable>0
|
|
|
|
+ </if>
|
|
|
|
+ <if test="searchType == 3">
|
|
|
|
+ AND collection_ing_payable-collection_ed_payable=0
|
|
|
|
+ </if>
|
|
|
|
+ </if>
|
|
|
|
+ <if test="contractNo != null and contractNo != ''">
|
|
|
|
+ AND contract_no = #{contractNo}
|
|
|
|
+ </if>
|
|
<if test="businessKeys != null and businessKeys.size > 0">
|
|
<if test="businessKeys != null and businessKeys.size > 0">
|
|
and(
|
|
and(
|
|
<foreach collection="businessKeys" item="businessValue" open="(" close=")" separator="or">
|
|
<foreach collection="businessKeys" item="businessValue" open="(" close=")" separator="or">
|
|
@@ -19,39 +30,13 @@
|
|
<if test="statusSet != null and statusSet.size > 0">
|
|
<if test="statusSet != null and statusSet.size > 0">
|
|
or (
|
|
or (
|
|
<foreach collection="statusSet" item="statusId" separator="or" open="(" close=")">
|
|
<foreach collection="statusSet" item="statusId" separator="or" open="(" close=")">
|
|
- t1.status_flag =
|
|
|
|
|
|
+ status_flag =
|
|
<if test="statusId != null">
|
|
<if test="statusId != null">
|
|
#{statusId}
|
|
#{statusId}
|
|
</if>
|
|
</if>
|
|
</foreach>
|
|
</foreach>
|
|
)
|
|
)
|
|
</if>
|
|
</if>
|
|
- <if test="searchType != null and searchType != ''">
|
|
|
|
- <if test="searchType == 1 and roleFlag==1" >
|
|
|
|
- AND status_flag = '1'
|
|
|
|
- OR status_flag = '8'
|
|
|
|
- OR status_flag = '11'
|
|
|
|
- </if>
|
|
|
|
- <if test="searchType == 1 and roleFlag==2" >
|
|
|
|
- AND status_flag = '2'
|
|
|
|
- </if>
|
|
|
|
- <if test="searchType == 1 and roleFlag==3" >
|
|
|
|
- AND status_flag = '7'
|
|
|
|
- </if>
|
|
|
|
- <if test="searchType == 1 and roleFlag==4" >
|
|
|
|
- AND status_flag = '4'
|
|
|
|
- OR status_flag = '9'
|
|
|
|
- </if>
|
|
|
|
- <if test="searchType == 2">
|
|
|
|
- AND collection_ing_payable-collection_ed_payable>0
|
|
|
|
- </if>
|
|
|
|
- <if test="searchType == 3">
|
|
|
|
- AND collection_ing_payable-collection_ed_payable=0
|
|
|
|
- </if>
|
|
|
|
- </if>
|
|
|
|
- <if test="contractNo != null and contractNo != ''">
|
|
|
|
- AND contract_no = #{contractNo}
|
|
|
|
- </if>
|
|
|
|
</select>
|
|
</select>
|
|
<!-- 获得销售出库统计列表 -->
|
|
<!-- 获得销售出库统计列表 -->
|
|
<select id="getListByCondition" parameterType="Map"
|
|
<select id="getListByCondition" parameterType="Map"
|
|
@@ -90,6 +75,17 @@
|
|
WHERE
|
|
WHERE
|
|
delete_flag = '0'
|
|
delete_flag = '0'
|
|
AND comp_id = #{compId}
|
|
AND comp_id = #{compId}
|
|
|
|
+ <if test="searchType != null and searchType != ''">
|
|
|
|
+ <if test="searchType == 2">
|
|
|
|
+ AND collection_ing_payable-collection_ed_payable>0
|
|
|
|
+ </if>
|
|
|
|
+ <if test="searchType == 3">
|
|
|
|
+ AND collection_ing_payable-collection_ed_payable=0
|
|
|
|
+ </if>
|
|
|
|
+ </if>
|
|
|
|
+ <if test="contractNo != null and contractNo != ''">
|
|
|
|
+ AND contract_no = #{contractNo}
|
|
|
|
+ </if>
|
|
<if test="businessKeys != null and businessKeys.size > 0">
|
|
<if test="businessKeys != null and businessKeys.size > 0">
|
|
and(
|
|
and(
|
|
<foreach collection="businessKeys" item="businessValue" open="(" close=")" separator="or">
|
|
<foreach collection="businessKeys" item="businessValue" open="(" close=")" separator="or">
|
|
@@ -100,39 +96,13 @@
|
|
<if test="statusSet != null and statusSet.size > 0">
|
|
<if test="statusSet != null and statusSet.size > 0">
|
|
or (
|
|
or (
|
|
<foreach collection="statusSet" item="statusId" separator="or" open="(" close=")">
|
|
<foreach collection="statusSet" item="statusId" separator="or" open="(" close=")">
|
|
- t1.status_flag =
|
|
|
|
|
|
+ status_flag =
|
|
<if test="statusId != null">
|
|
<if test="statusId != null">
|
|
#{statusId}
|
|
#{statusId}
|
|
</if>
|
|
</if>
|
|
</foreach>
|
|
</foreach>
|
|
)
|
|
)
|
|
</if>
|
|
</if>
|
|
- <if test="searchType != null and searchType != ''">
|
|
|
|
- <if test="searchType == 1 and roleFlag==1" >
|
|
|
|
- AND status_flag = '1'
|
|
|
|
- OR status_flag = '8'
|
|
|
|
- OR status_flag = '11'
|
|
|
|
- </if>
|
|
|
|
- <if test="searchType == 1 and roleFlag==2" >
|
|
|
|
- AND status_flag = '2'
|
|
|
|
- </if>
|
|
|
|
- <if test="searchType == 1 and roleFlag==3" >
|
|
|
|
- AND status_flag = '7'
|
|
|
|
- </if>
|
|
|
|
- <if test="searchType == 1 and roleFlag==4" >
|
|
|
|
- AND status_flag = '4'
|
|
|
|
- OR status_flag = '9'
|
|
|
|
- </if>
|
|
|
|
- <if test="searchType == 2">
|
|
|
|
- AND collection_ing_payable-collection_ed_payable>0
|
|
|
|
- </if>
|
|
|
|
- <if test="searchType == 3">
|
|
|
|
- AND collection_ing_payable-collection_ed_payable=0
|
|
|
|
- </if>
|
|
|
|
- </if>
|
|
|
|
- <if test="contractNo != null and contractNo != ''">
|
|
|
|
- AND contract_no = #{contractNo}
|
|
|
|
- </if>
|
|
|
|
ORDER BY update_date DESC
|
|
ORDER BY update_date DESC
|
|
<if test="currentPage != null and currentPage != ''">
|
|
<if test="currentPage != null and currentPage != ''">
|
|
LIMIT ${startRecord}, ${pageSize}
|
|
LIMIT ${startRecord}, ${pageSize}
|