From ae2109444321182febb45a9cb39362fdacff8714 Mon Sep 17 00:00:00 2001
From: juanf <juanf>
Date: Fri, 24 Mar 2017 14:01:23 +0000
Subject: [PATCH] SSDM-3501 : vocabulary browser view header

SVN: 37956
---
 .../eln-lims/html/js/controllers/MainController.js   |  4 ++--
 .../VocabularyManager/VocabularyManagerController.js |  4 ++--
 .../views/VocabularyManager/VocabularyManagerView.js | 12 +++++++-----
 3 files changed, 11 insertions(+), 9 deletions(-)

diff --git a/openbis_standard_technologies/dist/core-plugins/eln-lims/1/as/webapps/eln-lims/html/js/controllers/MainController.js b/openbis_standard_technologies/dist/core-plugins/eln-lims/1/as/webapps/eln-lims/html/js/controllers/MainController.js
index 5e1100ef3ab..8252cfdafe0 100644
--- a/openbis_standard_technologies/dist/core-plugins/eln-lims/1/as/webapps/eln-lims/html/js/controllers/MainController.js
+++ b/openbis_standard_technologies/dist/core-plugins/eln-lims/1/as/webapps/eln-lims/html/js/controllers/MainController.js
@@ -648,10 +648,10 @@ function MainController(profile) {
 	}
 	
 	this._showVocabularyManager = function() {
-		var content = this._getBackwardsCompatibleMainContainer();
+		var views = this._getNewViewModel(true, true, false);
 		
 		var vocabularyManagerController = new VocabularyManagerController(this);
-		vocabularyManagerController.init(content);
+		vocabularyManagerController.init(views);
 		this.currentView = vocabularyManagerController;
 	}
 	
diff --git a/openbis_standard_technologies/dist/core-plugins/eln-lims/1/as/webapps/eln-lims/html/js/views/VocabularyManager/VocabularyManagerController.js b/openbis_standard_technologies/dist/core-plugins/eln-lims/1/as/webapps/eln-lims/html/js/views/VocabularyManager/VocabularyManagerController.js
index c6f8e94214a..c93f416f697 100644
--- a/openbis_standard_technologies/dist/core-plugins/eln-lims/1/as/webapps/eln-lims/html/js/views/VocabularyManager/VocabularyManagerController.js
+++ b/openbis_standard_technologies/dist/core-plugins/eln-lims/1/as/webapps/eln-lims/html/js/views/VocabularyManager/VocabularyManagerController.js
@@ -19,7 +19,7 @@ function VocabularyManagerController(mainController) {
 	this._vocabularyManagerModel = new VocabularyManagerModel();
 	this._vocabularyManagerView = new VocabularyManagerView(this, this._vocabularyManagerModel);
 	
-	this.init = function($container) {
-		this._vocabularyManagerView.repaint($container);
+	this.init = function(views) {
+		this._vocabularyManagerView.repaint(views);
 	}
 }
\ No newline at end of file
diff --git a/openbis_standard_technologies/dist/core-plugins/eln-lims/1/as/webapps/eln-lims/html/js/views/VocabularyManager/VocabularyManagerView.js b/openbis_standard_technologies/dist/core-plugins/eln-lims/1/as/webapps/eln-lims/html/js/views/VocabularyManager/VocabularyManagerView.js
index 5a49197249c..4bde2f281be 100644
--- a/openbis_standard_technologies/dist/core-plugins/eln-lims/1/as/webapps/eln-lims/html/js/views/VocabularyManager/VocabularyManagerView.js
+++ b/openbis_standard_technologies/dist/core-plugins/eln-lims/1/as/webapps/eln-lims/html/js/views/VocabularyManager/VocabularyManagerView.js
@@ -20,8 +20,7 @@ function VocabularyManagerView(vocabularyManagerController, vocabularyManagerMod
 	this._dataGridContainer = $("<div>");
 	this._subtitle = $("<legend>");
 	
-	this.repaint = function($container) {
-		$container.empty();
+	this.repaint = function(views) {
 		
 		//
 		// Form template and title
@@ -33,11 +32,14 @@ function VocabularyManagerView(vocabularyManagerController, vocabularyManagerMod
 			"onsubmit" : ""
 		});
 		
-		$containerColumn.append($("<h1>").append("Vocabulary Viewer"));
-		$containerColumn.append(this._subtitle);
+		
+		views.header.append($("<h1>").append("Vocabulary Browser"));
+		views.header.append(this._subtitle);
+		views.content.append($containerColumn);
+		
 		this._showVocabularies();
 		$containerColumn.append(this._dataGridContainer);
-		$container.append($containerColumn);
+		
 	}
 	
 	this._showVocabularies = function() {
-- 
GitLab