|
|
@@ -1003,8 +1003,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
) sp_latest ON sp_latest.business_code = o.order_code AND sp_latest.rn = 1
|
|
|
LEFT JOIN fs_course_play_source_config csc ON csc.appid = sp_latest.app_id
|
|
|
<where>
|
|
|
- <if test="maps.coursePlaySourceConfigId != null">
|
|
|
- and csc.id = #{maps.coursePlaySourceConfigId}
|
|
|
+ <if test="maps.appId != null and maps.appId != ''">
|
|
|
+ and csc.appid = #{maps.appId}
|
|
|
</if>
|
|
|
<if test="maps.orderCodes != null and maps.orderCodes.size > 0">
|
|
|
and o.order_code in
|
|
|
@@ -1159,7 +1159,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<if test="maps.erpAccount != null and maps.erpAccount != ''">
|
|
|
LEFT JOIN fs_store_order_df df on df.order_id==o.id
|
|
|
</if>
|
|
|
- <if test="maps.coursePlaySourceConfigId != null">
|
|
|
+ <if test="maps.appId != null and maps.appId != ''">
|
|
|
LEFT JOIN (
|
|
|
SELECT
|
|
|
sp.*,
|
|
|
@@ -1169,8 +1169,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
LEFT JOIN fs_course_play_source_config csc ON csc.appid = sp_latest.app_id
|
|
|
</if>
|
|
|
<where>
|
|
|
- <if test="maps.coursePlaySourceConfigId != null">
|
|
|
- and csc.id = #{maps.coursePlaySourceConfigId}
|
|
|
+ <if test="maps.appId != null and maps.appId != ''">
|
|
|
+ and csc.appid = #{maps.appId}
|
|
|
</if>
|
|
|
<if test="maps.orderCodes != null and maps.orderCodes.size > 0">
|
|
|
and o.order_code in
|
|
|
@@ -1301,7 +1301,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
left join fs_store_order_item_scrm oi on o.id = oi.order_id
|
|
|
left join fs_store_product_scrm fsp on fsp.product_id = oi.product_id
|
|
|
</if>
|
|
|
- <if test="maps.coursePlaySourceConfigId != null">
|
|
|
+ <if test="maps.appId != null and maps.appId != ''">
|
|
|
LEFT JOIN (
|
|
|
SELECT
|
|
|
sp.*,
|
|
|
@@ -1312,8 +1312,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
LEFT JOIN fs_course_play_source_config csc ON csc.appid = sp_latest.app_id
|
|
|
</if>
|
|
|
<where>
|
|
|
- <if test="maps.coursePlaySourceConfigId != null">
|
|
|
- and csc.id = #{maps.coursePlaySourceConfigId}
|
|
|
+ <if test="maps.appId != null and maps.appId != ''">
|
|
|
+ and csc.appid = #{maps.appId}
|
|
|
</if>
|
|
|
<if test="maps.orderCodes != null and maps.orderCodes.size > 0">
|
|
|
and o.order_code in
|
|
|
@@ -1424,6 +1424,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<if test="maps.erpAccount == '未分拣'">
|
|
|
and ( df.login_account is null or df.login_account like '')
|
|
|
</if>
|
|
|
+ <if test="maps.appId != null and maps.appId != ''">
|
|
|
+ and csc.appid = #{maps.appId}
|
|
|
+ </if>
|
|
|
|
|
|
</where>
|
|
|
${maps.params.dataScope}
|
|
|
@@ -1442,7 +1445,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
LEFT JOIN fs_user us ON us.user_id=o.user_id
|
|
|
LEFT JOIN company_user cu on cu.user_id=o.company_user_id
|
|
|
LEFT JOIN fs_store_order_df df on df.order_id=o.id
|
|
|
- <if test="maps.coursePlaySourceConfigId != null">
|
|
|
+ <if test="maps.appId != null and maps.appId != ''">
|
|
|
LEFT JOIN (
|
|
|
SELECT
|
|
|
sp.*,
|
|
|
@@ -1453,8 +1456,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
LEFT JOIN fs_course_play_source_config csc ON csc.appid = sp_latest.app_id
|
|
|
</if>
|
|
|
<where>
|
|
|
- <if test="maps.coursePlaySourceConfigId != null">
|
|
|
- and csc.id = #{maps.coursePlaySourceConfigId}
|
|
|
+ <if test="maps.appId != null and maps.appId != ''">
|
|
|
+ and csc.appid = #{maps.appId}
|
|
|
</if>
|
|
|
<if test="maps.orderCodes != null and maps.orderCodes.size > 0">
|
|
|
and o.order_code in
|
|
|
@@ -1593,8 +1596,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
) sp_latest ON sp_latest.business_code = o.order_code AND sp_latest.rn = 1
|
|
|
LEFT JOIN fs_course_play_source_config csc ON csc.appid = sp_latest.app_id
|
|
|
<where>
|
|
|
- <if test="maps.coursePlaySourceConfigId != null">
|
|
|
- and csc.id = #{maps.coursePlaySourceConfigId}
|
|
|
+ <if test="maps.appId != null and maps.appId != ''">
|
|
|
+ and csc.appid = #{maps.appId}
|
|
|
</if>
|
|
|
<if test="maps.orderCodes != null and maps.orderCodes.size > 0">
|
|
|
and o.order_code in
|
|
|
@@ -1742,7 +1745,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
left join fs_store_order_item_scrm oi on o.id = oi.order_id
|
|
|
left join fs_store_product_scrm fsp on fsp.product_id = oi.product_id
|
|
|
</if>
|
|
|
- <if test="maps.coursePlaySourceConfigId != null">
|
|
|
+ <if test="maps.appId != null and maps.appId != ''">
|
|
|
LEFT JOIN (
|
|
|
SELECT
|
|
|
sp.*,
|
|
|
@@ -1754,8 +1757,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
</if>
|
|
|
|
|
|
<where>
|
|
|
- <if test="maps.coursePlaySourceConfigId != null">
|
|
|
- and csc.id = #{maps.coursePlaySourceConfigId}
|
|
|
+ <if test="maps.appId != null and map.appId != ''">
|
|
|
+ and csc.appid = #{maps.appId}
|
|
|
</if>
|
|
|
<if test="maps.orderCode != null and maps.orderCode !=''">
|
|
|
and o.order_code like CONCAT('%',#{maps.orderCode},'%')
|
|
|
@@ -1852,6 +1855,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<if test="maps.erpPhoneNumber != null and maps.erpPhoneNumber != ''">
|
|
|
and so.erp_phone like concat(#{maps.erpPhoneNumber},'%')
|
|
|
</if>
|
|
|
+ <if test="maps.appId != null and maps.appId != ''">
|
|
|
+ and csc.appid = #{maps.appId}
|
|
|
+ </if>
|
|
|
</where>
|
|
|
${maps.params.dataScope}
|
|
|
<if test="maps.productName != null and maps.productName != '' ">
|