|
@@ -1354,7 +1354,7 @@
|
|
|
order by p.create_time desc
|
|
|
</select>
|
|
|
|
|
|
- <select id="listPackageSettleList2" resultType="com.qunzhixinxi.hnqz.admin.entity.input.WmScorePackageSettleOutput">
|
|
|
+ <!--<select id="listPackageSettleList2" resultType="com.qunzhixinxi.hnqz.admin.entity.input.WmScorePackageSettleOutput">
|
|
|
SELECT p.id, d. NAME packageEntName, p.score_package_name, p.create_time, p.package_status,
|
|
|
p.package_finish_status,
|
|
|
p.settle_status,p.invoice_category, p.settle_amount ,p.package_type1, p.score, wk.ytj, wk.ysh, wk.dsh
|
|
@@ -1408,7 +1408,7 @@
|
|
|
</if>
|
|
|
ORDER BY
|
|
|
p.create_time DESC
|
|
|
- </select>
|
|
|
+ </select>-->
|
|
|
|
|
|
<!-- 积分包结算(分页) -->
|
|
|
<select id="listPackageSettleList" resultType="com.qunzhixinxi.hnqz.admin.entity.input.WmScorePackageSettleOutput">
|
|
@@ -1461,6 +1461,63 @@
|
|
|
p.create_time DESC
|
|
|
</select>
|
|
|
|
|
|
+ <!-- 积分包结算(分页) -->
|
|
|
+ <select id="listPackageSettleList2" resultType="com.qunzhixinxi.hnqz.admin.entity.input.WmScorePackageSettleOutput">
|
|
|
+ SELECT distinct
|
|
|
+ p.id,
|
|
|
+ d.name packageEntName,
|
|
|
+ p.score_package_name,
|
|
|
+ p.create_time,
|
|
|
+ p.package_status,
|
|
|
+ p.package_finish_status,
|
|
|
+ p.settle_status,
|
|
|
+ p.invoice_category,
|
|
|
+ p.settle_amount ,
|
|
|
+ p.package_type1,
|
|
|
+ p.score,
|
|
|
+ p.package_type2,
|
|
|
+ p.sub_type,
|
|
|
+ p.source_type,
|
|
|
+ p.oms_order_sn
|
|
|
+ FROM wm_score_package p left join sys_dept d on p.send_package_dept_id = d.dept_id
|
|
|
+ left join wm_score_package_status ps on p.id = ps.package_id
|
|
|
+ left join sys_user su on ps.user_id = su.user_id
|
|
|
+ <where>
|
|
|
+ <if test="query.sendPackageDeptId != null and query.sendPackageDeptId != ''">
|
|
|
+ AND p.send_package_dept_id= #{query.sendPackageDeptId}
|
|
|
+ </if>
|
|
|
+ <if test="query.scorePackageName != null and query.scorePackageName != ''">
|
|
|
+ AND p.score_package_name like CONCAT('%',#{query.scorePackageName},'%')
|
|
|
+ </if>
|
|
|
+ <if test="query.belongDate != null and query.belongDate != ''">
|
|
|
+ AND p.belong_date= #{query.belongDate}
|
|
|
+ </if>
|
|
|
+ <if test="query.typeid != null and query.typeid != ''">
|
|
|
+ AND p.typeid= #{query.typeid}
|
|
|
+ </if>
|
|
|
+ <if test="query.packageType1 != null and query.packageType1 != ''">
|
|
|
+ AND p.package_type1= #{query.packageType1}
|
|
|
+ </if>
|
|
|
+ <if test="query.packageFinishStatus != null and query.packageFinishStatus != ''">
|
|
|
+ AND p.package_finish_status= #{query.packageFinishStatus}
|
|
|
+ </if>
|
|
|
+ <if test="query.packageType2 != null and query.packageType2 != ''">
|
|
|
+ AND p.package_type2= #{query.packageType2}
|
|
|
+ </if>
|
|
|
+ <if test="query.settleFlag != null and query.settleFlag != ''">
|
|
|
+ AND p.settle_flag= #{query.settleFlag}
|
|
|
+ </if>
|
|
|
+ <if test="query.subType != null and query.subType != ''">
|
|
|
+ AND p.sub_type= #{query.subType}
|
|
|
+ </if>
|
|
|
+ <if test="query.userNames != null">
|
|
|
+ AND su.realname like CONCAT('%',#{query.userNames},'%')
|
|
|
+ </if>
|
|
|
+ </where>
|
|
|
+ ORDER BY
|
|
|
+ p.create_time DESC
|
|
|
+ </select>
|
|
|
+
|
|
|
<!-- 积分包结算列表 -->
|
|
|
<select id="listAllPackageSettle" resultType="com.qunzhixinxi.hnqz.admin.entity.input.WmScorePackageSettleOutput">
|
|
|
SELECT p.id, d.name packageEntName, p.score_package_name, p.create_time, p.package_status,
|
|
@@ -1497,6 +1554,63 @@
|
|
|
p.create_time DESC
|
|
|
</select>
|
|
|
|
|
|
+ <!-- 积分包结算 -->
|
|
|
+ <select id="listAllPackageSettle2" resultType="com.qunzhixinxi.hnqz.admin.entity.input.WmScorePackageSettleOutput">
|
|
|
+ SELECT distinct
|
|
|
+ p.id,
|
|
|
+ d.name packageEntName,
|
|
|
+ p.score_package_name,
|
|
|
+ p.create_time,
|
|
|
+ p.package_status,
|
|
|
+ p.package_finish_status,
|
|
|
+ p.settle_status,
|
|
|
+ p.invoice_category,
|
|
|
+ p.settle_amount ,
|
|
|
+ p.package_type1,
|
|
|
+ p.score,
|
|
|
+ p.package_type2,
|
|
|
+ p.sub_type,
|
|
|
+ p.source_type,
|
|
|
+ p.oms_order_sn
|
|
|
+ FROM wm_score_package p left join sys_dept d on p.send_package_dept_id = d.dept_id
|
|
|
+ left join wm_score_package_status ps on p.id = ps.package_id
|
|
|
+ left join sys_user su on ps.user_id = su.user_id
|
|
|
+ <where>
|
|
|
+ <if test="query.sendPackageDeptId != null and query.sendPackageDeptId != ''">
|
|
|
+ AND p.send_package_dept_id= #{query.sendPackageDeptId}
|
|
|
+ </if>
|
|
|
+ <if test="query.scorePackageName != null and query.scorePackageName != ''">
|
|
|
+ AND p.score_package_name like CONCAT('%',#{query.scorePackageName},'%')
|
|
|
+ </if>
|
|
|
+ <if test="query.belongDate != null and query.belongDate != ''">
|
|
|
+ AND p.belong_date= #{query.belongDate}
|
|
|
+ </if>
|
|
|
+ <if test="query.typeid != null and query.typeid != ''">
|
|
|
+ AND p.typeid= #{query.typeid}
|
|
|
+ </if>
|
|
|
+ <if test="query.packageType1 != null and query.packageType1 != ''">
|
|
|
+ AND p.package_type1= #{query.packageType1}
|
|
|
+ </if>
|
|
|
+ <if test="query.packageFinishStatus != null and query.packageFinishStatus != ''">
|
|
|
+ AND p.package_finish_status= #{query.packageFinishStatus}
|
|
|
+ </if>
|
|
|
+ <if test="query.packageType2 != null and query.packageType2 != ''">
|
|
|
+ AND p.package_type2= #{query.packageType2}
|
|
|
+ </if>
|
|
|
+ <if test="query.settleFlag != null and query.settleFlag != ''">
|
|
|
+ AND p.settle_flag= #{query.settleFlag}
|
|
|
+ </if>
|
|
|
+ <if test="query.subType != null and query.subType != ''">
|
|
|
+ AND p.sub_type= #{query.subType}
|
|
|
+ </if>
|
|
|
+ <if test="query.userNames != null">
|
|
|
+ AND su.realname like CONCAT('%',#{query.userNames},'%')
|
|
|
+ </if>
|
|
|
+ </where>
|
|
|
+ ORDER BY
|
|
|
+ p.create_time DESC
|
|
|
+ </select>
|
|
|
+
|
|
|
<!-- 积分包列表查询 -->
|
|
|
<select id="listScorePackage" resultType="com.qunzhixinxi.hnqz.admin.entity.WmScorePackage">
|
|
|
SELECT p.*
|