mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-31 17:38:48 +00:00
fix upload demo and inject uploadservice
This commit is contained in:
@@ -42,8 +42,6 @@ declare let __moduleName: string;
|
||||
})
|
||||
export class UploadDragAreaComponent {
|
||||
|
||||
private _uploaderService: UploadService;
|
||||
|
||||
@ViewChild('fileUploadingDialog')
|
||||
fileUploadingDialogComponent: FileUploadingDialogComponent;
|
||||
|
||||
@@ -61,13 +59,14 @@ export class UploadDragAreaComponent {
|
||||
@Output()
|
||||
onSuccess = new EventEmitter();
|
||||
|
||||
constructor(public el: ElementRef) {
|
||||
constructor(public el: ElementRef,
|
||||
private _uploaderService: UploadService) {
|
||||
console.log('UploadComponent constructor', el);
|
||||
|
||||
let site = this.getSiteId();
|
||||
let container = this.getContainerId();
|
||||
|
||||
this._uploaderService = new UploadService({
|
||||
this._uploaderService.setOptions({
|
||||
fieldName: 'filedata',
|
||||
formFields: {
|
||||
siteid: site,
|
||||
|
Reference in New Issue
Block a user