diff --git a/Mohem/src/app/authentication/sms-page/sms-page.page.ts b/Mohem/src/app/authentication/sms-page/sms-page.page.ts index 631dcd70..f5fffbc7 100644 --- a/Mohem/src/app/authentication/sms-page/sms-page.page.ts +++ b/Mohem/src/app/authentication/sms-page/sms-page.page.ts @@ -62,6 +62,8 @@ export class SmsPageComponent implements OnInit { ngOnInit() { this.activeType=this.common.getActiveTypeLogin(); + console.log("active "+ this.common.sharedService.getSharedData('active-type',true)); + console.log("activeType :"+this.activeType); this.count = 0; this.initTimer(); @@ -178,6 +180,7 @@ export class SmsPageComponent implements OnInit { if (this.platform.is('cordova')) { this.insertMobileLogin(); } + this.activeType =this.common.setActiveTypeLogin(0); this.common.openHome(); }); } diff --git a/Mohem/src/app/notification/home/home.component.ts b/Mohem/src/app/notification/home/home.component.ts index e169299b..3db98ab8 100644 --- a/Mohem/src/app/notification/home/home.component.ts +++ b/Mohem/src/app/notification/home/home.component.ts @@ -345,8 +345,10 @@ export class HomeComponent implements OnInit { arrayToFilter = this.newWorkListResponse.filter((workList) => { return workList.ITEM_TYPE === filter; }); - const sortData = this.sortArray(arrayToFilter); - this.showFormattedData = this.categorizeData(sortData); + const categorizeData = this.categorizeData(arrayToFilter); + this.showFormattedData = this.sortArray(categorizeData); + // const sortData = this.sortArray(arrayToFilter); + // this.showFormattedData = this.categorizeData(sortData); } } @@ -596,6 +598,7 @@ export class HomeComponent implements OnInit { } this.common.sharedService.setSharedData(segmentInfo, HomeComponent.REQUSET_INFO); this.common.sharedService.setSharedData(this.ITGItem, HomeComponent.ALL_REQUEST); + this.common.sharedService.setSharedData(false, 'loadWorkList'); this.common.openWorklistITGPage(); } diff --git a/Mohem/src/app/notification/work-list-main-itg/work-list-main-itg.component.html b/Mohem/src/app/notification/work-list-main-itg/work-list-main-itg.component.html index 7c41c2ff..127dc7e5 100644 --- a/Mohem/src/app/notification/work-list-main-itg/work-list-main-itg.component.html +++ b/Mohem/src/app/notification/work-list-main-itg/work-list-main-itg.component.html @@ -166,17 +166,17 @@ - + - {{action.name}} + {{action.name}} - + - Skip + Skip diff --git a/Mohem/src/app/notification/work-list-main-itg/work-list-main-itg.component.ts b/Mohem/src/app/notification/work-list-main-itg/work-list-main-itg.component.ts index cd5c6e5b..9078511f 100644 --- a/Mohem/src/app/notification/work-list-main-itg/work-list-main-itg.component.ts +++ b/Mohem/src/app/notification/work-list-main-itg/work-list-main-itg.component.ts @@ -181,6 +181,7 @@ export class WorkListMainItgComponent implements OnInit { return false; } } else if (this.index === this.all_request_names.length) { //if its the end request redirecte to worklist home + this.common.sharedService.setSharedData(true, 'loadWorkList'); this.common.openNotificationPage(); return false; } @@ -193,14 +194,16 @@ export class WorkListMainItgComponent implements OnInit { if (this.index !== this.all_request.length) { // check if its last one to redirecte to home otherwise to next request. this.clearDataArray(); this.changeITGForm(this.all_request[this.index], this.request_name); - break + break; } else { + this.common.sharedService.setSharedData(true, 'loadWorkList'); this.common.openNotificationPage(); - break + break; } } else { + this.common.sharedService.setSharedData(true, 'loadWorkList'); this.common.openNotificationPage(); - break + break; } } } @@ -359,7 +362,7 @@ export class WorkListMainItgComponent implements OnInit { }, this.ts.trPK('general', 'ok'), () => { this.actionSelected = ''; - this.common.sharedService.setSharedData(true, 'loadWorkList'); + this.common.sharedService.setSharedData(true, 'loadWorkList'); }, this.ts.trPK('general', 'cancel'), this.ts.trPK('vacation-rule', 'confirmation'), this.confirmMsg(action));