Skip to content

Commit 4218695

Browse files
committed
Fix dashboard infinite scrolling/pagination
Fixes #2253
1 parent 92fd6c1 commit 4218695

2 files changed

Lines changed: 5 additions & 2 deletions

File tree

frontend/src/modules/projects/views/projectView.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,10 @@ define(function(require) {
9797

9898
deleteProject: function(event) {
9999
this.model.destroy({
100-
success: _.bind(this.remove, this),
100+
success: _.bind(function() {
101+
Origin.trigger('dashboard:refresh');
102+
this.remove();
103+
}, this),
101104
error: function(model, response, options) {
102105
_.delay(function() {
103106
Origin.Notify.alert({ type: 'error', text: response.responseJSON.message });

frontend/src/modules/projects/views/projectsView.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ define(function(require){
2828
this._onResize = _.bind(_.debounce(this.onResize, 250), this);
2929

3030
this.listenTo(Origin, {
31-
'window:resize': this._onResize,
31+
'window:resize dashboard:refresh': this._onResize,
3232
'dashboard:dashboardSidebarView:filterBySearch': function(text) { this.doFilter(text) },
3333
'dashboard:dashboardSidebarView:filterByTags': function(tags) { this.doFilter(null, tags) },
3434
'dashboard:sort:asc': function() { this.doSort('asc'); },

0 commit comments

Comments
 (0)