new: add some meta information
parent
b04fa06d47
commit
a6ca4423ff
|
@ -95,6 +95,22 @@ def asn_details():
|
||||||
return render_template('asn.html', sources=sources, ranks=ranks, prefix_ips=prefix_ips, asn_descriptions=asn_descriptions, **session)
|
return render_template('asn.html', sources=sources, ranks=ranks, prefix_ips=prefix_ips, asn_descriptions=asn_descriptions, **session)
|
||||||
|
|
||||||
|
|
||||||
|
@app.route('/asn_description', methods=['POST'])
|
||||||
|
def asn_description():
|
||||||
|
load_session()
|
||||||
|
asn = None
|
||||||
|
if request.form.get('asn'):
|
||||||
|
asn = request.form.get('asn')
|
||||||
|
elif session.get('asn'):
|
||||||
|
asn = session.get('asn')
|
||||||
|
else:
|
||||||
|
to_return = {'error': 'asn required'}
|
||||||
|
if asn:
|
||||||
|
q = Querying()
|
||||||
|
to_return = q.get_asn_descriptions(asn, session.get('all_descriptions'))
|
||||||
|
return Response(json.dumps(to_return), mimetype='application/json')
|
||||||
|
|
||||||
|
|
||||||
@app.route('/asn_history', methods=['GET', 'POST'])
|
@app.route('/asn_history', methods=['GET', 'POST'])
|
||||||
def asn_history():
|
def asn_history():
|
||||||
load_session()
|
load_session()
|
||||||
|
|
|
@ -5,7 +5,9 @@
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|
||||||
|
|
||||||
{% block title %}Ranking - {{ asn }}{% endblock %}
|
{% block title %}
|
||||||
|
Ranking - {{ asn }}
|
||||||
|
{% endblock %}
|
||||||
|
|
||||||
{% block scripts %}
|
{% block scripts %}
|
||||||
{{ super() }}
|
{{ super() }}
|
||||||
|
@ -16,6 +18,11 @@
|
||||||
{% block content %}
|
{% block content %}
|
||||||
<center>
|
<center>
|
||||||
<h1>Ranking - {{asn}}</h1></br></br>
|
<h1>Ranking - {{asn}}</h1></br></br>
|
||||||
|
<button data-html="true" type="button" class="btn btn-secondary" data-container="body"
|
||||||
|
data-toggle="popover" data-placement="bottom"
|
||||||
|
data-content="<center><b>sum</b>(IP * weight of the list) </br><hr><b>sum</b>(IP in the prefix)</center>">
|
||||||
|
<h4>How is this ranking computed?</h4>
|
||||||
|
</button>
|
||||||
</center>
|
</center>
|
||||||
{% include ['top_forms.html'] %}
|
{% include ['top_forms.html'] %}
|
||||||
<table class="table">
|
<table class="table">
|
||||||
|
|
|
@ -15,6 +15,3 @@
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
</table>
|
</table>
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -5,6 +5,11 @@
|
||||||
{% block content %}
|
{% block content %}
|
||||||
<center>
|
<center>
|
||||||
<h1>BGP Ranking</h1></br></br>
|
<h1>BGP Ranking</h1></br></br>
|
||||||
|
<button data-html="true" type="button" class="btn btn-secondary" data-container="body"
|
||||||
|
data-toggle="popover" data-placement="bottom"
|
||||||
|
data-content="<center><b>sum</b>(IP * weight of the list) </br><hr><b>sum</b>(IP announced by the ASN)</center>">
|
||||||
|
<h4>How is this ranking computed?</h4>
|
||||||
|
</button>
|
||||||
</center>
|
</center>
|
||||||
{% include ['top_forms.html'] %}
|
{% include ['top_forms.html'] %}
|
||||||
<table class="table">
|
<table class="table">
|
||||||
|
|
|
@ -4,6 +4,11 @@
|
||||||
{{ super() }}
|
{{ super() }}
|
||||||
<script src='{{ url_for('static', filename='d3.v5.js') }}'></script>
|
<script src='{{ url_for('static', filename='d3.v5.js') }}'></script>
|
||||||
<script src='{{ url_for('static', filename='bootstrap-select.min.js') }}'></script>
|
<script src='{{ url_for('static', filename='bootstrap-select.min.js') }}'></script>
|
||||||
|
<script>
|
||||||
|
$(document).ready(function(){
|
||||||
|
$('[data-toggle="popover"]').popover();
|
||||||
|
});
|
||||||
|
</script>
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|
||||||
{% block head %}
|
{% block head %}
|
||||||
|
|
Loading…
Reference in New Issue