From c312479c921e96c4956b32e71feb6184b208e1b8 Mon Sep 17 00:00:00 2001 From: juanf <juanf> Date: Fri, 7 Jul 2017 12:54:16 +0000 Subject: [PATCH] SSDM-5304 : Show Position identifiers SVN: 38507 --- .../SampleForm/widgets/StorageListView.js | 34 +++++++++++-------- 1 file changed, 19 insertions(+), 15 deletions(-) diff --git a/openbis_standard_technologies/dist/core-plugins/eln-lims/1/as/webapps/eln-lims/html/js/views/SampleForm/widgets/StorageListView.js b/openbis_standard_technologies/dist/core-plugins/eln-lims/1/as/webapps/eln-lims/html/js/views/SampleForm/widgets/StorageListView.js index 9f7f606272a..700e5f8ed2f 100644 --- a/openbis_standard_technologies/dist/core-plugins/eln-lims/1/as/webapps/eln-lims/html/js/views/SampleForm/widgets/StorageListView.js +++ b/openbis_standard_technologies/dist/core-plugins/eln-lims/1/as/webapps/eln-lims/html/js/views/SampleForm/widgets/StorageListView.js @@ -48,21 +48,25 @@ function StorageListView(storageListController, storageListModel) { return data.identifier.toLowerCase().indexOf(filter) !== -1; } }); -// columns.push({ -// label : 'Identifier', -// property : 'identifier', -// isExportable: true, -// sortable : true, -// filter : function(data, filter) { -// return data.identifier.toLowerCase().indexOf(filter) !== -1; -// }, -// sort : function(data1, data2, asc) { -// var value1 = data1.identifier; -// var value2 = data2.identifier; -// var sortDirection = (asc)? 1 : -1; -// return sortDirection * naturalSort(value1, value2); -// } -// }); + columns.push({ + label : 'Identifier', + property : 'identifier', + isExportable: true, + sortable : false, + showByDefault: false, + render : function(data) { + return FormUtil.getFormLink(data.identifier, "Sample", data.permId); + }, + filter : function(data, filter) { + return data.identifier.toLowerCase().indexOf(filter) !== -1; + }, + sort : function(data1, data2, asc) { + var value1 = data1.identifier; + var value2 = data2.identifier; + var sortDirection = (asc)? 1 : -1; + return sortDirection * naturalSort(value1, value2); + } + }); var storagePropertyCodes = profile.getAllPropertiCodesForTypeCode("STORAGE_POSITION"); var storagePropertyCodesAsMap = {}; -- GitLab