|
@@ -52,7 +52,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
where log_id = #{logId}
|
|
|
</select>
|
|
|
<select id="selectFsCourseWatchLogListVO" resultType="com.fs.course.vo.FsCourseWatchLogListVO">
|
|
|
- select l.log_id,l.user_id,uc.course_name,v.title as video_name,u.nick_name as fsNickName, u.avatar as fsAvatar,
|
|
|
+ select l.log_id,
|
|
|
+ l.project as project,
|
|
|
+ l.user_id,uc.course_name,v.title as video_name,u.nick_name as fsNickName, u.avatar as fsAvatar,
|
|
|
l.log_type,SEC_TO_TIME(l.duration) as duration,c.company_name,l.camp_period_time,l.finish_time,
|
|
|
cu.nick_name as company_user_name ,l.send_type,l.create_time,l.update_time,l.last_heartbeat_time,
|
|
|
qu.qw_user_name,qec.name as external_user_name,c.company_id
|
|
@@ -486,4 +488,73 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
GROUP BY o.video_id,o.user_id,DATE(o.create_time)
|
|
|
ORDER BY o.video_id ,DATE(o.create_time)
|
|
|
</select>
|
|
|
+ <select id="selectFsCourseWatchLogListVONew" resultType="com.fs.course.vo.FsCourseWatchLogListVO">
|
|
|
+ select l.log_id,
|
|
|
+ l.project as project,
|
|
|
+ l.user_id,
|
|
|
+ l.log_type,
|
|
|
+ SEC_TO_TIME(l.duration) as duration,
|
|
|
+ l.camp_period_time,
|
|
|
+ l.finish_time,
|
|
|
+ l.send_type,
|
|
|
+ l.create_time,
|
|
|
+ l.update_time,
|
|
|
+ l.last_heartbeat_time,
|
|
|
+ l.company_id,
|
|
|
+ l.company_user_id,
|
|
|
+ l.course_id,
|
|
|
+ l.video_id
|
|
|
+ from fs_course_watch_log l
|
|
|
+ <where>
|
|
|
+ <if test ='maps.userId !=null'>
|
|
|
+ and l.user_id = #{maps.userId}
|
|
|
+ </if>
|
|
|
+ <if test ='maps.qwExternalContactId !=null'>
|
|
|
+ and l.qw_external_contact_id = #{maps.qwExternalContactId}
|
|
|
+ </if>
|
|
|
+ <if test ='maps.qwUserId !=null'>
|
|
|
+ and l.qw_user_id = #{maps.qwUserId}
|
|
|
+ </if>
|
|
|
+ <if test ='maps.courseId !=null'>
|
|
|
+ and l.course_id = #{maps.courseId}
|
|
|
+ </if>
|
|
|
+ <if test ='maps.videoId !=null'>
|
|
|
+ and l.video_id = #{maps.videoId}
|
|
|
+ </if>
|
|
|
+ <if test ='maps.logType !=null'>
|
|
|
+ and l.log_type = #{maps.logType}
|
|
|
+ </if>
|
|
|
+ <if test ='maps.companyId !=null'>
|
|
|
+ and l.company_id = #{maps.companyId}
|
|
|
+ </if>
|
|
|
+ <if test ='maps.companyUserId !=null'>
|
|
|
+ and l.company_user_id = #{maps.companyUserId}
|
|
|
+ </if>
|
|
|
+ <if test= 'maps.sTime != null '>
|
|
|
+ and DATE(l.create_time) >= DATE(#{maps.sTime})
|
|
|
+ </if>
|
|
|
+ <if test='maps.eTime != null '>
|
|
|
+ and DATE(l.create_time) <= DATE(#{maps.eTime})
|
|
|
+ </if>
|
|
|
+ <if test= 'maps.scheduleStartTime != null '>
|
|
|
+ and DATE(l.camp_period_time) >= DATE(#{maps.scheduleStartTime})
|
|
|
+ </if>
|
|
|
+ <if test='maps.scheduleEndTime != null '>
|
|
|
+ and DATE(l.camp_period_time) <= DATE(#{maps.scheduleEndTime})
|
|
|
+ </if>
|
|
|
+ <if test= 'maps.upSTime != null '>
|
|
|
+ and DATE(l.update_time) >= DATE(#{maps.upSTime})
|
|
|
+ </if>
|
|
|
+ <if test='maps.upETime != null '>
|
|
|
+ and DATE(l.update_time) <= DATE(#{maps.upETime})
|
|
|
+ </if>
|
|
|
+ <if test="maps.sopIds != null and maps.sopIds.size() > 0">
|
|
|
+ and l.sop_id in
|
|
|
+ <foreach item="sopId" index="index" collection="maps.sopIds" open="(" separator="," close=")">
|
|
|
+ #{sopId}
|
|
|
+ </foreach>
|
|
|
+ </if>
|
|
|
+ </where>
|
|
|
+ order by l.log_id desc
|
|
|
+ </select>
|
|
|
</mapper>
|