Implement motion editing
[cacert-boardvoting.git] / templates / create_motion_form.html
1 {{ template "header" . }}
2 <form action="/newmotion/" method="post">
3 <table>
4 <tr>
5 <td>ID:</td>
6 <td>(generated on submit)</td>
7 </tr>
8 <tr>
9 <td>Proponent:</td>
10 <td>{{ .Voter.Name }}</td>
11 </tr>
12 <tr>
13 <td>Proposed date/time:</td>
14 <td>(auto filled to current date/time)</td>
15 </tr>
16 <tr>
17 <td>Title:</td>
18 <td><input name="Title" value="{{ .Form.Title }}"/>
19 {{ with .Form.Errors.Title }}
20 <span class="error">{{ . }}</span>
21 {{ end }}
22 </td>
23 </tr>
24 <tr>
25 <td>Text:</td>
26 <td><textarea name="Content">{{ .Form.Content }}</textarea>
27 {{ with .Form.Errors.Content }}
28 <span class="error">{{ . }}</span>
29 {{ end }}
30 </td>
31 </tr>
32 <tr>
33 <td>Vote type:</td>
34 <td>
35 <select name="VoteType">
36 <option value="0"
37 {{ if eq "0" .Form.VoteType }}selected{{ end }}>
38 Motion
39 </option>
40 <option value="1"
41 {{ if eq "1" .Form.VoteType }}selected{{ end }}>Veto
42 </option>
43 </select>
44 {{ with .Form.Errors.VoteType }}
45 <span class="error">{{ . }}</span>
46 {{ end }}
47 </td>
48 </tr>
49 <tr>
50 <td rowspan="2">Due:</td>
51 <td>(autofilled from option below)</td>
52 </tr>
53 <tr>
54 <td>
55 <select name="Due">
56 <option value="+3 days">In 3 Days</option>
57 <option value="+7 days">In 1 Week</option>
58 <option value="+14 days">In 2 Weeks</option>
59 <option value="+28 days">In 4 Weeks</option>
60 </select>
61 {{ with .Form.Errors.Due }}
62 <span class="error">{{ . }}</span>
63 {{ end }}
64 </td>
65 </tr>
66 <tr>
67 <td>&nbsp;</td>
68 <td><input type="submit" value="Propose"/></td>
69 </tr>
70 </table>
71 </form>
72 <a href="/motions/">Back to motions</a>
73 {{ template "footer" . }}