Add composite asset creation functionality with new views and asset descriptor handling
All checks were successful
Build / build (push) Successful in 1m22s

This commit is contained in:
2025-06-15 20:27:17 +02:00
parent 40e13ec585
commit 069e38fef9
4 changed files with 61 additions and 2 deletions

View File

@@ -0,0 +1,11 @@
<body th:replace="~{fragments :: base(title='Select type to create', content=~{::content})}">
<div th:fragment="content">
<h2>Create a new composite device</h2>
<form method="get" action="/create_composite">
<div th:each="d : ${descriptors.getAssets()}" th:if="${d.visible}"><label><input type="checkbox" value="on" th:name="${d.type}"><span th:text="${d.displayName}"></span></label></div>
<p>
<input type="submit" value="Create Composite">
</p>
</form>
</div>
</body>

View File

@@ -2,6 +2,7 @@
<div th:fragment="content">
<h2>Create a new device</h2>
<ul>
<li><a href="/create_composite"><i>Composite</i></a></li>
<li th:each="d : ${descriptors.getAssets()}" th:if="${d.visible}"><a th:href="'/create/'+${d.getType()}" th:text="${d.displayName}"></a></li>
</ul>
</div>