2017-09-13 13:39:40 +02:00
|
|
|
{% extends "layout.html" %}
|
|
|
|
{% block body %}
|
|
|
|
<div class="container-fluid">
|
|
|
|
<div class="row">
|
|
|
|
<div class="col-md-12">
|
|
|
|
<h2>{{ format_tracker_name(tracker) }}</h2>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div class="row">
|
|
|
|
<div class="col-md-4">
|
|
|
|
{{ tracker.description | md }}
|
|
|
|
<h3 style="margin-top: 1rem">Submit ticket</h3>
|
|
|
|
<form method="POST" action="{{
|
|
|
|
url_for(".tracker_submit_GET",
|
2017-09-13 14:02:25 +02:00
|
|
|
owner="~" + tracker.owner.username,
|
2017-09-13 13:39:40 +02:00
|
|
|
name=tracker.name
|
|
|
|
)
|
|
|
|
}}">
|
2017-09-13 14:02:25 +02:00
|
|
|
<div class="form-group {{ valid.cls("title") }}">
|
2017-09-13 13:39:40 +02:00
|
|
|
<label for="title">Title</label>
|
|
|
|
<input
|
|
|
|
type="text"
|
|
|
|
class="form-control"
|
2017-09-13 14:02:25 +02:00
|
|
|
maxlength="2048"
|
2017-09-13 13:39:40 +02:00
|
|
|
id="title"
|
2017-09-13 14:02:25 +02:00
|
|
|
name="title"
|
2017-09-13 14:28:10 +02:00
|
|
|
autofocus
|
2017-09-13 14:02:25 +02:00
|
|
|
value="{{ title or "" }}" />
|
|
|
|
{{valid.summary("title")}}
|
2017-09-13 13:39:40 +02:00
|
|
|
</div>
|
2017-09-13 14:02:25 +02:00
|
|
|
<div class="form-group {{ valid.cls("description") }}">
|
2017-09-13 13:39:40 +02:00
|
|
|
<label for="description">Description</label>
|
|
|
|
<textarea
|
|
|
|
class="form-control"
|
|
|
|
id="description"
|
|
|
|
name="description"
|
|
|
|
placeholder="Markdown supported"
|
2017-09-13 14:02:25 +02:00
|
|
|
maxlength="16384"
|
|
|
|
rows="5">{{ description or "" }}</textarea>
|
|
|
|
{{valid.summary("description")}}
|
2017-09-13 13:39:40 +02:00
|
|
|
</div>
|
|
|
|
<button
|
|
|
|
type="submit"
|
|
|
|
class="btn btn-default"
|
|
|
|
>Submit</button>
|
|
|
|
<label class="form-check-label" style="margin-left: 0.5rem">
|
|
|
|
<input
|
|
|
|
class="form-check-input"
|
|
|
|
type="checkbox"
|
|
|
|
name="another"
|
|
|
|
style="position: relative; top: 2px;"
|
|
|
|
{% if another %}
|
|
|
|
checked
|
|
|
|
{% endif %}> Submit another?
|
|
|
|
</label>
|
|
|
|
</form>
|
|
|
|
</div>
|
|
|
|
<div class="col-md-8">
|
|
|
|
<form>
|
|
|
|
<input
|
|
|
|
name="search"
|
|
|
|
type="text"
|
|
|
|
placeholder="Search tickets... status:closed order:updated submitter:me"
|
|
|
|
class="form-control"
|
|
|
|
value="{{ search if search else "" }}" />
|
|
|
|
</form>
|
|
|
|
<ul class="nav nav-tabs">
|
|
|
|
<li class="nav-item">
|
|
|
|
<a
|
|
|
|
class="nav-link active"
|
|
|
|
href="#">open tickets</a>
|
|
|
|
</li>
|
|
|
|
<li class="nav-item">
|
|
|
|
<a
|
|
|
|
class="nav-link"
|
|
|
|
href="#">closed tickets</a>
|
|
|
|
</li>
|
|
|
|
</ul>
|
|
|
|
<table class="table table-striped">
|
|
|
|
<thead>
|
|
|
|
<tr>
|
|
|
|
<th></th>
|
|
|
|
<th>Title</th>
|
|
|
|
<th>Updated</th>
|
|
|
|
<th>Submitter</th>
|
|
|
|
</tr>
|
|
|
|
</thead>
|
|
|
|
<tbody>
|
2017-09-13 14:19:53 +02:00
|
|
|
{% for ticket in tickets %}
|
2017-09-13 13:39:40 +02:00
|
|
|
<tr>
|
2017-09-13 14:17:52 +02:00
|
|
|
<td><a href="{{url_for(".ticket_GET",
|
|
|
|
owner="~" + tracker.owner.username,
|
|
|
|
name=name,
|
|
|
|
ticket_id=ticket.id)}}">#{{ticket.id}}</a></td>
|
|
|
|
<td>{{ ticket.title }}</td>
|
|
|
|
<td>{{ ticket.updated | date }}</td>
|
|
|
|
<td><a href="{{url_for(".ticket_GET",
|
|
|
|
owner="~" + tracker.owner.username,
|
|
|
|
name=name,
|
|
|
|
ticket_id=ticket.id)}}">{{ ticket.submitter.username }}</a></td>
|
2017-09-13 13:39:40 +02:00
|
|
|
</tr>
|
|
|
|
{% endfor %}
|
|
|
|
</tbody>
|
|
|
|
</table>
|
2017-09-13 14:28:10 +02:00
|
|
|
{% if total_pages > 1 %}
|
2017-09-13 13:39:40 +02:00
|
|
|
<div class="row">
|
|
|
|
<div class="col-md-4">
|
2017-09-13 14:28:10 +02:00
|
|
|
{% if page != 1 %}
|
|
|
|
<a href="?page={{ page - 1 }}{{ '&search=' + search if search else '' }}">[previous]</a>
|
|
|
|
{% endif %}
|
2017-09-13 13:39:40 +02:00
|
|
|
</div>
|
|
|
|
<div class="col-md-4 text-centered">
|
2017-09-13 14:28:10 +02:00
|
|
|
[ {{ page }} / {{ total_pages }} ]
|
2017-09-13 13:39:40 +02:00
|
|
|
</div>
|
|
|
|
<div class="col-md-4 text-right">
|
2017-09-13 14:28:10 +02:00
|
|
|
{% if page != total_pages %}
|
|
|
|
<a href="?page={{ page + 1 }}{{ '&search=' + search if search else '' }}">[next]</a>
|
|
|
|
{% endif %}
|
2017-09-13 13:39:40 +02:00
|
|
|
</div>
|
|
|
|
</div>
|
2017-09-13 14:28:10 +02:00
|
|
|
{% endif %}
|
2017-09-13 13:39:40 +02:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
{% endblock %}
|