LP#1207533: (follow-up) fix ng lint warnings
authorGalen Charlton <gmc@equinoxOLI.org>
Thu, 23 Sep 2021 14:08:44 +0000 (10:08 -0400)
committerGalen Charlton <gmc@equinoxOLI.org>
Thu, 23 Sep 2021 14:08:44 +0000 (10:08 -0400)
Signed-off-by: Galen Charlton <gmc@equinoxOLI.org>
Open-ILS/src/eg2/src/app/staff/circ/item/event-log/event-grid.component.ts
Open-ILS/src/eg2/src/app/staff/circ/patron/event-log/event-grid.component.ts

index 063d2cd..eb6f068 100644 (file)
@@ -65,13 +65,13 @@ export class ItemEventGridComponent implements OnChanges, OnInit {
             // base query to grab everything
             const base: Object = {};
             base[this.idl.classes['atoul'].pkey] = {'!=' : null};
-            base['context_item'] = (this.item ? this.item : {'>' : 0})
+            base['context_item'] = (this.item ? this.item : {'>' : 0});
 
             // circs or holds?
-            if (this.event_type == 'circ') {
-                base['target_circ'] = { '>' : 0 }
+            if (this.event_type === 'circ') {
+                base['target_circ'] = { '>' : 0 };
             } else {
-                base['target_hold'] = { '>' : 0 }
+                base['target_hold'] = { '>' : 0 };
             }
 
             const query: any = new Array();
@@ -88,7 +88,7 @@ export class ItemEventGridComponent implements OnChanges, OnInit {
                 query, {
                 flesh: 3,
                 flesh_fields: {
-                    atoul: ['context_user','context_item'],
+                    atoul: ['context_user', 'context_item'],
                     au: ['card']
                 },
                 offset: pager.offset,
@@ -105,22 +105,22 @@ export class ItemEventGridComponent implements OnChanges, OnInit {
             ).subscribe(
                 (res) => {
                     if (this.evt.parse(res)) {
-                        console.error('parsed error response',res);
+                        console.error('parsed error response', res);
                     } else {
-                        console.log('success',res);
+                        console.log('success', res);
                     }
                 },
                 (err) => {
-                    console.error('error',err);
+                    console.error('error', err);
                 },
                 () => {
                     console.log('finis');
                     this.grid.reload();
                 }
             );
-        }
+        };
 
-        this.noRowSelected = (rows: IdlObject[]) => (rows.length == 0);
+        this.noRowSelected = (rows: IdlObject[]) => (rows.length === 0);
     }
 
     ngOnChanges() { this.reloadGrid(); }
index 083b1a4..993cebc 100644 (file)
@@ -65,13 +65,13 @@ export class EventGridComponent implements OnChanges, OnInit {
             // base query to grab everything
             const base: Object = {};
             base[this.idl.classes['atoul'].pkey] = {'!=' : null};
-            base['context_user'] = (this.patron ? this.patron : {'>' : 0})
+            base['context_user'] = (this.patron ? this.patron : {'>' : 0});
 
             // circs or holds?
-            if (this.event_type == 'circ') {
-                base['target_circ'] = { '>' : 0 }
+            if (this.event_type === 'circ') {
+                base['target_circ'] = { '>' : 0 };
             } else {
-                base['target_hold'] = { '>' : 0 }
+                base['target_hold'] = { '>' : 0 };
             }
 
             const query: any = new Array();
@@ -105,22 +105,22 @@ export class EventGridComponent implements OnChanges, OnInit {
             ).subscribe(
                 (res) => {
                     if (this.evt.parse(res)) {
-                        console.error('parsed error response',res);
+                        console.error('parsed error response', res);
                     } else {
-                        console.log('success',res);
+                        console.log('success', res);
                     }
                 },
                 (err) => {
-                    console.error('error',err);
+                    console.error('error', err);
                 },
                 () => {
                     console.log('finis');
                     this.grid.reload();
                 }
             );
-        }
+        };
 
-        this.noRowSelected = (rows: IdlObject[]) => (rows.length == 0);
+        this.noRowSelected = (rows: IdlObject[]) => (rows.length === 0);
     }
 
     ngOnChanges() { this.reloadGrid(); }