Replace order id in template with order type

This commit is contained in:
Theo Reichert 2024-01-19 18:20:57 +01:00
parent ea5ac78e85
commit b79fbecb98
2 changed files with 3 additions and 3 deletions

View file

@ -379,7 +379,7 @@ public class OrderController {
String order_id = Objects.requireNonNull(order.getId()).toString();
for (int i = start_index_inclusive; i < end_index_exclusive; i++) {
// FIXME: exchange order ids for a short name or a color
datesOfMonth.get(i).add(order_id);
datesOfMonth.get(i).add(order.getOrderType().toHumanReadable());
}
}

View file

@ -1,5 +1,5 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
// SPDX-FileCopyrightText: 2023 swt23w23
// SPDX-FileCopyrightText: 2023-2024 swt23w23
package catering.order;
import catering.staff.JobType;
@ -300,6 +300,6 @@ public class OrderControllerIntegrationTests {
void adminViewsCalender() throws Exception {
mvc.perform(get("/orders/calender"))
.andExpect(status().isOk())
.andExpect(content().string(containsString(myOrder.getId().toString())));
.andExpect(content().string(containsString(myOrder.getOrderType().toHumanReadable())));
}
}