Call display only on current view or view that has a parent

It is only needed to refresh the display of a view that is actually displayed
which means being attached to the DOM.

issue7363
review49271003
This commit is contained in:
Cédric Krier committed 2018-05-08 10:05:39 +02:00
1 parent b338862bfa
commit 2f9aa10dfe
1 file changed
+3 -1
+3 -1
View File
@@ -1087,7 +1087,9 @@
this.current_view.view_type));
deferreds.push(search_prm);
for (var i = 0; i < this.views.length; i++) {
if (this.views[i]) {
if (this.views[i] &&
((this.views[i] == this.current_view) ||
this.views[i].el.parent().length)) {
deferreds.push(this.views[i].display());
}
}