mirror of
https://github.com/moepman/bk-dss
synced 2024-12-22 18:24:27 +01:00
bump and adjust to bootstrap v5
This commit is contained in:
parent
3e401c6946
commit
a8ebf338d2
2
dss.py
2
dss.py
@ -37,7 +37,7 @@ class CreateForm(FlaskForm):
|
|||||||
|
|
||||||
|
|
||||||
class EditForm(FlaskForm):
|
class EditForm(FlaskForm):
|
||||||
user = StringField('Username', render_kw={'readonly': True})
|
user = StringField('Username', render_kw={'disabled': True})
|
||||||
pwd1 = PasswordField('New Password', validators=[DataRequired()])
|
pwd1 = PasswordField('New Password', validators=[DataRequired()])
|
||||||
pwd2 = PasswordField('New Password (repeat)', validators=[DataRequired(), EqualTo('pwd1', "Passwords must match")])
|
pwd2 = PasswordField('New Password (repeat)', validators=[DataRequired(), EqualTo('pwd1', "Passwords must match")])
|
||||||
submit = SubmitField('Submit')
|
submit = SubmitField('Submit')
|
||||||
|
9
static/css/bootstrap.min.css
vendored
9
static/css/bootstrap.min.css
vendored
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@ -2,7 +2,6 @@
|
|||||||
<html lang="en">
|
<html lang="en">
|
||||||
<head>
|
<head>
|
||||||
<meta charset="UTF-8">
|
<meta charset="UTF-8">
|
||||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
|
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
|
||||||
<link href="/static/css/bootstrap.min.css" type="text/css" rel="stylesheet">
|
<link href="/static/css/bootstrap.min.css" type="text/css" rel="stylesheet">
|
||||||
<link href="/static/css/style.css" type="text/css" rel="stylesheet">
|
<link href="/static/css/style.css" type="text/css" rel="stylesheet">
|
||||||
|
@ -1,18 +1,20 @@
|
|||||||
{% macro render_field(field) %}
|
{% macro render_field(field) %}
|
||||||
<div class="form-group row mb-3">
|
<div class="row mb-3">
|
||||||
{{ field.label(class_="col-form-label col-sm-3 text-right") }}
|
{{ field.label(class_="col-form-label col-sm-3 text-right") }}
|
||||||
{% if field.errors %}{% set class_extras = " is-invalid" %}{% else %}{% set class_extras = "" %}{% endif %}
|
{% if field.errors %}{% set class_extras = " is-invalid" %}{% else %}{% set class_extras = "" %}{% endif %}
|
||||||
|
{% if field.type == "SelectField" %}{% set class_extras = class_extras + " form-select" %}{% endif %}
|
||||||
<div class="col-sm-5">{{ field(class_="form-control" + class_extras) }}
|
<div class="col-sm-5">{{ field(class_="form-control" + class_extras) }}
|
||||||
{% if field.errors %}
|
{% if field.errors %}
|
||||||
<div class="invalid-feedback">
|
<div class="invalid-feedback">
|
||||||
{% for error in field.errors %}
|
{% for error in field.errors %}
|
||||||
{{ error }}
|
{{ error }}
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
</div>
|
</div>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
</div></div>
|
</div>
|
||||||
|
</div>
|
||||||
{%- endmacro %}
|
{%- endmacro %}
|
||||||
|
|
||||||
{% macro render_button(button) %}
|
{% macro render_button(button) %}
|
||||||
<div class="form-group row"><div class="offset-sm-3 col-sm-5">{{ button(class_="btn btn-primary") }}</div></div>
|
<div class="row"><div class="offset-sm-3 col-sm-5">{{ button(class_="btn btn-primary") }}</div></div>
|
||||||
{%- endmacro %}
|
{%- endmacro %}
|
||||||
|
Loading…
Reference in New Issue
Block a user