renamed dspaceObject to indexableObject

This commit is contained in:
Giuseppe Digilio
2019-04-03 15:27:08 +02:00
parent af2a995e24
commit 7c48504c82
30 changed files with 71 additions and 71 deletions

View File

@@ -17,7 +17,7 @@ const truncatableServiceStub: any = {
const mockCollectionWithAbstract: CollectionSearchResult = new CollectionSearchResult();
mockCollectionWithAbstract.hitHighlights = {};
mockCollectionWithAbstract.dspaceObject = Object.assign(new Collection(), {
mockCollectionWithAbstract.indexableObject = Object.assign(new Collection(), {
metadata: {
'dc.description.abstract': [
{
@@ -30,7 +30,7 @@ mockCollectionWithAbstract.dspaceObject = Object.assign(new Collection(), {
const mockCollectionWithoutAbstract: CollectionSearchResult = new CollectionSearchResult();
mockCollectionWithoutAbstract.hitHighlights = {};
mockCollectionWithoutAbstract.dspaceObject = Object.assign(new Collection(), {
mockCollectionWithoutAbstract.indexableObject = Object.assign(new Collection(), {
metadata: {
'dc.title': [
{
@@ -63,7 +63,7 @@ describe('CollectionSearchResultGridElementComponent', () => {
describe('When the collection has an abstract', () => {
beforeEach(() => {
collectionSearchResultGridElementComponent.dso = mockCollectionWithAbstract.dspaceObject;
collectionSearchResultGridElementComponent.dso = mockCollectionWithAbstract.indexableObject;
fixture.detectChanges();
});
@@ -75,7 +75,7 @@ describe('CollectionSearchResultGridElementComponent', () => {
describe('When the collection has no abstract', () => {
beforeEach(() => {
collectionSearchResultGridElementComponent.dso = mockCollectionWithoutAbstract.dspaceObject;
collectionSearchResultGridElementComponent.dso = mockCollectionWithoutAbstract.indexableObject;
fixture.detectChanges();
});

View File

@@ -17,7 +17,7 @@ const truncatableServiceStub: any = {
const mockCommunityWithAbstract: CommunitySearchResult = new CommunitySearchResult();
mockCommunityWithAbstract.hitHighlights = {};
mockCommunityWithAbstract.dspaceObject = Object.assign(new Community(), {
mockCommunityWithAbstract.indexableObject = Object.assign(new Community(), {
metadata: {
'dc.description.abstract': [
{
@@ -30,7 +30,7 @@ mockCommunityWithAbstract.dspaceObject = Object.assign(new Community(), {
const mockCommunityWithoutAbstract: CommunitySearchResult = new CommunitySearchResult();
mockCommunityWithoutAbstract.hitHighlights = {};
mockCommunityWithoutAbstract.dspaceObject = Object.assign(new Community(), {
mockCommunityWithoutAbstract.indexableObject = Object.assign(new Community(), {
metadata: {
'dc.title': [
{
@@ -63,7 +63,7 @@ describe('CommunitySearchResultGridElementComponent', () => {
describe('When the community has an abstract', () => {
beforeEach(() => {
communitySearchResultGridElementComponent.dso = mockCommunityWithAbstract.dspaceObject;
communitySearchResultGridElementComponent.dso = mockCommunityWithAbstract.indexableObject;
fixture.detectChanges();
});
@@ -75,7 +75,7 @@ describe('CommunitySearchResultGridElementComponent', () => {
describe('When the community has no abstract', () => {
beforeEach(() => {
communitySearchResultGridElementComponent.dso = mockCommunityWithoutAbstract.dspaceObject;
communitySearchResultGridElementComponent.dso = mockCommunityWithoutAbstract.indexableObject;
fixture.detectChanges();
});

View File

@@ -18,7 +18,7 @@ const truncatableServiceStub: any = {
const mockItemWithAuthorAndDate: ItemSearchResult = new ItemSearchResult();
mockItemWithAuthorAndDate.hitHighlights = {};
mockItemWithAuthorAndDate.dspaceObject = Object.assign(new Item(), {
mockItemWithAuthorAndDate.indexableObject = Object.assign(new Item(), {
bitstreams: observableOf({}),
metadata: {
'dc.contributor.author': [
@@ -38,7 +38,7 @@ mockItemWithAuthorAndDate.dspaceObject = Object.assign(new Item(), {
const mockItemWithoutAuthorAndDate: ItemSearchResult = new ItemSearchResult();
mockItemWithoutAuthorAndDate.hitHighlights = {};
mockItemWithoutAuthorAndDate.dspaceObject = Object.assign(new Item(), {
mockItemWithoutAuthorAndDate.indexableObject = Object.assign(new Item(), {
bitstreams: observableOf({}),
metadata: {
'dc.title': [
@@ -78,7 +78,7 @@ describe('ItemSearchResultGridElementComponent', () => {
describe('When the item has an author', () => {
beforeEach(() => {
itemSearchResultGridElementComponent.dso = mockItemWithAuthorAndDate.dspaceObject;
itemSearchResultGridElementComponent.dso = mockItemWithAuthorAndDate.indexableObject;
fixture.detectChanges();
});
@@ -90,7 +90,7 @@ describe('ItemSearchResultGridElementComponent', () => {
describe('When the item has no author', () => {
beforeEach(() => {
itemSearchResultGridElementComponent.dso = mockItemWithoutAuthorAndDate.dspaceObject;
itemSearchResultGridElementComponent.dso = mockItemWithoutAuthorAndDate.indexableObject;
fixture.detectChanges();
});
@@ -102,7 +102,7 @@ describe('ItemSearchResultGridElementComponent', () => {
describe('When the item has an issuedate', () => {
beforeEach(() => {
itemSearchResultGridElementComponent.dso = mockItemWithAuthorAndDate.dspaceObject;
itemSearchResultGridElementComponent.dso = mockItemWithAuthorAndDate.indexableObject;
fixture.detectChanges();
});
@@ -114,7 +114,7 @@ describe('ItemSearchResultGridElementComponent', () => {
describe('When the item has no issuedate', () => {
beforeEach(() => {
itemSearchResultGridElementComponent.dso = mockItemWithoutAuthorAndDate.dspaceObject;
itemSearchResultGridElementComponent.dso = mockItemWithoutAuthorAndDate.indexableObject;
fixture.detectChanges();
});

View File

@@ -18,7 +18,7 @@ export class SearchResultGridElementComponent<T extends SearchResult<K>, K exten
public constructor(@Inject('objectElementProvider') public listableObject: ListableObject, private truncatableService: TruncatableService) {
super(listableObject);
this.dso = this.object.dspaceObject;
this.dso = this.object.indexableObject;
}
/**