|
|
|
|
@ -175,9 +175,27 @@ export class HomeComponent implements OnInit {
|
|
|
|
|
|
|
|
|
|
ngOnInit() {
|
|
|
|
|
this.common.startLoading();
|
|
|
|
|
this.direction = TranslatorService.getCurrentLanguageName();
|
|
|
|
|
this.worklistNotifications = this.common.sharedService.getSharedData('worklistNotifications', false);
|
|
|
|
|
this.openNotificationsDashboard();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
ionViewWillEnter() {
|
|
|
|
|
console.log(this.filters);
|
|
|
|
|
const loadWorkList = this.common.sharedService.getSharedData('loadWorkList', false);
|
|
|
|
|
if (loadWorkList) {
|
|
|
|
|
this.common.startLoading();
|
|
|
|
|
if (this.infiniteScroll) {
|
|
|
|
|
this.infiniteScroll.complete();
|
|
|
|
|
}
|
|
|
|
|
this.currentActiveIndex = 0;
|
|
|
|
|
this.previousActiveIndex = 0;
|
|
|
|
|
this.itemType = '';
|
|
|
|
|
this.selectedFilter = 'ALL';
|
|
|
|
|
this.isPostNoLoad = true;
|
|
|
|
|
this.disableFilters();
|
|
|
|
|
this.resetData();
|
|
|
|
|
this.direction = TranslatorService.getCurrentLanguageName();
|
|
|
|
|
this.worklistNotifications = this.common.sharedService.getSharedData('worklistNotifications', false);
|
|
|
|
|
this.openNotificationsDashboard();
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
callWorkListServices() {
|
|
|
|
|
@ -222,6 +240,7 @@ export class HomeComponent implements OnInit {
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
activeFilter(index: number) {
|
|
|
|
|
console.log(this.filters);
|
|
|
|
|
if (this.currentActiveIndex !== index) {
|
|
|
|
|
this.previousActiveIndex = this.currentActiveIndex;
|
|
|
|
|
this.currentActiveIndex = index;
|
|
|
|
|
@ -399,6 +418,7 @@ export class HomeComponent implements OnInit {
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private handleWorkListResult(result: any) {
|
|
|
|
|
console.log(this.filters);
|
|
|
|
|
const lastItemIndex = result.length - 1;
|
|
|
|
|
const lastitem = result[lastItemIndex];
|
|
|
|
|
if (lastitem) {
|
|
|
|
|
@ -438,6 +458,7 @@ export class HomeComponent implements OnInit {
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
openNotificationDetail(obj) {
|
|
|
|
|
this.common.sharedService.setSharedData(false, 'loadWorkList');
|
|
|
|
|
this.common.sharedService.setSharedData(obj, HomeComponent.NOTIFICATION_DATA);
|
|
|
|
|
if (obj.REQUEST_TYPE === 'PR') {
|
|
|
|
|
this.common.openWorklistMainPRPage();
|
|
|
|
|
@ -468,6 +489,10 @@ export class HomeComponent implements OnInit {
|
|
|
|
|
this.WorkListObj.P_SEARCH_SUBJECT = '';
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// initializeWorkList() {
|
|
|
|
|
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
|
|
clearSearch() {
|
|
|
|
|
this.common.startLoading();
|
|
|
|
|
this.itemType = '';
|
|
|
|
|
|