summaryrefslogtreecommitdiffstats
path: root/src/main/resources/templates
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/resources/templates')
-rw-r--r--src/main/resources/templates/portal.html23
1 files changed, 17 insertions, 6 deletions
diff --git a/src/main/resources/templates/portal.html b/src/main/resources/templates/portal.html
index 836c42e..d2f1847 100644
--- a/src/main/resources/templates/portal.html
+++ b/src/main/resources/templates/portal.html
@@ -4,20 +4,32 @@
</head>
<body>
<div id="container">
+ <div th:if="${message}" th:text="${message}" th:class="${'alert ' + alertClass}"/></div>
<h1>
Hello, <span th:text="${username}"></span>.
</h1>
<div th:if="${attribute01 != null}" th:text="${attribute01}"></div>
- <h2>Available Docker Images:</h2>
+ <h2>Available images:</h2>
<table>
<tr th:each="image: ${docker_images}" th:if="${image.repoTags[0] != '<none>:<none>'}">
- <td th:text="${image.repoTags[0]}" />
- <td th:text="${image.created}" />
+ <td>
+ <table>
+ <tr th:each="tag: ${image.repoTags}">
+ <td th:text="${tag}"/>
+ <td>
+ <form id="deletion_pseudoform" action="#" th:action="@{'/frontend/image/delete/{id}'(id=${tag})}" th:method="delete" th:tag="${tag}" th:onsubmit="return confirm('Do you really want to delete the imag with tag ' + this.getAttribute('tag') + '?');">
+ <button class="btn btn-danger" id="deletion_submission" type="submit">x</button>
+ </form>
+ </td>
+ </tr>
+ </table>
+ </td>
+ <td th:text="${image.created}" />
</tr>
</table>
<h2>Generate new throw-away shell:</h2>
- <form th:object="${osChoice}" th:id="request_pseudoform" action="#" th:action="@{'/frontend/container/add'}" th:method="post" th:os="${osoption}" th:onsubmit="return confirm('You are about to generate a shell with the OS ' + this.getAttribute('os') + ' - please be patient after you confirm, as the generation may take a short while.');">
+ <form th:object="${osChoice}" th:id="request_pseudoform" action="#" th:action="@{'/frontend/container/add'}" th:method="post" th:os="${osChoice}" th:onsubmit="return confirm('You are about to generate a shell with the OS ' + this.getAttribute('osoption') + ' - please be patient after you confirm, as the generation may take a short while.');">
<select class="form-control" th:object="${osChoice}" name="osChoice">
<option value="">Select operating system ...</option>
<option
@@ -26,14 +38,13 @@
th:attr="value=${osoption}"
th:text="${osoption}"></option>
</select>
- <p><span th:text="${osChoice}"></span></p>
<button class="btn btn-primary" th:id="request_submission" th:type="submit">Generate</button>
</form>
- <h2>Existing Containers:</h2>
+ <h2>Existing containers:</h2>
<table>
<tr th:each="container: ${docker_containers}">
<td th:text="${container.names[0]}" />