1
0
Fork 0

frontend bugfix wrong collection type

This commit is contained in:
hkernbach 2016-03-29 13:37:31 +02:00
parent 06e40476f7
commit 51678757cb
1 changed files with 10 additions and 0 deletions

View File

@ -899,6 +899,14 @@
render: function() {
$(this.el).html(this.template.render({}));
if (this.type === 2) {
this.type = "document";
}
else if (this.type === 3) {
this.type = "edge";
}
this.tableView.setElement($(this.table)).drawLoading();
this.collectionContext = this.collectionsStore.getPosition(
@ -942,6 +950,7 @@
},
renderPaginationElements: function () {
console.log("hello");
this.renderPagination();
var total = $('#totalDocuments');
if (total.length === 0) {
@ -951,6 +960,7 @@
total = $('#totalDocuments');
}
if (this.type === 'document') {
console.log(numeral(this.collection.getTotal()).format('0,0') + " document(s)");
total.html(numeral(this.collection.getTotal()).format('0,0') + " document(s)");
}
if (this.type === 'edge') {