Browse Source

1、试听课
2、收费网管课活动

Joburgess 5 years ago
parent
commit
2d0064d74d

+ 5 - 1
mec-web/src/main/java/com/ym/mec/web/controller/education/EduPracticeGroupController.java

@@ -278,7 +278,11 @@ public class EduPracticeGroupController extends BaseController {
         if (sysUser == null) {
             return failed(HttpStatus.FORBIDDEN, "请登录");
         }
-        return succeed(eduPracticeGroupService.getStudentTrialPractices(studentId));
+        int studentIngTrialPracticeNum = practiceGroupDao.countStudentIngTrialPractices(studentId);
+        Map<String, Object> result=new HashMap<>();
+        result.put("practices", eduPracticeGroupService.getStudentTrialPractices(studentId));
+        result.put("existIngTrialPractices", studentIngTrialPracticeNum>0?1:0);
+        return succeed(result);
     }
 
     @ApiOperation("更新课程组信息")