| | |
| | | } else if (Constants.FIVE.equals(type)) { |
| | | userStudyRecord.setPair(Constants.ONE_HUNDRED); |
| | | } |
| | | if (userStudyRecord.getLook().equals(Constants.ONE_HUNDRED) && |
| | | userStudyRecord.getAnswer().equals(Constants.ONE_HUNDRED) && |
| | | userStudyRecord.getPair().equals(Constants.ONE_HUNDRED) && |
| | | userStudyRecord.getInduction().equals(Constants.ONE_HUNDRED) && |
| | | userStudyRecord.getListen().equals(Constants.ONE_HUNDRED)) { |
| | | // 学习完成,进入下一学习day |
| | | Integer nextDay = DAY_MAP.get(String.valueOf(userStudyRecord.getDay())); |
| | | userStudyRecord.setDay(nextDay); |
| | | // 下一day为 6,进入游戏日 |
| | | if (nextDay.equals(Constants.SIX)) { |
| | | // 游戏难度初始化 0(入门难度) |
| | | userStudyRecord.setGameDifficulty(Constants.ZERO); |
| | | } else { |
| | | // 重置学习进度 |
| | | userStudyRecord.setListen(Constants.BURDEN_ONE); |
| | | userStudyRecord.setLook(Constants.BURDEN_ONE); |
| | | userStudyRecord.setInduction(Constants.BURDEN_ONE); |
| | | userStudyRecord.setAnswer(Constants.BURDEN_ONE); |
| | | userStudyRecord.setPair(Constants.BURDEN_ONE); |
| | | } |
| | | if (userStudyRecord.getListen().equals(Constants.ONE_HUNDRED)){ |
| | | userStudyRecord.setDay(2); |
| | | |
| | | } |
| | | if (userStudyRecord.getLook().equals(Constants.ONE_HUNDRED)){ |
| | | userStudyRecord.setDay(3); |
| | | |
| | | } |
| | | if (userStudyRecord.getInduction().equals(Constants.ONE_HUNDRED)){ |
| | | userStudyRecord.setDay(4); |
| | | |
| | | } |
| | | if (userStudyRecord.getAnswer().equals(Constants.ONE_HUNDRED)){ |
| | | userStudyRecord.setDay(5); |
| | | |
| | | } |
| | | if (userStudyRecord.getPair().equals(Constants.ONE_HUNDRED)){ |
| | | userStudyRecord.setDay(6); |
| | | |
| | | } |
| | | if (userStudyRecord.getDay().equals(Constants.SIX)) { |
| | | // 游戏难度初始化 0(入门难度) |
| | | userStudyRecord.setGameDifficulty(Constants.ZERO); |
| | | } |
| | | // if (userStudyRecord.getLook().equals(Constants.ONE_HUNDRED) && |
| | | // userStudyRecord.getAnswer().equals(Constants.ONE_HUNDRED) && |
| | | // userStudyRecord.getPair().equals(Constants.ONE_HUNDRED) && |
| | | // userStudyRecord.getInduction().equals(Constants.ONE_HUNDRED) && |
| | | // userStudyRecord.getListen().equals(Constants.ONE_HUNDRED)) { |
| | | // // 学习完成,进入下一学习day |
| | | // Integer nextDay = DAY_MAP.get(String.valueOf(userStudyRecord.getDay())); |
| | | // userStudyRecord.setDay(nextDay); |
| | | // // 下一day为 6,进入游戏日 |
| | | // if (nextDay.equals(Constants.SIX)) { |
| | | // // 游戏难度初始化 0(入门难度) |
| | | // userStudyRecord.setGameDifficulty(Constants.ZERO); |
| | | // } else { |
| | | // // 重置学习进度 |
| | | // userStudyRecord.setListen(Constants.BURDEN_ONE); |
| | | // userStudyRecord.setLook(Constants.BURDEN_ONE); |
| | | // userStudyRecord.setInduction(Constants.BURDEN_ONE); |
| | | // userStudyRecord.setAnswer(Constants.BURDEN_ONE); |
| | | // userStudyRecord.setPair(Constants.BURDEN_ONE); |
| | | // } |
| | | // } |
| | | } |
| | | // 更新学习时长 |
| | | userStudyRecord.setTotalStudy(userStudyRecord.getTotalStudy() + studyTime); |