manipulate projects
This commit is contained in:
@ -81,14 +81,23 @@
|
||||
<tr>
|
||||
<th>Name</th>
|
||||
<th>Benutzt in %</th>
|
||||
<th></th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr th:each="project : ${projectList}">
|
||||
<td><span th:text="${project.name}"></span></td>
|
||||
<td><span th:text="${project.percentUsage}"></span></td>
|
||||
<td><a th:href="@{/done/edit/project/{id}(id=${project.pk})}" th:title="${project.pk}"><i class="fa fa-edit"></i></a></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
<tfoot>
|
||||
<tr>
|
||||
<td colspan="3">
|
||||
<a class="nav-link btn btn-success btn-white-text" th:href="@{/done/add/project}">neues Projekt</a>
|
||||
</td>
|
||||
</tr>
|
||||
</tfoot>
|
||||
</table>
|
||||
</div>
|
||||
<div id="div_module" class="tab-pane fade tab-pane-table">
|
||||
|
42
src/main/resources/templates/done/project.html
Normal file
42
src/main/resources/templates/done/project.html
Normal file
@ -0,0 +1,42 @@
|
||||
<!DOCTYPE html>
|
||||
<html xmlns:th="http://www.thymeleaf.org" xmlns:layout="http://www.ultraq.net.nz/thymeleaf/layout"
|
||||
xmlns:sec="http://www.thymeleaf.org/extras/spring-security" layout:decorate="~{layout/main.html}">
|
||||
<head>
|
||||
<title>Projekt aktualisieren</title>
|
||||
</head>
|
||||
<body>
|
||||
<ul layout:fragment="menu">
|
||||
</ul>
|
||||
<main layout:fragment="content">
|
||||
<div class="container formpane">
|
||||
<form th:action="@{/done/upsert/project}" th:object="${projectBean}" method="post">
|
||||
<div class="row mb-3" th:if="${projectBean.pk} != null">
|
||||
<label for="inputPk" class="col-sm-2 col-form-label">Inhalt von Eintrag</label>
|
||||
<div class="col-sm-10">
|
||||
<input id="inputPk" type="text" th:field="*{pk}" class="form-control" readonly="readonly" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="row mb-3">
|
||||
<label for="outputDay" class="col-sm-2 col-form-label">Name</label>
|
||||
<div class="col-sm-10">
|
||||
<input id="inputName" type="text" th:field="*{name}" class="form-control" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="row mb-3" style="margin-top: 8px">
|
||||
<div class="col-sm-2">Änderung</div>
|
||||
<div class="col-sm-10">
|
||||
<button id="okbtn" type="submit" class="btn btn-success">speichern</button>
|
||||
<a class="btn btn-secondary" th:href="@{/done/list}">abbrechen</a>
|
||||
<div class="dropdown float-right" th:if="${projectBean.pk != null}" sec:authorize="hasRole('timetrack_user')">
|
||||
<button class="btn btn-danger dropdown-toggle" type="button" data-bs-toggle="dropdown" aria-expanded="false">Eintrag löschen</button>
|
||||
<ul class="dropdown-menu">
|
||||
<li><a class="dropdown-item" th:href="@{/done/delete/project/{id}(id=${projectBean.pk})}">endgültig löschen</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</main>
|
||||
</body>
|
||||
</html>
|
Reference in New Issue
Block a user