mirror of https://github.com/MISP/misp-dashboard
Added support of org in URL GET param
parent
264a4e52e2
commit
85d7d10df5
|
@ -255,8 +255,11 @@ def geo():
|
||||||
def contrib():
|
def contrib():
|
||||||
categ_list = categories_in_datatable
|
categ_list = categories_in_datatable
|
||||||
categ_list_str = [ s[0].upper() + s[1:].replace('_', ' ') for s in categories_in_datatable]
|
categ_list_str = [ s[0].upper() + s[1:].replace('_', ' ') for s in categories_in_datatable]
|
||||||
|
currOrg = request.args.get('org')
|
||||||
|
if currOrg is None:
|
||||||
|
currOrg = ""
|
||||||
return render_template('contrib.html',
|
return render_template('contrib.html',
|
||||||
currOrg="",
|
currOrg=currOrg,
|
||||||
rankMultiplier=cfg.getfloat('CONTRIB' ,'rankMultiplier'),
|
rankMultiplier=cfg.getfloat('CONTRIB' ,'rankMultiplier'),
|
||||||
categ_list=json.dumps(categ_list),
|
categ_list=json.dumps(categ_list),
|
||||||
categ_list_str=categ_list_str
|
categ_list_str=categ_list_str
|
||||||
|
|
|
@ -250,8 +250,6 @@ function showOnlyOrg() {
|
||||||
}
|
}
|
||||||
|
|
||||||
$(document).ready(function() {
|
$(document).ready(function() {
|
||||||
if(currOrg != "") // currOrg selected
|
|
||||||
updateProgressHeader(org)
|
|
||||||
$('#orgName').typeahead(typeaheadOption);
|
$('#orgName').typeahead(typeaheadOption);
|
||||||
$('#btnCurrRank').popover(popOverOption);
|
$('#btnCurrRank').popover(popOverOption);
|
||||||
datatableTop = $('#topContribTable').DataTable(optionDatatable_top);
|
datatableTop = $('#topContribTable').DataTable(optionDatatable_top);
|
||||||
|
@ -285,7 +283,8 @@ $(document).ready(function() {
|
||||||
});
|
});
|
||||||
// top 5 contrib overtime
|
// top 5 contrib overtime
|
||||||
$.getJSON( url_getTop5Overtime, function( data ) {
|
$.getJSON( url_getTop5Overtime, function( data ) {
|
||||||
console.log(data);
|
|
||||||
var plotLineChart = $.plot("#divTop5Overtime", data, optionsLineChart);
|
var plotLineChart = $.plot("#divTop5Overtime", data, optionsLineChart);
|
||||||
});
|
});
|
||||||
|
if(currOrg != "") // currOrg selected
|
||||||
|
updateProgressHeader(currOrg)
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in New Issue