1
0
Fork 0

Removed unused routes and views and templates

This commit is contained in:
Michael Hackstein 2014-02-22 08:44:24 +01:00
parent e9d8392e48
commit b100eb85e4
4 changed files with 0 additions and 144 deletions

View File

@ -22,8 +22,6 @@
"databases" : "databases",
"application/installed/:key" : "applicationEdit",
"application/available/:key" : "applicationInstall",
"applications/installed" : "applicationsInstalled",
"applications/available" : "applicationsAvailable",
"applications" : "applications",
"application/documentation/:key" : "appDocumentation",
"graph" : "graph",
@ -389,26 +387,6 @@
this.naviView.selectMenuItem('applications-menu');
},
applicationsAvailable: function() {
if (this.applicationsInstalledView === undefined) {
this.applicationsInstalledView = new window.FoxxInstalledListView({
collection: this.foxxList
});
}
this.applicationsInstalledView.reload();
this.naviView.selectMenuItem('applications-menu');
},
applicationsInstalled: function() {
if (this.applicationsActiveView === undefined) {
this.applicationsActiveView = new window.FoxxActiveListView({
collection: this.foxxList
});
}
this.applicationsActiveView.reload();
this.naviView.selectMenuItem('applications-menu');
},
applicationEdit: function(appkey) {
this.foxxList.fetch({
async: false

View File

@ -1,18 +0,0 @@
<script id="foxxInstalledView.ejs" type="text/template">
<ul class="thumbnails2">
<div class="headerBar">
<a class="arangoHeader">Applications</a>
</div>
<div class="btn-group pull-right">
<button class="btn btn-inverse btn-small disabledHover">Filter:</button>
<button data-toggle="dropdown" class="btn btn-inverse btn-small dropdown-toggle"><span class="caret"></span></button>
<ul class="dropdown-menu dashboard-dropdown" id="menuGroups">
</ul>
</div>
</ul>
<ul class="contentDiv" id="foxxList">
</ul>
</script>

View File

@ -1,53 +0,0 @@
/*jslint indent: 2, nomen: true, maxlen: 100, vars: true, white: true, plusplus: true */
/*global Backbone, EJS, $, window, _, templateEngine*/
(function () {
"use strict";
window.FoxxActiveListView = Backbone.View.extend({
el: '#content',
template: templateEngine.createTemplate("foxxListView.ejs"),
events: {
// 'click button#add': 'callback'
},
initialize: function() {
this._subViews = {};
var self = this;
this.collection.fetch({
success: function() {
_.each(self.collection.where({type: "mount"}), function (foxx) {
var subView = new window.FoxxActiveView({model: foxx});
self._subViews[foxx.get('_id')] = subView;
});
self.render();
},
error: function() {
}
});
this.render();
},
reload: function() {
var self = this;
this.collection.fetch({
success: function() {
self._subViews = {};
_.each(self.collection.where({type: "mount"}), function (foxx) {
var subView = new window.FoxxActiveView({model: foxx});
self._subViews[foxx.get('_id')] = subView;
});
self.render();
}
});
},
render: function() {
$(this.el).html(this.template.render({}));
_.each(this._subViews, function (v) {
$("#foxxList").append(v.render());
});
this.delegateEvents();
return this;
}
});
}());

View File

@ -1,51 +0,0 @@
/*jslint indent: 2, nomen: true, maxlen: 100, vars: true, white: true, plusplus: true */
/*global Backbone, EJS, $, window, _, templateEngine*/
(function() {
"use strict";
window.FoxxInstalledListView = Backbone.View.extend({
el: '#content',
template: templateEngine.createTemplate("applicationsView.ejs"),
events: {
// 'click button#add': 'callback'
},
initialize: function() {
this._subViews = {};
var self = this;
this.collection.fetch({
success: function() {
_.each(self.collection.where({type: "app"}), function (foxx) {
var subView = new window.FoxxInstalledView({model: foxx});
self._subViews[foxx.get('_id')] = subView;
});
self.render();
}
});
},
reload: function() {
var self = this;
this.collection.fetch({
success: function() {
self._subViews = {};
_.each(self.collection.where({type: "app"}), function (foxx) {
var subView = new window.FoxxInstalledView({model: foxx});
self._subViews[foxx.get('_id')] = subView;
});
self.render();
}
});
},
render: function() {
$(this.el).html(this.template.render({}));
_.each(this._subViews, function (v) {
$("#foxxList").append(v.render());
});
this.delegateEvents();
return this;
}
});
}());