mirror of
https://github.com/binary-kitchen/doorlockd
synced 2024-12-22 02:14:26 +01:00
doorlockd: remove nasty flask-bootstrap dependency
Package is no longer officially maintainer, remove the dependency. Signed-off-by: Ralf Ramsauer <ralf@binary-kitchen.de>
This commit is contained in:
parent
f226f44190
commit
f857fffac6
@ -30,7 +30,6 @@ from threading import Thread
|
|||||||
from time import sleep
|
from time import sleep
|
||||||
|
|
||||||
from flask import abort, Flask, jsonify, render_template, request
|
from flask import abort, Flask, jsonify, render_template, request
|
||||||
from flask_bootstrap import Bootstrap
|
|
||||||
from flask_socketio import SocketIO
|
from flask_socketio import SocketIO
|
||||||
from flask_wtf import FlaskForm
|
from flask_wtf import FlaskForm
|
||||||
from wtforms import PasswordField, StringField, SubmitField
|
from wtforms import PasswordField, StringField, SubmitField
|
||||||
@ -72,7 +71,6 @@ webapp = Flask(__name__,
|
|||||||
static_folder=static_folder)
|
static_folder=static_folder)
|
||||||
webapp.config.from_pyfile(flask_config)
|
webapp.config.from_pyfile(flask_config)
|
||||||
socketio = SocketIO(webapp, async_mode='threading')
|
socketio = SocketIO(webapp, async_mode='threading')
|
||||||
Bootstrap(webapp)
|
|
||||||
serial_port = webapp.config.get('SERIAL_PORT')
|
serial_port = webapp.config.get('SERIAL_PORT')
|
||||||
simulate_ldap = webapp.config.get('SIMULATE_LDAP')
|
simulate_ldap = webapp.config.get('SIMULATE_LDAP')
|
||||||
simulate_serial = webapp.config.get('SIMULATE_SERIAL')
|
simulate_serial = webapp.config.get('SIMULATE_SERIAL')
|
||||||
|
7
share/doorlockd/static/css/bootstrap.min.css
vendored
Normal file
7
share/doorlockd/static/css/bootstrap.min.css
vendored
Normal file
File diff suppressed because one or more lines are too long
1
share/doorlockd/static/css/bootstrap.min.css.map
Normal file
1
share/doorlockd/static/css/bootstrap.min.css.map
Normal file
File diff suppressed because one or more lines are too long
7
share/doorlockd/static/js/bootstrap.min.js
vendored
Normal file
7
share/doorlockd/static/js/bootstrap.min.js
vendored
Normal file
File diff suppressed because one or more lines are too long
2
share/doorlockd/static/js/jquery.min.js
vendored
Normal file
2
share/doorlockd/static/js/jquery.min.js
vendored
Normal file
File diff suppressed because one or more lines are too long
@ -1,12 +1,15 @@
|
|||||||
{% extends "layout.html" %}
|
{% extends "layout.html" %}
|
||||||
|
|
||||||
{% block head %}
|
{% block head %}
|
||||||
|
{{ title }}
|
||||||
{{ super() }}
|
{{ super() }}
|
||||||
<meta http-equiv="refresh" content="600">
|
<meta http-equiv="refresh" content="600">
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|
||||||
{% block scripts %}
|
{% block scripts %}
|
||||||
{{ super() }}
|
{{ super() }}
|
||||||
|
<script src="/static/js/jquery.min.js"></script>
|
||||||
|
<script src="/static/js/bootstrap.min.js"></script>
|
||||||
<script type="text/javascript" src="static/socket.io.slim.js"></script>
|
<script type="text/javascript" src="static/socket.io.slim.js"></script>
|
||||||
<script type="text/javascript" charset="utf-8">
|
<script type="text/javascript" charset="utf-8">
|
||||||
$(document).ready(function() {
|
$(document).ready(function() {
|
||||||
@ -31,7 +34,7 @@
|
|||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|
||||||
{% block content %}
|
{% block content %}
|
||||||
<h1 class="text-center">Willkommen in der Binary Kitchen!</h1>
|
<h1 class="text-center display-4">Willkommen in der Binary Kitchen!</h1>
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col-md-3 text-center">
|
<div class="col-md-3 text-center">
|
||||||
<img id="led" src="">
|
<img id="led" src="">
|
||||||
|
@ -1,5 +1,4 @@
|
|||||||
{% extends "layout.html" %}
|
{% extends "layout.html" %}
|
||||||
{% import "bootstrap/wtf.html" as wtf %}
|
|
||||||
|
|
||||||
{%- block metas %}
|
{%- block metas %}
|
||||||
{{super()}}
|
{{super()}}
|
||||||
@ -13,7 +12,20 @@
|
|||||||
<img src="{{ led }}">
|
<img src="{{ led }}">
|
||||||
</div>
|
</div>
|
||||||
<div class="col-md-8">
|
<div class="col-md-8">
|
||||||
{{ wtf.quick_form(authentication_form, button_map={'open': 'success btn-lg btn-block', 'present': 'warning btn-lg btn-block', 'close': 'danger btn-lg btn-block'}) }}
|
<form action="" method="post" class="form" role="form">
|
||||||
|
{{ authentication_form.csrf_token }}
|
||||||
|
<div class="form-group ">
|
||||||
|
<label class="control-label" for="username">Username</label>
|
||||||
|
<input class="form-control" id="username" name="username" type="text" value="">
|
||||||
|
</div>
|
||||||
|
<div class="form-group required">
|
||||||
|
<label class="control-label" for="password">Password</label>
|
||||||
|
<input class="form-control" id="password" name="password" required type="password" value="">
|
||||||
|
</div>
|
||||||
|
<input class="btn btn-success btn-lg btn-block" id="open" name="open" type="submit" value="Open">
|
||||||
|
<input class="btn btn-warning btn-lg btn-block" id="present" name="present" type="submit" value="Present">
|
||||||
|
<input class="btn btn-danger btn-lg btn-block" id="close" name="close" type="submit" value="Close">
|
||||||
|
</form>
|
||||||
{% if response %}
|
{% if response %}
|
||||||
<hr/>
|
<hr/>
|
||||||
<h1>{{ response.to_html() }}</h1>
|
<h1>{{ response.to_html() }}</h1>
|
||||||
|
@ -1,11 +1,16 @@
|
|||||||
{%extends "bootstrap/base.html" %}
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
|
||||||
|
"http://www.w3.org/TR/html4/loose.dtd">
|
||||||
{% block title %}{{ title }}{% endblock %}
|
<html>
|
||||||
|
<head>
|
||||||
{%- block content %}
|
{% block head %}{%- endblock head %}
|
||||||
{{super()}}
|
<title>{{ title }}</title>
|
||||||
{%- block footer %}
|
{% block meta %}{%- endblock meta %}
|
||||||
<br><br><br>
|
<link href="/static/css/bootstrap.min.css" rel="stylesheet">
|
||||||
<footer>Ralf Ramsauer © 2018 Binary Kitchen e.V.</footer>
|
</head>
|
||||||
{%- endblock footer %}
|
<body>
|
||||||
{%- endblock content %}
|
{% block content %}{%- endblock content %}
|
||||||
|
<br><br><br>
|
||||||
|
<footer>Ralf Ramsauer © 2018 Binary Kitchen e.V.</footer>
|
||||||
|
{% block scripts %}{%- endblock scripts %}
|
||||||
|
</body>
|
||||||
|
</html>
|
||||||
|
Loading…
Reference in New Issue
Block a user