mirror of
https://github.com/DSpace/dspace-angular.git
synced 2025-10-07 01:54:15 +00:00
34 lines
738 B
TypeScript
34 lines
738 B
TypeScript
import { Component, Input, OnInit } from '@angular/core';
|
|
import { Observable } from 'rxjs/Observable';
|
|
|
|
import { Bitstream } from '../../../../core/shared/bitstream.model';
|
|
import { Item } from '../../../../core/shared/item.model';
|
|
|
|
/**
|
|
* This component renders the file section of the item
|
|
* inside a 'ds-metadata-field-wrapper' component.
|
|
*/
|
|
@Component({
|
|
selector: 'ds-item-page-file-section',
|
|
templateUrl: './file-section.component.html'
|
|
})
|
|
export class FileSectionComponent implements OnInit {
|
|
|
|
@Input() item: Item;
|
|
|
|
label = 'item.page.files';
|
|
|
|
separator = '<br/>';
|
|
|
|
files: Observable<Bitstream[]>;
|
|
|
|
ngOnInit(): void {
|
|
this.initialize();
|
|
}
|
|
|
|
initialize(): void {
|
|
this.files = this.item.getFiles();
|
|
}
|
|
|
|
}
|