From fd8575a8f624ef13ee8455f534ab11722934f012 Mon Sep 17 00:00:00 2001 From: Galen Charlton Date: Fri, 3 Jan 2020 14:28:15 -0500 Subject: [PATCH] LP#1811710: (follow-up) fix lint issues Signed-off-by: Galen Charlton Signed-off-by: Terran McCanna Signed-off-by: Chris Sharp --- .../eg2/src/app/staff/share/holds/grid.component.ts | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/Open-ILS/src/eg2/src/app/staff/share/holds/grid.component.ts b/Open-ILS/src/eg2/src/app/staff/share/holds/grid.component.ts index c2e5b104ce..92a2538aca 100644 --- a/Open-ILS/src/eg2/src/app/staff/share/holds/grid.component.ts +++ b/Open-ILS/src/eg2/src/app/staff/share/holds/grid.component.ts @@ -321,9 +321,9 @@ export class HoldsGridComponent implements OnInit { } metaRecordHoldsSelected(rows: IdlObject[]) { - var found = false; + let found = false; rows.forEach( row => { - if (row.hold_type == 'M') { + if (row.hold_type === 'M') { found = true; } }); @@ -331,9 +331,9 @@ export class HoldsGridComponent implements OnInit { } nonTitleHoldsSelected(rows: IdlObject[]) { - var found = false; + let found = false; rows.forEach( row => { - if (row.hold_type != 'T') { + if (row.hold_type !== 'T') { found = true; } }); @@ -388,10 +388,10 @@ export class HoldsGridComponent implements OnInit { } showOrder(rows: any[]) { - //Doesn't work in Typescript currently without compiler option: + // Doesn't work in Typescript currently without compiler option: // const bibIds = [...new Set( rows.map(r => r.record_id) )]; const bibIds = Array.from( - new Set( rows.filter(r => r.hold_type!='M').map(r => r.record_id) )); + new Set( rows.filter(r => r.hold_type !== 'M').map(r => r.record_id) )); bibIds.forEach( bibId => { const url = '/eg/staff/acq/legacy/lineitem/related/' + bibId + '?target=bib'; @@ -401,7 +401,7 @@ export class HoldsGridComponent implements OnInit { addVolume(rows: any[]) { const bibIds = Array.from( - new Set( rows.filter(r => r.hold_type!='M').map(r => r.record_id) )); + new Set( rows.filter(r => r.hold_type !== 'M').map(r => r.record_id) )); bibIds.forEach( bibId => { this.holdings.spawnAddHoldingsUi(bibId); }); @@ -410,7 +410,7 @@ export class HoldsGridComponent implements OnInit { showTitle(rows: any[]) { const bibIds = Array.from(new Set( rows.map(r => r.record_id) )); bibIds.forEach( bibId => { - //const url = '/eg/staff/cat/catalog/record/' + bibId; + // const url = '/eg/staff/cat/catalog/record/' + bibId; const url = '/eg2/staff/catalog/record/' + bibId; window.open(url, '_blank'); }); @@ -431,7 +431,7 @@ export class HoldsGridComponent implements OnInit { } showTransferDialog(rows: any[]) { - const holdIds = rows.filter(r => r.hold_type=='T').map(r => r.id).filter(id => Boolean(id)); + const holdIds = rows.filter(r => r.hold_type === 'T').map(r => r.id).filter(id => Boolean(id)); if (holdIds.length > 0) { this.transferDialog.holdIds = holdIds; this.transferDialog.open({}).subscribe( -- 2.11.0