]> juplo.de Git - demos/spring-boot/commitdiff
WIP
authorKai Moritz <kai@juplo.de>
Tue, 21 Jan 2020 19:25:58 +0000 (20:25 +0100)
committerKai Moritz <kai@juplo.de>
Fri, 7 Apr 2023 11:21:44 +0000 (13:21 +0200)
src/main/resources/templates/form.html

index b1f53d89c2c42763a4c33d9f8c84b2b875fe851a..f009beb3ee267b9d282246b7637b3bc0d0930b8c 100644 (file)
               <div class="form-group" th:each="row : ${card.value.entrySet()}">
                 <input type="checkbox" id="x" class="form-control" th:field="*{cards[__${card.key}__][__${row.key}__]}" />
                 <label for="x" th:for="${#ids.prev('cards[__${card.key}__][__${row.key}__]')}" th:text="${row.value}">ROW_NAME</label>
-                <button type="submit" name="removeRow" class="btn btn-primary" th:value="|${card.key}:${row.key}|">Remove</button>
+                <button type="submit" name="remove" class="btn btn-primary" th:value="|${card.key}:${row.key}|">Remove</button>
+              </div>
+              <div class="form-group">
+                <input type="text" th:field="*{row[__${card.key}__]}" />
+                <button type="submit" name="add" value="row" class="btn btn-primary">Add Row</button>
               </div>
-              <button type="submit" name="add" value="row" class="btn btn-primary">Add Row</button>
             </div>
             <div class="card-footer">
               <button type="submit" name="remove" value="card" class="btn btn-primary">Remove Card</button>
             </div>
           </div>
         </div>
-        <button type="submit" name="add" value="card" class="btn btn-primary">Add Card</button>
+        <p><button type="submit" name="add" value="card" class="btn btn-primary">Add Card</button></p>
       </form>
     </main>
   </body>