Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Odevzdávací Systém MO
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Model registry
Analyze
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Martin Mareš
Odevzdávací Systém MO
Merge requests
!2
Place editing
Code
Review changes
Check out branch
Download
Patches
Plain diff
Expand sidebar
Merged
Place editing
jirka/schools
into
master
Overview
28
Commits
14
Changes
3
Merged
Jiří Setnička
requested to merge
jirka/schools
into
master
4 years ago
Overview
28
Commits
14
Changes
3
0
0
Merge request reports
Viewing commit
c644f6bb
Prev
Next
Show latest version
3 files
+
4
−
0
Side-by-side
Compare changes
Side-by-side
Inline
Show whitespace changes
Show one file at a time
Files
3
c644f6bb
Přidání flask_bootstrap pro ulehčení práce s formy
· c644f6bb
Jiří Setnička
authored
4 years ago
mo/web/__init__.py
+
2
−
0
View file @ c644f6bb
Edit in single-file editor
Open in Web IDE
Show full file
@@ -5,6 +5,7 @@ import sys
@@ -5,6 +5,7 @@ import sys
import
os
import
os
import
logging
import
logging
from
flask_wtf
import
FlaskForm
from
flask_wtf
import
FlaskForm
from
flask_bootstrap
import
Bootstrap
import
flask_wtf.file
import
flask_wtf.file
import
wtforms
import
wtforms
import
wtforms.validators
as
validators
import
wtforms.validators
as
validators
@@ -29,6 +30,7 @@ app.jinja_env.trim_blocks = True
@@ -29,6 +30,7 @@ app.jinja_env.trim_blocks = True
app
.
logger
.
setLevel
(
logging
.
DEBUG
)
app
.
logger
.
setLevel
(
logging
.
DEBUG
)
db
.
flask_db
=
SQLAlchemy
(
app
,
metadata
=
db
.
metadata
)
db
.
flask_db
=
SQLAlchemy
(
app
,
metadata
=
db
.
metadata
)
Bootstrap
(
app
)
# make bootstrap libs accessible for the app
class
NeedLoginError
(
werkzeug
.
exceptions
.
Forbidden
):
class
NeedLoginError
(
werkzeug
.
exceptions
.
Forbidden
):
description
=
'
Need to log in
'
description
=
'
Need to log in
'
Loading