Explorar el Código

fix 添加字段

tanzh hace 3 años
padre
commit
8abae0e54d

+ 12 - 0
zhongzheng-system/src/main/java/com/zhongzheng/modules/grade/service/impl/ClassGradeUserServiceImpl.java

@@ -24,9 +24,11 @@ import com.zhongzheng.modules.alioss.service.OssService;
 import com.zhongzheng.modules.base.domain.UserProfile;
 import com.zhongzheng.modules.base.service.IUserProfileService;
 import com.zhongzheng.modules.course.domain.CourseBusiness;
+import com.zhongzheng.modules.course.domain.CourseEducationType;
 import com.zhongzheng.modules.course.domain.CourseMenuExam;
 import com.zhongzheng.modules.course.domain.CourseProjectType;
 import com.zhongzheng.modules.course.service.ICourseBusinessService;
+import com.zhongzheng.modules.course.service.ICourseEducationTypeService;
 import com.zhongzheng.modules.course.service.ICourseProjectTypeService;
 import com.zhongzheng.modules.course.vo.CourseBusinessVo;
 import com.zhongzheng.modules.course.vo.CourseChapterVo;
@@ -138,6 +140,9 @@ public class ClassGradeUserServiceImpl extends ServiceImpl<ClassGradeUserMapper,
     @Autowired
     private ICourseProjectTypeService iCourseProjectTypeService;
 
+    @Autowired
+    private ICourseEducationTypeService iCourseEducationTypeService;
+
     @Value("${aliyun.oss.endpoint}")
     private String ALIYUN_OSS_ENDPOINT;
 
@@ -1660,6 +1665,13 @@ public class ClassGradeUserServiceImpl extends ServiceImpl<ClassGradeUserMapper,
                 if (Validator.isNotEmpty(courseProjectTypeList)) {
                     vo.setProjectName(courseProjectTypeList.get(0).getProjectName());
                 }
+                LambdaQueryWrapper<CourseEducationType> lqw4 = Wrappers.lambdaQuery();
+                lqw4.eq(Validator.isNotEmpty(goods.getEducationTypeId()), CourseEducationType::getId, goods.getEducationTypeId());
+                CourseEducationType courseEducationType = iCourseEducationTypeService.getOne(lqw4);
+                if (Validator.isNotEmpty(courseEducationType)) {
+                    vo.setEducationName(courseEducationType.getEducationName());
+                    vo.setEducationTypeId(courseEducationType.getId());
+                }
                 for (ClassGradeVo classGrade : classGradeList) {
                     LambdaQueryWrapper<ClassGradeUser> lq = Wrappers.lambdaQuery();
                     lq.eq(ClassGradeUser::getGradeId, classGrade.getGradeId());