From 6f889347e46f2126512967e27fc4a4cc3bf10855 Mon Sep 17 00:00:00 2001 From: haroon amjad Date: Wed, 17 Jul 2019 10:48:07 +0300 Subject: [PATCH] Work List Pages Completed --- .../app/notification/notification.module.ts | 20 ++- .../notification/service/worklist.service.ts | 9 ++ .../view-note-modal.component.ts | 2 +- .../view-replacement-modal.component.html | 4 +- .../work-list-action-history.component.html | 65 +++++++++ .../work-list-action-history.component.scss | 55 +++++++ ...work-list-action-history.component.spec.ts | 27 ++++ .../work-list-action-history.component.ts | 107 ++++++++++++++ .../work-list-attach.component.html | 45 ++++++ .../work-list-attach.component.scss | 7 + .../work-list-attach.component.spec.ts | 27 ++++ .../work-list-attach.component.ts | 59 ++++++++ .../work-list-details.component.html | 136 ++++++++++++++++++ .../work-list-details.component.scss | 0 .../work-list-details.component.spec.ts | 27 ++++ .../work-list-details.component.ts | 69 +++++++++ Mohem/src/assets/localization/i18n.json | 28 +++- 17 files changed, 682 insertions(+), 5 deletions(-) create mode 100644 Mohem/src/app/notification/work-list-action-history/work-list-action-history.component.html create mode 100644 Mohem/src/app/notification/work-list-action-history/work-list-action-history.component.scss create mode 100644 Mohem/src/app/notification/work-list-action-history/work-list-action-history.component.spec.ts create mode 100644 Mohem/src/app/notification/work-list-action-history/work-list-action-history.component.ts create mode 100644 Mohem/src/app/notification/work-list-attach/work-list-attach.component.html create mode 100644 Mohem/src/app/notification/work-list-attach/work-list-attach.component.scss create mode 100644 Mohem/src/app/notification/work-list-attach/work-list-attach.component.spec.ts create mode 100644 Mohem/src/app/notification/work-list-attach/work-list-attach.component.ts create mode 100644 Mohem/src/app/notification/work-list-details/work-list-details.component.html create mode 100644 Mohem/src/app/notification/work-list-details/work-list-details.component.scss create mode 100644 Mohem/src/app/notification/work-list-details/work-list-details.component.spec.ts create mode 100644 Mohem/src/app/notification/work-list-details/work-list-details.component.ts diff --git a/Mohem/src/app/notification/notification.module.ts b/Mohem/src/app/notification/notification.module.ts index f886cc6d..463054e1 100644 --- a/Mohem/src/app/notification/notification.module.ts +++ b/Mohem/src/app/notification/notification.module.ts @@ -1,3 +1,4 @@ +import { WorkListAttachComponent } from './work-list-attach/work-list-attach.component'; import { ViewNoteModalComponent } from './view-note-modal/view-note-modal.component'; import { WorkListReplacementRollComponent } from './work-list-replacement-roll/work-list-replacement-roll.component'; import { HmgCommonModule } from './../hmg-common/hmg-common.module'; @@ -13,6 +14,8 @@ import { PipesModule } from '../pipes/pipes.module'; import { WorklistService } from './service/worklist.service'; import { WorkListRfcComponent } from './work-list-rfc/work-list-rfc.component'; import { ViewReplacementModalComponent } from './view-replacement-modal/view-replacement-modal.component'; +import { WorkListActionHistoryComponent } from './work-list-action-history/work-list-action-history.component'; +import { WorkListDetailsComponent } from './work-list-details/work-list-details.component'; // import { WorklistMainComponent } from './worklist-main/worklist-main.component'; @@ -45,6 +48,18 @@ const routes: Routes = [ path: 'view-replacement-modal', component: ViewReplacementModalComponent }, + { + path: 'work-list-action-history', + component: WorkListActionHistoryComponent + }, + { + path: 'work-list-attach', + component: WorkListAttachComponent + }, + { + path: 'work-list-details', + component: WorkListDetailsComponent + }, // { // path:'worklist-main', @@ -69,7 +84,10 @@ const routes: Routes = [ WorkListReplacementRollComponent, WorkListRfcComponent, ViewNoteModalComponent, - ViewReplacementModalComponent + ViewReplacementModalComponent, + WorkListActionHistoryComponent, + WorkListAttachComponent, + WorkListDetailsComponent // WorklistMainComponent ], providers:[WorklistService] diff --git a/Mohem/src/app/notification/service/worklist.service.ts b/Mohem/src/app/notification/service/worklist.service.ts index f7d3c437..6dce8f24 100644 --- a/Mohem/src/app/notification/service/worklist.service.ts +++ b/Mohem/src/app/notification/service/worklist.service.ts @@ -5,6 +5,7 @@ import { Observable } from 'rxjs'; import { WorkListReplacmentEmployeeRequest } from '../models/ReplacmentEmployeeReq'; import { WorkListActionHistoryRequest } from '../models/ActionHistoryReq'; import { WorKListRFCEmployeeResponse } from '../models/RFC-EmployeeRes'; +import { WorkListActionHistoryResponse } from '../models/ActionHistoryRes'; @Injectable() @@ -13,6 +14,7 @@ export class WorklistService { public static getWorkList = 'Services/ERP.svc/REST/GET_WORKLIST'; public static getReplacmentEmployeeList = 'Services/ERP.svc/REST/GET_REPLACEMENT_LIST'; public static getRFCEmployeeList = 'Services/ERP.svc/REST/GET_RFC_EMPLOYEE_LIST'; + public static getActionHistory = 'Services/ERP.svc/REST/GET_ACTION_HISTORY'; constructor( public api: ConnectorService, @@ -37,4 +39,11 @@ export class WorklistService { this.authService.authenticateRequest(request); return this.api.post(WorklistService.getRFCEmployeeList, request, onError, errorLabel); } + + public getActionHistory(historyActionReq: any, onError?: any, errorLabel?: string): Observable { + const request = historyActionReq; + this.authService.authenticateRequest(request); + return this.api.post(WorklistService.getActionHistory, request, onError, errorLabel); + } + } \ No newline at end of file diff --git a/Mohem/src/app/notification/view-note-modal/view-note-modal.component.ts b/Mohem/src/app/notification/view-note-modal/view-note-modal.component.ts index f20705df..357b7ec5 100644 --- a/Mohem/src/app/notification/view-note-modal/view-note-modal.component.ts +++ b/Mohem/src/app/notification/view-note-modal/view-note-modal.component.ts @@ -14,7 +14,7 @@ export class ViewNoteModalComponent implements OnInit { constructor(private modalCtrl: ModalController, private cs: CommonService) { } ngOnInit() { - this.getTextNote = this.cs.sharedService.getSharedData('textNote'); + this.getTextNote = this.cs.sharedService.getSharedData('ViewNoteModalPage'); } closeModal() { diff --git a/Mohem/src/app/notification/view-replacement-modal/view-replacement-modal.component.html b/Mohem/src/app/notification/view-replacement-modal/view-replacement-modal.component.html index 34857daf..72e7916b 100644 --- a/Mohem/src/app/notification/view-replacement-modal/view-replacement-modal.component.html +++ b/Mohem/src/app/notification/view-replacement-modal/view-replacement-modal.component.html @@ -12,7 +12,7 @@ @@ -30,7 +30,7 @@ {{RepList.USER_NAME}} {{RepList.EMPLOYEE_DISPLAY_NAME}} {{RepList.EMAIL_ADDRESS}} - + diff --git a/Mohem/src/app/notification/work-list-action-history/work-list-action-history.component.html b/Mohem/src/app/notification/work-list-action-history/work-list-action-history.component.html new file mode 100644 index 00000000..daec1cf6 --- /dev/null +++ b/Mohem/src/app/notification/work-list-action-history/work-list-action-history.component.html @@ -0,0 +1,65 @@ + + + + {{'workListMain, actionHis' | translate}} + + + + + + + +
{{'worklistMain, actionHis' | translate}}
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + + +
\ No newline at end of file diff --git a/Mohem/src/app/notification/work-list-action-history/work-list-action-history.component.scss b/Mohem/src/app/notification/work-list-action-history/work-list-action-history.component.scss new file mode 100644 index 00000000..5f7ccfcc --- /dev/null +++ b/Mohem/src/app/notification/work-list-action-history/work-list-action-history.component.scss @@ -0,0 +1,55 @@ +ion-card-content.card-content.card-content-md, +ion-card-content.card-content.card-content-ios { + padding: 0px; + margin: 0px; +} +.col { + //border: #dedede solid 1px; + padding: 2px !important; + text-align: center; + font-size: 15px; +} +.item-md.item-block .item-inner, +.item-ios.item-block .item-inner { + padding: 0px !important; +} +.itemAH { + padding: 0px !important + ; + font-size: 13px; +} +.gridAH { + text-align: center; + padding: 5px 5px !important; + border-radius: 5px; +} +.rowAH { + white-space: normal; + .col { + border: 1px solid #d9d9d9; + } +} +.Header { + font-weight: bold; + // font-family: "WorkSans-SemiBold" !important; + color: #1a586d; + // padding: 0px !important; + // margin: 0px !important; +} +.titleH { + //background-color:$custgreen; + //height: 40px; + //line-height: 2; + font-size: 15px; + border: 1px solid #d9d9d9; + border-top-right-radius: 5px; + border-top-left-radius: 5px; + border-bottom: 0px; + .col { + border: 0px; + } +} +ion-label.label.label-md, +ion-label.label.label-ios { + margin: 0px; +} diff --git a/Mohem/src/app/notification/work-list-action-history/work-list-action-history.component.spec.ts b/Mohem/src/app/notification/work-list-action-history/work-list-action-history.component.spec.ts new file mode 100644 index 00000000..c214648a --- /dev/null +++ b/Mohem/src/app/notification/work-list-action-history/work-list-action-history.component.spec.ts @@ -0,0 +1,27 @@ +import { CUSTOM_ELEMENTS_SCHEMA } from '@angular/core'; +import { async, ComponentFixture, TestBed } from '@angular/core/testing'; + +import { WorkListActionHistoryComponent } from './work-list-action-history.component'; + +describe('WorkListActionHistoryComponent', () => { + let component: WorkListActionHistoryComponent; + let fixture: ComponentFixture; + + beforeEach(async(() => { + TestBed.configureTestingModule({ + declarations: [ WorkListActionHistoryComponent ], + schemas: [CUSTOM_ELEMENTS_SCHEMA], + }) + .compileComponents(); + })); + + beforeEach(() => { + fixture = TestBed.createComponent(WorkListActionHistoryComponent); + component = fixture.componentInstance; + fixture.detectChanges(); + }); + + it('should create', () => { + expect(component).toBeTruthy(); + }); +}); diff --git a/Mohem/src/app/notification/work-list-action-history/work-list-action-history.component.ts b/Mohem/src/app/notification/work-list-action-history/work-list-action-history.component.ts new file mode 100644 index 00000000..286f70c9 --- /dev/null +++ b/Mohem/src/app/notification/work-list-action-history/work-list-action-history.component.ts @@ -0,0 +1,107 @@ +import { ViewNoteModalComponent } from './../view-note-modal/view-note-modal.component'; +import { WorklistService } from './../service/worklist.service'; +import { Component, OnInit } from '@angular/core'; +import { WorkListActionHistoryRequest } from '../models/ActionHistoryReq'; +import { CommonService } from 'src/app/hmg-common/services/common/common.service'; +import { TranslatorService } from 'src/app/hmg-common/services/translator/translator.service'; +import { ModalController } from '@ionic/angular'; +import { WorkListActionHistoryResponse } from '../models/ActionHistoryRes'; + +@Component({ + selector: 'app-work-list-action-history', + templateUrl: './work-list-action-history.component.html', + styleUrls: ['./work-list-action-history.component.scss'], +}) +export class WorkListActionHistoryComponent implements OnInit { + + private WorkListActionHistoryObj: WorkListActionHistoryRequest; + getPassNotificationDetails: any; + actionHistoryRes: any; + IsReachEnd: boolean = false; + P_PAGE_NUM: number = 1; + P_PAGE_LIMIT: number = 50; + + constructor(private cs: CommonService, private ts: TranslatorService, private modalCtrl: ModalController, public worklistService: WorklistService) { + this.getPassNotificationDetails = this.cs.sharedService.getSharedData('passNotificationInfo'); + this.WorkListActionHistoryObj = new WorkListActionHistoryRequest(); + this.WorkListActionHistoryObj.P_PAGE_NUM = this.P_PAGE_NUM; + this.WorkListActionHistoryObj.P_PAGE_LIMIT = this.P_PAGE_LIMIT; + this.WorkListActionHistoryObj.P_NOTIFICATION_ID = this.getPassNotificationDetails.NOTIFICATION_ID; + } + + ngOnInit() { + this.getActionHistory(this.WorkListActionHistoryObj); + } + + getActionHistory(WorkListActionHistoryObj) { + this.IsReachEnd = false; + this.worklistService.getActionHistory(WorkListActionHistoryObj). + subscribe((result: WorkListActionHistoryResponse) => { + this.handleWorkListActionHistoryResult(result); + }); + + + } + handleWorkListActionHistoryResult(result) { + if (this.cs.validResponse(result)) { + if (this.cs.hasData(result.GetActionHistoryList)) { + this.actionHistoryRes = result.GetActionHistoryList; + this.P_PAGE_NUM++; + let lastItemIndex = this.actionHistoryRes.length - 1; + if (result.GetActionHistoryList[lastItemIndex]) { + let lastitem = result.GetActionHistoryList[lastItemIndex]; + if (lastitem.NO_OF_ROWS == lastitem.ROW_NUM) { + this.IsReachEnd = true; + } else { + this.IsReachEnd = false; + } + } + } + } + } + + async openNoteDetail(note) { + // let modalPage = this.modalCtrl.create('ViewNoteModalPage', { textNote: note }); + // modalPage.present(); + + this.cs.sharedService.setSharedData(note, 'ViewNoteModalPage') + + const modal = await this.modalCtrl.create({ + component: ViewNoteModalComponent + }); + + return await modal.present(); + } + + doInfinite(infiniteScroll) { + if (!this.IsReachEnd) { + this.WorkListActionHistoryObj.P_PAGE_NUM = this.P_PAGE_NUM; + this.worklistService.getActionHistory(this.WorkListActionHistoryObj). + subscribe((result: any) => { + if (this.cs.validResponse(result)) { + if (result.GetActionHistoryList != undefined) { + this.P_PAGE_NUM++; + (result.GetActionHistoryList).forEach(element => { + if (element.ROW_NUM == element.NO_OF_ROWS) { + this.IsReachEnd = true; + } else { + this.IsReachEnd = false; + } + this.actionHistoryRes.push(element); + }, (Error) => console.log(Error), () => infiniteScroll.target.complete()); + }// if list length >0 + else { + this.IsReachEnd = true; + } + }// if response == 1 + //this.pageNum++; + infiniteScroll.target.complete(); + + }); + } else { + if (infiniteScroll) + infiniteScroll.target.complete(); + } + }//end infiniteScroll + +} diff --git a/Mohem/src/app/notification/work-list-attach/work-list-attach.component.html b/Mohem/src/app/notification/work-list-attach/work-list-attach.component.html new file mode 100644 index 00000000..ae0df3bb --- /dev/null +++ b/Mohem/src/app/notification/work-list-attach/work-list-attach.component.html @@ -0,0 +1,45 @@ + + + + {{'worklist, note' | translate}} + + + + + +
+

{{ 'general, notAttch' | translate}}

+
+
+ + + +
{{'worklistMain, suppDoc' | translate}}
+
+ + +
+ + +
+
+ + {{attachList.SEQ_NUM }}. {{attachList.FILE_NAME}} + +
+ + + +
+
+ +
+
+
+ +
+ +
\ No newline at end of file diff --git a/Mohem/src/app/notification/work-list-attach/work-list-attach.component.scss b/Mohem/src/app/notification/work-list-attach/work-list-attach.component.scss new file mode 100644 index 00000000..a01032d9 --- /dev/null +++ b/Mohem/src/app/notification/work-list-attach/work-list-attach.component.scss @@ -0,0 +1,7 @@ +ion-card-content.card-content.card-content-md, +ion-card-content.card-content.card-content-ios { + padding: 0px; +} +img.attachImg { + margin: 5px 8px 13px 0; +} diff --git a/Mohem/src/app/notification/work-list-attach/work-list-attach.component.spec.ts b/Mohem/src/app/notification/work-list-attach/work-list-attach.component.spec.ts new file mode 100644 index 00000000..c4804d78 --- /dev/null +++ b/Mohem/src/app/notification/work-list-attach/work-list-attach.component.spec.ts @@ -0,0 +1,27 @@ +import { CUSTOM_ELEMENTS_SCHEMA } from '@angular/core'; +import { async, ComponentFixture, TestBed } from '@angular/core/testing'; + +import { WorkListAttachComponent } from './work-list-attach.component'; + +describe('WorkListAttachComponent', () => { + let component: WorkListAttachComponent; + let fixture: ComponentFixture; + + beforeEach(async(() => { + TestBed.configureTestingModule({ + declarations: [ WorkListAttachComponent ], + schemas: [CUSTOM_ELEMENTS_SCHEMA], + }) + .compileComponents(); + })); + + beforeEach(() => { + fixture = TestBed.createComponent(WorkListAttachComponent); + component = fixture.componentInstance; + fixture.detectChanges(); + }); + + it('should create', () => { + expect(component).toBeTruthy(); + }); +}); diff --git a/Mohem/src/app/notification/work-list-attach/work-list-attach.component.ts b/Mohem/src/app/notification/work-list-attach/work-list-attach.component.ts new file mode 100644 index 00000000..c73997b3 --- /dev/null +++ b/Mohem/src/app/notification/work-list-attach/work-list-attach.component.ts @@ -0,0 +1,59 @@ +import { WorklistAttachService } from './../../absence/service/work-list-attach.service'; +import { ModalController } from '@ionic/angular'; +import { NotificationGetAttachResponse } from 'src/app/eit/models/NotificationGetAttachRes'; +import { CommonService } from 'src/app/hmg-common/services/common/common.service'; +import { WorkListButtonRequest } from 'src/app/eit/models/NotificationButtonReq'; +import { Component, OnInit } from '@angular/core'; +import { WorkListAttachViewComponent } from '../work-list-attach-view/work-list-attach-view.component'; + +@Component({ + selector: 'app-work-list-attach', + templateUrl: './work-list-attach.component.html', + styleUrls: ['./work-list-attach.component.scss'], +}) +export class WorkListAttachComponent implements OnInit { + + private WorkListAttachObj: WorkListButtonRequest; + getPassNotificationDetails: any; + attachmentRes: any; + + constructor(public cs: CommonService, public modalCtrl: ModalController, public worklistAttachService: WorklistAttachService) { + this.getPassNotificationDetails = this.cs.sharedService.getSharedData('passNotificationInfo'); + this.WorkListAttachObj = new WorkListButtonRequest(); + this.WorkListAttachObj.P_NOTIFICATION_ID = this.getPassNotificationDetails.NOTIFICATION_ID; + } + + ngOnInit() { + this.getAttachmentNotification(this.WorkListAttachObj); + } + + async OpenAttachFiles(value, Type) { + // let modal: Modal = this.modalCtrl.create('WorkListAttachViewPage', { displayData: value, TypeData: Type }); + // modal.present(); + + this.cs.sharedService.setSharedData({ displayData: value, TypeData: Type }, 'WorkListAttachViewPage') + const modal = await this.modalCtrl.create({ + component: WorkListAttachViewComponent + }); + + return await modal.present(); + } + + getAttachmentNotification(WorkListAttachObj) { + + this.worklistAttachService.getAttach(WorkListAttachObj). + subscribe((result: NotificationGetAttachResponse) => { + this.handleWorkListAttachResult(result); + }); + } + + handleWorkListAttachResult(result) { + if (this.cs.validResponse(result)) { + // this.sharedData.setSharedData(result, WorKListResponse.SHARED_DATA); + if (result.GetAttachementList != null) { + this.attachmentRes = result.GetAttachementList; + } // if result == null + } // valid it + } + +} diff --git a/Mohem/src/app/notification/work-list-details/work-list-details.component.html b/Mohem/src/app/notification/work-list-details/work-list-details.component.html new file mode 100644 index 00000000..eefc7a43 --- /dev/null +++ b/Mohem/src/app/notification/work-list-details/work-list-details.component.html @@ -0,0 +1,136 @@ + + + + {{'workListMain, notfDetails' | translate}} + + + + + +
+ + + + +
{{'general, info' | translate}}
+
+ + +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+
+ + + +
{{'worklistMain, notfDetails' | translate}}
+
+ + +
+ + + + + + + + +
+
+ +
+
+ +
\ No newline at end of file diff --git a/Mohem/src/app/notification/work-list-details/work-list-details.component.scss b/Mohem/src/app/notification/work-list-details/work-list-details.component.scss new file mode 100644 index 00000000..e69de29b diff --git a/Mohem/src/app/notification/work-list-details/work-list-details.component.spec.ts b/Mohem/src/app/notification/work-list-details/work-list-details.component.spec.ts new file mode 100644 index 00000000..a561ba66 --- /dev/null +++ b/Mohem/src/app/notification/work-list-details/work-list-details.component.spec.ts @@ -0,0 +1,27 @@ +import { CUSTOM_ELEMENTS_SCHEMA } from '@angular/core'; +import { async, ComponentFixture, TestBed } from '@angular/core/testing'; + +import { WorkListDetailsComponent } from './work-list-details.component'; + +describe('WorkListDetailsComponent', () => { + let component: WorkListDetailsComponent; + let fixture: ComponentFixture; + + beforeEach(async(() => { + TestBed.configureTestingModule({ + declarations: [ WorkListDetailsComponent ], + schemas: [CUSTOM_ELEMENTS_SCHEMA], + }) + .compileComponents(); + })); + + beforeEach(() => { + fixture = TestBed.createComponent(WorkListDetailsComponent); + component = fixture.componentInstance; + fixture.detectChanges(); + }); + + it('should create', () => { + expect(component).toBeTruthy(); + }); +}); diff --git a/Mohem/src/app/notification/work-list-details/work-list-details.component.ts b/Mohem/src/app/notification/work-list-details/work-list-details.component.ts new file mode 100644 index 00000000..1a3118b9 --- /dev/null +++ b/Mohem/src/app/notification/work-list-details/work-list-details.component.ts @@ -0,0 +1,69 @@ +import { WorklistsubmitterInfoResponse } from './../models/WorklistsubmitterInfoRes'; +import { WorklistMainService } from './../service/work-list.main.service'; +import { CommonService } from 'src/app/hmg-common/services/common/common.service'; +import { WorkListSubmitterInfoRequest } from './../models/WorklistsubmitterInfoReq'; +import { Component, OnInit } from '@angular/core'; +import { EITNotificatonBodyResponse } from 'src/app/eit/models/EITNotificationBodyRes'; +import { AbsenceNotificatonBodyResponse } from '../models/AbsenceNotificationBodyRes'; + +@Component({ + selector: 'app-work-list-details', + templateUrl: './work-list-details.component.html', + styleUrls: ['./work-list-details.component.scss'], +}) +export class WorkListDetailsComponent implements OnInit { + submitterInfoRes: any; + notificationBodyRes: any; + notBodyType: string = ""; + notBodyResult: any; + getPassNotificationDetails: any; + private WorkListSubmitterInfoObj: WorkListSubmitterInfoRequest; + + constructor(public cs: CommonService, public worklistMainService: WorklistMainService) { + this.WorkListSubmitterInfoObj = new WorkListSubmitterInfoRequest(); + this.notBodyType = this.cs.sharedService.getSharedData('NotBodyType', false); + if (this.notBodyType == "EIT") { + this.notBodyResult = this.cs.sharedService.getSharedData(EITNotificatonBodyResponse.SHARED_DATA); + this.getPassNotificationDetails = this.cs.sharedService.getSharedData(EITNotificatonBodyResponse.NOT_WORKLIST); + } else if (this.notBodyType == "ABSENCE") { + this.notBodyResult = this.cs.sharedService.getSharedData(AbsenceNotificatonBodyResponse.SHARED_DATA); + this.getPassNotificationDetails = this.cs.sharedService.getSharedData(AbsenceNotificatonBodyResponse.NOT_WORKLIST); + } + } + + ngOnInit() { + this.WorkListSubmitterInfoObj.P_PAGE_LIMIT = 100; + this.WorkListSubmitterInfoObj.P_PAGE_NUM = 1; + this.WorkListSubmitterInfoObj.P_SELECTED_EMPLOYEE_NUMBER = this.getPassNotificationDetails.SELECTED_EMPLOYEE_NUMBER; + this.WorkListSubmitterInfoObj.P_SELECTED_RESP_ID = -999; + this.WorkListSubmitterInfoObj.P_SEARCH_EMAIL_ADDRESS = ""; + this.WorkListSubmitterInfoObj.P_SEARCH_EMPLOYEE_DISPLAY_NAME = ""; + this.WorkListSubmitterInfoObj.P_SEARCH_USER_NAME = ""; + + this.getsubmitterInfo(this.WorkListSubmitterInfoObj); + this.handleNotificationBody(); + } + + getsubmitterInfo(notificationSubmitterInfoObj) { + this.worklistMainService.getSubmitterInfo(notificationSubmitterInfoObj). + subscribe((result: WorklistsubmitterInfoResponse) => { + this.handleSubmitterInfoResult(result); + }); + } + handleSubmitterInfoResult(result) { + if (this.cs.validResponse(result)) { + // this.sharedData.setSharedData(result, WorKListResponse.SHARED_DATA); + if (this.cs.hasData(result.MemberInformationList)) { + //if (result.MemberInformationList != null) { + this.submitterInfoRes = result.MemberInformationList; + } // if result == null + } // valid it + }// End handleWorkListButtonsResult + handleNotificationBody() { + this.notificationBodyRes = {}; + if (this.cs.hasData(this.notBodyResult)) { + this.notificationBodyRes = this.notBodyResult; + } + } + +} diff --git a/Mohem/src/assets/localization/i18n.json b/Mohem/src/assets/localization/i18n.json index 05c89c6f..71bd5658 100644 --- a/Mohem/src/assets/localization/i18n.json +++ b/Mohem/src/assets/localization/i18n.json @@ -846,7 +846,7 @@ "ar": "البريد الإلكتروني للمنشأة" }, "name": { - "en": "Emplyee Name", + "en": "Employee Name", "ar": "اسم الموظف " }, "orgName": { @@ -1371,6 +1371,32 @@ "rfc": { "en": "Return for correction", "ar": "عودة لتصحيح" + }, + "actionHis":{ + "en":"Action History", + "ar":"تاريخ العمل" + }, + "notfDetails":{ + "en":"Notification Details", + "ar":"تفاصيل الإخطار" + } + }, + "actionHis": { + "name":{ + "en":"Name", + "ar":"الإسم" + }, + "action":{ + "en":"Action", + "ar":"عمل" + }, + "date":{ + "en":"Date", + "ar":"تاريخ" + }, + "note":{ + "en":"Note", + "ar":"ملحوظة" } }, "addAttach":{