mirror of
https://github.com/ae-utbm/sith.git
synced 2025-07-11 04:19:25 +00:00
Improve counters views
This commit is contained in:
13
counter/templates/counter/counter_edit.jinja
Normal file
13
counter/templates/counter/counter_edit.jinja
Normal file
@ -0,0 +1,13 @@
|
||||
{% extends "core/base.jinja" %}
|
||||
|
||||
{% block content %}
|
||||
<h2>Edit counter</h2>
|
||||
<form action="" method="post">
|
||||
{% csrf_token %}
|
||||
{{ form.as_p() }}
|
||||
<p><input type="submit" value="Save!" /></p>
|
||||
</form>
|
||||
{% endblock %}
|
||||
|
||||
|
||||
|
@ -1,15 +1,18 @@
|
||||
{% extends "core/base.jinja" %}
|
||||
|
||||
{% block title %}
|
||||
Counter list
|
||||
Counter admin list
|
||||
{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
<p><a href="{{ url('counter:new') }}">New counter</a></p>
|
||||
{% if counter_list %}
|
||||
<h3>Counter list</h3>
|
||||
<h3>Counter admin list</h3>
|
||||
<ul>
|
||||
{% for c in counter_list %}
|
||||
<li><a href="{{ url('counter:details', counter_id=c.id) }}">{{ c }}</a></li>
|
||||
<li><a href="{{ url('counter:details', counter_id=c.id) }}">{{ c }}</a> -
|
||||
<a href="{{ url('counter:admin', counter_id=c.id) }}">Edit</a> -
|
||||
<a href="{{ url('counter:delete', counter_id=c.id) }}">Delete</a></li>
|
||||
{% endfor %}
|
||||
</ul>
|
||||
{% else %}
|
||||
|
Reference in New Issue
Block a user