Commit 8df66851 authored by liqin's avatar liqin 💬

bug fixed

parent 3859c910
......@@ -20,12 +20,18 @@ import java.util.List;
*/
public interface LearningContentBoardMapper extends BaseMapper<LearningContentBoard> {
@Select("SELECT lcb.*, eb.`name` as exhibition_board_name FROM learning_content_board lcb, exhibition_board eb WHERE lcb.exhibition_board_id = eb.id and lcb.learning_content_id = #{learningContentId} order by lcb.sortorder desc")
@Select("SELECT lcb.*, eb.`name` as exhibition_board_name " +
"FROM learning_content_board lcb, exhibition_board eb " +
"WHERE lcb.exhibition_board_id = eb.id " +
"and lcb.learning_content_id = #{learningContentId} " +
"and eb.is_published = 1 and eb.is_deleted = 0 " +
"order by lcb.sortorder desc")
List<LearningContentBoard> selectBoardListByLearningContentId(String learningContentId);
@Select("<script>"
+ "SELECT eb.* FROM learning_content_board lcb, exhibition_board eb "
+ "WHERE lcb.exhibition_board_id = eb.id "
+ "and eb.is_published = 1 and is_deleted = 0 "
+ "<if test='learningContentId != null'>and lcb.learning_content_id = #{learningContentId} </if>"
+ "<if test='nameOrCode != null'>and eb.name like CONCAT('%', #{nameOrCode}, '%') </if>"
+ "order by lcb.sortorder desc"
......@@ -40,6 +46,7 @@ public interface LearningContentBoardMapper extends BaseMapper<LearningContentBo
+ "and lcb.exhibition_board_id = eb.id "
+ "and eb.video_content_id = vc.id "
+ "and vc.id = a.ref_item_id "
+ "and lc.is_published = 1 and eb.is_published = 1 and eb.is_deleted = 0 and vc.is_deleted = 0 "
+ "and a.file_type = 'VIDEO' "
+ "and lc.applicable_scope = 'THIS_ORGAN' "
+ "and lc.organ_code = #{organCode} "
......@@ -48,6 +55,7 @@ public interface LearningContentBoardMapper extends BaseMapper<LearningContentBo
+ "WHERE lcb.learning_content_id = lc.id "
+ "and lcb.exhibition_board_id = eb.id "
+ "and eb.id = a.ref_item_id "
+ "and lc.is_published = 1 and eb.is_published = 1 and eb.is_deleted = 0 "
+ "and a.file_cat = 'EXHIBITION_BOARD_DATUM' "
+ "and a.file_type = 'VIDEO' "
+ "and lc.applicable_scope = 'THIS_ORGAN' "
......@@ -59,6 +67,7 @@ public interface LearningContentBoardMapper extends BaseMapper<LearningContentBo
+ "and lcb.exhibition_board_id = eb.id "
+ "and eb.video_content_id = vc.id "
+ "and vc.id = a.ref_item_id "
+ "and lc.is_published = 1 and eb.is_published = 1 and eb.is_deleted = 0 and vc.is_deleted = 0 "
+ "and a.file_type = 'VIDEO' "
+ "and lc.applicable_scope = 'THIS_ORGAN_SUB'"
+ "and lc.organ_code like CONCAT(#{organCode},'%') "
......@@ -67,6 +76,7 @@ public interface LearningContentBoardMapper extends BaseMapper<LearningContentBo
+ "WHERE lcb.learning_content_id = lc.id "
+ "and lcb.exhibition_board_id = eb.id "
+ "and eb.id = a.ref_item_id "
+ "and lc.is_published = 1 and eb.is_published = 1 and eb.is_deleted = 0 "
+ "and a.file_cat = 'EXHIBITION_BOARD_DATUM' "
+ "and a.file_type = 'VIDEO' "
+ "and lc.applicable_scope = 'THIS_ORGAN_SUB' "
......@@ -77,6 +87,7 @@ public interface LearningContentBoardMapper extends BaseMapper<LearningContentBo
+ "and lcb.exhibition_board_id = eb.id "
+ "and eb.video_content_id = vc.id "
+ "and vc.id = a.ref_item_id "
+ "and lc.is_published = 1 and eb.is_published = 1 and eb.is_deleted = 0 and vc.is_deleted = 0 "
+ "and a.file_type = 'VIDEO' "
+ "and lc.applicable_scope = 'ALL_PLAT'"
+ "UNION "
......@@ -85,6 +96,7 @@ public interface LearningContentBoardMapper extends BaseMapper<LearningContentBo
+ "WHERE lcb.learning_content_id = lc.id "
+ "and lcb.exhibition_board_id = eb.id "
+ "and eb.id = a.ref_item_id "
+ "and lc.is_published = 1 and eb.is_published = 1 and eb.is_deleted = 0 "
+ "and a.file_cat = 'EXHIBITION_BOARD_DATUM' "
+ "and a.file_type = 'VIDEO' "
+ "and lc.applicable_scope = 'ALL_PLAT'" +
......
......@@ -67,6 +67,7 @@ public class VideoContent implements Serializable {
@ApiModelProperty("是否已删除")
@TableField("is_deleted")
@TableLogic
private Boolean deleted;
@ApiModelProperty("创建日期")
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment