Parcourir la source

新客对话新增检验看课逻辑状态

xw il y a 6 jours
Parent
commit
f5b0f5cbde

+ 1 - 11
fs-service/src/main/java/com/fs/sop/mapper/QwSopTempContentMapper.java

@@ -91,17 +91,7 @@ public interface QwSopTempContentMapper extends BaseMapper<QwSopTempContent>{
             "\tAND c.content_type = 3")
     List<QwSopTempContentVO> updateSiFenTemp();
 
-    @Select("select   tc.id,\n" +
-            "  tc.content_type,\n" +
-            "  tc.content,\n" +
-            "  tr.course_id,\n" +
-            "  tr.video_id,\n" +
-            "  tr.course_type as courseType,\n" +
-            "  COALESCE(tr.type, tr.content_type) as type \n" +
-            "FROM\n" +
-            "  qw_sop_temp_content tc " +
-            "left join qw_sop_temp_rules tr on  tc.rules_id=tr.id " +
-            "where tc.temp_id=#{tempId}")
+
     List<QwSopTempContent> selectQwSopTempContentByTempIdAndRules(@Param("tempId") String tempId);
 
     List<QwSopTempContent> selectQwSopTempContentByTempId(@Param("tempId") String tempId);

+ 15 - 0
fs-service/src/main/resources/mapper/sop/QwSopTempContentMapper.xml

@@ -51,6 +51,21 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
         where temp_id = #{tempId}
     </select>
 
+    <select id="selectQwSopTempContentByTempIdAndRules" resultType="com.fs.sop.domain.QwSopTempContent">
+        SELECT
+               tc.content_type,
+               tc.id,
+               tc.content_type,
+               tc.content,
+               tr.course_id,
+               tr.video_id,
+               tr.course_type,
+               tr.content_type as type
+        FROM qw_sop_temp_content tc
+                 LEFT JOIN qw_sop_temp_rules tr ON tc.rules_id = tr.id
+        WHERE tc.temp_id = #{tempId}
+    </select>
+
     <insert id="insertQwSopTempContent" parameterType="QwSopTempContent">
         insert into qw_sop_temp_content
         <trim prefix="(" suffix=")" suffixOverrides=",">