From bee4741231d258c635d6260b63a21b29977c957f Mon Sep 17 00:00:00 2001
From: juanf <juanf>
Date: Wed, 6 Sep 2017 09:55:40 +0000
Subject: [PATCH] SSDM-5555 : Show/Hide boxName, size and position depending if
 they are present

SVN: 38702
---
 .../StorageManager/widgets/StorageController.js    | 14 ++++++++++++--
 1 file changed, 12 insertions(+), 2 deletions(-)

diff --git a/openbis_standard_technologies/dist/core-plugins/eln-lims/1/as/webapps/eln-lims/html/js/views/StorageManager/widgets/StorageController.js b/openbis_standard_technologies/dist/core-plugins/eln-lims/1/as/webapps/eln-lims/html/js/views/StorageManager/widgets/StorageController.js
index a40e73ae7dc..4d4a5fb67bd 100644
--- a/openbis_standard_technologies/dist/core-plugins/eln-lims/1/as/webapps/eln-lims/html/js/views/StorageManager/widgets/StorageController.js
+++ b/openbis_standard_technologies/dist/core-plugins/eln-lims/1/as/webapps/eln-lims/html/js/views/StorageManager/widgets/StorageController.js
@@ -45,11 +45,21 @@ function StorageController(configOverride) {
 			if(data.samples.length > 1 || 
 					data.samples.length === 1 && data.samples[0].properties[_this._storageModel.storagePropertyGroup.boxProperty]) {
 				_this._storageView.showBoxName();
-				_this._storageView.showBoxSize();
-				_this._storageView.showPosField(data.size, true);
 			} else {
 				_this._storageView.hideBoxField();
+			}
+			
+			if(data.samples.length > 1 || 
+					data.samples.length === 1 && data.samples[0].properties[_this._storageModel.storagePropertyGroup.boxSizeProperty]) {
+				_this._storageView.showBoxSize();
+			} else {
 				_this._storageView.hideBoxSizeField();
+			}
+			
+			if(data.samples.length > 1 || 
+					data.samples.length === 1 && data.samples[0].properties[_this._storageModel.storagePropertyGroup.positionProperty]) {
+				_this._storageView.showPosField(data.size, true);
+			} else {
 				_this._storageView.hidePosField();
 			}
 			
-- 
GitLab