mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-24 17:32:15 +00:00
Fix filename shown in title area of viewer component
This commit is contained in:
@@ -148,7 +148,7 @@
|
||||
[multipleFiles]="true"
|
||||
(onSuccess)="refreshDocumentList($event)"></alfresco-upload-button>
|
||||
|
||||
<alfresco-viewer [(showViewer)]="fileShowed" [urlFile]="urlFile" [mimeType]="mimeType" [overlayMode]="true">
|
||||
<alfresco-viewer [(showViewer)]="fileShowed" [urlFile]="urlFile" [fileName]="fileName" [mimeType]="mimeType" [overlayMode]="true">
|
||||
<div class="mdl-spinner mdl-js-spinner is-active"></div>
|
||||
</alfresco-viewer>
|
||||
<file-uploading-dialog></file-uploading-dialog>
|
||||
|
@@ -46,6 +46,7 @@ export class FilesComponent {
|
||||
relativePath: string = '';
|
||||
|
||||
urlFile: string;
|
||||
fileName: string;
|
||||
mimeType: string;
|
||||
fileShowed: boolean = false;
|
||||
|
||||
@@ -75,6 +76,7 @@ export class FilesComponent {
|
||||
|
||||
showFile(event) {
|
||||
if (event.value.entry.isFile) {
|
||||
this.fileName = event.value.entry.name;
|
||||
this.mimeType = event.value.entry.content.mimeType;
|
||||
this.urlFile = this.contentService.getContentUrl(event.value);
|
||||
this.fileShowed = true;
|
||||
|
@@ -37,6 +37,7 @@ declare let __moduleName: string;
|
||||
export class SearchBarComponent {
|
||||
|
||||
urlFile: string;
|
||||
fileName: string;
|
||||
mimeType: string;
|
||||
fileShowed: boolean = false;
|
||||
|
||||
@@ -65,6 +66,7 @@ export class SearchBarComponent {
|
||||
|
||||
onFileClicked(event) {
|
||||
if (event.value.entry.isFile) {
|
||||
this.fileName = event.value.entry.name;
|
||||
this.mimeType = event.value.entry.content.mimeType;
|
||||
this.urlFile = this.contentService.getContentUrl(event.value);
|
||||
this.fileShowed = true;
|
||||
|
Reference in New Issue
Block a user