From b8fd2f9c97947ffa81733a599ef94a675fae0ece Mon Sep 17 00:00:00 2001 From: Hadi Nategh Date: Wed, 4 Apr 2018 17:51:31 +0200 Subject: [PATCH] Fix vfsSelect extra buttons sometimes failing to close the dialog after execution --- api/js/etemplate/et2_widget_vfs.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/api/js/etemplate/et2_widget_vfs.js b/api/js/etemplate/et2_widget_vfs.js index fd3b2d3bd8..f6d1391fd3 100644 --- a/api/js/etemplate/et2_widget_vfs.js +++ b/api/js/etemplate/et2_widget_vfs.js @@ -1037,6 +1037,7 @@ var et2_vfsSelect = (function(){ "use strict"; return et2_inputWidget.extend( var extra_buttons_action = []; for (var i=0; i < this.options.extra_buttons.length; i++) { + delete(this.options.extra_buttons[i]['click']); buttons.push(this.options.extra_buttons[i]); extra_buttons_action[this.options.extra_buttons[i]['id']] = this.options.extra_buttons[i]['id']; } @@ -1093,6 +1094,7 @@ var et2_vfsSelect = (function(){ "use strict"; return et2_inputWidget.extend( jQuery(self.node).change(); } delete app.vfsSelectUI; + return true; } }, title: this.options.dialog_title,