hjl
2024-06-07 3407c10808d75f2f9340a030f90191ecafa055a2
ruoyi-service/ruoyi-study/src/main/java/com/ruoyi/study/service/impl/TStudyServiceImpl.java
@@ -1,6 +1,7 @@
package com.ruoyi.study.service.impl;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.ruoyi.common.core.constant.Constants;
import com.ruoyi.common.core.exception.GlobalException;
import com.ruoyi.common.core.utils.bean.BeanUtils;
import com.ruoyi.common.security.service.TokenService;
@@ -58,6 +59,7 @@
    @Override
    public void checkDifficulty(Integer difficulty, Integer week, TGame game) {
        // 判断用户是否完成上一个等级
        if (!Constants.ZERO.equals(difficulty)) {
        Integer level = GAME_DIFFICULTY_MAP.get(String.valueOf(difficulty));
        if (null == level) {
            throw new GlobalException("游戏等级异常,请重试!");
@@ -70,6 +72,7 @@
            throw new GlobalException("请先完成上一难度再挑战当前难度!");
        }
    }
    }
    @Override
    public StudyListenResultVO listenSelectPicture(Integer week, Integer day, List<TStudyListen> studyListens) {