1 | <nav class="navbar bg-secondary bg-gradient container-fluid px-0">
|
---|
2 | <div class="container-fluid">
|
---|
3 | <span class="navbar-brand mb-0 h1">Податоци за адресите</span>
|
---|
4 | </div>
|
---|
5 | </nav>
|
---|
6 |
|
---|
7 | <div class="container-fluid">
|
---|
8 |
|
---|
9 | <div class="container">
|
---|
10 | <h2>Додади адреси</h2>
|
---|
11 | <form th:object="${address}" action="/admin/address" method="post">
|
---|
12 | <input type="hidden" th:field="*{id}">
|
---|
13 | <div class="mb-3">
|
---|
14 | <label for="street" class="form-label">Име на улица</label>
|
---|
15 | <input type="text" th:field="*{street}" class="form-control" id="street" aria-describedby="emailHelp">
|
---|
16 | </div>
|
---|
17 | <div class="mb-3">
|
---|
18 | <label for="houseNumber" class="form-label">Број</label>
|
---|
19 | <input type="number" th:field="*{houseNumber}" class="form-control" id="houseNumber">
|
---|
20 | </div>
|
---|
21 | <div class="mb-3">
|
---|
22 | <label for="entranceNumber" class="form-label">Влез</label>
|
---|
23 | <input type="number" th:field="*{entranceNumber}" class="form-control" id="entranceNumber">
|
---|
24 | </div>
|
---|
25 | <div class="mb-3">
|
---|
26 | <label for="apartmentNumber" class="form-label">Број стан</label>
|
---|
27 | <input type="number" th:field="*{apartmentNumber}" class="form-control" id="apartmentNumber">
|
---|
28 | </div>
|
---|
29 | <div class="mb-3">
|
---|
30 | <label for="apartmentNumber" class="form-label">Општина</label>
|
---|
31 | <select class="form-select" id="municipalities" name="municipality">
|
---|
32 | <option th:each="muni : ${municipalities}" th:field="*{municipality}" th:value="${muni.id}" th:text="${muni.name}"></option>
|
---|
33 | </select>
|
---|
34 | </div>
|
---|
35 | <div class="mb-3">
|
---|
36 | <label for="apartmentNumber" class="form-label">Гласачко место</label>
|
---|
37 | <select class="form-select" id="pollingStations" name="pollingStation">
|
---|
38 | <option th:each="poll : ${pollingStations}" th:field="*{pollingStation}" th:value="${poll.id}" th:text="${poll.name}"></option>
|
---|
39 | </select>
|
---|
40 | </div>
|
---|
41 | <button type="submit" class="btn btn-primary">Запиши</button>
|
---|
42 | </form>
|
---|
43 | </div>
|
---|
44 |
|
---|
45 | <div class="container">
|
---|
46 | <table class="table table-striped table-hover">
|
---|
47 | <thead class="table-header">
|
---|
48 | <tr>
|
---|
49 | <th>#</th>
|
---|
50 | <th>Улица</th>
|
---|
51 | <th>Број</th>
|
---|
52 | <th>Влез</th>
|
---|
53 | <th>Врој стан</th>
|
---|
54 | <th>Општина</th>
|
---|
55 | <th>Гласачко место</th>
|
---|
56 | </tr>
|
---|
57 | </thead>
|
---|
58 | <tbody>
|
---|
59 | <tr th:onclick="|window.location.href='/admin/address/${address.id}/edit';|" th:each="address, iter : ${addresses}">
|
---|
60 | <td th:text="${iter.count}"></td>
|
---|
61 | <td th:text="${address.street}"></td>
|
---|
62 | <td th:text="${address.houseNumber}"></td>
|
---|
63 | <td th:text="${address.entranceNumber}"></td>
|
---|
64 | <td th:text="${address.apartmentNumber}"></td>
|
---|
65 | <td th:text="${address?.municipality.name}"></td>
|
---|
66 | <td th:text="${address?.pollingStation?.name}"></td>
|
---|
67 | </tr>
|
---|
68 | </tbody>
|
---|
69 | </table>
|
---|
70 | </div>
|
---|
71 |
|
---|
72 | </div>
|
---|