From 81bcd9fb4273e327d29db1bf390b6da2912d2a3e Mon Sep 17 00:00:00 2001 From: Hadi Nategh Date: Mon, 18 Dec 2017 09:58:40 +0100 Subject: [PATCH] Fix vfsSelect dialog does not preserve the name field on reload --- api/js/etemplate/vfsSelectUI.js | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/api/js/etemplate/vfsSelectUI.js b/api/js/etemplate/vfsSelectUI.js index 3808ea5281..e260948e7e 100644 --- a/api/js/etemplate/vfsSelectUI.js +++ b/api/js/etemplate/vfsSelectUI.js @@ -300,6 +300,13 @@ app.classes.vfsSelectUI = (function(){ "use strict"; return AppJS.extend( jQuery.extend(arrMgrs.content.data, arrMgrs.modifications.data); this.et2.setArrayMgrs(arrMgrs); } + + // preserve value of the name + if (arrMgrs && this.et2.getWidgetById('name')) + { + arrMgrs.content.data['name'] = this.et2.getWidgetById('name').get_value(); + } + this.vfsSelectWidget._content(arrMgrs.content.data, _callback); } });}).call(this);