mirror of
https://github.com/binary-kitchen/doorlockd
synced 2024-12-22 10:24:26 +01:00
index: refactor render_field to render_field_label
Signed-off-by: Ralf Ramsauer <ralf@binary-kitchen.de>
This commit is contained in:
parent
ef198b74c0
commit
1b59b273d8
@ -1,4 +1,4 @@
|
|||||||
{% macro render_field(field) %}
|
{% macro render_field_label(field) %}
|
||||||
<dt>{{ field.label }}
|
<dt>{{ field.label }}
|
||||||
<dd>{{ field(**kwargs)|safe }}
|
<dd>{{ field(**kwargs)|safe }}
|
||||||
{% if field.errors %}
|
{% if field.errors %}
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
{% from "formhelpers.html" import render_field %}
|
{% from "formhelpers.html" import render_field_label %}
|
||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html>
|
<html>
|
||||||
<head>
|
<head>
|
||||||
@ -38,10 +38,10 @@
|
|||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
<form name="login" method="POST" action="{{ url_for('home') }}">
|
<form name="login" method="POST" action="{{ url_for('home') }}">
|
||||||
{{ render_field(authentication_form.username) }}
|
{{ render_field_label(authentication_form.username) }}
|
||||||
{{ render_field(authentication_form.password) }}
|
{{ render_field_label(authentication_form.password) }}
|
||||||
{{ render_field(authentication_form.open) }}
|
{{ render_field_label(authentication_form.open) }}
|
||||||
{{ render_field(authentication_form.close) }}
|
{{ render_field_label(authentication_form.close) }}
|
||||||
{{ authentication_form.csrf_token }}
|
{{ authentication_form.csrf_token }}
|
||||||
</form>
|
</form>
|
||||||
{% if response %}
|
{% if response %}
|
||||||
|
Loading…
Reference in New Issue
Block a user