aboutsummaryrefslogtreecommitdiff
path: root/basicConfig/templates/residency.html
diff options
context:
space:
mode:
authorChristian Kollmann <christian.kollmann@a-sit.at>2021-12-01 14:46:18 +0100
committerChristian Kollmann <christian.kollmann@a-sit.at>2021-12-02 16:13:48 +0100
commit401cd39689d73f1cc865bb3c7cfca40a3f5ac625 (patch)
treedbfbbe4fd54d05b3a80a7c87b016cfd47e501ffe /basicConfig/templates/residency.html
parent47565187c7f273c49e0347fb5ad34ae4a3d1f616 (diff)
downloadNational_eIDAS_Gateway-401cd39689d73f1cc865bb3c7cfca40a3f5ac625.tar.gz
National_eIDAS_Gateway-401cd39689d73f1cc865bb3c7cfca40a3f5ac625.tar.bz2
National_eIDAS_Gateway-401cd39689d73f1cc865bb3c7cfca40a3f5ac625.zip
Add simple page to search for an Austrian Address
Diffstat (limited to 'basicConfig/templates/residency.html')
-rw-r--r--basicConfig/templates/residency.html80
1 files changed, 80 insertions, 0 deletions
diff --git a/basicConfig/templates/residency.html b/basicConfig/templates/residency.html
new file mode 100644
index 00000000..96fa13f8
--- /dev/null
+++ b/basicConfig/templates/residency.html
@@ -0,0 +1,80 @@
+<!DOCTYPE html>
+<html xmlns:th="http://www.thymeleaf.org"
+ xmlns:layout="http://www.ultraq.net.nz/thymeleaf/layout"
+ layout:decorator="fragments/base"
+ th:with="lang=${#locale.language}" th:lang="${lang}">
+
+<head>
+ <meta content="text/html; charset=utf-8" http-equiv="Content-Type">
+ <meta name="viewport" content="width=device-width, initial-scale=1">
+ <link rel="stylesheet" href="$contextPath/static/css/css_country.css" th:href="@{/static/css/css_country.css}"/>
+ <script type="text/javascript" src="$contextPath/static/js/jquery-3.6.0.js"
+ th:attr="src=@{/static/js/jquery-3.6.0.min.js}"></script>
+ <title th:text="#{gui.residency.title}">Österreichischer Wohnsitz</title>
+ <script type="text/javascript" th:inline="javascript">
+ function search() {
+ let updatedText = /*[[#{gui.residency.updated}]]*/ 'Updated text';
+ let errorText = /*[[#{gui.residency.error}]]*/ 'Error';
+ $.ajax({
+ type: "POST",
+ url: "http://localhost:8080/ms_connector/residency/search",
+ data: $("#inputForm").serialize()
+ }).done(function (data, textStatus, jqXHR) {
+ $("#inputCity").val(data["city"]);
+ $("#inputStreet").val(data["street"]);
+ $("#inputNumber").val(data["number"]);
+ $("#textInfo").text(updatedText);
+ }).fail(function (jqXHR, textStatus, errorThrown) {
+ $("#textInfo").text(errorText);
+ })
+ }
+ </script>
+</head>
+
+<body>
+<div id="page">
+ <div class="languageselection" th:include="language_selection :: selectlanguage">
+ LanguageSelectionBlock
+ </div>
+
+ <h2 th:text="#{gui.residency.header.selection}">Search your Austrian Residency</h2>
+
+ <div id="residency">
+ <div>
+ <p><span id="textInfo">Infotext</span></p>
+ </div>
+ <form id="inputForm" class="block" method="post" action="$contextPath$submitEndpoint"
+ th:attr="action=@{${submitEndpoint}}">
+ <div>
+ <label for="inputCity">City</label>
+ <input type="text" id="inputCity" name="city" value="City"/>
+ </div>
+ <div>
+ <label for="inputStreet">Street</label>
+ <input type="text" id="inputStreet" name="street" value="Street"/>
+ </div>
+ <div>
+ <label for="inputNumber">Number</label>
+ <input type="text" id="inputNumber" name="number" value="Number"/>
+ </div>
+ <div>
+ <button type="button" class="block" onclick="search()" th:attr="value=#{gui.residency.search}">Search
+ </button>
+ </div>
+ <div>
+ <button type="button" class="block" th:attr="value=#{gui.residency.proceed}">Proceed</button>
+ </div>
+ <input type="hidden" name="pendingid" value="$pendingid" th:attr="value=${pendingid}"/>
+ </form>
+ </div>
+
+ <form class="block" method="post" action="$contextPath$submitEndpoint" th:attr="action=@{${submitEndpoint}}">
+ <input type="submit" class="btn btn-outline-primary btn-block" value="Abbrechen/Cancel"
+ th:attr="value=#{gui.residency.cancel}">
+ <input type="hidden" name="stopAuthProcess" value="true">
+ <input type="hidden" name="pendingid" value="$pendingid" th:attr="value=${pendingid}">
+ </form>
+
+</div>
+</body>
+</html>