mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/per-boe/java-servers.git
synced 2025-12-07 18:06:50 +08:00
在线管理资源完成情况修改
This commit is contained in:
@@ -190,10 +190,10 @@ public class StudyServiceImpl implements IStudyService{
|
||||
return scItemDao.findPage(query.builder());
|
||||
}else if (status == 1) {
|
||||
String sql = "select bsc.id,bsc.course_id,bsc.course_name,bsc.aname from boe_study_course bsc " +
|
||||
" where bsc.course_id = '"+courseId+"' and bsc.id != (" +
|
||||
" where bsc.course_id = '"+courseId+"' and bsc.id not in (" +
|
||||
" select bsc.id from boe_study_course bsc " +
|
||||
" left join boe_study_course_item item on item.course_id = bsc.course_id and item.study_id = bsc.id " +
|
||||
" where bsc.course_id = '" + courseId + "' and item.content_id = '"+ contentId+"'" +
|
||||
" where bsc.course_id = '" + courseId + "' and item.content_id = '"+ contentId+"' group by bsc.id" +
|
||||
" )";
|
||||
log.info("资源完成情况未开始sql"+sql);
|
||||
List<Object[]> list = scDao.sqlFindList(sql);
|
||||
@@ -217,15 +217,15 @@ public class StudyServiceImpl implements IStudyService{
|
||||
}
|
||||
String sql2 = "select * from (select bsc.id,bsc.course_id,bsc.course_name,bsc.aname,item.progress,item.status from boe_study_course bsc left join " +
|
||||
"boe_study_course_item item on item.course_id = bsc.course_id and item.study_id = bsc.id " +
|
||||
"where bsc.`status` in (2,9) and bsc.course_id = '"+ courseId+"' " +
|
||||
"where bsc.`status` in (2,9) and bsc.course_id = '"+ courseId+"' group by bsc.id" +
|
||||
"UNION ALL " +
|
||||
" select bsc.id,bsc.course_id,bsc.course_name,bsc.aname,0 as progress,1 as status from boe_study_course bsc " +
|
||||
" LEFT JOIN boe_study_course_item item on item.course_id = bsc.course_id " +
|
||||
" where bsc.course_id = '"+courseId+"' and bsc.id != (" +
|
||||
" where bsc.course_id = '"+courseId+"' and bsc.id not in (" +
|
||||
" select bsc.id from boe_study_course bsc " +
|
||||
" left join boe_study_course_item item on item.course_id = bsc.course_id and item.study_id = bsc.id " +
|
||||
" where bsc.course_id = '" + courseId + "' and item.content_id = '"+ contentId+"'" +
|
||||
" )) a group by a.id";
|
||||
" where bsc.course_id = '" + courseId + "' and item.content_id = '"+ contentId+"' group by bsc.id" +
|
||||
" )group by bsc.id) a group by a.id";
|
||||
log.info("资源完成情况全部sql"+sql2);
|
||||
List<Object[]> list = scDao.sqlFindList(sql2);
|
||||
log.info("资源完成情况人数"+list);
|
||||
|
||||
Reference in New Issue
Block a user