|
@@ -23,6 +23,7 @@ import com.ym.mec.biz.dal.enums.*;
|
|
|
import com.ym.mec.biz.service.*;
|
|
|
import com.ym.mec.common.controller.BaseController;
|
|
|
import com.ym.mec.common.entity.HttpResponseResult;
|
|
|
+import com.ym.mec.common.tenant.TenantContextHolder;
|
|
|
import org.apache.commons.collections.ListUtils;
|
|
|
import org.apache.commons.lang3.StringUtils;
|
|
|
import org.codehaus.jackson.map.util.BeanUtil;
|
|
@@ -4944,18 +4945,17 @@ public class CourseScheduleServiceImpl extends BaseServiceImpl<Long, CourseSched
|
|
|
PageInfo<CourseScheduleEndDto> pageInfo = new PageInfo<>(queryInfo.getPage(), queryInfo.getRows());
|
|
|
Map<String, Object> params = new HashMap<>(16);
|
|
|
MapUtil.populateMap(params, queryInfo);
|
|
|
+ Integer tenantId = TenantContextHolder.getTenantId();
|
|
|
+ if("COURSE_TIME_ERROR".equals(queryInfo.getSearchType())){
|
|
|
+ String courseStartTimeError = sysTenantConfigService.getTenantConfigValue(SysConfigService.COURSE_START_TIME_ERROR, tenantId);
|
|
|
+ String courseEndTimeError = sysTenantConfigService.getTenantConfigValue(SysConfigService.COURSE_END_TIME_ERROR, tenantId);
|
|
|
+ if(StringUtils.isEmpty(courseStartTimeError) || StringUtils.isEmpty(courseEndTimeError)){
|
|
|
+ return pageInfo;
|
|
|
+ }
|
|
|
+ params.put("courseStartTimeError",courseStartTimeError);
|
|
|
+ params.put("courseEndTimeError",courseEndTimeError);
|
|
|
+ }
|
|
|
|
|
|
-// List<CourseScheduleEndDto> results;
|
|
|
-// SysUser sysUser = sysUserFeignService.queryUserInfo();
|
|
|
-// List<Integer> userRole = employeeDao.queryUserRole(sysUser.getId());
|
|
|
- //如果当前用户只有教务老师角色,那么只能看到他所管理的课程组的信息
|
|
|
-// if (!sysUser.getIsSuperAdmin() && userRole.size() == 1 && userRole.contains(SysUserRole.EDUCATIONAL_TEACHER)) {
|
|
|
-// List<Long> classGroupIds = classGroupDao.queryGroupClassGroupIds(sysUser.getId());
|
|
|
-// if(classGroupIds.size() == 0){
|
|
|
-// return pageInfo;
|
|
|
-// }
|
|
|
-// params.put("classGroupIds",classGroupIds);
|
|
|
-// }
|
|
|
int count = courseScheduleDao.endCountCourseSchedules(params);
|
|
|
if(queryInfo.getIsExport() && count > 50000){
|
|
|
throw new BizException("数据集太大,不能导出.最大数据集不能超过50000");
|
|
@@ -4968,7 +4968,7 @@ public class CourseScheduleServiceImpl extends BaseServiceImpl<Long, CourseSched
|
|
|
List<Integer> teacherIds=results.stream().filter(t->Objects.nonNull(t.getActualTeacherId())).map(CourseSchedule::getActualTeacherId).collect(Collectors.toList());
|
|
|
|
|
|
List<Map<Integer, String>> nameIdMaps = teacherDao.queryNameByIdList(teacherIds);
|
|
|
- Map<Integer, String> nameIdMap=MapUtil.convertIntegerMap(nameIdMaps);
|
|
|
+ Map<Integer, String> nameIdMap = MapUtil.convertIntegerMap(nameIdMaps);
|
|
|
|
|
|
List<Map<Long, Long>> courseMergeCourseNum = courseScheduleDao.countCourseMergeCourseNum(courseScheduleIds);
|
|
|
Map<Long, Long> courseMergeCourseNumMap = new HashMap<>();
|