forms work and are saved to ldap correctly, added RFID form

This commit is contained in:
Uwe Kamper 2013-10-24 21:27:15 +02:00
parent 0aade5be94
commit 8fdc6064fa
14 changed files with 317 additions and 240 deletions

View file

@ -0,0 +1,18 @@
{% extends "base.html" %}
{% load i18n %}
{% block container %}
<div class="row">
<div class="span12">
<h2>{% block form_title %}{% endblock %}</h2>
{% block form_description %}{% endblock %}
{% if message %}
<div class="alert alert-success">{{ message }}</div>
{% endif %}
{% block form_fields %}{% endblock form_fields %}
</div>
</div>
{% endblock container %}

View file

@ -0,0 +1,20 @@
{% extends "base.html" %}
{% block body %}
<div class="container">
<div class="row">
<div class="span12">
<h2>Gastro-Pin</h2>
{% if message %}
<div class="alert alert-success">{{ message }}</div>
{% endif %}
<form action="/gastropin/" method="post">
{{ form.non_field_errors }}
{% csrf_token %}
{{ form.as_p }}
<button type="submit" class="btn btn-primary">Submit</button>
</form>
</div>
</div>
</div>
{% endblock %}

View file

@ -0,0 +1,23 @@
{% extends "form_base.html" %}
{% load i18n %}
{% load crispy_forms_tags %}
{% block form_title %}{% trans "RFID"%}{% endblock %}
{% block form_description %}
<p>{% blocktrans %}Blabla testblab bla bla blub{% endblocktrans %}</p>
{% endblock %}
{% block form_fields %}
{{ form.non_field_errors }}
<form action="{% url account.views.rfid %}" method="post" class="form-horizontal well">
{% csrf_token %}
{{ form|crispy }}
<div class="control-group">
<div class="controls">
<button type="submit" class="btn btn-primary">Speichern</button>
</div>
</div>
</form>
{% endblock form_fields %}

View file

@ -0,0 +1,25 @@
{% extends "form_base.html" %}
{% load i18n %}
{% load crispy_forms_tags %}
{% block form_title %}{% trans "WiFi Presence"%}{% endblock %}
{% block form_description %}
<p>{% blocktrans %}The WiFi Presence automatically logs you in
to the c-base presence system when you connect a device to the Crew-Wifi
(SSID: c-base-crew) with your username and password.{% endblocktrans %}</p>
{% endblock %}
{% block form_fields %}
{{ form.non_field_errors }}
<form action="{% url account.views.wlan_presence %}" method="post" class="form-horizontal well">
{% csrf_token %}
{{ form|crispy }}
<div class="control-group">
<div class="controls">
<button type="submit" class="btn btn-primary">Speichern</button>
</div>
</div>
</form>
{% endblock form_fields %}