mirror of
https://github.com/DSpace/dspace-angular.git
synced 2025-10-13 13:03:04 +00:00
One approach
This commit is contained in:
@@ -16,7 +16,21 @@ export class ComcolPageBrowseByComponent implements OnInit {
|
|||||||
* The ID of the Community or Collection
|
* The ID of the Community or Collection
|
||||||
*/
|
*/
|
||||||
@Input() id: string;
|
@Input() id: string;
|
||||||
@Input() thisurl: string;
|
@Input() contentType: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* getPathfromType
|
||||||
|
*/
|
||||||
|
getPathfromType(t) {
|
||||||
|
if (t === "collection") {
|
||||||
|
t = "/collections/";
|
||||||
|
} else if (t === "community") {
|
||||||
|
t = "/communities/";
|
||||||
|
} else {
|
||||||
|
t = "/";
|
||||||
|
}
|
||||||
|
return t;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* List of currently active browse configurations
|
* List of currently active browse configurations
|
||||||
@@ -28,6 +42,7 @@ export class ComcolPageBrowseByComponent implements OnInit {
|
|||||||
|
|
||||||
ngOnInit(): void {
|
ngOnInit(): void {
|
||||||
this.types = this.config.browseBy.types;
|
this.types = this.config.browseBy.types;
|
||||||
|
this.contentTypePath = this.getPathfromType(this.contentType) ;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user