new: Add date picker
parent
5e0f198836
commit
5cfd5df97e
|
@ -0,0 +1,7 @@
|
|||
#!/bin/bash
|
||||
|
||||
set -e
|
||||
set -x
|
||||
|
||||
wget https://code.jquery.com/ui/1.12.1/jquery-ui.js -O web/static/jquery-ui.js
|
||||
wget https://code.jquery.com/ui/1.12.1/themes/base/jquery-ui.css -O web/static/jquery-ui.css
|
|
@ -1,3 +1,4 @@
|
|||
# Web thing
|
||||
flask
|
||||
flask-bootstrap
|
||||
Flask-Datepicker
|
||||
|
|
|
@ -1,9 +1,9 @@
|
|||
#!/usr/bin/env python
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
|
||||
from flask import Flask, render_template, request
|
||||
from flask_bootstrap import Bootstrap
|
||||
from flask_datepicker import datepicker
|
||||
|
||||
from bgpranking.querying import Querying
|
||||
|
||||
|
@ -11,6 +11,7 @@ app = Flask(__name__)
|
|||
|
||||
Bootstrap(app)
|
||||
app.config['BOOTSTRAP_SERVE_LOCAL'] = True
|
||||
datepicker(app=app, local=['static/jquery-ui.js', 'static/jquery-ui.css'])
|
||||
|
||||
app.debug = True
|
||||
|
||||
|
|
|
@ -10,6 +10,9 @@
|
|||
ASN to search: <input type=number name=asn>
|
||||
<input type="submit" value="Search">
|
||||
</form>
|
||||
<form class="verticalform">
|
||||
<input type="text" class="form-control dp" />
|
||||
</form>
|
||||
<table class="table">
|
||||
<tr>
|
||||
<th>ASN</th>
|
||||
|
|
|
@ -2,6 +2,8 @@
|
|||
|
||||
{% block scripts %}
|
||||
{{ super() }}
|
||||
{{ datepicker.loader() }}
|
||||
{{ datepicker.picker(id=".dp") }}
|
||||
{% endblock %}
|
||||
|
||||
{% block head %}
|
||||
|
|
Loading…
Reference in New Issue