From e72cf0e41fe882784d5a31ec5b094687620e6bd8 Mon Sep 17 00:00:00 2001 From: Florian BLOUET Date: Tue, 31 May 2016 14:36:39 +0200 Subject: [PATCH] PHRAS-1104 - edit record: fix empty value in multivalued fields --- resources/www/prod/js/jquery.Edit.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/resources/www/prod/js/jquery.Edit.js b/resources/www/prod/js/jquery.Edit.js index 6828bf6d2e..e78590892f 100644 --- a/resources/www/prod/js/jquery.Edit.js +++ b/resources/www/prod/js/jquery.Edit.js @@ -197,6 +197,9 @@ if (window.console) { console.log('adding new multi value ', value); } + if( value === '') { + return; + } this.datas.push(new recordFieldValue(null, value, VocabularyId)); this.options.dirty = true; } @@ -211,6 +214,7 @@ if (window.console) { console.log('Merging value ', value); } + this.datas[0].setValue(this.datas[0].getValue() + ' ' + value, VocabularyId); this.options.dirty = true;