[ADF - 1030] Datatable - enable isLoading to show the spinner in all the components (#2063)

* added spinner module and  translate text for process-list component

* added spinner loader for data-table in processlist-variable component

* added spinner loader for data-table in processlist component

* added spinner loader for data-table in process-attachmentlist component

* added spinner module and translate text for tasklist component

* changed css for adf-datatable: selector changed in component

* added spinner loader for data-table in tasklist component

* added spinner loader for data-table in task-attachmentlist component

* removed no-content template from task/process attachment list

* fixed tasklist testcase issues

* changed imort order for test cases

* fixed testcase issue in processlist component
This commit is contained in:
Infad Kachancheri
2017-07-11 21:14:09 +05:30
committed by Eugenio Romano
parent 34bb8b824d
commit e6a2b7112b
23 changed files with 224 additions and 69 deletions

View File

@@ -39,6 +39,7 @@ export class TaskAttachmentListComponent implements OnChanges {
error: EventEmitter<any> = new EventEmitter<any>();
attachments: any[] = [];
loadingFlag: boolean = true;
constructor(private translateService: AlfrescoTranslationService,
private activitiContentService: ActivitiContentService,
@@ -76,6 +77,8 @@ export class TaskAttachmentListComponent implements OnChanges {
private loadAttachmentsByTaskId(taskId: string) {
if (taskId) {
this.loadingFlag = true;
this.reset();
this.activitiContentService.getTaskRelatedContent(taskId).subscribe(
(res: any) => {
let attachList = [];
@@ -90,9 +93,11 @@ export class TaskAttachmentListComponent implements OnChanges {
});
this.attachments = attachList;
this.success.emit(this.attachments);
this.loadingFlag = false;
},
(err) => {
this.error.emit(err);
this.loadingFlag = false;
});
}
}
@@ -175,4 +180,8 @@ export class TaskAttachmentListComponent implements OnChanges {
}
);
}
isLoading() {
return this.loadingFlag;
}
}