Commit bd14a02d by 丁伟峰

根据0803的商议,正常上班的日历不必在日历中显示

1 parent 9c1fffb1
...@@ -243,13 +243,13 @@ public class EngineerCalendarServiceImpl implements EngineerCalendarService { ...@@ -243,13 +243,13 @@ public class EngineerCalendarServiceImpl implements EngineerCalendarService {
calendar.setDate(date); calendar.setDate(date);
int dayOfWeek = LocalDate.parse(date).getDayOfWeek().getValue(); int dayOfWeek = LocalDate.parse(date).getDayOfWeek().getValue();
calendar.setWeek(DateUtils.toWeekChinese(dayOfWeek)); calendar.setWeek(DateUtils.toWeekChinese(dayOfWeek));
EngineerCalendarDTO.Content content = new EngineerCalendarDTO.Content();
List<String> workdays = Arrays.asList(e.getWorkdays().split(",")); List<String> workdays = Arrays.asList(e.getWorkdays().split(","));
if (!workdays.contains(String.valueOf(dayOfWeek))) { if (!workdays.contains(String.valueOf(dayOfWeek))) {
EngineerCalendarDTO.Content content = new EngineerCalendarDTO.Content();
content.setType("REST"); content.setType("REST");
content.setTitle("休息"); content.setTitle("休息");
}
calendar.setContent(Collections.singletonList(content)); calendar.setContent(Collections.singletonList(content));
}
return calendar; return calendar;
} }
} }
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!