From 7632e08974e5b73fde72f1fcb66c136500226aac Mon Sep 17 00:00:00 2001 From: Artur Arseniev Date: Wed, 5 Jul 2017 13:49:59 +0200 Subject: [PATCH] Rerender assets when the collection is resetted --- src/asset_manager/view/AssetsView.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/asset_manager/view/AssetsView.js b/src/asset_manager/view/AssetsView.js index 0d0c6199d..94208064d 100644 --- a/src/asset_manager/view/AssetsView.js +++ b/src/asset_manager/view/AssetsView.js @@ -32,8 +32,9 @@ module.exports = Backbone.View.extend({ this.config = o.config; this.pfx = this.config.stylePrefix || ''; this.ppfx = this.config.pStylePrefix || ''; - this.listenTo( this.collection, 'add', this.addToAsset ); - this.listenTo( this.collection, 'deselectAll', this.deselectAll ); + this.listenTo(this.collection, 'add', this.addToAsset ); + this.listenTo(this.collection, 'deselectAll', this.deselectAll); + this.listenTo(this.collection, 'reset', this.render); this.className = this.pfx + 'assets'; this.events = {};