[view/explorer][xs]: remove (already obsolete) router and routing code from explorer.
This commit is contained in:
parent
706819e288
commit
c9a3471b57
19
src/view.js
19
src/view.js
@ -225,9 +225,6 @@ my.DataExplorer = Backbone.View.extend({
|
||||
this.updateNav(this.pageViews[0].id);
|
||||
}
|
||||
|
||||
this.router = new Backbone.Router();
|
||||
this.setupRouting();
|
||||
|
||||
this.model.bind('query:start', function() {
|
||||
my.notify('Loading data', {loader: true});
|
||||
});
|
||||
@ -239,7 +236,6 @@ my.DataExplorer = Backbone.View.extend({
|
||||
var qs = my.parseHashQueryString();
|
||||
qs.reclineQuery = JSON.stringify(self.model.queryState.toJSON());
|
||||
var out = my.getNewHashForQueryString(qs);
|
||||
// self.router.navigate(out);
|
||||
});
|
||||
this.model.bind('query:fail', function(error) {
|
||||
my.clearNotifications();
|
||||
@ -299,21 +295,6 @@ my.DataExplorer = Backbone.View.extend({
|
||||
this.el.find('.header').append(facetViewer.el);
|
||||
},
|
||||
|
||||
setupRouting: function() {
|
||||
var self = this;
|
||||
// Default route
|
||||
// this.router.route(/^(\?.*)?$/, this.pageViews[0].id, function(queryString) {
|
||||
// self.updateNav(self.pageViews[0].id, queryString);
|
||||
// });
|
||||
// $.each(this.pageViews, function(idx, view) {
|
||||
// self.router.route(/^([^?]+)(\?.*)?/, 'view', function(viewId, queryString) {
|
||||
// self.updateNav(viewId, queryString);
|
||||
// });
|
||||
// });
|
||||
this.router.route(/.*/, 'view', function() {
|
||||
});
|
||||
},
|
||||
|
||||
updateNav: function(pageName) {
|
||||
this.el.find('.navigation li').removeClass('active');
|
||||
this.el.find('.navigation li a').removeClass('disabled');
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user