blob: 37631b8c3fc81898f0f8710f287352e5499999d3 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
|
<!DOCTYPE HTML>
<html xmlns:th="http://www.thymeleaf.org" lang="en">
<div th:replace="~{common :: head}"></div>
<body>
<div th:replace="~{common :: page-header}"></div>
<div class="indent">
<div id="updateToggleSelector">
<button id="updateBtn" class="btn btn-primary" onclick="toggleDisabled()">Изменить</button><br><br>
<a th:href="'/operationProducts/' + ${operation.getId()}">
<button class="btn btn-primary">Управление продуктами</button>
</a><br><br>
</div>
<form method="post" action="/operation">
<input disabled hidden id="operationId" name="operationId" th:value="${operation.getId()}">
<p th:text="'Тип: ' + ${operation.getType().toString()}"></p>
<label for="operationStatus">Статус:</label>
<select disabled id="operationStatus" name="operationStatus" required>
<option value="0" disabled>Выберите статус</option>
<option th:value="'CHECKOUT'" th:text="CHECKOUT" th:selected="${operation.getStatus().toString() == 'CHECKOUT'}"></option>
<option th:value="'APPROVAL'" th:text="APPROVAL" th:selected="${operation.getStatus().toString() == 'APPROVAL'}"></option>
<option th:value="'READY'" th:text="READY" th:selected="${operation.getStatus().toString() == 'READY'}"></option>
<option th:value="'EXECUTED'" th:text="EXECUTED" th:selected="${operation.getStatus().toString() == 'EXECUTED'}"></option>
<option th:value="'CANCELLED'" th:text="CANCELLED" th:selected="${operation.getStatus().toString() == 'CANCELLED'}"></option>
</select> <br><br>
<a th:href="@{/partner(id=${operation.getPartner().getId()})}">
<p th:text="'Партнер: ' + ${operation.getPartner().getName()}"></p>
</a>
<label for="operationResponsible">Ответственное лицо:</label>
<select disabled id="operationResponsible" name="operationResponsible" required>
<option value="0" disabled>Выберите ответственного</option>
<option th:each="contact : ${operation.getPartner().getContacts()}"
th:value="${contact.getId()}" th:text="${contact.getSurname()} + ' ' + ${contact.getName()}" th:selected="${operation.getResponsible() == contact}"></option>
</select> <br><br>
<label for="operationAddress">Адрес:</label>
<input disabled type="text" id="operationAddress" name="operationAddress" required th:value="${operation.getAddress()}"><br><br>
<p th:text="'Дата создания: ' + ${operation.getDateCreated()}"></p>
<p th:text="'Дата изменения: ' + ${operation.getDateModified()}"></p>
<p th:if="${operation.getDateFinished() != null}" th:text="'Дата окончания: ' + ${operation.getDateFinished()}"></p>
<input id="saveBtn" type="submit" value="Сохранить" class="btn btn-primary" hidden>
</form>
</div>
<div th:replace="~{common :: site-footer}"></div>
<div th:replace="~{common :: site-script}"></div>
<div th:replace="~{common :: editFieldsToggle}"></div>
</body>
</html>
|