diff --git a/demo-shell/resources/i18n/en.json b/demo-shell/resources/i18n/en.json index 92f267e7fa..986ce84307 100644 --- a/demo-shell/resources/i18n/en.json +++ b/demo-shell/resources/i18n/en.json @@ -59,6 +59,7 @@ "CUSTOM_FILTER" :"Custom extensions filter", "MAX_SIZE" : "Max size filter", "ENABLE_VERSIONING" :"Enable versioning", + "ENABLE_VERSION_DOWNLOAD" :"Enable version download", "DESCRIPTION_UPLOAD" : "Enable upload", "ENABLE_INFINITE_SCROLL":"Enable Infinite Scrolling", "MULTISELECT_DESCRIPTION" : "Use Cmd (Mac) or Ctrl (Windows) to toggle selection of multiple items", diff --git a/demo-shell/src/app/components/files/files.component.html b/demo-shell/src/app/components/files/files.component.html index 28c5d72b54..2c37d927d7 100644 --- a/demo-shell/src/app/components/files/files.component.html +++ b/demo-shell/src/app/components/files/files.component.html @@ -353,7 +353,8 @@ + [showComments]="showVersionComments" + [enableDownload]="enableVersionDownload"> @@ -440,8 +441,11 @@
- {{'DOCUMENT_LIST.SHOW_VERSION_COMMENTS' | - translate}} + + {{'DOCUMENT_LIST.SHOW_VERSION_COMMENTS' | translate}} + + + {{'DOCUMENT_LIST.ENABLE_VERSION_DOWNLOAD' | translate}}
diff --git a/demo-shell/src/app/components/files/files.component.ts b/demo-shell/src/app/components/files/files.component.ts index 06648bf4b6..6124d90346 100644 --- a/demo-shell/src/app/components/files/files.component.ts +++ b/demo-shell/src/app/components/files/files.component.ts @@ -102,6 +102,9 @@ export class FilesComponent implements OnInit, OnChanges, OnDestroy { @Input() versioning = false; + @Input() + enableVersionDownload = true; + @Input() acceptedFilesType = '.jpg,.pdf,.js'; @@ -362,10 +365,11 @@ export class FilesComponent implements OnInit, OnChanges, OnDestroy { onManageVersions(event) { const contentEntry = event.value.entry; const showComments = this.showVersionComments; + const enableDownload = this.enableVersionDownload; if (this.contentService.hasPermission(contentEntry, 'update')) { this.dialog.open(VersionManagerDialogAdapterComponent, { - data: { contentEntry, showComments }, + data: { contentEntry, showComments, enableDownload }, panelClass: 'adf-version-manager-dialog', width: '630px' }); diff --git a/demo-shell/src/app/components/files/version-manager-dialog-adapter.component.html b/demo-shell/src/app/components/files/version-manager-dialog-adapter.component.html index 6a2dc154c8..509c3bb54a 100644 --- a/demo-shell/src/app/components/files/version-manager-dialog-adapter.component.html +++ b/demo-shell/src/app/components/files/version-manager-dialog-adapter.component.html @@ -1,6 +1,6 @@
{{'VERSION.DIALOG.TITLE' | translate}}
- +