mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-31 17:38:48 +00:00
#149 Fixed event preventDefault
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"name": "ng2-alfresco-upload",
|
||||
"description": "Alfresco Angular2 Upload Component",
|
||||
"version": "0.1.30",
|
||||
"version": "0.1.31",
|
||||
"author": "Alfresco Software, Ltd.",
|
||||
"scripts": {
|
||||
"typings": "typings install",
|
||||
|
@@ -1,7 +1,7 @@
|
||||
<div [ngClass]="{hide: isUploadCompleted()}" [ngClass]="{show: !isUploadCompleted()}"
|
||||
class="body-dialog-header">
|
||||
<div class="body-dialog-action"></div>
|
||||
<div class="body-dialog-cancel"><a data-automation-id="cancel_upload_all" href="#" (click)="cancelAllFiles()">{{'FILE_UPLOAD.BUTTON.CANCEL' | translate}}</a></div>
|
||||
<div class="body-dialog-cancel"><a data-automation-id="cancel_upload_all" href="#" (click)="cancelAllFiles($event)">{{'FILE_UPLOAD.BUTTON.CANCEL' | translate}}</a></div>
|
||||
</div>
|
||||
<table class="mdl-data-table mdl-js-data-table mdl-shadow--2dp">
|
||||
<tr>
|
||||
|
@@ -63,7 +63,10 @@ export class FileUploadingListComponent {
|
||||
/**
|
||||
* Call the abort method for each file
|
||||
*/
|
||||
cancelAllFiles() {
|
||||
cancelAllFiles($event) {
|
||||
if($event) {
|
||||
$event.preventDefault();
|
||||
}
|
||||
this.filesUploadingList.forEach((uploadingFileModel: FileModel) => {
|
||||
uploadingFileModel.setAbort();
|
||||
});
|
||||
|
Reference in New Issue
Block a user