@@ -106,8 +106,9 @@ public class TimeCalculationServiceImpl extends ServiceImpl<TimeCalculationMappe
//然后根据日期和用户id获取到所有的记录 然后手动累加在一起
Long[] timeArray = {0L, 0L, 0L, 0L, 0L, 0L, 0L, 0L, 0L, 0L};
//其他 编程 上网 文档 设计 美工 运营 看小说 影视娱乐 听音乐
- for (Map<String, Object> dataMap : timeCalculationMapper
- .getTodayStatistics((String) userMap.get("id"), date, companyId)) {
+ List<Map<String, Object>> tatistics = timeCalculationMapper
+ .getTodayStatistics((String) userMap.get("id"), date, companyId);
+ for (Map<String, Object> dataMap : tatistics) {
timeArray[(int) dataMap.get("type") + 1] += (Long) dataMap.get("duration");
}
Long[] resultArray = new Long[6];