diff --git a/ui-eln-lims/src/core-plugins/eln-lims/1/as/webapps/eln-lims/html/js/controllers/MainController.js b/ui-eln-lims/src/core-plugins/eln-lims/1/as/webapps/eln-lims/html/js/controllers/MainController.js index cafdc77be442485c6da1fd0e87cc1870455389d4..dca72c8a18cc53c87eb37935d67e5c7d926e6097 100644 --- a/ui-eln-lims/src/core-plugins/eln-lims/1/as/webapps/eln-lims/html/js/controllers/MainController.js +++ b/ui-eln-lims/src/core-plugins/eln-lims/1/as/webapps/eln-lims/html/js/controllers/MainController.js @@ -404,7 +404,45 @@ function MainController(profile) { CKEditorManager.destroy(); this.sideMenu.removeSubSideMenu(); - + + // + // Permanent URLs + // + if (shouldURLBePushToHistory) { + var menuUniqueId = this.sideMenu.getCurrentNodeId(); + var url = Util.getURLFor(menuUniqueId, newViewChange, arg); + history.pushState(null, "", url); //History Push State + + var toPush = null; + if(shouldStateBePushToHistory) { + toPush = { + header : null, + content : null, + auxContent : null + } + + if(this.views.header) { + toPush.header = this.views.header; + toPush.header.detach(); + } + + if(this.views.content) { + toPush.content = this.views.content; + toPush.content.detach(); + } + + if(this.views.auxContent) { + toPush.auxContent = this.views.auxContent; + toPush.auxContent.detach(); + } + } + + this.backStack.push({ + view : toPush, + url : url + }); + } + // // // @@ -894,47 +932,8 @@ function MainController(profile) { } catch(err) { Util.manageError(err); } - - // - // Permanent URLs - // - if (shouldURLBePushToHistory) { - var menuUniqueId = this.sideMenu.getCurrentNodeId(); - var url = Util.getURLFor(menuUniqueId, newViewChange, arg); - history.pushState(null, "", url); //History Push State - - var toPush = null; - if(shouldStateBePushToHistory) { - toPush = { - header : null, - content : null, - auxContent : null - } - - if(this.views.header) { - toPush.header = this.views.header; - toPush.header.detach(); - } - - if(this.views.content) { - toPush.content = this.views.content; - toPush.content.detach(); - } - - if(this.views.auxContent) { - toPush.auxContent = this.views.auxContent; - toPush.auxContent.detach(); - } - } - - this.backStack.push({ - view : toPush, - url : url - }); - } - // // Refresh Functionality // diff --git a/ui-eln-lims/src/core-plugins/eln-lims/1/as/webapps/eln-lims/html/js/views/DataGrid/ExperimentDataGridUtil.js b/ui-eln-lims/src/core-plugins/eln-lims/1/as/webapps/eln-lims/html/js/views/DataGrid/ExperimentDataGridUtil.js index 4fdf4c34570d9df80c9449251010270e8e526a82..384cc39d60beeb2dbf5549e7567ec99dc5eabade 100644 --- a/ui-eln-lims/src/core-plugins/eln-lims/1/as/webapps/eln-lims/html/js/views/DataGrid/ExperimentDataGridUtil.js +++ b/ui-eln-lims/src/core-plugins/eln-lims/1/as/webapps/eln-lims/html/js/views/DataGrid/ExperimentDataGridUtil.js @@ -59,7 +59,7 @@ var ExperimentDataGridUtil = new function() { exportableProperty: DataGridExportOptions.EXPORTABLE_FIELD.PERM_ID, sortable : true, render : function(data) { - return FormUtil.getFormLink(data.permId, "Experiment", data.permId); + return FormUtil.getFormLink(data.permId, "Experiment", data.identifier); }, filter : function(data, filter) { return data.identifier.toLowerCase().indexOf(filter) !== -1;