mirror of
https://github.com/DSpace/dspace-angular.git
synced 2025-10-07 01:54:15 +00:00
[CST-4499] Version history - SSR bug fixed
This commit is contained in:
@@ -62,7 +62,6 @@ export class DsoPageVersionButtonComponent implements OnInit {
|
|||||||
|
|
||||||
ngOnInit() {
|
ngOnInit() {
|
||||||
this.isAuthorized$ = this.authorizationService.isAuthorized(FeatureID.CanCreateVersion, this.dso.self);
|
this.isAuthorized$ = this.authorizationService.isAuthorized(FeatureID.CanCreateVersion, this.dso.self);
|
||||||
console.log('href = ' + this.dso._links.version.href);
|
|
||||||
|
|
||||||
this.disableNewVersionButton$ = this.versionHistoryService.hasDraftVersion$(this.dso._links.version.href).pipe(
|
this.disableNewVersionButton$ = this.versionHistoryService.hasDraftVersion$(this.dso._links.version.href).pipe(
|
||||||
// button is disabled if hasDraftVersion = true, and enabled if hasDraftVersion = false or null
|
// button is disabled if hasDraftVersion = true, and enabled if hasDraftVersion = false or null
|
||||||
|
@@ -405,8 +405,7 @@ export class ItemVersionsComponent implements OnInit {
|
|||||||
);
|
);
|
||||||
|
|
||||||
const versionHistory$ = this.versionHistoryRD$.pipe(
|
const versionHistory$ = this.versionHistoryRD$.pipe(
|
||||||
getAllSucceededRemoteData(),
|
getFirstSucceededRemoteDataPayload(),
|
||||||
getRemoteDataPayload(),
|
|
||||||
hasValueOperator(),
|
hasValueOperator(),
|
||||||
);
|
);
|
||||||
this.getAllVersions(versionHistory$);
|
this.getAllVersions(versionHistory$);
|
||||||
|
Reference in New Issue
Block a user