Updated configuration.

This commit is contained in:
Michael Spalti
2022-09-09 10:34:17 -07:00
parent 580986adae
commit ccb4c0794c
15 changed files with 23 additions and 19 deletions

View File

@@ -168,9 +168,8 @@ browseBy:
fiveYearLimit: 30 fiveYearLimit: 30
# The absolute lowest year to display in the dropdown (only used when no lowest date can be found for all items) # The absolute lowest year to display in the dropdown (only used when no lowest date can be found for all items)
defaultLowerLimit: 1900 defaultLowerLimit: 1900
# If true, thumbnail images for items will be added to search and browse result lists.
# If true, thumbnail images for items will be added to search and browse result lists. showItemThumbnails: true
showItemThumbnails: false
# Item Config # Item Config
item: item:

View File

@@ -123,7 +123,7 @@ export class BrowseByMetadataPageComponent implements OnInit {
protected dsoService: DSpaceObjectDataService, protected dsoService: DSpaceObjectDataService,
protected paginationService: PaginationService, protected paginationService: PaginationService,
protected router: Router) { protected router: Router) {
this.embedThumbnail = environment.showItemThumbnails; this.embedThumbnail = environment.browseBy.showItemThumbnails;
} }
ngOnInit(): void { ngOnInit(): void {

View File

@@ -22,7 +22,7 @@ export class JournalIssueSearchResultListElementComponent extends ItemSearchResu
ngOnInit(): void { ngOnInit(): void {
super.ngOnInit(); super.ngOnInit();
this.showThumbnails = environment.showItemThumbnails; this.showThumbnails = environment.browseBy.showItemThumbnails;
} }
} }

View File

@@ -22,7 +22,7 @@ export class JournalVolumeSearchResultListElementComponent extends ItemSearchRes
ngOnInit(): void { ngOnInit(): void {
super.ngOnInit(); super.ngOnInit();
this.showThumbnails = environment.showItemThumbnails; this.showThumbnails = environment.browseBy.showItemThumbnails;
} }
} }

View File

@@ -22,7 +22,7 @@ export class JournalSearchResultListElementComponent extends ItemSearchResultLis
ngOnInit(): void { ngOnInit(): void {
super.ngOnInit(); super.ngOnInit();
this.showThumbnails = environment.showItemThumbnails; this.showThumbnails = environment.browseBy.showItemThumbnails;
} }
} }

View File

@@ -22,7 +22,7 @@ export class OrgUnitSearchResultListElementComponent extends ItemSearchResultLis
ngOnInit(): void { ngOnInit(): void {
super.ngOnInit(); super.ngOnInit();
this.showThumbnails = environment.showItemThumbnails; this.showThumbnails = environment.browseBy.showItemThumbnails;
} }
} }

View File

@@ -32,7 +32,7 @@ export class PersonSearchResultListElementComponent extends ItemSearchResultList
ngOnInit(): void { ngOnInit(): void {
super.ngOnInit(); super.ngOnInit();
this.showThumbnails = environment.showItemThumbnails; this.showThumbnails = environment.browseBy.showItemThumbnails;
} }
/** /**

View File

@@ -22,7 +22,7 @@ export class ProjectSearchResultListElementComponent extends ItemSearchResultLis
ngOnInit(): void { ngOnInit(): void {
super.ngOnInit(); super.ngOnInit();
this.showThumbnails = environment.showItemThumbnails; this.showThumbnails = environment.browseBy.showItemThumbnails;
} }
} }

View File

@@ -24,7 +24,7 @@ export class CollectionSearchResultListElementComponent extends SearchResultList
ngOnInit(): void { ngOnInit(): void {
super.ngOnInit(); super.ngOnInit();
this.showThumbnails = environment.showItemThumbnails; this.showThumbnails = environment.browseBy.showItemThumbnails;
} }
} }

View File

@@ -24,6 +24,6 @@ export class CommunitySearchResultListElementComponent extends SearchResultListE
ngOnInit(): void { ngOnInit(): void {
super.ngOnInit(); super.ngOnInit();
this.showThumbnails = environment.showItemThumbnails; this.showThumbnails = environment.browseBy.showItemThumbnails;
} }
} }

View File

@@ -30,7 +30,7 @@ export class ItemSearchResultListElementComponent extends SearchResultListElemen
ngOnInit(): void { ngOnInit(): void {
super.ngOnInit(); super.ngOnInit();
this.showThumbnails = environment.showItemThumbnails; this.showThumbnails = environment.browseBy.showItemThumbnails;
this.itemPageRoute = getItemPageRoute(this.dso); this.itemPageRoute = getItemPageRoute(this.dso);
} }
} }

View File

@@ -31,7 +31,6 @@ interface AppConfig extends Config {
defaultLanguage: string; defaultLanguage: string;
languages: LangConfig[]; languages: LangConfig[];
browseBy: BrowseByConfig; browseBy: BrowseByConfig;
showItemThumbnails: boolean;
item: ItemConfig; item: ItemConfig;
collection: CollectionPageConfig; collection: CollectionPageConfig;
themes: ThemeConfig[]; themes: ThemeConfig[];

View File

@@ -18,4 +18,9 @@ export interface BrowseByConfig extends Config {
* The absolute lowest year to display in the dropdown when no lowest date can be found for all items * The absolute lowest year to display in the dropdown when no lowest date can be found for all items
*/ */
defaultLowerLimit: number; defaultLowerLimit: number;
/**
* If true, thumbnail images for items will be added to search and browse result lists.
*/
showItemThumbnails: boolean;
} }

View File

@@ -205,12 +205,11 @@ export class DefaultAppConfig implements AppConfig {
// Limit for years to display using jumps of five years (current year - fiveYearLimit) // Limit for years to display using jumps of five years (current year - fiveYearLimit)
fiveYearLimit: 30, fiveYearLimit: 30,
// The absolute lowest year to display in the dropdown (only used when no lowest date can be found for all items) // The absolute lowest year to display in the dropdown (only used when no lowest date can be found for all items)
defaultLowerLimit: 1900 defaultLowerLimit: 1900,
// Whether to add item thumbnail images to browse and search result lists.
showItemThumbnails: true
}; };
// Whether to add item thumbnail images to browse and search result lists.
showItemThumbnails: false;
// Item Config // Item Config
item: ItemConfig = { item: ItemConfig = {
edit: { edit: {

View File

@@ -199,8 +199,10 @@ export const environment: BuildConfig = {
fiveYearLimit: 30, fiveYearLimit: 30,
// The absolute lowest year to display in the dropdown (only used when no lowest date can be found for all items) // The absolute lowest year to display in the dropdown (only used when no lowest date can be found for all items)
defaultLowerLimit: 1900, defaultLowerLimit: 1900,
// Whether to add item thumbnail images to browse and search result lists.
showItemThumbnails: true
}, },
showItemThumbnails: false,
item: { item: {
edit: { edit: {
undoTimeout: 10000 // 10 seconds undoTimeout: 10000 // 10 seconds