mirror of
https://github.com/DSpace/dspace-angular.git
synced 2025-10-18 15:33:04 +00:00
Merge remote-tracking branch 'remotes/origin/main' into upgrade_angular10
# Conflicts: # src/app/+item-page/item-page.module.ts # src/app/core/shared/item.model.ts # src/app/shared/object-grid/item-grid-element/item-types/item/item-grid-element.component.spec.ts # src/app/shared/search/search-filters/search-filter/search-authority-filter/search-authority-filter.component.ts # src/app/shared/search/search-filters/search-filter/search-facet-filter-options/search-facet-option/search-facet-option.component.ts # src/app/shared/search/search-filters/search-filter/search-facet-filter-options/search-facet-selected-option/search-facet-selected-option.component.ts # src/app/shared/search/search-filters/search-filter/search-facet-filter/search-facet-filter.component.ts # src/app/shared/shared.module.ts
This commit is contained in:
@@ -1,7 +1,6 @@
|
||||
import { autoserialize, autoserializeAs, deserialize, inheritSerialization } from 'cerialize';
|
||||
import { Observable } from 'rxjs';
|
||||
import { isEmpty } from '../../shared/empty.util';
|
||||
import { DEFAULT_ENTITY_TYPE } from '../../shared/metadata-representation/metadata-representation.decorator';
|
||||
import { ListableObject } from '../../shared/object-collection/shared/listable-object.model';
|
||||
import { link, typedObject } from '../cache/builders/build-decorators';
|
||||
import { PaginatedList } from '../data/paginated-list';
|
||||
@@ -105,9 +104,9 @@ export class Item extends DSpaceObject implements ChildHALResource {
|
||||
* Method that returns as which type of object this object should be rendered
|
||||
*/
|
||||
getRenderTypes(): (string | GenericConstructor<ListableObject>)[] {
|
||||
let entityType = this.firstMetadataValue('relationship.type');
|
||||
const entityType = this.firstMetadataValue('relationship.type');
|
||||
if (isEmpty(entityType)) {
|
||||
entityType = DEFAULT_ENTITY_TYPE;
|
||||
return super.getRenderTypes();
|
||||
}
|
||||
return [entityType, ...super.getRenderTypes()];
|
||||
}
|
||||
|
Reference in New Issue
Block a user