Under some circumstances, the search results screen in the new
experimental Angular staff catalog did not display any results (though
it did show the pager, facets, etc.).
This was traced back to the results array attempting to be populated
with ID values of '-1' instead of the real IDs. Coercing the incoming
IDs to numbers appears to resolve the issue.
Signed-off-by: Bill Erickson <berickxx@gmail.com>
Signed-off-by: Dan Wells <dbw2@calvin.edu>
net: NetService;
constructor(record: IdlObject, orgId: number, orgDepth: number) {
- this.id = record.id();
+ this.id = Number(record.id());
this.record = record;
this.orgId = orgId;
this.orgDepth = orgDepth;
// Reconsider this approach (see also note above about API).
this.getBibSummary(metabib.master_record(), orgId, orgDepth)
.subscribe(summary => {
- summary.metabibId = metabib.id();
+ summary.metabibId = Number(metabib.id());
summary.metabibRecords =
metabib.source_maps().map(m => Number(m.source()));
}
addResultId(id: number, resultIdx: number ): void {
- this.resultIds[resultIdx + this.pager.offset] = id;
+ this.resultIds[resultIdx + this.pager.offset] = Number(id);
}
// Return the record at the requested index.