|
@@ -407,6 +407,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
cgu.official_status_num,
|
|
cgu.official_status_num,
|
|
|
u.user_account,
|
|
u.user_account,
|
|
|
u.user_id,
|
|
u.user_id,
|
|
|
|
|
+ u.company_name,
|
|
|
cgu.`status`,
|
|
cgu.`status`,
|
|
|
u.realname,
|
|
u.realname,
|
|
|
og.goods_id,
|
|
og.goods_id,
|
|
@@ -453,7 +454,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
ueg.exam_number,
|
|
ueg.exam_number,
|
|
|
ueg.do_number,
|
|
ueg.do_number,
|
|
|
ueg.expend_number,
|
|
ueg.expend_number,
|
|
|
- ueg.expend_before
|
|
|
|
|
|
|
+ ueg.expend_before,
|
|
|
|
|
+ up.`status` as profile_status,
|
|
|
|
|
+ cet.education_name
|
|
|
FROM
|
|
FROM
|
|
|
class_grade_user cgu
|
|
class_grade_user cgu
|
|
|
LEFT JOIN class_grade cg ON cgu.grade_id = cg.grade_id
|
|
LEFT JOIN class_grade cg ON cgu.grade_id = cg.grade_id
|
|
@@ -463,8 +466,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
LEFT JOIN major m ON g.major_id = m.id
|
|
LEFT JOIN major m ON g.major_id = m.id
|
|
|
LEFT JOIN course_business cb ON g.business_id = cb.id
|
|
LEFT JOIN course_business cb ON g.business_id = cb.id
|
|
|
LEFT JOIN course_project_type cpt ON g.project_id = cpt.id
|
|
LEFT JOIN course_project_type cpt ON g.project_id = cpt.id
|
|
|
|
|
+ LEFT JOIN course_education_type cet ON g.education_type_id = cet.id
|
|
|
LEFT JOIN user_wx_follow uwf ON u.union_id = uwf.union_id
|
|
LEFT JOIN user_wx_follow uwf ON u.union_id = uwf.union_id
|
|
|
LEFT JOIN user_exam_goods ueg ON ueg.order_goods_id = og.order_goods_id
|
|
LEFT JOIN user_exam_goods ueg ON ueg.order_goods_id = og.order_goods_id
|
|
|
|
|
+ LEFT JOIN user_profile up on cgu.order_goods_id = up.order_goods_id and up.type_status=1 and up.current_status = 1
|
|
|
where 1=1 and cgu.`status` = 1
|
|
where 1=1 and cgu.`status` = 1
|
|
|
<if test="sevenCode != null and sevenCode !='' ">
|
|
<if test="sevenCode != null and sevenCode !='' ">
|
|
|
AND cg.seven_code = #{sevenCode}
|
|
AND cg.seven_code = #{sevenCode}
|
|
@@ -490,12 +495,21 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<if test="studyCountMore != null and studyCountMore == 0 ">
|
|
<if test="studyCountMore != null and studyCountMore == 0 ">
|
|
|
AND og.study_count = 0
|
|
AND og.study_count = 0
|
|
|
</if>
|
|
</if>
|
|
|
|
|
+ <if test="periodStatus != null ">
|
|
|
|
|
+ AND cgu.period_status = #{periodStatus}
|
|
|
|
|
+ </if>
|
|
|
<if test="officialStatus != null and officialStatus == 1 ">
|
|
<if test="officialStatus != null and officialStatus == 1 ">
|
|
|
AND cgu.official_status = 1
|
|
AND cgu.official_status = 1
|
|
|
</if>
|
|
</if>
|
|
|
<if test="officialStatus != null and officialStatus == 0 ">
|
|
<if test="officialStatus != null and officialStatus == 0 ">
|
|
|
AND (cgu.official_status is NULL or cgu.official_status=0)
|
|
AND (cgu.official_status is NULL or cgu.official_status=0)
|
|
|
</if>
|
|
</if>
|
|
|
|
|
+ <if test="periodPlush != null and periodPlush == 1 ">
|
|
|
|
|
+ AND cgu.period_plush = 1
|
|
|
|
|
+ </if>
|
|
|
|
|
+ <if test="periodPlush != null and periodPlush == 0 ">
|
|
|
|
|
+ AND (cgu.period_plush is NULL or cgu.period_plush=0)
|
|
|
|
|
+ </if>
|
|
|
<if test="realname != null and realname != ''">
|
|
<if test="realname != null and realname != ''">
|
|
|
AND u.realname like concat('%', #{realname}, '%')
|
|
AND u.realname like concat('%', #{realname}, '%')
|
|
|
</if>
|
|
</if>
|
|
@@ -514,6 +528,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
#{item,typeHandler=com.zhongzheng.common.type.EncryptHandler}
|
|
#{item,typeHandler=com.zhongzheng.common.type.EncryptHandler}
|
|
|
</foreach>
|
|
</foreach>
|
|
|
</if>
|
|
</if>
|
|
|
|
|
+ <if test="searchKey != null and searchKey != ''">
|
|
|
|
|
+ AND (cg.class_name like concat('%', #{searchKey}, '%') or u.realname like concat('%', #{searchKey}, '%') or u.company_name like concat('%', #{searchKey}, '%'))
|
|
|
|
|
+ </if>
|
|
|
<if test="orderSn != null and orderSn != ''">
|
|
<if test="orderSn != null and orderSn != ''">
|
|
|
AND og.order_sn = #{orderSn}
|
|
AND og.order_sn = #{orderSn}
|
|
|
</if>
|
|
</if>
|
|
@@ -661,6 +678,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<if test="studyCountMore != null and studyCountMore == 0 ">
|
|
<if test="studyCountMore != null and studyCountMore == 0 ">
|
|
|
AND og.study_count = 0
|
|
AND og.study_count = 0
|
|
|
</if>
|
|
</if>
|
|
|
|
|
+ <if test="periodStatus != null ">
|
|
|
|
|
+ AND cgu.period_status = #{periodStatus}
|
|
|
|
|
+ </if>
|
|
|
<if test="officialStatus != null and officialStatus == 1 ">
|
|
<if test="officialStatus != null and officialStatus == 1 ">
|
|
|
AND cgu.official_status = 1
|
|
AND cgu.official_status = 1
|
|
|
</if>
|
|
</if>
|