Bill form style update
This commit is contained in:
parent
9826d12466
commit
c29ec24bdd
|
@ -11,14 +11,15 @@ FORM_RENDER_KW = {
|
|||
}
|
||||
|
||||
class BillForm(Form):
|
||||
payment_to = StringField(_("Payment to"), [validators.DataRequired()])
|
||||
payment_to = StringField(_("Payment to"), [validators.DataRequired()], render_kw = FORM_RENDER_KW)
|
||||
description = TextAreaField(_("Description"), render_kw = {
|
||||
"cols": 55,
|
||||
"rows": 8
|
||||
"rows": 8,
|
||||
**FORM_RENDER_KW
|
||||
})
|
||||
sum = DecimalField(_("Sum"))
|
||||
kid = IntegerField(_("KID"))
|
||||
date_due = DateField(_("Date due"))
|
||||
sum = DecimalField(_("Sum"), render_kw = FORM_RENDER_KW)
|
||||
kid = IntegerField(_("KID"), render_kw = FORM_RENDER_KW)
|
||||
date_due = DateField(_("Date due"), render_kw = FORM_RENDER_KW)
|
||||
|
||||
class LoginForm(Form):
|
||||
email = StringField(_("Email"), [
|
||||
|
|
|
@ -23,18 +23,17 @@
|
|||
</div>
|
||||
<div class="modal-body">
|
||||
{% macro render_field(field) %}
|
||||
<dt>
|
||||
<div class="form-group">
|
||||
<label for="{{ field.label.field_id }}">{{ _(field.label.text) }}</label>
|
||||
</dt>
|
||||
<dd>{{ field(**kwargs)|safe }}
|
||||
{{ field(**kwargs)|safe }}
|
||||
{% if field.errors %}
|
||||
<ul class=errors>
|
||||
{% for error in field.errors %}
|
||||
<li>{{ error }}</li>
|
||||
<li>{{ error }}</li>
|
||||
{% endfor %}
|
||||
</ul>
|
||||
{% endif %}
|
||||
</dd>
|
||||
</div>
|
||||
{% endmacro %}
|
||||
<form method=post>
|
||||
<dl>
|
||||
|
|
Loading…
Reference in New Issue
Block a user