mirror of
https://github.com/spring-projects/spring-petclinic.git
synced 2025-07-22 15:25:49 +00:00
Vet selection from visit OK. Date Selection NOK
This commit is contained in:
parent
7602727cf4
commit
87f0123a92
1 changed files with 14 additions and 4 deletions
|
@ -1,4 +1,4 @@
|
|||
<html>
|
||||
<html xmlns:th="http://www.w3.org/1999/xhtml">
|
||||
<body>
|
||||
<form>
|
||||
<th:block th:fragment="input (label, name, type)">
|
||||
|
@ -14,10 +14,20 @@
|
|||
pattern="(?:19|20)[0-9]{2}-(?:(?:0[1-9]|1[0-2])-(?:0[1-9]|1[0-9]|2[0-9])|(?:(?!02)(?:0[1-9]|1[0-2])-(?:30))|(?:(?:0[13578]|1[02])-31))"/>
|
||||
<input th:case="'datetime'" class="form-control" type="text" th:field="*{__${name}__}"
|
||||
placeholder="YYYY-MM-DD HH:MM" title="Enter a date in this format: YYYY-MM-DD HH:MM"/>
|
||||
<select th:case="'vet'" class="form-control" th:field="*{__${name}__}">
|
||||
<option value="null" th:text="Select: "></option>
|
||||
<option th:each="vet : ${vets}" th:value="${vet}" th:text="${vet.getFirstName() + ' ' + vet.getLastName()}"></option>
|
||||
|
||||
<select th:case="'vet'" class="form-control" th:field="*{vet.id}">
|
||||
<option value="-1" th:text="Select"></option>
|
||||
<option th:each="selVet : ${vets}" th:value="${selVet.id}" th:text="${selVet.getFirstName() + ' ' + selVet.getLastName()}"></option>
|
||||
</select>
|
||||
|
||||
<div th:case="'vetdate'" th:each="selVet : ${vets}">
|
||||
<div th:if="(${selVet.id} == 1)">
|
||||
<select class="form-control" th:field="*{__${name}__}"><!-- ${#temporals.format(date, 'yyyy-MM-dd HH:mm')} -->
|
||||
<option th:each="sad : ${selVet.getAvailableHours()}" th:value="${sad}" th:text="lol"></option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<span th:if="${valid}"
|
||||
class="glyphicon glyphicon-ok form-control-feedback"
|
||||
|
|
Loading…
Reference in a new issue