日志调试

This commit is contained in:
lims1@hunktimes.com
2023-08-07 15:21:41 +08:00
parent 18f35c0f81
commit 900f297c86
2 changed files with 7 additions and 0 deletions

View File

@@ -264,15 +264,19 @@ public class CoursePortalApi extends ApiBaseController{
boolean pass = false;
if(!preview) {
log.debug("=--------- 开始查询受众信息 ---------------------------------");
log.error("=--------- 开始查询受众信息 ---------------------------------");
String token = request.getHeader("token");
log.debug("=--------- 获取token token = " + token);
log.error("=--------- 获取token token = " + token);
if (!courseCrowdList.isEmpty()) {
for (CourseCrowd c : courseCrowdList) {
//同一个受众,同一个只会有一条记录,所以这里就直接查询了
// List<UserGroupItem> hasItem = userGroupService.findByGroupIdAndAid(c.getGroupId(),aid);
log.debug("=--------- 开始调研用户中心受众接口 groupId = " + c.getGroupId());
log.error("=--------- 开始调研用户中心受众接口 groupId = " + c.getGroupId());
List<AuditList> allAudienceList = thirdApi.getAllAudienceList(AuditListParam.builder().audienceId(c.getGroupId()).pageSize(1000).pageNo(1).build(), token);
log.debug("=--------- allAudienceList: " +allAudienceList);
log.error("=--------- allAudienceList: " +allAudienceList);
List<Long> userIdList = allAudienceList.stream().map(AuditList::getUserId).collect(Collectors.toList());
if (userIdList.contains(aid)) {
pass = true;
@@ -290,6 +294,7 @@ public class CoursePortalApi extends ApiBaseController{
}
log.debug("=--------- 是否有权限查看此课程: " +pass);
log.error("=--------- 是否有权限查看此课程: " +pass);
List<CourseContent> cclist=contentService.getByCourseId(id);
List<CourseSection> sectionlist=sectionService.getByCourseId(id);
List<CourseTeacher> teachers=courseService.findTeachersByCourseId(id);

View File

@@ -171,6 +171,8 @@ public class StudyCourseApi extends ApiBaseController{
boolean pass = false;
if (!courseCrowdList.isEmpty()) {
log.debug("=---studyIndex------ 开始查询受众信息 ---------------------------------");
log.error("=----studyIndex----- 开始查询受众信息 ---------------------------------");
String token = request.getHeader("token");
for (CourseCrowd c : courseCrowdList) {
//同一个受众,同一个只会有一条记录,所以这里就直接查询了