source: Git/src/main/resources/templates/discussionsAdd.html@ 3fe36de

main
Last change on this file since 3fe36de was 5b447b0, checked in by Test <matonikolov77@…>, 3 years ago

Adding models and resources

  • Property mode set to 100644
File size: 3.1 KB
RevLine 
[5b447b0]1<main xmlns:th="http://www.thymeleaf.org">
2
3 <div class="container">
4 <div class="row">
5 <div class="col-md-5">
6 <form th:action="@{'/discussions/save/{discussionId}' (discussionId = ${discussion?.getDiscussionId()})}" method="POST">
7 <div class="form-group">
8
9 <label for="title">Наслов</label>
10 <input type="text"
11 class="form-control"
12 id="title"
13 name="title"
14 th:value="${discussion?.getTitle()}"
15 required
16 placeholder="Наслов">
17 </div>
18 <div class="form-group">
19 <label for="text">Опис</label>
20 <input type="text"
21 class="form-control"
22 id="text"
23 name="text"
24 th:value="${discussion?.getText()}"
25 multiple
26 placeholder="Опис">
27 </div>
28
29 <div>
30 <input type="radio"
31 class="form-control discussion-type"
32 name="type"
33 th:value="M"
34 th:text="Филм"
35 th:checked="${discussion?.getType() != null && discussion.getType().toString().equals('M')}"
36
37 >
38 <input type="radio"
39 class="form-control discussion-type"
40 name="type"
41 th:value="P"
42 th:text="Личност"
43 th:checked="${discussion?.getType() != null && discussion.getType().toString().equals('P')}">
44 </div>
45
46
47
48
49 <div class="form-group">
50 <select name="idDiscussed" class="selected-discussion">
51 <option></option>
52 <option class="movies-discussion" th:each="movie:${movies}" th:value="${movie.getMovieId()}"
53 th:text="${movie.getTitle()}"
54 th:selected="${discussion?.getMovie()?.equals(movie)}"></option>
55
56 <option class="persons-discussion" th:each="person:${persons}" th:value="${person.getPersonId()}"
57 th:text="${person.getName() + ' ' + person.getSurname()}"
58 th:selected="${discussion?.getPerson()?.equals(person)}"></option>
59
60 </select>
61 </div>
62
63
64 <button id="submit" type="submit" class="btn btn-primary">Submit</button>
65 <a type="button" class="btn btn-primary" th:href="@{/discussions}">Back</a>
66 </form>
67 </div>
68 </div>
69 </div>
70
71
72</main>
Note: See TracBrowser for help on using the repository browser.