|
@@ -111,14 +111,13 @@ public class AppUserServiceImpl implements AppUserService {
|
|
|
old.setLastQuestionId(questionMapper.getLastQuestionId(old.getUserId()));
|
|
old.setLastQuestionId(questionMapper.getLastQuestionId(old.getUserId()));
|
|
|
old.setTodayAnswerCount(questionMapper.getAnswerCount(old.getUserId(),1));
|
|
old.setTodayAnswerCount(questionMapper.getAnswerCount(old.getUserId(),1));
|
|
|
old.setHistoryAnswerCount(questionMapper.getAnswerCount(old.getUserId(),2));
|
|
old.setHistoryAnswerCount(questionMapper.getAnswerCount(old.getUserId(),2));
|
|
|
- List<YtDyzAnswerRecord> reversedList = new ArrayList<>(questionMapper.getAnswerRecords(old.getUserId()));
|
|
|
|
|
- Collections.reverse(reversedList);
|
|
|
|
|
|
|
+ List<YtDyzAnswerRecord> recordList = questionMapper.getAnswerRecords(old.getUserId());
|
|
|
List<String> viewList = new ArrayList<>();
|
|
List<String> viewList = new ArrayList<>();
|
|
|
- int count = 1;
|
|
|
|
|
- for (YtDyzAnswerRecord ytDyzAnswerRecord : reversedList) {
|
|
|
|
|
|
|
+ int count = recordList.size();
|
|
|
|
|
+ for (YtDyzAnswerRecord ytDyzAnswerRecord : recordList) {
|
|
|
SimpleDateFormat sdf = new SimpleDateFormat("yyyy/MM/dd HH:mm:ss");
|
|
SimpleDateFormat sdf = new SimpleDateFormat("yyyy/MM/dd HH:mm:ss");
|
|
|
String timeStr = count + ":" + sdf.format(ytDyzAnswerRecord.getAnswerTime());
|
|
String timeStr = count + ":" + sdf.format(ytDyzAnswerRecord.getAnswerTime());
|
|
|
- count++;
|
|
|
|
|
|
|
+ count--;
|
|
|
viewList.add(timeStr);
|
|
viewList.add(timeStr);
|
|
|
}
|
|
}
|
|
|
old.setAnswerRecordTimeList(viewList);
|
|
old.setAnswerRecordTimeList(viewList);
|