|
1 | | -<!DOCTYPE html> |
2 | | -<html th:lang="${#locale.language}" |
3 | | - xmlns="http://www.w3.org/1999/xhtml" |
4 | | - xmlns:th="http://www.thymeleaf.org" |
5 | | - xmlns:sec="http://www.thymeleaf.org/extras/spring-security" |
6 | | - xmlns:sd="http://www.thymeleaf.org/spring-data"> |
7 | | -<head th:replace="layout/page :: tw-page-head(headtitle=~{::title},links=~{},refreshMessages=false)"> |
8 | | - <title th:text="'SimpleWorklist | ' + #{task.add.h1}">Title</title> |
9 | | -</head> |
10 | | -<body th:replace="layout/page :: tw-page-body(twcontent=~{::mytwcontent},twtitle=~{::mytwtitle},,scripts=~{::script})"> |
11 | | - |
12 | | -<div th:fragment="mytwtitle"> |
13 | | - <!-- New Task Form --> |
14 | | - <h1> |
15 | | - <i class="fas fa-plus-square"></i> |
16 | | - <span th:utext="#{task.add.h1}">Add Task</span> |
17 | | - </h1> |
18 | | -</div> |
19 | | - |
20 | | -<div th:fragment="mytwcontent"> |
21 | | - <form id="formId" th:action="@{/task/addtoproject/{projectId}(projectId=${thisProject.id})}" th:object="${task}" method="post"> |
22 | | - <input type="hidden" th:field="*{taskState}" /> |
23 | | - <input type="hidden" th:field="*{userAccount.id}" /> |
24 | | - <input type="hidden" th:field="*{rowCreatedAt.time}" /> |
25 | | - <div class="form-group"> |
26 | | - <label th:for="${#ids.next('title')}" class="control-label"> |
27 | | - <span th:utext="#{task.show.title}">Title</span> |
28 | | - </label> |
29 | | - <input type="text" th:field="*{title}" class="form-control" /> |
30 | | - <div> |
31 | | - <div th:each="err : ${#fields.errors('title')}" th:text="${err}" class="alert alert-danger" > |
32 | | - </div> |
33 | | - </div> |
34 | | - </div> |
35 | | - <div class="form-group"> |
36 | | - <label for="taskDueDate" class="control-label"> |
37 | | - <span th:utext="#{task.show.dueDate}">Due Date</span> |
38 | | - </label> |
39 | | - <input id="taskDueDate" type="text" th:field="*{dueDate}" class="form-control" /> |
40 | | - <div> |
41 | | - <div th:each="err : ${#fields.errors('dueDate')}" th:text="${err}" class="alert alert-danger"> |
42 | | - </div> |
43 | | - </div> |
44 | | - </div> |
45 | | - <div class="form-group"> |
46 | | - <label th:for="textEditor" class="control-label"> |
47 | | - <span th:utext="#{task.show.text}">Text</span> |
48 | | - </label> |
49 | | - <textarea id="textEditor" name="textEditor" rows="10" cols="50" th:field="*{text}" class="form-control" ></textarea> |
50 | | - <div> |
51 | | - <div th:each="err : ${#fields.errors('text')}" th:text="${err}" class="alert alert-danger"> |
52 | | - </div> |
53 | | - </div> |
54 | | - </div> |
55 | | - <div> |
56 | | - <span class="form-group"> |
57 | | - <label th:for="${#ids.next('taskEnergy')}" class="control-label"> |
58 | | - <span th:utext="#{task.show.taskEnergy}">Energy</span> |
59 | | - </label> |
60 | | - <select th:field="*{taskEnergy}"> |
61 | | - <option th:each="taskEnergyItem : ${listTaskEnergy}" |
62 | | - th:value="${taskEnergyItem.value}" |
63 | | - th:text="${#messages.msgOrNull(taskEnergyItem.code)}">Wireframe</option> |
64 | | - </select> |
65 | | - <div> |
66 | | - <div th:each="err : ${#fields.errors('taskEnergy')}" th:text="${err}" class="alert alert-danger"> |
67 | | - </div> |
68 | | - </div> |
69 | | - </span> |
70 | | - <span class="form-group"> |
71 | | - <label th:for="${#ids.next('taskTime')}" class="control-label"> |
72 | | - <span th:utext="#{task.show.taskTime}">Time</span> |
73 | | - </label> |
74 | | - <select th:field="*{taskTime}"> |
75 | | - <option th:each="taskTimeItem : ${listTaskTime}" |
76 | | - th:value="${taskTimeItem.value}" |
77 | | - th:text="${#messages.msgOrNull(taskTimeItem.code)}">Wireframe</option> |
78 | | - </select> |
79 | | - <div> |
80 | | - <div th:each="err : ${#fields.errors('taskTime')}" th:text="${err}" class="alert alert-danger"> |
81 | | - </div> |
82 | | - </div> |
83 | | - </span> |
84 | | - <span class="form-group"> |
85 | | - <label th:for="${#ids.next('context.id')}" class="control-label"> |
86 | | - <span th:utext="#{task.show.context}">Area</span> |
87 | | - </label> |
88 | | - <select th:field="*{context.id}"> |
89 | | - <option th:each="areaOption : ${contexts}" |
90 | | - th:value="${areaOption.id}" |
91 | | - th:text="${locale == 'de' ? areaOption.nameDe : areaOption.nameEn}">Wireframe</option> |
92 | | - </select> |
93 | | - <div> |
94 | | - <div th:each="err : ${#fields.errors('context.id')}" th:text="${err}" class="alert alert-danger"> |
95 | | - </div> |
96 | | - </div> |
97 | | - </span> |
98 | | - </div> |
99 | | - <button id="createNewTask" type="submit" class="btn btn-primary"> |
100 | | - <i class="fas fa-save"></i> |
101 | | - <span th:utext="#{task.add.button}">Add Task</span> |
102 | | - </button> |
103 | | - </form> |
104 | | -</div> |
105 | | - |
106 | | - <script th:src="@{/webjars/ckeditor/4.11.3/full/ckeditor.js}"></script> |
107 | | - <script th:inline="javascript"> |
108 | | - CKEDITOR.replace( 'textEditor' ); |
109 | | - </script> |
110 | | -</body> |
111 | | -</html> |
| 1 | +<!DOCTYPE html> |
| 2 | +<html th:lang="${#locale.language}" |
| 3 | + xmlns="http://www.w3.org/1999/xhtml" |
| 4 | + xmlns:th="http://www.thymeleaf.org" |
| 5 | + xmlns:sec="http://www.thymeleaf.org/extras/spring-security" |
| 6 | + xmlns:sd="http://www.thymeleaf.org/spring-data"> |
| 7 | +<head th:replace="layout/page :: tw-page-head(headtitle=~{::title},links=~{},refreshMessages=false)"> |
| 8 | + <title th:text="'SimpleWorklist | ' + #{task.add.h1}">Title</title> |
| 9 | +</head> |
| 10 | +<body th:replace="layout/page :: tw-page-body(twcontent=~{::mytwcontent},twtitle=~{::mytwtitle},,scripts=~{::script})"> |
| 11 | + |
| 12 | +<div th:fragment="mytwtitle"> |
| 13 | + <!-- New Task Form --> |
| 14 | + <h1> |
| 15 | + <i class="fas fa-plus-square"></i> |
| 16 | + <span th:utext="#{task.add.h1}">Add Task</span> |
| 17 | + </h1> |
| 18 | +</div> |
| 19 | + |
| 20 | +<div th:fragment="mytwcontent"> |
| 21 | + <form id="formId" th:action="@{/task/addtoproject/{projectId}(projectId=${thisProject.id})}" th:object="${task}" method="post"> |
| 22 | + <input type="hidden" th:field="*{taskState}" /> |
| 23 | + <input type="hidden" th:field="*{context.id}" /> |
| 24 | + <input type="hidden" th:field="*{rowCreatedAt.time}" /> |
| 25 | + <div class="form-group"> |
| 26 | + <label th:for="${#ids.next('title')}" class="control-label"> |
| 27 | + <span th:utext="#{task.show.title}">Title</span> |
| 28 | + </label> |
| 29 | + <input type="text" th:field="*{title}" class="form-control" /> |
| 30 | + <div> |
| 31 | + <div th:each="err : ${#fields.errors('title')}" th:text="${err}" class="alert alert-danger" > |
| 32 | + </div> |
| 33 | + </div> |
| 34 | + </div> |
| 35 | + <div class="form-group"> |
| 36 | + <label for="taskDueDate" class="control-label"> |
| 37 | + <span th:utext="#{task.show.dueDate}">Due Date</span> |
| 38 | + </label> |
| 39 | + <input id="taskDueDate" type="text" th:field="*{dueDate}" class="form-control" /> |
| 40 | + <div> |
| 41 | + <div th:each="err : ${#fields.errors('dueDate')}" th:text="${err}" class="alert alert-danger"> |
| 42 | + </div> |
| 43 | + </div> |
| 44 | + </div> |
| 45 | + <div class="form-group"> |
| 46 | + <label th:for="textEditor" class="control-label"> |
| 47 | + <span th:utext="#{task.show.text}">Text</span> |
| 48 | + </label> |
| 49 | + <textarea id="textEditor" name="textEditor" rows="10" cols="50" th:field="*{text}" class="form-control" ></textarea> |
| 50 | + <div> |
| 51 | + <div th:each="err : ${#fields.errors('text')}" th:text="${err}" class="alert alert-danger"> |
| 52 | + </div> |
| 53 | + </div> |
| 54 | + </div> |
| 55 | + <div> |
| 56 | + <span class="form-group"> |
| 57 | + <label th:for="${#ids.next('taskEnergy')}" class="control-label"> |
| 58 | + <span th:utext="#{task.show.taskEnergy}">Energy</span> |
| 59 | + </label> |
| 60 | + <select th:field="*{taskEnergy}"> |
| 61 | + <option th:each="taskEnergyItem : ${listTaskEnergy}" |
| 62 | + th:value="${taskEnergyItem.value}" |
| 63 | + th:text="${#messages.msgOrNull(taskEnergyItem.code)}">Wireframe</option> |
| 64 | + </select> |
| 65 | + <div> |
| 66 | + <div th:each="err : ${#fields.errors('taskEnergy')}" th:text="${err}" class="alert alert-danger"> |
| 67 | + </div> |
| 68 | + </div> |
| 69 | + </span> |
| 70 | + <span class="form-group"> |
| 71 | + <label th:for="${#ids.next('taskTime')}" class="control-label"> |
| 72 | + <span th:utext="#{task.show.taskTime}">Time</span> |
| 73 | + </label> |
| 74 | + <select th:field="*{taskTime}"> |
| 75 | + <option th:each="taskTimeItem : ${listTaskTime}" |
| 76 | + th:value="${taskTimeItem.value}" |
| 77 | + th:text="${#messages.msgOrNull(taskTimeItem.code)}">Wireframe</option> |
| 78 | + </select> |
| 79 | + <div> |
| 80 | + <div th:each="err : ${#fields.errors('taskTime')}" th:text="${err}" class="alert alert-danger"> |
| 81 | + </div> |
| 82 | + </div> |
| 83 | + </span> |
| 84 | + <span class="form-group"> |
| 85 | + <label th:for="${#ids.next('context.id')}" class="control-label"> |
| 86 | + <span th:utext="#{task.show.context}">Area</span> |
| 87 | + </label> |
| 88 | + <select th:field="*{context.id}"> |
| 89 | + <option th:each="areaOption : ${contexts}" |
| 90 | + th:value="${areaOption.id}" |
| 91 | + th:text="${locale == 'de' ? areaOption.nameDe : areaOption.nameEn}">Wireframe</option> |
| 92 | + </select> |
| 93 | + <div> |
| 94 | + <div th:each="err : ${#fields.errors('context.id')}" th:text="${err}" class="alert alert-danger"> |
| 95 | + </div> |
| 96 | + </div> |
| 97 | + </span> |
| 98 | + </div> |
| 99 | + <button id="createNewTask" type="submit" class="btn btn-primary"> |
| 100 | + <i class="fas fa-save"></i> |
| 101 | + <span th:utext="#{task.add.button}">Add Task</span> |
| 102 | + </button> |
| 103 | + </form> |
| 104 | +</div> |
| 105 | + |
| 106 | + <script th:src="@{/webjars/ckeditor/4.11.3/full/ckeditor.js}"></script> |
| 107 | + <script th:inline="javascript"> |
| 108 | + CKEDITOR.replace( 'textEditor' ); |
| 109 | + </script> |
| 110 | +</body> |
| 111 | +</html> |
0 commit comments