给报表的接口增加商品类别的查询参数
This commit is contained in:
@@ -339,6 +339,12 @@
|
||||
</foreach>
|
||||
) or dh.sub_type='采购退货' or dh.sub_type='零售' or dh.sub_type='其它')
|
||||
</if>
|
||||
<if test="categoryList.size()>0">
|
||||
and m.category_id in
|
||||
<foreach collection="categoryList" item="item" index="index" separator="," open="(" close=")">
|
||||
#{item}
|
||||
</foreach>
|
||||
</if>
|
||||
<if test="forceFlag">
|
||||
and dh.status = '1'
|
||||
</if>
|
||||
@@ -410,6 +416,12 @@
|
||||
</foreach>
|
||||
) or dh.sub_type='采购退货' or dh.sub_type='零售' or dh.sub_type='其它')
|
||||
</if>
|
||||
<if test="categoryList.size()>0">
|
||||
and m.category_id in
|
||||
<foreach collection="categoryList" item="item" index="index" separator="," open="(" close=")">
|
||||
#{item}
|
||||
</foreach>
|
||||
</if>
|
||||
<if test="forceFlag">
|
||||
and dh.status = '1'
|
||||
</if>
|
||||
@@ -472,6 +484,12 @@
|
||||
</foreach>
|
||||
) or dh.sub_type='采购退货' or dh.sub_type='零售' or dh.sub_type='其它')
|
||||
</if>
|
||||
<if test="categoryList.size()>0">
|
||||
and m.category_id in
|
||||
<foreach collection="categoryList" item="item" index="index" separator="," open="(" close=")">
|
||||
#{item}
|
||||
</foreach>
|
||||
</if>
|
||||
<if test="forceFlag">
|
||||
and dh.status = '1'
|
||||
</if>
|
||||
@@ -553,6 +571,12 @@
|
||||
or m.color like #{bindKey} or m.mfrs like #{bindKey} or m.brand like #{bindKey} or m.other_field1 like #{bindKey}
|
||||
or m.other_field2 like #{bindKey} or m.other_field3 like #{bindKey})
|
||||
</if>
|
||||
<if test="categoryList.size()>0">
|
||||
and m.category_id in
|
||||
<foreach collection="categoryList" item="item" index="index" separator="," open="(" close=")">
|
||||
#{item}
|
||||
</foreach>
|
||||
</if>
|
||||
<if test="forceFlag">
|
||||
and (dh.status = '1' or dh.status = '2' or dh.status = '3')
|
||||
</if>
|
||||
@@ -624,6 +648,12 @@
|
||||
or m.color like #{bindKey} or m.mfrs like #{bindKey} or m.brand like #{bindKey} or m.other_field1 like #{bindKey}
|
||||
or m.other_field2 like #{bindKey} or m.other_field3 like #{bindKey})
|
||||
</if>
|
||||
<if test="categoryList.size()>0">
|
||||
and m.category_id in
|
||||
<foreach collection="categoryList" item="item" index="index" separator="," open="(" close=")">
|
||||
#{item}
|
||||
</foreach>
|
||||
</if>
|
||||
<if test="forceFlag">
|
||||
and (dh.status = '1' or dh.status = '2' or dh.status = '3')
|
||||
</if>
|
||||
@@ -688,6 +718,12 @@
|
||||
or m.color like #{bindKey} or m.mfrs like #{bindKey} or m.brand like #{bindKey} or m.other_field1 like #{bindKey}
|
||||
or m.other_field2 like #{bindKey} or m.other_field3 like #{bindKey})
|
||||
</if>
|
||||
<if test="categoryList.size()>0">
|
||||
and m.category_id in
|
||||
<foreach collection="categoryList" item="item" index="index" separator="," open="(" close=")">
|
||||
#{item}
|
||||
</foreach>
|
||||
</if>
|
||||
<if test="forceFlag">
|
||||
and (dh.status = '1' or dh.status = '2' or dh.status = '3')
|
||||
</if>
|
||||
@@ -735,6 +771,12 @@
|
||||
</foreach>
|
||||
)
|
||||
</if>
|
||||
<if test="categoryList.size()>0">
|
||||
and m.category_id in
|
||||
<foreach collection="categoryList" item="item" index="index" separator="," open="(" close=")">
|
||||
#{item}
|
||||
</foreach>
|
||||
</if>
|
||||
<if test="forceFlag">
|
||||
and dh.status = '1'
|
||||
</if>
|
||||
@@ -794,6 +836,12 @@
|
||||
</foreach>
|
||||
)
|
||||
</if>
|
||||
<if test="categoryList.size()>0">
|
||||
and m.category_id in
|
||||
<foreach collection="categoryList" item="item" index="index" separator="," open="(" close=")">
|
||||
#{item}
|
||||
</foreach>
|
||||
</if>
|
||||
<if test="forceFlag">
|
||||
and dh.status = '1'
|
||||
</if>
|
||||
@@ -846,6 +894,12 @@
|
||||
</foreach>
|
||||
)
|
||||
</if>
|
||||
<if test="categoryList.size()>0">
|
||||
and m.category_id in
|
||||
<foreach collection="categoryList" item="item" index="index" separator="," open="(" close=")">
|
||||
#{item}
|
||||
</foreach>
|
||||
</if>
|
||||
<if test="forceFlag">
|
||||
and dh.status = '1'
|
||||
</if>
|
||||
|
||||
@@ -419,6 +419,12 @@
|
||||
left join jsh_depot_head dh on di.header_id=dh.id and ifnull(dh.delete_flag,'0') !='1'
|
||||
left join jsh_unit u on m.unit_id=u.id and ifnull(u.delete_Flag,'0') !='1'
|
||||
where 1=1
|
||||
<if test="categoryList.size()>0">
|
||||
and m.category_id in
|
||||
<foreach collection="categoryList" item="item" index="index" separator="," open="(" close=")">
|
||||
#{item}
|
||||
</foreach>
|
||||
</if>
|
||||
<if test="materialParam != null and materialParam !=''">
|
||||
<bind name="bindKey" value="'%'+materialParam+'%'"/>
|
||||
and (me.bar_code like #{bindKey} or m.name like #{bindKey} or m.mnemonic like #{bindKey} or m.standard like #{bindKey} or m.model like #{bindKey}
|
||||
@@ -481,6 +487,12 @@
|
||||
left join jsh_material_extend me on me.id=di.material_extend_id and ifnull(me.delete_Flag,'0') !='1'
|
||||
left join jsh_depot_head dh on di.header_id=dh.id and ifnull(dh.delete_flag,'0') !='1'
|
||||
where 1=1
|
||||
<if test="categoryList.size()>0">
|
||||
and m.category_id in
|
||||
<foreach collection="categoryList" item="item" index="index" separator="," open="(" close=")">
|
||||
#{item}
|
||||
</foreach>
|
||||
</if>
|
||||
<if test="materialParam != null and materialParam !=''">
|
||||
<bind name="bindKey" value="'%'+materialParam+'%'"/>
|
||||
and (me.bar_code like #{bindKey} or m.name like #{bindKey} or m.mnemonic like #{bindKey} or m.standard like #{bindKey} or m.model like #{bindKey}
|
||||
@@ -618,6 +630,12 @@
|
||||
and dh.type=#{type} and dh.sub_type=#{subType}
|
||||
and dh.oper_time >= #{beginTime}
|
||||
and dh.oper_time <= #{endTime}
|
||||
<if test="categoryList.size()>0">
|
||||
and m.category_id in
|
||||
<foreach collection="categoryList" item="item" index="index" separator="," open="(" close=")">
|
||||
#{item}
|
||||
</foreach>
|
||||
</if>
|
||||
<if test="materialParam != null and materialParam !=''">
|
||||
<bind name="bindKey" value="'%'+materialParam+'%'"/>
|
||||
and (me.bar_code like #{bindKey} or m.name like #{bindKey} or m.mnemonic like #{bindKey} or m.standard like #{bindKey} or m.model like #{bindKey})
|
||||
@@ -895,6 +913,12 @@
|
||||
#{item}
|
||||
</foreach>
|
||||
</if>
|
||||
<if test="categoryList.size()>0">
|
||||
and m.category_id in
|
||||
<foreach collection="categoryList" item="item" index="index" separator="," open="(" close=")">
|
||||
#{item}
|
||||
</foreach>
|
||||
</if>
|
||||
order by depotName asc
|
||||
<if test="offset != null and rows != null">
|
||||
limit #{offset},#{rows}
|
||||
@@ -928,6 +952,12 @@
|
||||
#{item}
|
||||
</foreach>
|
||||
</if>
|
||||
<if test="categoryList.size()>0">
|
||||
and m.category_id in
|
||||
<foreach collection="categoryList" item="item" index="index" separator="," open="(" close=")">
|
||||
#{item}
|
||||
</foreach>
|
||||
</if>
|
||||
) tb
|
||||
</select>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user