Skip to content

Commit

Permalink
Show if person works on public holiday (#643)
Browse files Browse the repository at this point in the history
  • Loading branch information
derTobsch authored Apr 4, 2024
2 parents 608a1ca + 457e0d1 commit c41bae2
Show file tree
Hide file tree
Showing 4 changed files with 19 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -365,6 +365,7 @@ private WorkingTimeListEntryDto workingTimeListEntryDto(WorkingTime workingTime)
workingTime.isCurrent(),
workingTime.validFrom().isPresent(),
federalStateMessageKey,
workingTime.worksOnPublicHoliday(),
workingTime.getMonday().hoursDoubleValue(),
workingTime.getTuesday().hoursDoubleValue(),
workingTime.getWednesday().hoursDoubleValue(),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ record WorkingTimeListEntryDto(
boolean isCurrent,
boolean isDeletable,
String federalStateMessageKey,
boolean worksOnPublicHoliday,
Double workingTimeMonday,
Double workingTimeTuesday,
Double workingTimeWednesday,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,9 @@
</th:block>
</th:block>
</th:block>
<span th:if="${workingTime.worksOnPublicHoliday}" th:text="'(' + #{usermanagement.working-time.federalstate.works-on-public-holiday.label} + ')'">
(arbeitet an Feiertagen)
</span>
</summary>
<div
th:ref="working-time-block"
Expand Down Expand Up @@ -185,8 +188,13 @@
th:with="workingTime=${workingTimes[0]}"
>
<div class="mt-8">
<p th:text="${#messages.msg(workingTime.federalStateMessageKey)}">
Baden-Württemberg
<p>
<span th:text="${#messages.msg(workingTime.federalStateMessageKey)}">
Baden-Württemberg
</span>
<span th:if="${workingTime.worksOnPublicHoliday}" th:text="'(' + #{usermanagement.working-time.federalstate.works-on-public-holiday.label} + ')'">
(arbeitet an Feiertagen)
</span>
</p>
<div th:replace="~{::working-time-block}"></div>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,7 @@ void ensureSimpleGet() throws Exception {
true,
false,
"federalState.GERMANY_BADEN_WUERTTEMBERG",
false,
8.0,
8.0,
8.0,
Expand Down Expand Up @@ -314,6 +315,7 @@ void ensureSimpleGetJavaScript() throws Exception {
true,
false,
"federalState.GERMANY_BADEN_WUERTTEMBERG",
false,
8.0,
8.0,
8.0,
Expand Down Expand Up @@ -372,6 +374,7 @@ void ensureSimpleGetForWorkingTimeWithSpecialWorkingDays() throws Exception {
true,
false,
"federalState.GERMANY_BADEN_WUERTTEMBERG",
false,
4.0,
0d,
5.0,
Expand Down Expand Up @@ -428,6 +431,7 @@ void ensureSearch() throws Exception {
true,
false,
"federalState.GERMANY_BADEN_WUERTTEMBERG",
false,
8.0,
8.0,
8.0,
Expand Down Expand Up @@ -487,6 +491,7 @@ void ensureSearchJavaScript() throws Exception {
true,
false,
"federalState.GERMANY_BADEN_WUERTTEMBERG",
false,
8.0,
8.0,
8.0,
Expand Down Expand Up @@ -554,6 +559,7 @@ void ensureSearchWithSelectedUserNotInQuery() throws Exception {
true,
false,
"federalState.GERMANY_BADEN_WUERTTEMBERG",
false,
8.0,
8.0,
8.0,
Expand Down Expand Up @@ -620,6 +626,7 @@ void ensureSearchWithSelectedUserNotInQueryJavaScript() throws Exception {
true,
false,
"federalState.GERMANY_BADEN_WUERTTEMBERG",
false,
8.0,
8.0,
8.0,
Expand Down

0 comments on commit c41bae2

Please sign in to comment.