]> WPIA git - motion.git/blob - templates/index.html
ad4b643d7bf1b456749199289b2f30a4e6d22bd1
[motion.git] / templates / index.html
1 {% extends "base.html" %}
2 {% block body %}
3 <div class="container">
4 {%- if categories|length != 0 %}
5 <div class="card">
6 <div class="card-body">
7 User: {{g.user}}
8 </div>
9 </div>
10 <form action="/motion" method="POST" class="form-inline">
11 <div class="motion card">
12   <div class="motion-title card-heading alert-light from-group">
13     <input class="form-control motion-title-input" placeholder="Motion title" type="text" name="title" id="title" required="yes">
14     {%- if categories|length == 1 %}
15     <input type="text" class="float form-control" maxwidth="10" disabled value="{{categories[0]}}">
16     <input type="hidden" name="category" value="{{categories[0]}}">
17     {%- else %}
18     <select class="float form-control" name="category">
19       {%- for cat in categories %}
20       <option>{{cat}}</option>
21       {%- endfor %}
22     </select>
23     {%- endif %}
24     <select class="float form-control" name="days">
25       {%- for time in times %}
26       <option>{{time}}</option>
27       {%- endfor %}
28     </select>
29   </div>
30   <div class="card-body">
31     <textarea class="form-control" placeholder="Motion content" name="content" rows="8"></textarea><br>
32     Editing note: Markdown is used formatting.<br>
33     To add a line break add two lines, to enter a link use [text](https://domain.tld/link)<br>
34     <button class="btn btn-primary" type="submit">Submit Motion</button>
35   </div>
36 </div>
37 </form>
38 {%- endif %}
39 {%- if prev %}
40 {%- if prev == -1 %}
41 <a href="/" class="btn btn-primary">Prev</a>
42 {%- else %}
43 <a href="/?start={{ prev }}" class="btn btn-primary">Prev</a>
44 {%- endif %}
45 {%- endif %}
46 {%- for motion in motions %}
47 {% include 'motion.html' %}
48 {%- endfor %}
49 {%- if more %}
50 <a href="/?start={{ more }}" class="btn btn-primary">Next</a>
51 {%- endif %}
52 </div>
53 {%- endblock %}