source: src/main/resources/templates/kontrola.html@ bde8b13

Last change on this file since bde8b13 was bde8b13, checked in by ppaunovski <paunovskipavel@…>, 6 months ago

All 3 main use cases implemented.

  1. Starting a commute
  2. Writing a ticket
  3. Starting an instance of a Bus Line
  • Property mode set to 100644
File size: 5.6 KB
Line 
1<div xmlns:th="http://www.thymeleaf.org">
2 <section class="jumbotron text-center">
3 <div class="container">
4 <h1 class="jumbotron-heading">WEB PROGRAMMING SHOP</h1>
5 <h3 class="jumbotron-heading">All products</h3>
6 </div>
7 </section>
8
9
10 <form class="form-signin mt-xl-5" method="post" th:action="@{'/kontrola/{id}/kazni-neregistriran'(id=${kontrola.kontrolaId})}">
11 <h2 class="form-signin-heading">Kazna za neregirstiran</h2>
12
13 <p>
14 <label for="dokument" class="sr-only">Email</label>
15 <input class="form-control" name="dokument" id="dokument" type="text">
16 </p>
17
18
19 <p>
20 <label for="telefon" class="sr-only">Telefon</label>
21 <input class="form-control" name="telefon" id="telefon" type="text">
22 </p>
23
24 <p>
25 <label for="ime" class="sr-only">Ime</label>
26 <input class="form-control" name="ime" id="ime" type="text">
27 </p>
28
29 <p>
30 <label for="adresa" class="sr-only">Adresa</label>
31 <input class="form-control" name="adresa" id="adresa" type="text">
32 </p>
33
34
35 <p>
36 <label for="iznos" class="sr-only">Iznos</label>
37 <input class="form-control" name="iznos" id="iznos" type="number">
38 </p>
39
40
41 <div th:if="${param.error}" th:text="${param.error}" class="text-danger"></div>
42
43 <div class="row">
44 <div class="col-md-3">
45 <button id="submit" class="btn btn-lg btn-primary btn-block" type="submit">Kazni</button>
46 </div>
47 </div>
48 </form>
49
50
51 <form class="form-signin mt-xl-5" method="post" th:action="@{'/kontrola/{id}/kazni-registriran'(id=${kontrola.kontrolaId})}">
52 <h2 class="form-signin-heading">Kazna za regirstiran</h2>
53
54 <p>
55 <label for="dk" class="sr-only">Dokument</label>
56 <input class="form-control" name="dokument" id="dk" type="text">
57 </p>
58
59 <p>
60 <label for="iz" class="sr-only">Iznos</label>
61 <input class="form-control" name="iznos" id="iz" type="number">
62 </p>
63
64 <p>
65 <label for="patnik" class="sr-only">Patnik</label>
66 <select id="patnik" name="patnik" class="form-control">
67 <option th:each="patnik : ${patnici}"
68 th:value="${patnik.kId}"
69 th:text="${patnik.kIme} + ' - ' + ${patnik.kEmail}">
70
71 </option>
72 </select>
73 </p>
74
75
76 <div th:if="${param.error}" th:text="${param.error}" class="text-danger"></div>
77
78 <div class="row">
79 <div class="col-md-3">
80 <button id="sub" class="btn btn-lg btn-primary btn-block" type="submit">Kazni</button>
81 </div>
82 </div>
83 </form>
84
85
86
87
88
89
90
91
92 <div class="container mb-4">
93 <div class="row">
94 <div class="col-12" >
95 <div class="table-responsive">
96 <table class="table table-striped">
97 <thead>
98 <tr>
99 <th scope="col">#</th>
100 <th scope="col">Iznos</th>
101 <th scope="col">Plateno</th>
102 <th scope="col">Dokument</th>
103 <th scope="col"></th>
104 <th scope="col"></th>
105 <th scope="col"></th>
106 </tr>
107 </thead>
108 <tbody>
109 <tr th:each="kazna : ${kazni}" class="product">
110 <td th:text="${kazna.kzId}"></td>
111 <td th:text="${kazna.kzIznos}"></td>
112 <td th:text="${kazna.kzPlateno}"></td>
113 <td th:text="${kazna.kzDokument}"></td>
114
115 <td class="text-right">
116 <th:block sec:authorize="hasRole('ROLE_ADMIN')">
117 <form th:action="@{'/products/delete/{id}' (id=${kazna.kzId})}"
118 th:method="DELETE">
119 <button type="submit"
120 class="btn btn-sm btn-danger delete-product">
121 <i class="fas fa-trash-alt"></i> Delete
122 </button>
123 </form>
124 </th:block>
125 </td>
126 <td>
127 <th:block sec:authorize="hasRole('ROLE_ADMIN')">
128 <a th:href="@{'/products/edit-form/{id}' (id=${kazna.kzId})}"
129 class="btn btn-sm btn-info edit-product">
130 <i class="fas fa-edit"></i> Edit
131 </a>
132 </th:block>
133 </td>
134 <td>
135 <form th:action="@{'/shopping-cart/add-product/{id}' (id=${kazna.kzId})}"
136 th:method="POST">
137 <button type="submit" class="btn btn-sm btn-success add-to-cart">
138 <i class="fas fa-shopping-cart"></i> Add to cart
139 </button>
140 </form>
141 </td>
142 </tr>
143 </tbody>
144 </table>
145 </div>
146 </div>
147
148 </div>
149 </div>
150</div>
151
152
Note: See TracBrowser for help on using the repository browser.