diff --git a/frontend/src/modules/projects/views/projectView.js b/frontend/src/modules/projects/views/projectView.js index 960a6a39fe..46395695af 100644 --- a/frontend/src/modules/projects/views/projectView.js +++ b/frontend/src/modules/projects/views/projectView.js @@ -97,7 +97,10 @@ define(function(require) { deleteProject: function(event) { this.model.destroy({ - success: _.bind(this.remove, this), + success: _.bind(function() { + Origin.trigger('dashboard:refresh'); + this.remove(); + }, this), error: function(model, response, options) { _.delay(function() { Origin.Notify.alert({ type: 'error', text: response.responseJSON.message }); diff --git a/frontend/src/modules/projects/views/projectsView.js b/frontend/src/modules/projects/views/projectsView.js index 26aa2a6826..636f7b7f65 100644 --- a/frontend/src/modules/projects/views/projectsView.js +++ b/frontend/src/modules/projects/views/projectsView.js @@ -28,7 +28,7 @@ define(function(require){ this._onResize = _.bind(_.debounce(this.onResize, 250), this); this.listenTo(Origin, { - 'window:resize': this._onResize, + 'window:resize dashboard:refresh': this._onResize, 'dashboard:dashboardSidebarView:filterBySearch': function(text) { this.doFilter(text) }, 'dashboard:dashboardSidebarView:filterByTags': function(tags) { this.doFilter(null, tags) }, 'dashboard:sort:asc': function() { this.doSort('asc'); },