|
@@ -482,50 +482,5 @@
|
|
|
ORDER BY og.create_time DESC
|
|
|
</select>
|
|
|
|
|
|
- <select id="listLiveGoodsList" parameterType="com.zhongzheng.modules.goods.bo.GoodsQueryBo" resultMap="GoodsUserQuestionVo">
|
|
|
- SELECT
|
|
|
- g.*,
|
|
|
- cet.education_name,
|
|
|
- cpt.project_name,
|
|
|
- cb.business_name,
|
|
|
- o.user_id,
|
|
|
- o.order_sn,
|
|
|
- og.create_time as order_create_time,
|
|
|
- og.service_start_time,
|
|
|
- og.service_end_time,
|
|
|
- og.order_goods_id,
|
|
|
- u.realname,
|
|
|
- u.id_card,
|
|
|
- u.user_id
|
|
|
- FROM `order` o
|
|
|
- LEFT JOIN order_goods og ON o.order_sn = og.order_sn
|
|
|
- LEFT JOIN goods g ON og.goods_id = g.goods_id
|
|
|
- LEFT JOIN course_education_type cet ON g.education_type_id = cet.id
|
|
|
- LEFT JOIN course_project_type cpt ON g.project_id = cpt.id
|
|
|
- LEFT JOIN course_business cb ON g.business_id = cb.id
|
|
|
- LEFT JOIN `user` u ON u.user_id = o.user_id
|
|
|
- WHERE
|
|
|
- 1 = 1
|
|
|
- <if test="goodsType != null and goodsType != ''">
|
|
|
- AND g.goods_type = #{goodsType}
|
|
|
- </if>
|
|
|
- AND og.pay_status IN ( 2, 3, 4 )
|
|
|
- AND og.refund_status IN (0,3,1)
|
|
|
- <if test="goodsId != null and goodsId != ''">
|
|
|
- AND og.goods_id = #{goodsId}
|
|
|
- </if>
|
|
|
- <if test="educationTypeId != null and educationTypeId != ''">
|
|
|
- AND g.education_type_id = #{educationTypeId}
|
|
|
- </if>
|
|
|
- <if test="businessId != null and businessId != ''">
|
|
|
- AND g.business_id = #{businessId}
|
|
|
- </if>
|
|
|
- <if test="majorId != null and majorId != ''">
|
|
|
- AND g.major_id = #{majorId}
|
|
|
- </if>
|
|
|
- <if test="searchKey != null and searchKey != ''">
|
|
|
- and (g.goods_name like concat('%', #{searchKey}, '%') or g.code like concat('%', #{searchKey}, '%') or u.realname like concat('%', #{searchKey}, '%') or u.id_card like concat('%', #{searchKey}, '%'))
|
|
|
- </if>
|
|
|
- ORDER BY og.create_time DESC
|
|
|
- </select>
|
|
|
+
|
|
|
</mapper>
|