[ADF-2161] download directive (#2934)

* node download directive

* integrate with demo shell

* docs on the directive

* node actions integration

* test fixes

* remove old and disable invalid tests

* remove fdescribe

* fix unit tests
This commit is contained in:
Denys Vuika
2018-02-15 09:23:55 +00:00
committed by GitHub
parent 2c1271a5b2
commit 63a146616b
13 changed files with 356 additions and 165 deletions

View File

@@ -16,16 +16,27 @@
*/
import { Injectable } from '@angular/core';
import { MinimalNodeEntryEntity } from 'alfresco-js-api';
import { MinimalNodeEntryEntity, MinimalNodeEntity } from 'alfresco-js-api';
import { Subject } from 'rxjs/Subject';
import { AlfrescoApiService } from '@alfresco/adf-core';
import { MatDialog } from '@angular/material';
import { DocumentListService } from './document-list.service';
import { ContentNodeDialogService } from '../../content-node-selector/content-node-dialog.service';
import { NodeDownloadDirective } from '../../directives/node-download.directive';
@Injectable()
export class NodeActionsService {
constructor(private contentDialogService: ContentNodeDialogService,
private documentListService?: DocumentListService) {}
private documentListService?: DocumentListService,
private apiService?: AlfrescoApiService,
private dialog?: MatDialog) {}
downloadNode(node: MinimalNodeEntity) {
new NodeDownloadDirective(this.apiService, this.dialog)
.downloadNode(node);
}
/**
* Copy content node