From: Jane Sandberg Date: Thu, 8 Sep 2022 22:14:59 +0000 (-0700) Subject: LP1959048: manual ng lint fixes X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=c1faaf054fcc7c28e1037ef8b620f817f3853fe5;p=evergreen%2Fpines.git LP1959048: manual ng lint fixes Signed-off-by: Jane Sandberg Signed-off-by: Galen Charlton --- diff --git a/Open-ILS/src/eg2/src/app/share/.eslintrc b/Open-ILS/src/eg2/src/app/share/.eslintrc new file mode 100644 index 0000000000..773bf7745f --- /dev/null +++ b/Open-ILS/src/eg2/src/app/share/.eslintrc @@ -0,0 +1,8 @@ +{ + "rules": { + // Temporarily turn of this rule for this dir only, per + // https://bugs.launchpad.net/evergreen/+bug/1959048/comments/2 + // TODO: eventually adhere to this rule + "@angular-eslint/no-output-on-prefix": "off" + } +} \ No newline at end of file diff --git a/Open-ILS/src/eg2/src/app/share/catalog/bib-display-field.component.ts b/Open-ILS/src/eg2/src/app/share/catalog/bib-display-field.component.ts index 83176d9995..f8eb571a88 100644 --- a/Open-ILS/src/eg2/src/app/share/catalog/bib-display-field.component.ts +++ b/Open-ILS/src/eg2/src/app/share/catalog/bib-display-field.component.ts @@ -1,9 +1,5 @@ -import {Component, OnInit, Input, ViewEncapsulation} from '@angular/core'; -import {NetService} from '@eg/core/net.service'; -import {OrgService} from '@eg/core/org.service'; -import {AuthService} from '@eg/core/auth.service'; -import {BibRecordService, BibRecordSummary - } from '@eg/share/catalog/bib-record.service'; +import {Component, Input, ViewEncapsulation} from '@angular/core'; +import {BibRecordSummary} from '@eg/share/catalog/bib-record.service'; /* Display content from a bib summary display field. If highlight * data is avaialble, it will be used in lieu of the plan display string. @@ -21,7 +17,7 @@ const PAD_SPACE = ' '; // U+2007 styleUrls: ['bib-display-field.component.css'], encapsulation: ViewEncapsulation.None // required for search highlighting }) -export class BibDisplayFieldComponent implements OnInit { +export class BibDisplayFieldComponent { @Input() summary: BibRecordSummary; @Input() field: string; // display field name @@ -35,10 +31,6 @@ export class BibDisplayFieldComponent implements OnInit { // If provided, turn the display value into a link @Input() routerLink: string; - constructor() {} - - ngOnInit() {} - // Returns an array of display values which may either be // plain string values or strings with embedded HTML markup // for search results highlighting. diff --git a/Open-ILS/src/eg2/src/app/share/eg-help-popover/eg-help-popover.component.ts b/Open-ILS/src/eg2/src/app/share/eg-help-popover/eg-help-popover.component.ts index ffad186aad..f0b61e9588 100644 --- a/Open-ILS/src/eg2/src/app/share/eg-help-popover/eg-help-popover.component.ts +++ b/Open-ILS/src/eg2/src/app/share/eg-help-popover/eg-help-popover.component.ts @@ -1,12 +1,11 @@ -import { Component, OnInit, Input } from '@angular/core'; -import {NgbPopover} from '@ng-bootstrap/ng-bootstrap'; +import { Component, Input } from '@angular/core'; @Component({ selector: 'eg-help-popover', templateUrl: './eg-help-popover.component.html', styleUrls: ['./eg-help-popover.component.css'] }) -export class EgHelpPopoverComponent implements OnInit { +export class EgHelpPopoverComponent { // The text to display in the popover @Input() @@ -23,10 +22,4 @@ export class EgHelpPopoverComponent implements OnInit { // 'top', and so forth. @Input() placement = ''; - - constructor() { } - - ngOnInit() { - } - } diff --git a/Open-ILS/src/eg2/src/app/share/file-reader/file-reader.component.ts b/Open-ILS/src/eg2/src/app/share/file-reader/file-reader.component.ts index 4cbe5deaf0..98b0c75f74 100644 --- a/Open-ILS/src/eg2/src/app/share/file-reader/file-reader.component.ts +++ b/Open-ILS/src/eg2/src/app/share/file-reader/file-reader.component.ts @@ -2,11 +2,8 @@ * * */ -import {Component, OnInit, Input, Output, ViewChild, - TemplateRef, EventEmitter, ElementRef, forwardRef} from '@angular/core'; +import {Component, forwardRef} from '@angular/core'; import {ControlValueAccessor, NG_VALUE_ACCESSOR} from '@angular/forms'; -import {Observable, of, Subject} from 'rxjs'; -import {map, tap, reduce, mergeMap, mapTo, debounceTime, distinctUntilChanged, merge, filter} from 'rxjs/operators'; @Component({ selector: 'eg-file-reader', @@ -17,15 +14,12 @@ import {map, tap, reduce, mergeMap, mapTo, debounceTime, distinctUntilChanged, m multi: true }] }) -export class FileReaderComponent implements ControlValueAccessor, OnInit { +export class FileReaderComponent implements ControlValueAccessor { // Stub functions required by ControlValueAccessor propagateChange = (_: any) => {}; propagateTouch = () => {}; - ngOnInit() { - } - changeListener($event): void { const me = this; if ($event.target.files.length < 1) { diff --git a/Open-ILS/src/eg2/src/app/share/grid/grid-body-cell.component.ts b/Open-ILS/src/eg2/src/app/share/grid/grid-body-cell.component.ts index d1e88ba425..ee3daaa070 100644 --- a/Open-ILS/src/eg2/src/app/share/grid/grid-body-cell.component.ts +++ b/Open-ILS/src/eg2/src/app/share/grid/grid-body-cell.component.ts @@ -1,25 +1,17 @@ -import {Component, Input, OnInit, AfterViewInit, - TemplateRef, ElementRef} from '@angular/core'; -import {GridContext, GridColumn, GridRowSelector, - GridColumnSet, GridDataSource} from './grid'; +import {Component, Input} from '@angular/core'; +import {GridContext, GridColumn} from './grid'; @Component({ selector: 'eg-grid-body-cell', templateUrl: './grid-body-cell.component.html' }) -export class GridBodyCellComponent implements OnInit { +export class GridBodyCellComponent { @Input() context: GridContext; @Input() row: any; @Input() column: GridColumn; initDone: boolean; - - constructor( - private elm: ElementRef - ) {} - - ngOnInit() {} } diff --git a/Open-ILS/src/eg2/src/app/share/grid/grid-body.component.ts b/Open-ILS/src/eg2/src/app/share/grid/grid-body.component.ts index 918622e2c5..2c2152795b 100644 --- a/Open-ILS/src/eg2/src/app/share/grid/grid-body.component.ts +++ b/Open-ILS/src/eg2/src/app/share/grid/grid-body.component.ts @@ -1,6 +1,5 @@ -import {Component, Input, OnInit, Host} from '@angular/core'; -import {GridContext, GridColumn, GridRowSelector, - GridToolbarAction, GridColumnSet, GridDataSource} from './grid'; +import {Component, Input, Host} from '@angular/core'; +import {GridContext} from './grid'; import {GridComponent} from './grid.component'; import {NgbPopover} from '@ng-bootstrap/ng-bootstrap'; @@ -9,7 +8,7 @@ import {NgbPopover} from '@ng-bootstrap/ng-bootstrap'; templateUrl: './grid-body.component.html' }) -export class GridBodyComponent implements OnInit { +export class GridBodyComponent { @Input() context: GridContext; @@ -21,8 +20,6 @@ export class GridBodyComponent implements OnInit { this.contextMenus = []; } - ngOnInit() {} - // Not using @HostListener because it only works globally. onGridKeyDown(evt: KeyboardEvent) { switch (evt.key) { diff --git a/Open-ILS/src/eg2/src/app/share/grid/grid.component.html b/Open-ILS/src/eg2/src/app/share/grid/grid.component.html index 2ab6be0505..7100187acd 100644 --- a/Open-ILS/src/eg2/src/app/share/grid/grid.component.html +++ b/Open-ILS/src/eg2/src/app/share/grid/grid.component.html @@ -18,7 +18,7 @@ - +
diff --git a/Open-ILS/src/eg2/src/app/share/tree/tree.component.ts b/Open-ILS/src/eg2/src/app/share/tree/tree.component.ts index 64dd298215..2a60270128 100644 --- a/Open-ILS/src/eg2/src/app/share/tree/tree.component.ts +++ b/Open-ILS/src/eg2/src/app/share/tree/tree.component.ts @@ -1,4 +1,4 @@ -import {Component, OnInit, Input, Output, EventEmitter} from '@angular/core'; +import {Component, Input, Output, EventEmitter} from '@angular/core'; import {Tree, TreeNode} from './tree'; /* @@ -35,7 +35,7 @@ nodeClicked(node: TreeNode) { templateUrl: 'tree.component.html', styleUrls: ['tree.component.css'] }) -export class TreeComponent implements OnInit { +export class TreeComponent { _tree: Tree; @Input() set tree(t: Tree) { @@ -55,8 +55,6 @@ export class TreeComponent implements OnInit { this.nodeClicked = new EventEmitter(); } - ngOnInit() {} - displayNodes(): TreeNode[] { if (!this.tree) { return []; } return this.tree.nodeList(true); diff --git a/Open-ILS/src/eg2/src/app/share/util/bool.component.ts b/Open-ILS/src/eg2/src/app/share/util/bool.component.ts index bfbf054553..7c886a026e 100644 --- a/Open-ILS/src/eg2/src/app/share/util/bool.component.ts +++ b/Open-ILS/src/eg2/src/app/share/util/bool.component.ts @@ -7,7 +7,7 @@ import {Component, Input} from '@angular/core'; template: ` Yes - No + No Unset diff --git a/Open-ILS/src/eg2/src/app/staff/acq/provider/acq-provider-search-form.component.ts b/Open-ILS/src/eg2/src/app/staff/acq/provider/acq-provider-search-form.component.ts index 618cb44b55..e1fa6df2d7 100644 --- a/Open-ILS/src/eg2/src/app/staff/acq/provider/acq-provider-search-form.component.ts +++ b/Open-ILS/src/eg2/src/app/staff/acq/provider/acq-provider-search-form.component.ts @@ -1,11 +1,4 @@ -import {Component, OnInit, AfterViewInit, Input, Output, EventEmitter, ViewChild} from '@angular/core'; -import {NgbTabset, NgbTabChangeEvent} from '@ng-bootstrap/ng-bootstrap'; -import {Router, ActivatedRoute} from '@angular/router'; -import {StaffCommonModule} from '@eg/staff/common.module'; -import {IdlService, IdlObject} from '@eg/core/idl.service'; -import {PcrudService} from '@eg/core/pcrud.service'; -import {StringComponent} from '@eg/share/string/string.component'; -import {ToastService} from '@eg/share/toast/toast.service'; +import {Component, OnInit, Output, EventEmitter} from '@angular/core'; import {AuthService} from '@eg/core/auth.service'; import {AcqProviderSearchTerm, AcqProviderSearch} from './acq-provider-search.service'; import {StoreService} from '@eg/core/store.service'; @@ -17,7 +10,7 @@ import {OrgFamily} from '@eg/share/org-family-select/org-family-select.component templateUrl: './acq-provider-search-form.component.html' }) -export class AcqProviderSearchFormComponent implements OnInit, AfterViewInit { +export class AcqProviderSearchFormComponent implements OnInit { @Output() searchSubmitted = new EventEmitter(); @@ -36,12 +29,7 @@ export class AcqProviderSearchFormComponent implements OnInit, AfterViewInit { providerIsActive = 'active'; constructor( - private router: Router, - private route: ActivatedRoute, - private pcrud: PcrudService, private localStore: StoreService, - private idl: IdlService, - private toast: ToastService, private auth: AuthService, ) {} @@ -51,8 +39,6 @@ export class AcqProviderSearchFormComponent implements OnInit, AfterViewInit { this.collapsed = this.localStore.getLocalItem('eg.acq.provider.search.collapse_form') || false; } - ngAfterViewInit() {} - clearSearch() { this.providerName = ''; this.providerCode = ''; diff --git a/Open-ILS/src/eg2/src/app/staff/acq/provider/acq-provider.component.html b/Open-ILS/src/eg2/src/app/staff/acq/provider/acq-provider.component.html index 74137070fc..d769a72df5 100644 --- a/Open-ILS/src/eg2/src/app/staff/acq/provider/acq-provider.component.html +++ b/Open-ILS/src/eg2/src/app/staff/acq/provider/acq-provider.component.html @@ -50,7 +50,7 @@
-
@@ -61,7 +61,7 @@
-
@@ -72,7 +72,7 @@
-
@@ -83,7 +83,7 @@
-
@@ -94,7 +94,7 @@
-
@@ -105,7 +105,7 @@
-
@@ -116,7 +116,7 @@
-
@@ -127,7 +127,7 @@
-
diff --git a/Open-ILS/src/eg2/src/app/staff/acq/provider/provider-holdings.component.html b/Open-ILS/src/eg2/src/app/staff/acq/provider/provider-holdings.component.html index 897ddf8c91..889a4bdc86 100644 --- a/Open-ILS/src/eg2/src/app/staff/acq/provider/provider-holdings.component.html +++ b/Open-ILS/src/eg2/src/app/staff/acq/provider/provider-holdings.component.html @@ -32,7 +32,7 @@
+ [disabled]="!holdingTagForm.dirty || (provider && provider._holding_tag === provider.holding_tag())" i18n>Save
diff --git a/Open-ILS/src/eg2/src/app/staff/acq/search/acq-search-form.component.ts b/Open-ILS/src/eg2/src/app/staff/acq/search/acq-search-form.component.ts index 19d4a1f9c8..1ddc94f9c1 100644 --- a/Open-ILS/src/eg2/src/app/staff/acq/search/acq-search-form.component.ts +++ b/Open-ILS/src/eg2/src/app/staff/acq/search/acq-search-form.component.ts @@ -1,7 +1,5 @@ -import {Component, OnInit, AfterViewInit, Input, Output, EventEmitter, ViewChild, +import {Component, OnInit, Input, Output, EventEmitter, ViewChild, OnChanges, SimpleChanges} from '@angular/core'; -import {Router, ActivatedRoute} from '@angular/router'; -import {StaffCommonModule} from '@eg/staff/common.module'; import {IdlService, IdlObject} from '@eg/core/idl.service'; import {PcrudService} from '@eg/core/pcrud.service'; import {StringComponent} from '@eg/share/string/string.component'; @@ -15,7 +13,7 @@ import {ServerStoreService} from '@eg/core/server-store.service'; templateUrl: './acq-search-form.component.html' }) -export class AcqSearchFormComponent implements OnInit, AfterViewInit, OnChanges { +export class AcqSearchFormComponent implements OnInit, OnChanges { @Input() initialSearchTerms: AcqSearchTerm[] = []; @Input() fallbackSearchTerms: AcqSearchTerm[] = []; @@ -45,8 +43,6 @@ export class AcqSearchFormComponent implements OnInit, AfterViewInit, OnChanges searchTerms: AcqSearchTerm[] = []; constructor( - private router: Router, - private route: ActivatedRoute, private pcrud: PcrudService, private store: ServerStoreService, private idl: IdlService, @@ -130,8 +126,6 @@ export class AcqSearchFormComponent implements OnInit, AfterViewInit, OnChanges }); } - ngAfterViewInit() {} - ngOnChanges(changes: SimpleChanges) { if ('initialSearchTerms' in changes && !changes.initialSearchTerms.firstChange) { this.ngOnInit(); diff --git a/Open-ILS/src/eg2/src/app/staff/acq/search/acq-search.component.ts b/Open-ILS/src/eg2/src/app/staff/acq/search/acq-search.component.ts index 959963f0ac..6d0cd45d63 100644 --- a/Open-ILS/src/eg2/src/app/staff/acq/search/acq-search.component.ts +++ b/Open-ILS/src/eg2/src/app/staff/acq/search/acq-search.component.ts @@ -1,11 +1,8 @@ -import {Component, OnInit, AfterViewInit, ViewChild, ViewChildren, QueryList, OnDestroy} from '@angular/core'; +import {Component, OnInit, ViewChild, ViewChildren, QueryList, OnDestroy} from '@angular/core'; import {NgbNav, NgbNavChangeEvent} from '@ng-bootstrap/ng-bootstrap'; import {Router, ActivatedRoute, ParamMap, RouterEvent, NavigationEnd} from '@angular/router'; import {filter, takeUntil} from 'rxjs/operators'; import {Subject} from 'rxjs'; -import {StaffCommonModule} from '@eg/staff/common.module'; -import {IdlService, IdlObject} from '@eg/core/idl.service'; -import {PcrudService} from '@eg/core/pcrud.service'; import {AcqSearchTerm} from './acq-search.service'; import {LineitemResultsComponent} from './lineitem-results.component'; import {PurchaseOrderResultsComponent} from './purchase-order-results.component'; @@ -16,7 +13,7 @@ import {PicklistResultsComponent} from './picklist-results.component'; templateUrl: './acq-search.component.html' }) -export class AcqSearchComponent implements OnInit, AfterViewInit, OnDestroy { +export class AcqSearchComponent implements OnInit, OnDestroy { searchType = ''; validSearchTypes = ['lineitems', 'purchaseorders', 'invoices', 'selectionlists']; @@ -37,8 +34,6 @@ export class AcqSearchComponent implements OnInit, AfterViewInit, OnDestroy { constructor( private router: Router, private route: ActivatedRoute, - private pcrud: PcrudService, - private idl: IdlService, ) { this.route.queryParamMap.subscribe((params: ParamMap) => { this.urlSearchTerms = []; @@ -136,8 +131,6 @@ export class AcqSearchComponent implements OnInit, AfterViewInit, OnDestroy { }; } - ngAfterViewInit() {} - ngOnDestroy(): void { this.destroyed.next(); this.destroyed.complete(); diff --git a/Open-ILS/src/eg2/src/app/staff/acq/search/picklist-clone-dialog.component.ts b/Open-ILS/src/eg2/src/app/staff/acq/search/picklist-clone-dialog.component.ts index aceca1e309..91aab9ad37 100644 --- a/Open-ILS/src/eg2/src/app/staff/acq/search/picklist-clone-dialog.component.ts +++ b/Open-ILS/src/eg2/src/app/staff/acq/search/picklist-clone-dialog.component.ts @@ -1,5 +1,4 @@ -import {Component, Input, ViewChild, TemplateRef, OnInit, Renderer2} from '@angular/core'; -import {Observable, from, empty, throwError} from 'rxjs'; +import {Component, Input, ViewChild, Renderer2} from '@angular/core'; import {DialogComponent} from '@eg/share/dialog/dialog.component'; import {AlertDialogComponent} from '@eg/share/dialog/alert.component'; import {IdlService, IdlObject} from '@eg/core/idl.service'; @@ -7,7 +6,6 @@ import {EventService} from '@eg/core/event.service'; import {NetService} from '@eg/core/net.service'; import {AuthService} from '@eg/core/auth.service'; import {NgbModal} from '@ng-bootstrap/ng-bootstrap'; -import {ComboboxEntry} from '@eg/share/combobox/combobox.component'; @Component({ selector: 'eg-picklist-clone-dialog', @@ -15,7 +13,7 @@ import {ComboboxEntry} from '@eg/share/combobox/combobox.component'; }) export class PicklistCloneDialogComponent - extends DialogComponent implements OnInit { + extends DialogComponent { @Input() grid: any; selectionListName: String; @@ -35,9 +33,6 @@ export class PicklistCloneDialogComponent super(modal); } - ngOnInit() { - } - update() { this.leadListName = this.grid.context.getSelectedRows()[0].name(); this.renderer.selectRootElement('#create-picklist-name').focus(); diff --git a/Open-ILS/src/eg2/src/app/staff/acq/search/picklist-delete-dialog.component.ts b/Open-ILS/src/eg2/src/app/staff/acq/search/picklist-delete-dialog.component.ts index f7cfd49349..466f0c6cd3 100644 --- a/Open-ILS/src/eg2/src/app/staff/acq/search/picklist-delete-dialog.component.ts +++ b/Open-ILS/src/eg2/src/app/staff/acq/search/picklist-delete-dialog.component.ts @@ -1,13 +1,11 @@ -import {Component, Input, ViewChild, TemplateRef, OnInit} from '@angular/core'; -import {Observable, forkJoin, from, empty, throwError} from 'rxjs'; +import {Component, Input, ViewChild} from '@angular/core'; +import {forkJoin} from 'rxjs'; import {DialogComponent} from '@eg/share/dialog/dialog.component'; import {AlertDialogComponent} from '@eg/share/dialog/alert.component'; -import {IdlService, IdlObject} from '@eg/core/idl.service'; import {EventService} from '@eg/core/event.service'; import {NetService} from '@eg/core/net.service'; import {AuthService} from '@eg/core/auth.service'; import {NgbModal} from '@ng-bootstrap/ng-bootstrap'; -import {ComboboxEntry} from '@eg/share/combobox/combobox.component'; @Component({ selector: 'eg-picklist-delete-dialog', @@ -15,7 +13,7 @@ import {ComboboxEntry} from '@eg/share/combobox/combobox.component'; }) export class PicklistDeleteDialogComponent - extends DialogComponent implements OnInit { + extends DialogComponent { @Input() grid: any; listNames: string[]; @@ -23,7 +21,6 @@ export class PicklistDeleteDialogComponent @ViewChild('fail', { static: true }) private fail: AlertDialogComponent; constructor( - private idl: IdlService, private evt: EventService, private net: NetService, private auth: AuthService, @@ -32,9 +29,6 @@ export class PicklistDeleteDialogComponent super(modal); } - ngOnInit() { - } - update() { this.listNames = this.grid.context.getSelectedRows().map( r => r.name() ); } diff --git a/Open-ILS/src/eg2/src/app/staff/acq/search/picklist-merge-dialog.component.ts b/Open-ILS/src/eg2/src/app/staff/acq/search/picklist-merge-dialog.component.ts index 60ed6d6060..a4c71f58ff 100644 --- a/Open-ILS/src/eg2/src/app/staff/acq/search/picklist-merge-dialog.component.ts +++ b/Open-ILS/src/eg2/src/app/staff/acq/search/picklist-merge-dialog.component.ts @@ -1,5 +1,4 @@ -import {Component, Input, ViewChild, TemplateRef, OnInit} from '@angular/core'; -import {Observable, forkJoin, from, empty, throwError} from 'rxjs'; +import {Component, Input, ViewChild} from '@angular/core'; import {DialogComponent} from '@eg/share/dialog/dialog.component'; import {AlertDialogComponent} from '@eg/share/dialog/alert.component'; import {IdlService, IdlObject} from '@eg/core/idl.service'; @@ -7,7 +6,6 @@ import {EventService} from '@eg/core/event.service'; import {NetService} from '@eg/core/net.service'; import {AuthService} from '@eg/core/auth.service'; import {NgbModal} from '@ng-bootstrap/ng-bootstrap'; -import {ComboboxEntry} from '@eg/share/combobox/combobox.component'; @Component({ selector: 'eg-picklist-merge-dialog', @@ -15,7 +13,7 @@ import {ComboboxEntry} from '@eg/share/combobox/combobox.component'; }) export class PicklistMergeDialogComponent - extends DialogComponent implements OnInit { + extends DialogComponent { @Input() grid: any; listNames: string[]; @@ -34,9 +32,6 @@ export class PicklistMergeDialogComponent super(modal); } - ngOnInit() { - } - update() { this.selectedLists = this.grid.context.getSelectedRows(); this.listNames = this.selectedLists.map( r => r.name() ); diff --git a/Open-ILS/src/eg2/src/app/staff/admin/acq/claiming-admin.component.ts b/Open-ILS/src/eg2/src/app/staff/admin/acq/claiming-admin.component.ts index 92b9a86a7c..3ffabafb90 100644 --- a/Open-ILS/src/eg2/src/app/staff/admin/acq/claiming-admin.component.ts +++ b/Open-ILS/src/eg2/src/app/staff/admin/acq/claiming-admin.component.ts @@ -1,10 +1,7 @@ -import {Component, OnInit, Input, ViewChild} from '@angular/core'; +import {Component} from '@angular/core'; @Component({ templateUrl: './claiming-admin.component.html' }) -export class ClaimingAdminComponent implements OnInit { - - ngOnInit() { - } +export class ClaimingAdminComponent { } diff --git a/Open-ILS/src/eg2/src/app/staff/admin/acq/edi_attr_set/edi-attr-set-edit-dialog.component.ts b/Open-ILS/src/eg2/src/app/staff/admin/acq/edi_attr_set/edi-attr-set-edit-dialog.component.ts index 203f72600e..2cc0e7e8fe 100644 --- a/Open-ILS/src/eg2/src/app/staff/admin/acq/edi_attr_set/edi-attr-set-edit-dialog.component.ts +++ b/Open-ILS/src/eg2/src/app/staff/admin/acq/edi_attr_set/edi-attr-set-edit-dialog.component.ts @@ -1,16 +1,8 @@ -import {Component, Input, ViewChild, TemplateRef, OnInit} from '@angular/core'; +import {Component, Input, OnInit} from '@angular/core'; import {DialogComponent} from '@eg/share/dialog/dialog.component'; -import {NgForm} from '@angular/forms'; import {IdlService, IdlObject} from '@eg/core/idl.service'; -import {EventService} from '@eg/core/event.service'; -import {NetService} from '@eg/core/net.service'; -import {AuthService} from '@eg/core/auth.service'; import {PcrudService} from '@eg/core/pcrud.service'; -import {Pager} from '@eg/share/util/pager'; import {NgbModal} from '@ng-bootstrap/ng-bootstrap'; -import {StringComponent} from '@eg/share/string/string.component'; -import {ToastService} from '@eg/share/toast/toast.service'; -import {PermService} from '@eg/core/perm.service'; @Component({ selector: 'eg-edi-attr-set-edit-dialog', @@ -29,12 +21,7 @@ export class EdiAttrSetEditDialogComponent constructor( private idl: IdlService, - private evt: EventService, - private net: NetService, - private auth: AuthService, private pcrud: PcrudService, - private perm: PermService, - private toast: ToastService, private modal: NgbModal ) { super(modal); diff --git a/Open-ILS/src/eg2/src/app/staff/admin/acq/edi_attr_set/edi-attr-set-providers-dialog.component.ts b/Open-ILS/src/eg2/src/app/staff/admin/acq/edi_attr_set/edi-attr-set-providers-dialog.component.ts index fad5b63eaa..e0e63be17e 100644 --- a/Open-ILS/src/eg2/src/app/staff/admin/acq/edi_attr_set/edi-attr-set-providers-dialog.component.ts +++ b/Open-ILS/src/eg2/src/app/staff/admin/acq/edi_attr_set/edi-attr-set-providers-dialog.component.ts @@ -1,17 +1,6 @@ -import {Component, Input, ViewChild, TemplateRef, OnInit} from '@angular/core'; +import {Component, Input} from '@angular/core'; import {DialogComponent} from '@eg/share/dialog/dialog.component'; -import {NgForm} from '@angular/forms'; -import {IdlService, IdlObject} from '@eg/core/idl.service'; -import {EventService} from '@eg/core/event.service'; -import {NetService} from '@eg/core/net.service'; -import {AuthService} from '@eg/core/auth.service'; -import {PcrudService} from '@eg/core/pcrud.service'; -import {Pager} from '@eg/share/util/pager'; import {NgbModal} from '@ng-bootstrap/ng-bootstrap'; -import {StringComponent} from '@eg/share/string/string.component'; -import {ToastService} from '@eg/share/toast/toast.service'; -import {PermService} from '@eg/core/perm.service'; -import {EdiAttrSetProvidersComponent} from './edi-attr-set-providers.component'; @Component({ selector: 'eg-edi-attr-set-providers-dialog', @@ -19,23 +8,13 @@ import {EdiAttrSetProvidersComponent} from './edi-attr-set-providers.component'; }) export class EdiAttrSetProvidersDialogComponent - extends DialogComponent implements OnInit { + extends DialogComponent { @Input() attrSetId: number; constructor( - private idl: IdlService, - private evt: EventService, - private net: NetService, - private auth: AuthService, - private pcrud: PcrudService, - private perm: PermService, - private toast: ToastService, private modal: NgbModal ) { super(modal); } - - ngOnInit() { } - } diff --git a/Open-ILS/src/eg2/src/app/staff/admin/acq/funds/fund-details-dialog.component.html b/Open-ILS/src/eg2/src/app/staff/admin/acq/funds/fund-details-dialog.component.html index 19084cc7ac..ed3d7bf768 100644 --- a/Open-ILS/src/eg2/src/app/staff/admin/acq/funds/fund-details-dialog.component.html +++ b/Open-ILS/src/eg2/src/app/staff/admin/acq/funds/fund-details-dialog.component.html @@ -28,7 +28,7 @@ (click)="doTransfer()" i18n>Transfer Money
-
diff --git a/Open-ILS/src/eg2/src/app/staff/admin/local/admin-carousel.component.html b/Open-ILS/src/eg2/src/app/staff/admin/local/admin-carousel.component.html index a56294fd43..dfdafddafa 100644 --- a/Open-ILS/src/eg2/src/app/staff/admin/local/admin-carousel.component.html +++ b/Open-ILS/src/eg2/src/app/staff/admin/local/admin-carousel.component.html @@ -48,7 +48,7 @@ - diff --git a/Open-ILS/src/eg2/src/app/staff/admin/local/circ_limit_set/circ_limit_set_edit.component.html b/Open-ILS/src/eg2/src/app/staff/admin/local/circ_limit_set/circ_limit_set_edit.component.html index 499b230e8d..edeb545057 100644 --- a/Open-ILS/src/eg2/src/app/staff/admin/local/circ_limit_set/circ_limit_set_edit.component.html +++ b/Open-ILS/src/eg2/src/app/staff/admin/local/circ_limit_set/circ_limit_set_edit.component.html @@ -26,7 +26,7 @@
Remove
-
+
{{ mod.code }} : {{ mod.name }}
@@ -57,7 +57,7 @@
Remove
-
+
{{ location.shortname }} : {{ location.name }}
@@ -88,7 +88,7 @@
Remove
-
+
{{ group.name }}
diff --git a/Open-ILS/src/eg2/src/app/staff/admin/local/copy-loc-order/copy-loc-order.component.html b/Open-ILS/src/eg2/src/app/staff/admin/local/copy-loc-order/copy-loc-order.component.html index 6c42172b08..378bfa3744 100644 --- a/Open-ILS/src/eg2/src/app/staff/admin/local/copy-loc-order/copy-loc-order.component.html +++ b/Open-ILS/src/eg2/src/app/staff/admin/local/copy-loc-order/copy-loc-order.component.html @@ -49,7 +49,7 @@ + [ngClass]="{'border border-primary rounded': selectedEntry === entry.id()}"> {{entry.location().name()}} ({{orgSn(entry.location().owning_lib())}}) (unsaved) diff --git a/Open-ILS/src/eg2/src/app/staff/admin/local/staff_portal_page/staff-portal-page.component.html b/Open-ILS/src/eg2/src/app/staff/admin/local/staff_portal_page/staff-portal-page.component.html index 175e607ffd..cf4e119eb1 100644 --- a/Open-ILS/src/eg2/src/app/staff/admin/local/staff_portal_page/staff-portal-page.component.html +++ b/Open-ILS/src/eg2/src/app/staff/admin/local/staff_portal_page/staff-portal-page.component.html @@ -77,7 +77,7 @@ - diff --git a/Open-ILS/src/eg2/src/app/staff/admin/workstation/workstations/workstations.component.html b/Open-ILS/src/eg2/src/app/staff/admin/workstation/workstations/workstations.component.html index 0ff3ce599d..e853e95f5d 100644 --- a/Open-ILS/src/eg2/src/app/staff/admin/workstation/workstations/workstations.component.html +++ b/Open-ILS/src/eg2/src/app/staff/admin/workstation/workstations/workstations.component.html @@ -16,7 +16,7 @@
Workstation {{removeWorkstation}} is no longer valid. Removing registration.
-
+
Please register a workstation.
@@ -62,10 +62,10 @@
- +
- +
diff --git a/Open-ILS/src/eg2/src/app/staff/catalog/result/pagination.component.html b/Open-ILS/src/eg2/src/app/staff/catalog/result/pagination.component.html index 7cdda006e2..a15e428b2e 100644 --- a/Open-ILS/src/eg2/src/app/staff/catalog/result/pagination.component.html +++ b/Open-ILS/src/eg2/src/app/staff/catalog/result/pagination.component.html @@ -14,7 +14,7 @@ unnecessary given we have to track paging externally anyway.
  • + [ngClass]="{active : searchContext.pager.currentPage() === page}"> {{page}} (current)
  • diff --git a/Open-ILS/src/eg2/src/app/staff/catalog/search-form.component.html b/Open-ILS/src/eg2/src/app/staff/catalog/search-form.component.html index bd1d0991aa..e75ef48fe9 100644 --- a/Open-ILS/src/eg2/src/app/staff/catalog/search-form.component.html +++ b/Open-ILS/src/eg2/src/app/staff/catalog/search-form.component.html @@ -35,10 +35,10 @@
    -
    +
    remove_circle_outline - diff --git a/Open-ILS/src/eg2/src/app/staff/share/marc-edit/editor-dialog.component.ts b/Open-ILS/src/eg2/src/app/staff/share/marc-edit/editor-dialog.component.ts index 67e836bb0c..a0304e14ee 100644 --- a/Open-ILS/src/eg2/src/app/staff/share/marc-edit/editor-dialog.component.ts +++ b/Open-ILS/src/eg2/src/app/staff/share/marc-edit/editor-dialog.component.ts @@ -1,5 +1,4 @@ -import {Component, Input, Output, OnInit, EventEmitter} from '@angular/core'; -import {Observable} from 'rxjs'; +import {Component, Input} from '@angular/core'; import {NetService} from '@eg/core/net.service'; import {OrgService} from '@eg/core/org.service'; import {AuthService} from '@eg/core/auth.service'; @@ -19,7 +18,7 @@ import {MarcEditContext} from './editor-context'; }) export class MarcEditorDialogComponent - extends DialogComponent implements OnInit { + extends DialogComponent { @Input() context: MarcEditContext; @Input() recordXml: string; @@ -34,8 +33,6 @@ export class MarcEditorDialogComponent super(modal); } - ngOnInit() {} - handleRecordSaved(saved) { this.close(saved); } diff --git a/Open-ILS/src/eg2/src/app/staff/share/marc-edit/editor.component.html b/Open-ILS/src/eg2/src/app/staff/share/marc-edit/editor.component.html index 25e14c0500..e92e9bc268 100644 --- a/Open-ILS/src/eg2/src/app/staff/share/marc-edit/editor.component.html +++ b/Open-ILS/src/eg2/src/app/staff/share/marc-edit/editor.component.html @@ -58,11 +58,11 @@
    + [disabled]="(record && record.deleted) || record.id === -1" i18n>Save Changes
    - @@ -104,7 +104,7 @@
    + [disabled]="(record && record.deleted) || record.id === -1" i18n>Save Changes
    diff --git a/Open-ILS/src/eg2/src/app/staff/share/marc-edit/fixed-fields-editor.component.ts b/Open-ILS/src/eg2/src/app/staff/share/marc-edit/fixed-fields-editor.component.ts index d02981606b..fb3de96d82 100644 --- a/Open-ILS/src/eg2/src/app/staff/share/marc-edit/fixed-fields-editor.component.ts +++ b/Open-ILS/src/eg2/src/app/staff/share/marc-edit/fixed-fields-editor.component.ts @@ -1,5 +1,4 @@ -import {Component, Input, Output, OnInit, AfterViewInit, EventEmitter, - OnDestroy} from '@angular/core'; +import {Component, Input} from '@angular/core'; import {IdlService} from '@eg/core/idl.service'; import {OrgService} from '@eg/core/org.service'; import {MarcRecord} from './marcrecord'; @@ -15,7 +14,7 @@ import {TagTableService} from './tagtable.service'; templateUrl: './fixed-fields-editor.component.html' }) -export class FixedFieldsEditorComponent implements OnInit { +export class FixedFieldsEditorComponent { @Input() context: MarcEditContext; get record(): MarcRecord { return this.context.record; } @@ -25,7 +24,5 @@ export class FixedFieldsEditorComponent implements OnInit { private org: OrgService, private tagTable: TagTableService ) {} - - ngOnInit() {} } diff --git a/Open-ILS/src/eg2/src/app/staff/share/patron/search-dialog.component.ts b/Open-ILS/src/eg2/src/app/staff/share/patron/search-dialog.component.ts index 98e1c22d72..93c611979c 100644 --- a/Open-ILS/src/eg2/src/app/staff/share/patron/search-dialog.component.ts +++ b/Open-ILS/src/eg2/src/app/staff/share/patron/search-dialog.component.ts @@ -1,5 +1,5 @@ -import {Component, OnInit, Input, Output, ViewChild} from '@angular/core'; -import {IdlService, IdlObject} from '@eg/core/idl.service'; +import {Component, ViewChild} from '@angular/core'; +import {IdlObject} from '@eg/core/idl.service'; import {NgbModal} from '@ng-bootstrap/ng-bootstrap'; import {DialogComponent} from '@eg/share/dialog/dialog.component'; import {PatronSearchComponent} from './search.component'; @@ -17,15 +17,13 @@ import {PatronSearchComponent} from './search.component'; }) export class PatronSearchDialogComponent - extends DialogComponent implements OnInit { + extends DialogComponent { @ViewChild('searchForm', {static: false}) searchForm: PatronSearchComponent; constructor(private modal: NgbModal) { super(modal); } - ngOnInit() {} - // Fired when a row in the search grid is dbl-clicked / activated patronsSelected(patrons: IdlObject[]) { this.close(patrons); diff --git a/Open-ILS/src/eg2/src/app/welcome.component.ts b/Open-ILS/src/eg2/src/app/welcome.component.ts index a5886614b0..c226a1d42a 100644 --- a/Open-ILS/src/eg2/src/app/welcome.component.ts +++ b/Open-ILS/src/eg2/src/app/welcome.component.ts @@ -1,12 +1,10 @@ -import { Component, OnInit } from '@angular/core'; +import { Component } from '@angular/core'; @Component({ templateUrl : './welcome.component.html' }) -export class WelcomeComponent implements OnInit { - ngOnInit() { - } +export class WelcomeComponent { }