diff options
author | Georg Pfuetzenreuter | 2022-05-06 11:49:22 +0200 |
---|---|---|
committer | Georg Pfuetzenreuter | 2022-05-06 11:49:22 +0200 |
commit | beb92675071c69b86b5338297822c834ffd548f6 (patch) | |
tree | d81391468881407374f6c16105c5ca0ae61331c2 /src | |
parent | 6edbc437a1e993f77eeabd458d82d52c77d8e5fa (diff) | |
download | pubsh-web-beb92675071c69b86b5338297822c834ffd548f6.tar.gz pubsh-web-beb92675071c69b86b5338297822c834ffd548f6.tar.bz2 pubsh-web-beb92675071c69b86b5338297822c834ffd548f6.zip |
Init templates
Signed-off-by: Georg Pfuetzenreuter <mail@georg-pfuetzenreuter.net>
Diffstat (limited to 'src')
-rw-r--r-- | src/main/java/net/libertacasa/pubsh/web/WebApplication.java | 2 | ||||
-rw-r--r-- | src/main/resources/templates/external.html | 22 | ||||
-rw-r--r-- | src/main/resources/templates/layout.html | 18 | ||||
-rw-r--r-- | src/main/resources/templates/logout.html | 9 | ||||
-rw-r--r-- | src/main/resources/templates/portal.html | 55 | ||||
-rw-r--r-- | src/main/resources/templates/userInfo.html | 15 |
6 files changed, 120 insertions, 1 deletions
diff --git a/src/main/java/net/libertacasa/pubsh/web/WebApplication.java b/src/main/java/net/libertacasa/pubsh/web/WebApplication.java index 2d35692..ad1a2d4 100644 --- a/src/main/java/net/libertacasa/pubsh/web/WebApplication.java +++ b/src/main/java/net/libertacasa/pubsh/web/WebApplication.java @@ -34,7 +34,7 @@ public class WebApplication { @GetMapping("/") public String index() { - return "homepage"; + return "external"; } diff --git a/src/main/resources/templates/external.html b/src/main/resources/templates/external.html new file mode 100644 index 0000000..c2c8cd4 --- /dev/null +++ b/src/main/resources/templates/external.html @@ -0,0 +1,22 @@ +<!DOCTYPE html> +<html xmlns:th="http://www.thymeleaf.org"> +<head th:include="layout :: headerFragment"> +</head> +<body> + <div class="container"> + <div class="jumbotron text-center"> + <h1>Welcome ...</h1> + </div> + <div> + + <h2>Existing Users</h2> + <div class="well"> + <b>Enter the intranet: </b><a th:href="@{/portal}">Portal</a> + </div> + </div> + <!--div id="pagefoot" th:include="layout :: footerFragment">Footer</div--> + </div> + <!-- container --> + +</body> +</html> diff --git a/src/main/resources/templates/layout.html b/src/main/resources/templates/layout.html new file mode 100644 index 0000000..bab0c29 --- /dev/null +++ b/src/main/resources/templates/layout.html @@ -0,0 +1,18 @@ + +<head th:fragment="headerFragment"> +<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> +<title>Customer Portal</title> +<link + href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css" + rel="stylesheet" + integrity="sha384-BVYiiSIFeK1dGmJRAkycuHAHRg32OmUcww7on3RYdg4Va+PmSTsz/K68vbdEjh4u" + crossorigin="anonymous"></link> +<link + href="https://cdn.datatables.net/1.10.16/css/jquery.dataTables.min.css" + rel="stylesheet"></link> +</head> + +<div id="pagefoot" th:fragment="footerFragment"> + <p>Document last modified 2017/10/23.</p> + <p>Copyright: Lorem Ipsum</p> +</div>
\ No newline at end of file diff --git a/src/main/resources/templates/logout.html b/src/main/resources/templates/logout.html new file mode 100644 index 0000000..81679cf --- /dev/null +++ b/src/main/resources/templates/logout.html @@ -0,0 +1,9 @@ +<!DOCTYPE html> +<html xmlns:th="http://www.thymeleaf.org"> +<head th:include="layout :: headerFragment"> +</head> +<body> +<p>You logged out.</p> +<a href="/">Go home</a> +</body> +</html>
\ No newline at end of file diff --git a/src/main/resources/templates/portal.html b/src/main/resources/templates/portal.html new file mode 100644 index 0000000..8cd2ad6 --- /dev/null +++ b/src/main/resources/templates/portal.html @@ -0,0 +1,55 @@ +<!DOCTYPE html> +<html xmlns:th="http://www.thymeleaf.org"> +<head th:include="layout :: headerFragment"> +</head> +<body> + <div id="container"> + <h1> + Hello, <span th:text="${username}"></span>. + </h1> + <div th:if="${attribute01 != null}" th:text="${attribute01}"></div> + <h2>Docker 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}" /> + </tr> + </table> + <h2>Docker Containers:</h2> + <table> + <tr th:each="container: ${docker_containers}"> + <td th:text="${container.names[0]}" /> + <td th:text="${container.image}" /> + <td th:text="${container.imageId}" /> + <td th:text="${container.status}" /> + <td><input type="hidden" th:value="${container.id}" name="containerID"/><button type="submit" class="removebutton" name="action" value="remove">Remove</button></td> + </tr> + </table> + + <!--h4>We are currently running <span th:text="${docker_containercount}"></span> containers.</h4--> + + <!--table class="table table-striped"> + <thead> + <tr> + <th>ID</th> + <th>Name</th> + <th>Address</th> + <th>Service Rendered</th> + </tr> + </thead> + <tbody> + <tr th:each="customer : ${customers}"> + <td th:text="${customer.id}">Text ...</td> + <td th:text="${customer.name}">Text ...</td> + <td th:text="${customer.address}">Text ...</td> + <td th:text="${customer.serviceRendered}">Text...</td> + </tr> + </tbody> + </table--> + <!--div id="pagefoot" th:include="layout :: footerFragment">Footer</div--> + <p></p> + <a href="/logout">Logout</a> + </div> + <!-- container --> +</body> +</html> diff --git a/src/main/resources/templates/userInfo.html b/src/main/resources/templates/userInfo.html new file mode 100644 index 0000000..1446fe2 --- /dev/null +++ b/src/main/resources/templates/userInfo.html @@ -0,0 +1,15 @@ +<!DOCTYPE html> +<html xmlns:th="http://www.thymeleaf.org"> +<head th:include="layout :: headerFragment"> +</head> +<body> + <div id="container"> + <h1> + Hello, <span th:text="${username}">--name--</span>. + </h1> + <h3> + Your Date of Birth as per our records is <span th:text="${dob}" />. + </h3> + </div> +</body> +</html> |