65529: AoT build error fixes

This commit is contained in:
Kristof De Langhe
2019-10-15 13:58:03 +02:00
parent 98cd2aa84c
commit f1b4b57cdb
5 changed files with 8 additions and 6 deletions

View File

@@ -7,7 +7,7 @@ import { ItemMetadataRepresentation } from '../../../core/shared/metadata-repres
const itemType = 'type';
const metadataRepresentation1 = new MetadatumRepresentation(itemType);
const metadataRepresentation2 = new ItemMetadataRepresentation();
const metadataRepresentation2 = new ItemMetadataRepresentation(Object.assign({}));
const representations = [metadataRepresentation1, metadataRepresentation2];
describe('MetadataRepresentationListComponent', () => {

View File

@@ -28,7 +28,7 @@ const mockItem: Item = Object.assign(new Item(), {
]
}
});
const mockItemMetadataRepresentation = Object.assign(new ItemMetadataRepresentation(), mockItem);
const mockItemMetadataRepresentation = Object.assign(new ItemMetadataRepresentation(Object.assign({})), mockItem);
let viewMode = ItemViewMode.Full;
describe('ItemTypeSwitcherComponent', () => {

View File

@@ -5,7 +5,7 @@ import { ItemMetadataListElementComponent } from './item-metadata-list-element.c
import { By } from '@angular/platform-browser';
import { ItemMetadataRepresentation } from '../../../../core/shared/metadata-representation/item/item-metadata-representation.model';
const mockItemMetadataRepresentation = new ItemMetadataRepresentation();
const mockItemMetadataRepresentation = new ItemMetadataRepresentation(Object.assign({}));
describe('ItemMetadataListElementComponent', () => {
let comp: ItemMetadataListElementComponent;

View File

@@ -1,7 +1,7 @@
import { MetadataRepresentationListElementComponent } from '../metadata-representation-list-element.component';
import { Component, Inject } from '@angular/core';
import { ITEM } from '../../../items/switcher/item-type-switcher.component';
import { MetadataRepresentation } from '../../../../core/shared/metadata-representation/metadata-representation.model';
import { ItemMetadataRepresentation } from '../../../../core/shared/metadata-representation/item/item-metadata-representation.model';
@Component({
selector: 'ds-item-metadata-representation-list-element',
@@ -11,7 +11,7 @@ import { MetadataRepresentation } from '../../../../core/shared/metadata-represe
* An abstract class for displaying a single ItemMetadataRepresentation
*/
export class ItemMetadataRepresentationListElementComponent extends MetadataRepresentationListElementComponent {
constructor(@Inject(ITEM) public metadataRepresentation: MetadataRepresentation) {
constructor(@Inject(ITEM) public metadataRepresentation: ItemMetadataRepresentation) {
super(metadataRepresentation);
}
}

View File

@@ -143,6 +143,7 @@ import { DsoInputSuggestionsComponent } from './input-suggestions/dso-input-sugg
import { TypedItemSearchResultGridElementComponent } from './object-grid/item-grid-element/item-types/typed-item-search-result-grid-element.component';
import { PublicationGridElementComponent } from './object-grid/item-grid-element/item-types/publication/publication-grid-element.component';
import { ItemTypeBadgeComponent } from './object-list/item-type-badge/item-type-badge.component';
import { ItemMetadataRepresentationListElementComponent } from './object-list/metadata-representation-list-element/item/item-metadata-representation-list-element.component';
const MODULES = [
// Do NOT include UniversalModule, HttpModule, or JsonpModule here
@@ -310,7 +311,8 @@ const ENTRY_COMPONENTS = [
StartsWithTextComponent,
PlainTextMetadataListElementComponent,
ItemMetadataListElementComponent,
MetadataRepresentationListElementComponent
MetadataRepresentationListElementComponent,
ItemMetadataRepresentationListElementComponent
];
const SHARED_ITEM_PAGE_COMPONENTS = [