From f07de65e5c4abf02cca7468b607594e440be81ef Mon Sep 17 00:00:00 2001 From: haroon amjad Date: Wed, 17 Jul 2019 08:25:13 +0300 Subject: [PATCH] work list replacement component implemented --- .../confirm-add-eit.component.ts | 3 +- .../services/common/common.service.ts | 5 + .../app/notification/notification.module.ts | 6 + .../notification/service/worklist.service.ts | 38 ++- .../view-replacement-modal.component.html | 3 + .../view-replacement-modal.component.scss | 0 .../view-replacement-modal.component.spec.ts | 27 ++ .../view-replacement-modal.component.ts | 14 + .../work-list-attach-view.component.html | 1 - .../work-list-replacement-roll.component.html | 71 +++++ .../work-list-replacement-roll.component.scss | 10 + ...rk-list-replacement-roll.component.spec.ts | 27 ++ .../work-list-replacement-roll.component.ts | 293 ++++++++++++++++++ Mohem/src/assets/localization/i18n.json | 34 +- 14 files changed, 510 insertions(+), 22 deletions(-) create mode 100644 Mohem/src/app/notification/view-replacement-modal/view-replacement-modal.component.html create mode 100644 Mohem/src/app/notification/view-replacement-modal/view-replacement-modal.component.scss create mode 100644 Mohem/src/app/notification/view-replacement-modal/view-replacement-modal.component.spec.ts create mode 100644 Mohem/src/app/notification/view-replacement-modal/view-replacement-modal.component.ts create mode 100644 Mohem/src/app/notification/work-list-replacement-roll/work-list-replacement-roll.component.html create mode 100644 Mohem/src/app/notification/work-list-replacement-roll/work-list-replacement-roll.component.scss create mode 100644 Mohem/src/app/notification/work-list-replacement-roll/work-list-replacement-roll.component.spec.ts create mode 100644 Mohem/src/app/notification/work-list-replacement-roll/work-list-replacement-roll.component.ts diff --git a/Mohem/src/app/eit/confirm-add-eit/confirm-add-eit.component.ts b/Mohem/src/app/eit/confirm-add-eit/confirm-add-eit.component.ts index 62fe1d69..4171b53f 100644 --- a/Mohem/src/app/eit/confirm-add-eit/confirm-add-eit.component.ts +++ b/Mohem/src/app/eit/confirm-add-eit/confirm-add-eit.component.ts @@ -214,7 +214,8 @@ export class ConfirmAddEitComponent implements OnInit { // } // this.navCtrl.popToRoot(); - this.cs.openHome(); + // this.cs.openHome(); + this.cs.openNotificationPage(); } } diff --git a/Mohem/src/app/hmg-common/services/common/common.service.ts b/Mohem/src/app/hmg-common/services/common/common.service.ts index bd483690..0df72e56 100644 --- a/Mohem/src/app/hmg-common/services/common/common.service.ts +++ b/Mohem/src/app/hmg-common/services/common/common.service.ts @@ -970,6 +970,11 @@ export class CommonService { public openWorklistMainPage() { this.nav.navigateForward(["/notification/worklist-main"]); } + + public openWorklistReplacementRollPage() { + this.nav.navigateForward(["/notification/work-list-replacement-roll"]); + } + public reload(url: string, from: string) { console.log("force reload called from:" + from); // window.location.reload(); diff --git a/Mohem/src/app/notification/notification.module.ts b/Mohem/src/app/notification/notification.module.ts index 6f02872d..8ed84b29 100644 --- a/Mohem/src/app/notification/notification.module.ts +++ b/Mohem/src/app/notification/notification.module.ts @@ -1,3 +1,4 @@ +import { WorkListReplacementRollComponent } from './work-list-replacement-roll/work-list-replacement-roll.component'; import { HmgCommonModule } from './../hmg-common/hmg-common.module'; import { WorkListAttachViewComponent } from './work-list-attach-view/work-list-attach-view.component'; import { HomeComponent } from './home/home.component'; @@ -25,6 +26,10 @@ const routes: Routes = [ path: 'work-list-attach-view', component: WorkListAttachViewComponent }, + { + path: 'work-list-replacement-roll', + component: WorkListReplacementRollComponent + }, // { // path:'worklist-main', // component:WorklistMainComponent @@ -45,6 +50,7 @@ const routes: Routes = [ declarations: [ NotificationPage, HomeComponent, + WorkListReplacementRollComponent // WorklistMainComponent ], providers:[WorklistService] diff --git a/Mohem/src/app/notification/service/worklist.service.ts b/Mohem/src/app/notification/service/worklist.service.ts index 32335be1..5524f79a 100644 --- a/Mohem/src/app/notification/service/worklist.service.ts +++ b/Mohem/src/app/notification/service/worklist.service.ts @@ -1,25 +1,31 @@ -import {Injectable} from '@angular/core'; -import {Http, Response, Headers} from "@angular/http"; +import { Injectable } from '@angular/core'; import { AuthenticationService } from "src/app/hmg-common/services/authentication/authentication.service"; import { ConnectorService } from "src/app/hmg-common/services/connector/connector.service"; -import {Observable} from 'rxjs'; -import {WorkListRequest} from '../models/workListRequest'; -import {WorKListResponse} from '../models/workListResponse'; +import { Observable } from 'rxjs'; +import { WorkListReplacmentEmployeeRequest } from '../models/ReplacmentEmployeeReq'; @Injectable() export class WorklistService { + public static getWorkList = 'Services/ERP.svc/REST/GET_WORKLIST'; - constructor( - public api: ConnectorService, - public authService: AuthenticationService, - - ) { } - - public getWorkList(WorkListReq: any, onError?: any, errorLabel?: string): Observable { - const request = WorkListReq; - this.authService.authenticateRequest(request); - return this.api.post(WorklistService.getWorkList, request, onError, errorLabel); - } + public static getReplacmentEmployeeList = 'Services/ERP.svc/REST/GET_REPLACEMENT_LIST'; + + constructor( + public api: ConnectorService, + public authService: AuthenticationService, + + ) { } + + public getWorkList(WorkListReq: any, onError?: any, errorLabel?: string): Observable { + const request = WorkListReq; + this.authService.authenticateRequest(request); + return this.api.post(WorklistService.getWorkList, request, onError, errorLabel); + } + public getReplacmentEmployeeList(ReplacmentEmployeeRequest: any, onError?: any, errorLabel?: string): Observable { + const request = ReplacmentEmployeeRequest; + this.authService.authenticateRequest(request); + return this.api.post(WorklistService.getReplacmentEmployeeList, request, onError, errorLabel); + } } \ No newline at end of file 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 new file mode 100644 index 00000000..31549e41 --- /dev/null +++ b/Mohem/src/app/notification/view-replacement-modal/view-replacement-modal.component.html @@ -0,0 +1,3 @@ +

+ view-replacement-modal works! +

diff --git a/Mohem/src/app/notification/view-replacement-modal/view-replacement-modal.component.scss b/Mohem/src/app/notification/view-replacement-modal/view-replacement-modal.component.scss new file mode 100644 index 00000000..e69de29b diff --git a/Mohem/src/app/notification/view-replacement-modal/view-replacement-modal.component.spec.ts b/Mohem/src/app/notification/view-replacement-modal/view-replacement-modal.component.spec.ts new file mode 100644 index 00000000..d6960f17 --- /dev/null +++ b/Mohem/src/app/notification/view-replacement-modal/view-replacement-modal.component.spec.ts @@ -0,0 +1,27 @@ +import { CUSTOM_ELEMENTS_SCHEMA } from '@angular/core'; +import { async, ComponentFixture, TestBed } from '@angular/core/testing'; + +import { ViewReplacementModalComponent } from './view-replacement-modal.component'; + +describe('ViewReplacementModalComponent', () => { + let component: ViewReplacementModalComponent; + let fixture: ComponentFixture; + + beforeEach(async(() => { + TestBed.configureTestingModule({ + declarations: [ ViewReplacementModalComponent ], + schemas: [CUSTOM_ELEMENTS_SCHEMA], + }) + .compileComponents(); + })); + + beforeEach(() => { + fixture = TestBed.createComponent(ViewReplacementModalComponent); + component = fixture.componentInstance; + fixture.detectChanges(); + }); + + it('should create', () => { + expect(component).toBeTruthy(); + }); +}); diff --git a/Mohem/src/app/notification/view-replacement-modal/view-replacement-modal.component.ts b/Mohem/src/app/notification/view-replacement-modal/view-replacement-modal.component.ts new file mode 100644 index 00000000..d1ff05a1 --- /dev/null +++ b/Mohem/src/app/notification/view-replacement-modal/view-replacement-modal.component.ts @@ -0,0 +1,14 @@ +import { Component, OnInit } from '@angular/core'; + +@Component({ + selector: 'app-view-replacement-modal', + templateUrl: './view-replacement-modal.component.html', + styleUrls: ['./view-replacement-modal.component.scss'], +}) +export class ViewReplacementModalComponent implements OnInit { + + constructor() { } + + ngOnInit() {} + +} diff --git a/Mohem/src/app/notification/work-list-attach-view/work-list-attach-view.component.html b/Mohem/src/app/notification/work-list-attach-view/work-list-attach-view.component.html index 59bda499..635bbcb9 100644 --- a/Mohem/src/app/notification/work-list-attach-view/work-list-attach-view.component.html +++ b/Mohem/src/app/notification/work-list-attach-view/work-list-attach-view.component.html @@ -1,6 +1,5 @@ - {{'workListMain, suppDoc' | translate}} diff --git a/Mohem/src/app/notification/work-list-replacement-roll/work-list-replacement-roll.component.html b/Mohem/src/app/notification/work-list-replacement-roll/work-list-replacement-roll.component.html new file mode 100644 index 00000000..fece6581 --- /dev/null +++ b/Mohem/src/app/notification/work-list-replacement-roll/work-list-replacement-roll.component.html @@ -0,0 +1,71 @@ + + + + {{ 'replacementRoll, title' | translate}} + + + + + + + + {{'replacementRoll, searchBy' | translate}} + + {{'addAttach, name' | translate}} + {{'login, username' | translate}} + {{'general, email' | translate}} + + + + + + + + + + + +
+ {{"replacementRoll, question" | translate}} : + {{pQuestion}} ? + {{"replacementRoll, answer" | translate}} + + {{"replacementRoll, enterNote" | translate}} + + + + +
+ + + + + + {{employee.EMPLOYEE_DISPLAY_NAME}}
{{employee.USER_NAME}}
+ {{employee.EMAIL_ADDRESS}}
+ +
+
+ + + + +
+ +
+ + +
+ + {{'general, submit' | translate}} +
+
\ No newline at end of file diff --git a/Mohem/src/app/notification/work-list-replacement-roll/work-list-replacement-roll.component.scss b/Mohem/src/app/notification/work-list-replacement-roll/work-list-replacement-roll.component.scss new file mode 100644 index 00000000..d07c1ea2 --- /dev/null +++ b/Mohem/src/app/notification/work-list-replacement-roll/work-list-replacement-roll.component.scss @@ -0,0 +1,10 @@ +button.item-button.button.button-md.button-clear.button-clear-md { + background-color: transparent; +} + +.footer-button { + border-radius: 3px; + padding: 0 1.1em; + min-height: 45px; + min-width: 200px; +} diff --git a/Mohem/src/app/notification/work-list-replacement-roll/work-list-replacement-roll.component.spec.ts b/Mohem/src/app/notification/work-list-replacement-roll/work-list-replacement-roll.component.spec.ts new file mode 100644 index 00000000..d91108d5 --- /dev/null +++ b/Mohem/src/app/notification/work-list-replacement-roll/work-list-replacement-roll.component.spec.ts @@ -0,0 +1,27 @@ +import { CUSTOM_ELEMENTS_SCHEMA } from '@angular/core'; +import { async, ComponentFixture, TestBed } from '@angular/core/testing'; + +import { WorkListReplacementRollComponent } from './work-list-replacement-roll.component'; + +describe('WorkListReplacementRollComponent', () => { + let component: WorkListReplacementRollComponent; + let fixture: ComponentFixture; + + beforeEach(async(() => { + TestBed.configureTestingModule({ + declarations: [ WorkListReplacementRollComponent ], + schemas: [CUSTOM_ELEMENTS_SCHEMA], + }) + .compileComponents(); + })); + + beforeEach(() => { + fixture = TestBed.createComponent(WorkListReplacementRollComponent); + component = fixture.componentInstance; + fixture.detectChanges(); + }); + + it('should create', () => { + expect(component).toBeTruthy(); + }); +}); diff --git a/Mohem/src/app/notification/work-list-replacement-roll/work-list-replacement-roll.component.ts b/Mohem/src/app/notification/work-list-replacement-roll/work-list-replacement-roll.component.ts new file mode 100644 index 00000000..fcaf6bda --- /dev/null +++ b/Mohem/src/app/notification/work-list-replacement-roll/work-list-replacement-roll.component.ts @@ -0,0 +1,293 @@ +import { ModalController } from '@ionic/angular'; +import { WorklistService } from './../service/worklist.service'; +import { Component, OnInit } from '@angular/core'; +import { WorKListReplacmentEmployeeResponse } from '../models/ReplacmentEmployeeRes'; +import { WorkListReplacmentEmployeeRequest } from '../models/ReplacmentEmployeeReq'; +import { WorkListActionRequest } from '../models/NotificationActionReq'; +import { CommonService } from 'src/app/hmg-common/services/common/common.service'; +import { TranslatorService } from 'src/app/hmg-common/services/translator/translator.service'; +import { WorklistMainService } from '../service/work-list.main.service'; +import { ViewReplacementModalComponent } from '../view-replacement-modal/view-replacement-modal.component'; + +@Component({ + selector: 'app-work-list-replacement-roll', + templateUrl: './work-list-replacement-roll.component.html', + styleUrls: ['./work-list-replacement-roll.component.scss'], +}) +export class WorkListReplacementRollComponent implements OnInit { + P_SEARCH_EMPLOYEE_DISPLAY_NAME: string = ""; + P_SEARCH_EMAIL_ADDRESS: string = ""; + getPassActionMode: any; + selectedValue: any; + inputSearch: any; + selEmpName: any; + selectedUserInf: any; + userNote: any; + getPassNotificationDetails: any; + isAnswer: boolean = false; + pQuestion: string = ""; + selEmp: any; + P_PAGE_NUM: number; + P_PAGE_LIMIT: number; + ReplacementList: any = []; + searchBy: string = ""; + IsReachEnd: boolean = false; + ReplacmentListRes: WorKListReplacmentEmployeeResponse; + private WorkListReplacmentEmployeeObj: WorkListReplacmentEmployeeRequest = new WorkListReplacmentEmployeeRequest(); + private WorkListActionObj: WorkListActionRequest; + getpassResAttr: any = []; + + constructor(public worklistService: WorklistService, private cs: CommonService, private ts: TranslatorService, public workListMainService: WorklistMainService, public modalCtrl: ModalController) { + this.P_PAGE_NUM = 1; + this.P_PAGE_LIMIT = 50; + this.getPassActionMode = this.cs.sharedService.getSharedData('passActionMode'); + this.getPassNotificationDetails = this.cs.sharedService.getSharedData('passNotificationInfo'); + this.getpassResAttr = this.cs.sharedService.getSharedData('passResAttr'); + this.pQuestion = this.cs.sharedService.getSharedData('pQuestion'); + if (this.getPassActionMode == "ANSWER_INFO") { + this.isAnswer = true; + } + this.WorkListReplacmentEmployeeObj.P_PAGE_NUM = this.P_PAGE_NUM; + this.WorkListReplacmentEmployeeObj.P_PAGE_LIMIT = this.P_PAGE_LIMIT; + + this.WorkListActionObj = new WorkListActionRequest(); + this.WorkListActionObj.P_NOTIFICATION_ID = this.getPassNotificationDetails.NOTIFICATION_ID; + this.WorkListActionObj.P_FORWARD_TO_USER_NAME = ""; + this.WorkListActionObj.P_ACTION_MODE = ""; + this.WorkListActionObj.P_COMMENTS = ""; + this.WorkListActionObj.RespondAttributeList = this.getpassResAttr; + this.WorkListActionObj.P_APPROVER_INDEX = null; + } + + ngOnInit() { } + + getreplacmentemployee() { + this.ReplacementList = []; + this.IsReachEnd = false; + this.P_PAGE_NUM = 1; + if (this.inputSearch) { + switch (this.searchBy) { + case '1': { + + this.WorkListReplacmentEmployeeObj.P_SEARCH_EMPLOYEE_DISPLAY_NAME = this.inputSearch; + this.WorkListReplacmentEmployeeObj.P_SEARCH_USER_NAME = ""; + this.WorkListReplacmentEmployeeObj.P_SEARCH_EMAIL_ADDRESS = ""; + + break; + } + case '2': { + this.WorkListReplacmentEmployeeObj.P_SEARCH_USER_NAME = this.inputSearch; + this.WorkListReplacmentEmployeeObj.P_SEARCH_EMPLOYEE_DISPLAY_NAME = ""; + this.WorkListReplacmentEmployeeObj.P_SEARCH_EMAIL_ADDRESS = ""; + break; + } + case '3': { + this.WorkListReplacmentEmployeeObj.P_SEARCH_EMAIL_ADDRESS = this.inputSearch; + this.WorkListReplacmentEmployeeObj.P_SEARCH_USER_NAME = ""; + this.WorkListReplacmentEmployeeObj.P_SEARCH_EMPLOYEE_DISPLAY_NAME = ""; + break; + } + default: { + this.WorkListReplacmentEmployeeObj.P_SEARCH_USER_NAME = ""; + this.WorkListReplacmentEmployeeObj.P_SEARCH_EMPLOYEE_DISPLAY_NAME = ""; + this.WorkListReplacmentEmployeeObj.P_SEARCH_EMAIL_ADDRESS = ""; + break; + } + } + } else { + this.WorkListReplacmentEmployeeObj.P_SEARCH_USER_NAME = ""; + this.WorkListReplacmentEmployeeObj.P_SEARCH_EMPLOYEE_DISPLAY_NAME = ""; + this.WorkListReplacmentEmployeeObj.P_SEARCH_EMAIL_ADDRESS = ""; + } + // if(this.selectedValue =="1"){ + // this.WorkListReplacmentEmployeeObj.P_SEARCH_USER_NAME=this.inputSearch; + // this.WorkListReplacmentEmployeeObj.P_SEARCH_EMPLOYEE_DISPLAY_NAME=""; + // this.WorkListReplacmentEmployeeObj.P_SEARCH_EMAIL_ADDRESS=""; + // } + // else if(this.selectedValue =="2"){ + // this.WorkListReplacmentEmployeeObj.P_SEARCH_USER_NAME=""; + // this.WorkListReplacmentEmployeeObj.P_SEARCH_EMPLOYEE_DISPLAY_NAME=this.inputSearch; + // this.WorkListReplacmentEmployeeObj.P_SEARCH_EMAIL_ADDRESS=""; + // } + // else if(this.selectedValue =="3"){ + // this.WorkListReplacmentEmployeeObj.P_SEARCH_USER_NAME=""; + // this.WorkListReplacmentEmployeeObj.P_SEARCH_EMPLOYEE_DISPLAY_NAME=""; + // this.WorkListReplacmentEmployeeObj.P_SEARCH_EMAIL_ADDRESS=this.inputSearch; + // } + + this.worklistService.getReplacmentEmployeeList(this.WorkListReplacmentEmployeeObj). + subscribe((result: WorKListReplacmentEmployeeResponse) => { + this.handleWorkListReplacmentEmployeeResult(result); + }); + + }//End replacment Employee + + handleWorkListReplacmentEmployeeResult(result) { + + if (this.cs.validResponse(result)) { + // this.sharedData.setSharedData(result, WorKListResponse.SHARED_DATA); + if (this.cs.hasData(result.ReplacementList)) { + //this.ReplacmentListRes =result.ReplacementList; + this.ReplacementList = result.ReplacementList; + this.P_PAGE_NUM++; + let lastItemIndex = this.ReplacementList.length - 1; + if (result.ReplacementList[lastItemIndex]) { + let lastitem = result.ReplacementList[lastItemIndex]; + if (lastitem.NO_OF_ROWS == lastitem.ROW_NUM) { + this.IsReachEnd = true; + } else { + this.IsReachEnd = false; + } + } + } else { + let msg: string = this.ts.trPK('general', 'noResult'); + this.cs.presentAlert(msg); + } + // if(result.ReplacementList.length == 0){ + + // } + + // else if(result.ReplacementList != null) + // { + // this.ReplacmentListRes =result.ReplacementList; + // //open modal + // this.openModale(this.ReplacmentListRes); + + + // } // if result == null + + } // valid it + } + + getValueSelected(Value) { + + this.selectedValue = Value; + } + clear() { + this.selEmpName = ""; + this.selectedUserInf = null; + + } + async openModale(ReplacmentListRes) { + const modal = await this.modalCtrl.create({ + component: ViewReplacementModalComponent + }); + + modal.onDidDismiss() + .then((data) => { + if (data == "cancel" || data == "undefined") { + //this.selEmpName=""; + return; + } else { + this.selectedUserInf = data; + this.selEmpName = this.selectedUserInf.EMPLOYEE_DISPLAY_NAME; + } + }); + + return await modal.present(); + } + + submitAction() { + if (this.selEmp && this.isAnswer == false) { + this.selectedUserInf = this.ReplacementList[this.selEmp]; + + if (this.selectedUserInf && this.selectedUserInf.USER_NAME) { + if (this.userNote) { + this.WorkListActionObj.P_FORWARD_TO_USER_NAME = this.selectedUserInf.USER_NAME; + this.WorkListActionObj.P_ACTION_MODE = this.getPassActionMode; + this.WorkListActionObj.P_COMMENTS = this.userNote;// response Attr + + this.workListMainService.actionButton(this.WorkListActionObj). + subscribe((result: any) => { + this.handleApplayActionResult(result); + }); + } else { + let msg: string = this.ts.trPK("replacementRoll", "enterNote"); + this.cs.showErrorMessageDialog(() => { + }, this.ts.trPK('general', 'ok'), msg); + + } + } else { + let msg: string = this.ts.trPK("replacementRoll", "msg"); + this.cs.showErrorMessageDialog(() => { + }, this.ts.trPK('general', 'ok'), msg); + } + } else if (this.isAnswer == true) { + if (this.userNote) { + this.WorkListActionObj.P_FORWARD_TO_USER_NAME = null; + this.WorkListActionObj.P_ACTION_MODE = this.getPassActionMode; + this.WorkListActionObj.P_COMMENTS = this.userNote;// response Attr + + this.workListMainService.actionButton(this.WorkListActionObj). + subscribe((result: any) => { + this.handleApplayActionResult(result); + }); + } else { + let msg: string = this.ts.trPK("replacementRoll", "enterNote"); + this.cs.showErrorMessageDialog(() => { + }, this.ts.trPK('general', 'ok'), msg); + } + } else { + let msg: string = this.ts.trPK("replacementRoll", "msg"); + this.cs.showErrorMessageDialog(() => { + }, this.ts.trPK('general', 'ok'), msg); + } + } + + handleApplayActionResult(result) { + if (this.cs.validResponse(result)) { + // let msg=this.translate.translate("general.success"); + // this.cs.showAlert(msg); + // this.navCtrl.push("HomePage"); + this.cs.openNotificationPage(); + } // valid it + } + + // cancel() { + // this.navCtrl.pop(); + // } + + + doInfinite(infiniteScroll) { + if (!this.IsReachEnd) { + //const request =new WorkListActionRequest(); + // request.WorkListReplacmentEmployeeObj.P_SEARCH_USER_NAME=this.P_SEARCH_USER_NAME; + // request.WorkListReplacmentEmployeeObj.P_SEARCH_EMPLOYEE_DISPLAY_NAME=this.P_SEARCH_EMPLOYEE_DISPLAY_NAME; + // request.P_SEARCH_EMAIL_ADDRESS=this.P_SEARCH_EMAIL_ADDRESS; + this.WorkListReplacmentEmployeeObj.P_PAGE_NUM = this.P_PAGE_NUM; + this.WorkListReplacmentEmployeeObj.P_PAGE_LIMIT = this.P_PAGE_LIMIT; + // request.P_SELECTED_EMPLOYEE_NUMBER=this.selEmp; + + this.worklistService.getReplacmentEmployeeList(this.WorkListReplacmentEmployeeObj). + subscribe((result: any) => { + if (this.cs.validResponse(result)) { + if (this.cs.hasData(result.ReplacementList)) { + this.P_PAGE_NUM++; + result.ReplacementList.forEach(vr => { + if (vr.ROW_NUM == vr.NO_OF_ROWS) { + this.IsReachEnd = true; + } + else { + this.IsReachEnd = false; + } + this.ReplacementList.push(vr); + // this.pro.GetVacationRulesList.push(vr); + }); + } else { + this.IsReachEnd = true; + } + } + //this.P_PAGE_NUM++; + if (infiniteScroll) + infiniteScroll.complete(); + + + // console.log(resFlag); + }, (Error) => console.log(Error), () => infiniteScroll.complete()); + } else { + if (infiniteScroll) + infiniteScroll.complete(); + } + } + +} diff --git a/Mohem/src/assets/localization/i18n.json b/Mohem/src/assets/localization/i18n.json index d8e232d7..5f19c7b5 100644 --- a/Mohem/src/assets/localization/i18n.json +++ b/Mohem/src/assets/localization/i18n.json @@ -761,10 +761,6 @@ "en":"", "ar":"" }, - "noData":{ - "en":"There are no requests", - "ar":"لاتوجد طلبات" - }, "confirmation":{ "en":"Confirmation", "ar":"تأكيد" @@ -1420,6 +1416,36 @@ "ar":"لايمكن عرض هذا النوع من الملفات" } }, + "replacementRoll": { + "enterNote":{ + "en": "Enter a note", + "ar":"أدخل ملاحظة" + }, + "msg":{ + "en": "Select a replacement", + "ar":"اختيار بديل" + }, + "title":{ + "en": "Replacement Roll", + "ar":"استبدال لفة" + }, + "searchForReplacment":{ + "en": "Search for an employee", + "ar":"ابحث عن موظف" + }, + "searchBy":{ + "en": "Search by", + "ar":"البحث عن طريق" + }, + "question":{ + "en": "Question", + "ar":"سؤال" + }, + "answer":{ + "en": "Answer", + "ar":"جواب" + } + }, "worklist": { "view":{ "en": "View",