64387: Upload bitstream component + Edit bitstream placeholder

This commit is contained in:
Kristof De Langhe
2019-08-16 13:35:04 +02:00
parent d1dbe49333
commit 7bd6c9acab
14 changed files with 327 additions and 17 deletions

View File

@@ -0,0 +1,30 @@
import { ChangeDetectionStrategy, Component, OnInit } from '@angular/core';
import { Observable } from 'rxjs/internal/Observable';
import { RemoteData } from '../../core/data/remote-data';
import { Bitstream } from '../../core/shared/bitstream.model';
import { ActivatedRoute } from '@angular/router';
import { map } from 'rxjs/operators';
@Component({
selector: 'ds-edit-bitstream-page',
templateUrl: './edit-bitstream-page.component.html',
changeDetection: ChangeDetectionStrategy.OnPush
})
/**
* Page component for editing a bitstream
*/
export class EditBitstreamPageComponent implements OnInit {
/**
* The bitstream to edit
*/
bitstreamRD$: Observable<RemoteData<Bitstream>>;
constructor(private route: ActivatedRoute) {
}
ngOnInit(): void {
this.bitstreamRD$ = this.route.data.pipe(map((data) => data.bitstream));
}
}