From 8e1e7901a6214e2c38dea7ef8aefffb3022c23e9 Mon Sep 17 00:00:00 2001 From: Arvind Date: Wed, 26 Mar 2014 04:59:10 +0530 Subject: [PATCH] Adding page for llv viz --- mouchak/static/js/mouchak.js | 27 ++++++++++++++++++++++++--- 1 file changed, 24 insertions(+), 3 deletions(-) diff --git a/mouchak/static/js/mouchak.js b/mouchak/static/js/mouchak.js index c4ae6a8..67c21a8 100644 --- a/mouchak/static/js/mouchak.js +++ b/mouchak/static/js/mouchak.js @@ -187,19 +187,40 @@ var AppRouter = Backbone.Router.extend({ this.showPage('mobile-usage'); try { if(CRP.mv.init) { - CRP.mv.init(); + CRP.mv.init('/static/weekly-statistics.csv'); } else { setTimeout(function() { - CRP.mv.init(); + CRP.mv.init('/static/weekly-statistics.csv'); }, 2000); } } catch(e) { setTimeout(function() { - CRP.mv.init(); + CRP.mv.init('/static/weekly-statistics.csv'); }, 2000); } }, + showGKAMU: function() { + //bad hack to circumvent plugin loading problems + //not even foolproof. + //TODO: should implement plugin loaders + this.showPage('gka-mobile-usage'); + try { + if(CRP.gmv.init) { + CRP.gmv.init('/static/llv-weekly-statistics.csv'); + } + else { + setTimeout(function() { + CRP.gmv.init('/static/llv-weekly-statistics.csv'); + }, 2000); + } + } catch(e) { + setTimeout(function() { + CRP.gmv.init('/static/llv-weekly-statistics.csv'); + }, 2000); + } + }, + showSigViz: function() { //bad hack to circumvent plugin loading problems //not even foolproof. -- 1.7.10.4