2 import {Component, OnInit, ViewChild, Input, TemplateRef} from '@angular/core';
3 import {IdlObject} from '@eg/core/idl.service';
4 import {PcrudService} from '@eg/core/pcrud.service';
5 import {AuthService} from '@eg/core/auth.service';
6 import {FormatService} from '@eg/core/format.service';
7 import {Pager} from '@eg/share/util/pager';
8 import {DateSelectComponent} from '@eg/share/date-select/date-select.component';
9 import {BibRecordService, BibRecordSummary} from '@eg/share/catalog/bib-record.service';
12 templateUrl: 'hopeless.component.html'
14 export class HopelessComponent implements OnInit {
18 workstation_lib: IdlObject;
20 changeStartDate(date) {
21 this.startDate = date;
32 private pcrud: PcrudService,
33 private auth: AuthService,
34 private format: FormatService,
35 private bib: BibRecordService,
40 // for the pickup library selector
41 this.workstation_lib = this.auth.user().ws_ou();
43 // Default startDate to today - 10 years
44 const sd = new Date();
45 sd.setFullYear( sd.getFullYear() - 10 );
46 this.startDate = sd.toISOString();
48 // Default endDate to today.
49 const ed = new Date();
53 this.endDate = ed.toISOString();