upgrade templates to named urls for django-1.8
This commit is contained in:
parent
43260fb59f
commit
ebe3a3a7e1
10 changed files with 17 additions and 18 deletions
|
|
@ -9,7 +9,7 @@
|
|||
{% endblock %}
|
||||
|
||||
{% block form_fields %}
|
||||
<form action="{% url account.views.admin %}" method="post" class="form-horizontal well">
|
||||
<form action="{% url 'admin' %}" method="post" class="form-horizontal well">
|
||||
{% csrf_token %}
|
||||
{{ form|crispy }}
|
||||
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@
|
|||
{% endblock %}
|
||||
|
||||
{% block form_fields %}
|
||||
<form action="{% url account.views.clabpin %}" method="post" class="form-horizontal well">
|
||||
<form action="{% url 'clabpin' %}" method="post" class="form-horizontal well">
|
||||
{% csrf_token %}
|
||||
{{ form|crispy }}
|
||||
|
||||
|
|
|
|||
|
|
@ -14,7 +14,7 @@
|
|||
{% endblock %}
|
||||
|
||||
{% block form_fields %}
|
||||
<form action="{% url account.views.gastropin %}" method="post" class="form-horizontal well">
|
||||
<form action="{% url 'gastropin' %}" method="post" class="form-horizontal well">
|
||||
{% csrf_token %}
|
||||
{{ form|crispy }}
|
||||
|
||||
|
|
|
|||
|
|
@ -1,7 +1,6 @@
|
|||
{% extends "base.html" %}
|
||||
|
||||
{% block container %}
|
||||
BLA
|
||||
<div class="row">
|
||||
<div class="span12">
|
||||
<h2>members of {{ group.name }}</h2>
|
||||
|
|
|
|||
|
|
@ -4,41 +4,41 @@
|
|||
{% block body %}
|
||||
<div class="container">
|
||||
<ul class="nav nav-tabs">
|
||||
{% url account.views.home as home_url %}
|
||||
{% url 'home' as home_url %}
|
||||
<li class="{% if request.path == home_url %}active{% endif %}">
|
||||
<a href="{{ home_url }}">{% trans "Home" %}</a>
|
||||
</li>
|
||||
{% url account.views.password as password_url %}
|
||||
{% url 'password' as password_url %}
|
||||
<li class="{% if request.path == password_url %}active{% endif %}">
|
||||
<a href="{{ password_url }}">{% trans "Password" %}</a>
|
||||
</li>
|
||||
{% url account.views.gastropin as gastro_url %}
|
||||
{% url 'gastropin' as gastro_url %}
|
||||
<li class="{% if request.path == gastro_url %}active{% endif %}">
|
||||
<a href="{{ gastro_url }}">{% trans "Gastro-PIN" %}</a>
|
||||
</li>
|
||||
{% url account.views.wlan_presence as wlan_presence_url %}
|
||||
{% url 'wlan_presence' as wlan_presence_url %}
|
||||
<li class="{% if request.path == wlan_presence_url %}active{% endif %}">
|
||||
<a href="{{ wlan_presence_url }}">{% trans "WiFi presence" %}</a>
|
||||
</li>
|
||||
{% url account.views.rfid as rfid_url %}
|
||||
{% url 'rfid' as rfid_url %}
|
||||
<li class="{% if request.path == rfid_url %}active{% endif %}">
|
||||
<a href="{{ rfid_url }}">{% trans "RFID" %}</a>
|
||||
</li>
|
||||
{% url account.views.clabpin as clab_url %}
|
||||
{% url 'clabpin' as clab_url %}
|
||||
<li class="{% if request.path == clab_url %}active{% endif %}">
|
||||
<a href="{{ clab_url }}">{% trans "c-lab-PIN" %}</a>
|
||||
</li>
|
||||
{% url account.views.nrf24 as nrf24_url %}
|
||||
{% url 'nrf24' as nrf24_url %}
|
||||
<li class="{% if request.path == nrf24_url %}active{% endif %}">
|
||||
<a href="{{ nrf24_url }}">{% trans "NRF24" %}</a>
|
||||
</li>
|
||||
{% url account.views.sippin as sippin_url %}
|
||||
{% url 'sippin' as sippin_url %}
|
||||
<li class="{% if request.path == sippin_url %}active{% endif %}">
|
||||
<a href="{{ sippin_url }}">{% trans "SIP-PIN" %}</a>
|
||||
</li>
|
||||
{% for group in request.user.groups.all %}
|
||||
{% if group.name == 'ldap_admins' %}
|
||||
{% url account.views.admin as admin_url %}
|
||||
{% url 'admin' as admin_url %}
|
||||
<li class="{% if request.path == admin_url %}active{% endif %}">
|
||||
<a href="{{ admin_url }}"><i class="icon icon-white icon-star"></i>
|
||||
{% trans "Admin" %}</a>
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@
|
|||
{% endblock %}
|
||||
|
||||
{% block form_fields %}
|
||||
<form action="{% url account.views.nrf24 %}" method="post" class="form-horizontal well">
|
||||
<form action="{% url 'nrf24' %}" method="post" class="form-horizontal well">
|
||||
{% csrf_token %}
|
||||
{{ form|crispy }}
|
||||
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@
|
|||
{% endblock %}
|
||||
|
||||
{% block form_fields %}
|
||||
<form action="{% url account.views.password %}" method="post" class="form-horizontal well">
|
||||
<form action="{% url 'password' %}" method="post" class="form-horizontal well">
|
||||
{% csrf_token %}
|
||||
{{ form|crispy }}
|
||||
|
||||
|
|
|
|||
|
|
@ -15,7 +15,7 @@
|
|||
|
||||
{% block form_fields %}
|
||||
{{ form.non_field_errors }}
|
||||
<form action="{% url account.views.rfid %}" method="post"
|
||||
<form action="{% url 'rfid' %}" method="post"
|
||||
class="form-horizontal well">
|
||||
{% csrf_token %}
|
||||
{{ form|crispy }}
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@
|
|||
{% endblock %}
|
||||
|
||||
{% block form_fields %}
|
||||
<form action="{% url account.views.sippin %}" method="post" class="form-horizontal well">
|
||||
<form action="{% url 'sippin' %}" method="post" class="form-horizontal well">
|
||||
{% csrf_token %}
|
||||
{{ form|crispy }}
|
||||
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@
|
|||
|
||||
{% block form_fields %}
|
||||
{{ form.non_field_errors }}
|
||||
<form action="{% url account.views.wlan_presence %}" method="post" class="form-horizontal well">
|
||||
<form action="{% url 'wlan_presence' %}" method="post" class="form-horizontal well">
|
||||
{% csrf_token %}
|
||||
{{ form|crispy }}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue