From ad48b3c8d663c85e84fcc282921cce466bdaca9a Mon Sep 17 00:00:00 2001
From: juanf <juanf>
Date: Tue, 31 Jan 2017 09:51:28 +0000
Subject: [PATCH] SSDM-4721 : Fix for table settings to not loose not found
 columns.

SVN: 37647
---
 .../1/as/webapps/eln-lims/html/lib/grid/js/Grid.js        | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/openbis_standard_technologies/dist/core-plugins/eln-lims/1/as/webapps/eln-lims/html/lib/grid/js/Grid.js b/openbis_standard_technologies/dist/core-plugins/eln-lims/1/as/webapps/eln-lims/html/lib/grid/js/Grid.js
index d7cda39f46d..e45ca73db96 100644
--- a/openbis_standard_technologies/dist/core-plugins/eln-lims/1/as/webapps/eln-lims/html/lib/grid/js/Grid.js
+++ b/openbis_standard_technologies/dist/core-plugins/eln-lims/1/as/webapps/eln-lims/html/lib/grid/js/Grid.js
@@ -429,7 +429,13 @@ $.extend(Grid.prototype, {
 		});
 
 		if(this.onChangeState) {
-			this.tableSettings.columns = columnsModel;
+			if(this.tableSettings.columns) {
+				for(key in columnsModel) {
+					this.tableSettings.columns[key] = columnsModel[key];
+				}
+			} else {
+				this.tableSettings.columns = columnsModel;
+			}
 			this.onChangeState(this.tableSettings);
 		}
 		
-- 
GitLab