mirror of
https://github.com/DSpace/dspace-angular.git
synced 2025-10-07 10:04:11 +00:00
[CST-5676] Bitstream edit page is broken if no policies are set
This commit is contained in:
@@ -706,11 +706,20 @@ export class EditBitstreamPageComponent implements OnInit, OnDestroy {
|
||||
getFirstSucceededRemoteData(),
|
||||
map((format: RemoteData<BitstreamFormat>) => format.payload.mimetype.includes('image/')));
|
||||
|
||||
let isImageBitstream = false;
|
||||
isImage$.subscribe(res => {
|
||||
isImageBitstream = res;
|
||||
});
|
||||
|
||||
const isIIIFBundle$ = this.bitstream.bundle.pipe(
|
||||
getFirstSucceededRemoteData(),
|
||||
map((bundle: RemoteData<Bundle>) =>
|
||||
this.dsoNameService.getName(bundle.payload).match(regexExcludeBundles) == null));
|
||||
|
||||
let isIIIFBundleBitstream = false;
|
||||
isIIIFBundle$.subscribe(res => {
|
||||
isIIIFBundleBitstream = res;
|
||||
});
|
||||
const isEnabled$ = this.bitstream.bundle.pipe(
|
||||
getFirstSucceededRemoteData(),
|
||||
map((bundle: RemoteData<Bundle>) => bundle.payload.item.pipe(
|
||||
@@ -720,6 +729,11 @@ export class EditBitstreamPageComponent implements OnInit, OnDestroy {
|
||||
item.payload.firstMetadataValue('dspace.iiif.enabled').match(regexIIIFItem) !== null)
|
||||
))));
|
||||
|
||||
let isEnabledBitstream: Observable<boolean>;
|
||||
isEnabled$.subscribe(res => {
|
||||
isEnabledBitstream = res;
|
||||
});
|
||||
|
||||
const iiifSub = combineLatest(
|
||||
isImage$,
|
||||
isIIIFBundle$,
|
||||
|
Reference in New Issue
Block a user