click$: Subject<string>;
entrylist: ComboboxEntry[];
- @ViewChild('instance') instance: NgbTypeahead;
+ @ViewChild('instance', { static: true }) instance: NgbTypeahead;
// Applies a name attribute to the input.
// Useful in forms.
@Input() public dialogTitle: string;
// Pointer to the dialog content template.
- @ViewChild('dialogContent')
+ @ViewChild('dialogContent', {static: false})
private dialogContent: TemplateRef<any>;
// Emitted after open() is called on the ngbModal.
// Emit an error message when the save action fails.
@Output() onError$ = new EventEmitter<string>();
- @ViewChild('translator') private translator: TranslateComponent;
+ @ViewChild('translator', { static: true }) private translator: TranslateComponent;
// IDL info for the the selected IDL class
idlDef: any;
export class GridPrintComponent {
@Input() gridContext: GridContext;
- @ViewChild('printTemplate') private printTemplate: TemplateRef<any>;
- @ViewChild('progressDialog')
+ @ViewChild('printTemplate', { static: true }) private printTemplate: TemplateRef<any>;
+ @ViewChild('progressDialog', { static: true })
private progressDialog: ProgressDialogComponent;
constructor(private printer: PrintService) {}
// Disable the entire input
@Input() disabled: boolean;
- @ViewChild('instance') instance: NgbTypeahead;
+ @ViewChild('instance', { static: false }) instance: NgbTypeahead;
// Placeholder text for selector input
@Input() placeholder = '';
this.setTitle();
}
- @ViewChild('titleString') titleString: StringComponent;
+ @ViewChild('titleString', { static: true }) titleString: StringComponent;
constructor(private title: Title) {}
template: `<eg-bool></eg-bool>`
})
class TestHostComponent {
- @ViewChild(BoolDisplayComponent, /* TODO: add static flag */ {})
+ @ViewChild(BoolDisplayComponent, {static: false})
public boolDisplayComponent: BoolDisplayComponent;
}
tree: Tree;
selected: TreeNode;
- @ViewChild('editDialog') editDialog: FmRecordEditorComponent;
- @ViewChild('editString') editString: StringComponent;
- @ViewChild('createString') createString: StringComponent;
- @ViewChild('errorString') errorString: StringComponent;
- @ViewChild('delConfirm') delConfirm: ConfirmDialogComponent;
+ @ViewChild('editDialog', { static: true }) editDialog: FmRecordEditorComponent;
+ @ViewChild('editString', { static: true }) editString: StringComponent;
+ @ViewChild('createString', { static: true }) createString: StringComponent;
+ @ViewChild('errorString', { static: true }) errorString: StringComponent;
+ @ViewChild('delConfirm', { static: true }) delConfirm: ConfirmDialogComponent;
constructor(
private idl: IdlService,
newName: string;
defaultName: string;
- @ViewChild('workstationExistsDialog')
+ @ViewChild('workstationExistsDialog', { static: true })
private wsExistsDialog: ConfirmDialogComponent;
// Org selector options.
exportingBasket: boolean;
basketRecords: number[];
- @ViewChild('fileSelector') private fileSelector;
- @ViewChild('exportProgress')
+ @ViewChild('fileSelector', { static: false }) private fileSelector;
+ @ViewChild('exportProgress', { static: true })
private exportProgress: ProgressInlineComponent;
constructor(
formTemplates: {[name: string]: any};
newTemplateName: string;
- @ViewChild('fileSelector') private fileSelector;
- @ViewChild('uploadProgress')
+ @ViewChild('fileSelector', { static: false }) private fileSelector;
+ @ViewChild('uploadProgress', { static: true })
private uploadProgress: ProgressInlineComponent;
- @ViewChild('enqueueProgress')
+ @ViewChild('enqueueProgress', { static: true })
private enqueueProgress: ProgressInlineComponent;
- @ViewChild('importProgress')
+ @ViewChild('importProgress', { static: true })
private importProgress: ProgressInlineComponent;
// Need these refs so values can be applied via external stimuli
- @ViewChild('formTemplateSelector')
+ @ViewChild('formTemplateSelector', { static: true })
private formTemplateSelector: ComboboxComponent;
- @ViewChild('recordTypeSelector')
+ @ViewChild('recordTypeSelector', { static: true })
private recordTypeSelector: ComboboxComponent;
- @ViewChild('bibSourceSelector')
+ @ViewChild('bibSourceSelector', { static: true })
private bibSourceSelector: ComboboxComponent;
- @ViewChild('matchSetSelector')
+ @ViewChild('matchSetSelector', { static: true })
private matchSetSelector: ComboboxComponent;
- @ViewChild('holdingsProfileSelector')
+ @ViewChild('holdingsProfileSelector', { static: true })
private holdingsProfileSelector: ComboboxComponent;
- @ViewChild('mergeProfileSelector')
+ @ViewChild('mergeProfileSelector', { static: true })
private mergeProfileSelector: ComboboxComponent;
- @ViewChild('fallThruMergeProfileSelector')
+ @ViewChild('fallThruMergeProfileSelector', { static: true })
private fallThruMergeProfileSelector: ComboboxComponent;
- @ViewChild('dupeQueueAlert')
+ @ViewChild('dupeQueueAlert', { static: true })
private dupeQueueAlert: AlertDialogComponent;
constructor(
newPointType: string;
newId: number;
- @ViewChild('newPoint') newPoint: MatchSetNewPointComponent;
+ @ViewChild('newPoint', { static: true }) newPoint: MatchSetNewPointComponent;
constructor(
private idl: IdlService,
gridSource: GridDataSource;
deleteSelected: (rows: IdlObject[]) => void;
createNew: () => void;
- @ViewChild('grid') grid: GridComponent;
- @ViewChild('editDialog') editDialog: FmRecordEditorComponent;
+ @ViewChild('grid', { static: true }) grid: GridComponent;
+ @ViewChild('editDialog', { static: true }) editDialog: FmRecordEditorComponent;
constructor(
private router: Router,
newPointType: string;
matchSetType: string;
dataSource: GridDataSource;
- @ViewChild('newPoint') newPoint: MatchSetNewPointComponent;
- @ViewChild('grid') grid: GridComponent;
+ @ViewChild('newPoint', { static: true }) newPoint: MatchSetNewPointComponent;
+ @ViewChild('grid', { static: true }) grid: GridComponent;
deleteSelected: (rows: IdlObject[]) => void;
constructor(
filterImportErrors: boolean;
gridSource: GridDataSource;
- @ViewChild('itemsGrid') itemsGrid: GridComponent;
+ @ViewChild('itemsGrid', { static: true }) itemsGrid: GridComponent;
constructor(
private router: Router,
// points to the currently active grid.
queueGrid: GridComponent;
- @ViewChild('bibQueueGrid') bibQueueGrid: GridComponent;
- @ViewChild('authQueueGrid') authQueueGrid: GridComponent;
+ @ViewChild('bibQueueGrid', { static: false }) bibQueueGrid: GridComponent;
+ @ViewChild('authQueueGrid', { static: false }) authQueueGrid: GridComponent;
constructor(
private router: Router,
// keep a local copy for convenience
attrDefs: IdlObject[];
- @ViewChild('queueGrid') queueGrid: GridComponent;
- @ViewChild('confirmDelDlg') confirmDelDlg: ConfirmDialogComponent;
- @ViewChild('progressDlg') progressDlg: ProgressDialogComponent;
+ @ViewChild('queueGrid', { static: true }) queueGrid: GridComponent;
+ @ViewChild('confirmDelDlg', { static: false }) confirmDelDlg: ConfirmDialogComponent;
+ @ViewChild('progressDlg', { static: true }) progressDlg: ProgressDialogComponent;
constructor(
private router: Router,
@Input() queueType: string;
@Input() recordId: number;
- @ViewChild('bibGrid') bibGrid: GridComponent;
- @ViewChild('authGrid') authGrid: GridComponent;
+ @ViewChild('bibGrid', { static: false }) bibGrid: GridComponent;
+ @ViewChild('authGrid', { static: false }) authGrid: GridComponent;
queuedRecord: IdlObject;
bibDataSource: GridDataSource;
@Input() recordId: number;
gridSource: GridDataSource;
- @ViewChild('itemsGrid') itemsGrid: GridComponent;
+ @ViewChild('itemsGrid', { static: true }) itemsGrid: GridComponent;
constructor(
private net: NetService,
basketAction: string;
- @ViewChild('addBasketToBucketDialog')
+ @ViewChild('addBasketToBucketDialog', { static: true })
addToBucketDialog: BucketDialogComponent;
constructor(
})
export class BrowseComponent implements OnInit {
- @ViewChild('searchForm') searchForm: SearchFormComponent;
+ @ViewChild('searchForm', { static: true }) searchForm: SearchFormComponent;
constructor(
private staffCat: StaffCatalogService
})
export class CnBrowseComponent implements OnInit {
- @ViewChild('searchForm') searchForm: SearchFormComponent;
+ @ViewChild('searchForm', { static: true }) searchForm: SearchFormComponent;
constructor(
private staffCat: StaffCatalogService,
gridDataSource: GridDataSource;
idsToUnlink: number[];
- @ViewChild('conjoinedGrid') private grid: GridComponent;
+ @ViewChild('conjoinedGrid', { static: true }) private grid: GridComponent;
- @ViewChild('conjoinedDialog')
+ @ViewChild('conjoinedDialog', { static: true })
private conjoinedDialog: ConjoinedItemsDialogComponent;
- @ViewChild('confirmUnlink')
+ @ViewChild('confirmUnlink', { static: true })
private confirmUnlink: ConfirmDialogComponent;
constructor(
initDone = false;
gridDataSource: GridDataSource;
copyContext: any; // grid context
- @ViewChild('copyGrid') copyGrid: GridComponent;
+ @ViewChild('copyGrid', { static: true }) copyGrid: GridComponent;
@Input() set recordId(id: number) {
this.recId = id;
initDone = false;
gridDataSource: GridDataSource;
gridTemplateContext: any;
- @ViewChild('holdingsGrid') holdingsGrid: GridComponent;
+ @ViewChild('holdingsGrid', { static: true }) holdingsGrid: GridComponent;
// Manage visibility of various sub-sections
- @ViewChild('volsCheckbox')
+ @ViewChild('volsCheckbox', { static: true })
private volsCheckbox: GridToolbarCheckboxComponent;
- @ViewChild('copiesCheckbox')
+ @ViewChild('copiesCheckbox', { static: true })
private copiesCheckbox: GridToolbarCheckboxComponent;
- @ViewChild('emptyVolsCheckbox')
+ @ViewChild('emptyVolsCheckbox', { static: true })
private emptyVolsCheckbox: GridToolbarCheckboxComponent;
- @ViewChild('emptyLibsCheckbox')
+ @ViewChild('emptyLibsCheckbox', { static: true })
private emptyLibsCheckbox: GridToolbarCheckboxComponent;
- @ViewChild('markDamagedDialog')
+ @ViewChild('markDamagedDialog', { static: true })
private markDamagedDialog: MarkDamagedDialogComponent;
- @ViewChild('markMissingDialog')
+ @ViewChild('markMissingDialog', { static: true })
private markMissingDialog: MarkMissingDialogComponent;
- @ViewChild('copyAlertsDialog')
+ @ViewChild('copyAlertsDialog', { static: true })
private copyAlertsDialog: CopyAlertsDialogComponent;
- @ViewChild('replaceBarcode')
+ @ViewChild('replaceBarcode', { static: true })
private replaceBarcode: ReplaceBarcodeDialogComponent;
- @ViewChild('deleteVolcopy')
+ @ViewChild('deleteVolcopy', { static: true })
private deleteVolcopy: DeleteVolcopyDialogComponent;
- @ViewChild('bucketDialog')
+ @ViewChild('bucketDialog', { static: true })
private bucketDialog: BucketDialogComponent;
- @ViewChild('conjoinedDialog')
+ @ViewChild('conjoinedDialog', { static: true })
private conjoinedDialog: ConjoinedItemsDialogComponent;
- @ViewChild('makeBookableDialog')
+ @ViewChild('makeBookableDialog', { static: true })
private makeBookableDialog: MakeBookableDialogComponent;
holdingsTree: HoldingsTree;
recId: number;
gridDataSource: GridDataSource;
initDone: boolean;
- @ViewChild('partsGrid') partsGrid: GridComponent;
- @ViewChild('editDialog') editDialog: FmRecordEditorComponent;
- @ViewChild('mergeDialog') mergeDialog: PartMergeDialogComponent;
+ @ViewChild('partsGrid', { static: true }) partsGrid: GridComponent;
+ @ViewChild('editDialog', { static: true }) editDialog: FmRecordEditorComponent;
+ @ViewChild('mergeDialog', { static: true }) mergeDialog: PartMergeDialogComponent;
canCreate: boolean;
canDelete: boolean;
recordTab: string;
summary: BibRecordSummary;
searchContext: CatalogSearchContext;
- @ViewChild('recordTabs') recordTabs: NgbTabset;
+ @ViewChild('recordTabs', { static: true }) recordTabs: NgbTabset;
defaultTab: string; // eg.cat.default_record_tab
constructor(
})
export class SandboxComponent implements OnInit {
- @ViewChild('progressDialog')
+ @ViewChild('progressDialog', { static: true })
private progressDialog: ProgressDialogComponent;
- @ViewChild('dateSelect')
+ @ViewChild('dateSelect', { static: false })
private dateSelector: DateSelectComponent;
- @ViewChild('printTemplate')
+ @ViewChild('printTemplate', { static: true })
private printTemplate: TemplateRef<any>;
- @ViewChild('fmRecordEditor')
+ @ViewChild('fmRecordEditor', { static: true })
private fmRecordEditor: FmRecordEditorComponent;
// @ViewChild('helloStr') private helloStr: StringComponent;
// Optional comma-separated list of read-only fields
@Input() readonlyFields: string;
- @ViewChild('grid') grid: GridComponent;
- @ViewChild('editDialog') editDialog: FmRecordEditorComponent;
- @ViewChild('successString') successString: StringComponent;
- @ViewChild('createString') createString: StringComponent;
- @ViewChild('createErrString') createErrString: StringComponent;
- @ViewChild('updateFailedString') updateFailedString: StringComponent;
- @ViewChild('translator') translator: TranslateComponent;
+ @ViewChild('grid', { static: true }) grid: GridComponent;
+ @ViewChild('editDialog', { static: true }) editDialog: FmRecordEditorComponent;
+ @ViewChild('successString', { static: true }) successString: StringComponent;
+ @ViewChild('createString', { static: true }) createString: StringComponent;
+ @ViewChild('createErrString', { static: true }) createErrString: StringComponent;
+ @ViewChild('updateFailedString', { static: true }) updateFailedString: StringComponent;
+ @ViewChild('translator', { static: true }) translator: TranslateComponent;
idlClassDef: any;
pkeyField: string;
onOpenSub: Subscription;
- @ViewChild('successMsg') private successMsg: StringComponent;
- @ViewChild('errorMsg') private errorMsg: StringComponent;
+ @ViewChild('successMsg', { static: true }) private successMsg: StringComponent;
+ @ViewChild('errorMsg', { static: true }) private errorMsg: StringComponent;
constructor(
private modal: NgbModal, // required for passing to parent
existingMaps: any;
onOpenSub: Subscription;
- @ViewChild('successMsg') private successMsg: StringComponent;
- @ViewChild('errorMsg') private errorMsg: StringComponent;
+ @ViewChild('successMsg', { static: true }) private successMsg: StringComponent;
+ @ViewChild('errorMsg', { static: true }) private errorMsg: StringComponent;
constructor(
private modal: NgbModal, // required for passing to parent
newAlert: IdlObject;
changesMade: boolean;
- @ViewChild('successMsg') private successMsg: StringComponent;
- @ViewChild('errorMsg') private errorMsg: StringComponent;
+ @ViewChild('successMsg', { static: true }) private successMsg: StringComponent;
+ @ViewChild('errorMsg', { static: true }) private errorMsg: StringComponent;
constructor(
private modal: NgbModal, // required for passing to parent
numSucceeded: number;
numFailed: number;
- @ViewChild('successMsg')
+ @ViewChild('successMsg', { static: true })
private successMsg: StringComponent;
- @ViewChild('errorMsg')
+ @ViewChild('errorMsg', { static: true })
private errorMsg: StringComponent;
constructor(
newNote: string;
newBtype: number;
- @ViewChild('successMsg') private successMsg: StringComponent;
- @ViewChild('errorMsg') private errorMsg: StringComponent;
+ @ViewChild('successMsg', { static: true }) private successMsg: StringComponent;
+ @ViewChild('errorMsg', { static: true }) private errorMsg: StringComponent;
// Charge data returned from the server requesting additional charge info.
numSucceeded: number;
numFailed: number;
- @ViewChild('successMsg')
+ @ViewChild('successMsg', { static: true })
private successMsg: StringComponent;
- @ViewChild('errorMsg')
+ @ViewChild('errorMsg', { static: true })
private errorMsg: StringComponent;
constructor(
numSucceeded: number;
numFailed: number;
- @ViewChild('successMsg')
+ @ViewChild('successMsg', { static: true })
private successMsg: StringComponent;
- @ViewChild('errorMsg')
+ @ViewChild('errorMsg', { static: true })
private errorMsg: StringComponent;
constructor(
extends DialogComponent implements OnInit {
@Input() holdIds: number[];
- @ViewChild('successMsg') private successMsg: StringComponent;
- @ViewChild('errorMsg') private errorMsg: StringComponent;
+ @ViewChild('successMsg', { static: true }) private successMsg: StringComponent;
+ @ViewChild('errorMsg', { static: true }) private errorMsg: StringComponent;
changesApplied: boolean;
numSucceeded: number;
editHolds: number[];
transferTarget: number;
- @ViewChild('holdsGrid') private holdsGrid: GridComponent;
- @ViewChild('progressDialog')
+ @ViewChild('holdsGrid', { static: false }) private holdsGrid: GridComponent;
+ @ViewChild('progressDialog', { static: true })
private progressDialog: ProgressDialogComponent;
- @ViewChild('transferDialog')
+ @ViewChild('transferDialog', { static: true })
private transferDialog: HoldTransferDialogComponent;
- @ViewChild('markDamagedDialog')
+ @ViewChild('markDamagedDialog', { static: true })
private markDamagedDialog: MarkDamagedDialogComponent;
- @ViewChild('markMissingDialog')
+ @ViewChild('markMissingDialog', { static: true })
private markMissingDialog: MarkMissingDialogComponent;
- @ViewChild('retargetDialog')
+ @ViewChild('retargetDialog', { static: true })
private retargetDialog: HoldRetargetDialogComponent;
- @ViewChild('cancelDialog')
+ @ViewChild('cancelDialog', { static: true })
private cancelDialog: HoldCancelDialogComponent;
- @ViewChild('manageDialog')
+ @ViewChild('manageDialog', { static: true })
private manageDialog: HoldManageDialogComponent;
// Bib record ID.
extends DialogComponent implements OnInit {
@Input() holdIds: number | number[];
- @ViewChild('successMsg') private successMsg: StringComponent;
- @ViewChild('errorMsg') private errorMsg: StringComponent;
+ @ViewChild('successMsg', { static: true }) private successMsg: StringComponent;
+ @ViewChild('errorMsg', { static: true }) private errorMsg: StringComponent;
changesApplied: boolean;
numSucceeded: number;
@Input() holdIds: number | number[];
- @ViewChild('successMsg') private successMsg: StringComponent;
- @ViewChild('errorMsg') private errorMsg: StringComponent;
- @ViewChild('targetNeeded') private targetNeeded: StringComponent;
+ @ViewChild('successMsg', { static: true }) private successMsg: StringComponent;
+ @ViewChild('errorMsg', { static: true }) private errorMsg: StringComponent;
+ @ViewChild('targetNeeded', { static: true }) private targetNeeded: StringComponent;
transferTarget: number;
changesApplied: boolean;