2023-11-09 20:21:34 +01:00
|
|
|
<!DOCTYPE html>
|
|
|
|
<html xmlns:th="http://www.thymeleaf.org"
|
|
|
|
xmlns:sec="http://www.thymeleaf.org/extras/spring-security"
|
|
|
|
xmlns:layout="http://www.ultraq.net.nz/thymeleaf/layout">
|
|
|
|
<head>
|
2023-11-11 20:40:28 +01:00
|
|
|
<title>Basisevent-Konfiguration</title>
|
|
|
|
</head>
|
2023-11-09 20:21:34 +01:00
|
|
|
<body>
|
|
|
|
<nav>
|
|
|
|
<div class="topnav"> <!-- später für css -->
|
|
|
|
<a th:href="@{/}" th:text="Home">Home</a>
|
|
|
|
<a th:href="@{/catalog}" th:text="Katalog">Katalog</a>
|
|
|
|
<a th:href="@{/event}" th:text="Eventplaner">Eventplaner</a>
|
|
|
|
<a th:href="@{/orders}" th:text="Aufträge">Aufträge</a>
|
|
|
|
<!--<a href="#account">Mein Konto</a>-->
|
|
|
|
</div>
|
|
|
|
</nav>
|
2023-11-09 23:46:55 +01:00
|
|
|
<h1>Basisevent konfigurieren</h1>
|
2023-11-10 18:35:12 +01:00
|
|
|
<input type="hidden" name="addCatalog">
|
2023-11-09 20:21:34 +01:00
|
|
|
<div class="content">
|
2023-11-12 00:46:47 +01:00
|
|
|
<h2>Dienstleistung</h2>
|
|
|
|
<label for="events"></label>
|
|
|
|
<form th:object="${formCatalogEntry}" method="post" th:action="@{/catalog_editor/chooseEvent}">
|
|
|
|
<select name="events" id="events">
|
|
|
|
<option value="event_catering">Eventcatering</option>
|
|
|
|
<option value="party_service">Partyservice</option>
|
|
|
|
<option value="mobile_breakfast">Mobile Breakfast</option>
|
|
|
|
<option value="rent_a_cook">Rent-a-Cook</option>
|
|
|
|
</select>
|
|
|
|
<button type="submit">Event auswählen</button>
|
|
|
|
</form>
|
2023-11-09 20:21:34 +01:00
|
|
|
Eventbasispreis: 500€
|
|
|
|
|
2023-11-12 00:46:47 +01:00
|
|
|
<h2>Mindestzeitraum</h2>
|
2023-11-10 18:35:12 +01:00
|
|
|
<form th:object="${formCatalogEntry}" method="post" th:action="@{/catalog_editor/add_time}">
|
2023-11-11 20:40:28 +01:00
|
|
|
<label>Mindestzeitraum:</label>
|
2023-11-12 00:46:47 +01:00
|
|
|
<input type="hidden" th:field="*{eventType}">
|
2023-11-11 22:06:48 +01:00
|
|
|
<input th:field="*{minimumTimePeriod}" type="number" min="0" step="1" value="1"/>
|
2023-11-11 20:40:28 +01:00
|
|
|
<button type="submit">Zum Model hinzufügen</button>
|
2023-11-10 18:35:12 +01:00
|
|
|
</form>
|
|
|
|
|
2023-11-12 00:46:47 +01:00
|
|
|
<h2>Basisausstattung</h2>
|
2023-11-09 20:21:34 +01:00
|
|
|
<table>
|
|
|
|
<tr>
|
|
|
|
<th>Produktname</th>
|
|
|
|
<th>Menge</th>
|
|
|
|
<th>Stückpreis</th>
|
|
|
|
</tr>
|
2023-11-10 18:35:12 +01:00
|
|
|
<tr th:each="item : ${inventory}">
|
|
|
|
<td th:text="${item.getName()}">
|
|
|
|
<td th:text="${item.getAmount()}">
|
|
|
|
<td th:text="${item.getCost()}"> €
|
2023-11-09 20:21:34 +01:00
|
|
|
<td>
|
2023-11-10 18:35:12 +01:00
|
|
|
<form method="post" th:action="@{/catalog_editor/remove_product}">
|
2023-11-11 20:40:28 +01:00
|
|
|
<input type="hidden" name="id" th:value="${item.getItemId()}">
|
2023-11-10 18:35:12 +01:00
|
|
|
<button type="submit">Entfernen</button>
|
2023-11-09 20:21:34 +01:00
|
|
|
</form>
|
|
|
|
</td>
|
|
|
|
</table>
|
2023-11-12 00:46:47 +01:00
|
|
|
<hr>
|
2023-11-11 22:06:48 +01:00
|
|
|
<div style="height: 20px;"></div>
|
2023-11-11 20:40:28 +01:00
|
|
|
<form method="post" th:action="@{/catalog_editor/product_add}">
|
|
|
|
<label for="name">Produktname</label>
|
|
|
|
<input type="text" id="name" name="name" required>
|
|
|
|
<label for="amount">Menge</label>
|
|
|
|
<input type="number" id="amount" name="amount" min="1" required>
|
|
|
|
<input type="hidden" name="cost" value="50.0">
|
|
|
|
<button type="submit">Artikel hinzufügen</button>
|
2023-11-12 00:46:47 +01:00
|
|
|
</form>hinzufügen
|
|
|
|
<br>
|
|
|
|
<h3>Momentane Auswahl</h3>
|
|
|
|
Eventtyp: <span th:text="${formCatalogEntry.getEventType()}"></span><br>
|
|
|
|
Mindestzeitraum: <span th:text="${formCatalogEntry.getMinimumTimePeriod()}"></span><br>
|
|
|
|
<span>Gesamtpreis: 90 €</span>
|
2023-11-10 18:35:12 +01:00
|
|
|
<form method="post" th:action="@{/catalog_editor/catalog_add}" th:object="${formCatalogEntry}">
|
2023-11-12 00:46:47 +01:00
|
|
|
<input type="hidden" name="eventType" th:value="${formCatalogEntry.getEventType()}">
|
|
|
|
<input type="hidden" name="products" th:value="${inventory}">
|
|
|
|
<input type="hidden" name="minimumTimePeriod" th:value="${formCatalogEntry.getMinimumTimePeriod}">
|
|
|
|
<input type="hidden" name="totalCost" th:value="${formCatalogEntry.getTotalCost()}">
|
2023-11-10 18:35:12 +01:00
|
|
|
<button type="submit">Zum Katalog hinzufügen</button>
|
|
|
|
</form>
|
2023-11-09 20:21:34 +01:00
|
|
|
</div>
|
|
|
|
</body>
|
|
|
|
</html>
|