Skip to content

Commit b794944

Browse files
Merge 22.10 to develop
2 parents f810e7a + ab16f10 commit b794944

File tree

4 files changed

+12
-7
lines changed

4 files changed

+12
-7
lines changed

LDK/resources/web/LDK/Utils.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -538,15 +538,16 @@ LDK.Utils = new function(){
538538
window.location = LABKEY.ActionURL.buildURL('ldk', 'updateQuery', null, params);
539539
},
540540

541-
splitIds: function(subjectArray, unsorted, preserveDuplicates){
541+
splitIds: function(subjectArray, unsorted, preserveDuplicates, preserveCase){
542542
if (!subjectArray){
543543
return [];
544544
}
545545

546546
subjectArray = Ext4.String.trim(subjectArray);
547547
subjectArray = subjectArray.replace(/[\s,;]+/g, ';');
548548
subjectArray = subjectArray.replace(/(^;|;$)/g, '');
549-
subjectArray = subjectArray.toLowerCase();
549+
if (!preserveCase)
550+
subjectArray = subjectArray.toLowerCase();
550551

551552
if (subjectArray){
552553
subjectArray = subjectArray.split(';');

LDK/resources/web/LDK/panel/MultiSubjectFilterType.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ Ext4.define('LDK.panel.MultiSubjectFilterType', {
100100
},
101101

102102
addId: function (callback, panel) {
103-
var subjectArray = LDK.Utils.splitIds(this.down('#subjArea').getValue());
103+
var subjectArray = LDK.Utils.splitIds(this.down('#subjArea').getValue(), false, false, this.caseInsensitive);
104104

105105
if (subjectArray.length > 0) {
106106
subjectArray = Ext4.unique(subjectArray);
@@ -148,7 +148,7 @@ Ext4.define('LDK.panel.MultiSubjectFilterType', {
148148
//we clean up, combine, then split the subjectBox and subject inputs
149149
var subjectArray = this.subjects;
150150
if (subjectArray.length == 0)
151-
subjectArray = LDK.Utils.splitIds(this.down('#subjArea').getValue());
151+
subjectArray = LDK.Utils.splitIds(this.down('#subjArea').getValue(), false, false, this.caseInsensitive);
152152

153153
if (existing)
154154
subjectArray = subjectArray.concat(existing);
@@ -187,7 +187,7 @@ Ext4.define('LDK.panel.MultiSubjectFilterType', {
187187
},
188188

189189
loadReport: function (tab, callback, panel, forceRefresh) {
190-
var subjectArray = LDK.Utils.splitIds(this.down('#subjArea').getValue());
190+
var subjectArray = LDK.Utils.splitIds(this.down('#subjArea').getValue(), false, false, this.caseInsensitive);
191191

192192
if(subjectArray.length > 0) {
193193
this.addId(function(){

LDK/resources/web/LDK/panel/SingleSubjectFilterType.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ Ext4.define('LDK.panel.SingleSubjectFilterType', {
5959

6060
handleFilters: function (tab, filters) {
6161
var filterArray = {
62-
subjects: LDK.Utils.splitIds(this.down('#subjArea').getValue()),
62+
subjects: LDK.Utils.splitIds(this.down('#subjArea').getValue(), false, false, this.caseInsensitive),
6363
removable: [],
6464
nonRemovable: []
6565
};
@@ -122,7 +122,7 @@ Ext4.define('LDK.panel.SingleSubjectFilterType', {
122122
},
123123

124124
loadReport: function(tab, callback, panel, forceRefresh){
125-
var subjectArray = LDK.Utils.splitIds(this.down('#subjArea').getValue());
125+
var subjectArray = LDK.Utils.splitIds(this.down('#subjArea').getValue(), false, false, this.caseInsensitive);
126126

127127
if (subjectArray.length > 0){
128128
subjectArray = Ext4.unique(subjectArray);

LDK/resources/web/LDK/panel/TabbedReportPanel.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,9 @@ Ext4.define('LDK.panel.TabbedReportPanel', {
2828
autoLoadDefaultTab: false,
2929
clearBetweenClicks: true,
3030

31+
// Passed to filters implementing caseInsensitive id search
32+
caseInsensitiveSubjects: false,
33+
3134
btnPanelPrefix: 'btnPanel',
3235
totalPanelPrefix: 'totalPanel',
3336
btnPrefix: 'btn',
@@ -1015,6 +1018,7 @@ Ext4.define('LDK.panel.TabbedReportPanel', {
10151018
var cfg = Ext4.apply({}, filterType);
10161019
cfg.tabbedReportPanel = this;
10171020
cfg.filterContext = this.getFilterContext();
1021+
cfg.caseInsensitive = this.caseInsensitiveSubjects;
10181022

10191023
if (this.activeFilterType){
10201024
this.activeFilterType.prepareRemove();

0 commit comments

Comments
 (0)