Merge branch 'master' into firebasex

MOE_DEV_NEW_TEMPORARY_DESIGN
umasoodch 6 years ago
commit 4c5153c69d

@ -121,7 +121,7 @@ export class HomeComponent implements OnInit {
this.absService.getAbsenceList(request).subscribe(
(result: any) => {
if (this.common.validResponse(result)) {
if (this.common.hasData(result.GetWorkList)) {
if (this.common.hasData(result.GetAbsenceTransactionList)) {
this.P_PAGE_NUM++;
result.GetAbsenceTransactionList.forEach(vr => {
if (vr.ROW_NUM == vr.NO_OF_ROWS) {

@ -103,7 +103,7 @@ export class HomeComponent implements OnInit {
if (this.cs.validResponse(result)) {
if (this.cs.hasData(result.GetEmployeeSubordinatesList)) {
this.empSubordinate = result.GetEmployeeSubordinatesList;
this.pageNum++;
this.infiniteRequest.P_PAGE_NUM= this.pageNum++;
let lastItemIndex = this.empSubordinate.length - 1;
if (result.GetEmployeeSubordinatesList[lastItemIndex]) {
let lastitem = result.GetEmployeeSubordinatesList[lastItemIndex];
@ -121,12 +121,14 @@ export class HomeComponent implements OnInit {
doInfinite(infiniteScroll) {
if (!this.IsReachEnd && this.infiniteRequest) {
this.infiniteRequest.P_PAGE_NUM = this.pageNum;
// this.infiniteRequest.P_PAGE_NUM = this.pageNum;
this.myTeamService.getEmployeeSubordinates(this.infiniteRequest).
subscribe((result: any) => {
if (this.cs.validResponse(result)) {
this.pageNum++;
if (this.cs.hasData(result.GetWorkList)) {
// this.pageNum++;
this.infiniteRequest.P_PAGE_NUM= this.pageNum++;
if (this.cs.hasData(result.GetEmployeeSubordinatesList)) {
result.GetEmployeeSubordinatesList.forEach(vr => {
if (vr.ROW_NUM == vr.NO_OF_ROWS) {
this.IsReachEnd = true;

@ -168,7 +168,8 @@ export class DetailsComponent implements OnInit {
if (this.common.validResponse(result)) {
if (this.common.hasData(result.GetEmployeeSubordinatesList)) {
this.empSubordinate = result.GetEmployeeSubordinatesList;
this.pageNum++;
// this.pageNum++;
this.infiniteRequest.P_PAGE_NUM= this.pageNum++;
let lastItemIndex = this.empSubordinate.length - 1;
if (result.GetEmployeeSubordinatesList[lastItemIndex]) {
let lastitem = result.GetEmployeeSubordinatesList[lastItemIndex];
@ -185,14 +186,15 @@ export class DetailsComponent implements OnInit {
}
doInfinite(infiniteScroll) {
if (!this.IsReachEnd && this.infiniteRequest) {
this.infiniteRequest.P_PAGE_NUM = this.pageNum;
// this.infiniteRequest.P_PAGE_NUM = this.pageNum;
this.myTeamService
.getEmployeeSubordinates(this.infiniteRequest)
.subscribe(
(result: any) => {
if (this.common.validResponse(result)) {
this.pageNum++;
if (this.common.hasData(result.GetWorkList)) {
this.infiniteRequest.P_PAGE_NUM= this.pageNum++;
if (this.common.hasData(result.GetEmployeeSubordinatesList)) {
result.GetEmployeeSubordinatesList.forEach(vr => {
if (vr.ROW_NUM == vr.NO_OF_ROWS) {
this.IsReachEnd = true;

@ -45,7 +45,7 @@
<ion-input [(ngModel)]="searchKey" placeholder="{{ts.trPK('general','enter')}}"></ion-input>
</ion-item>
</ion-list>
<div>
<!-- <div> -->
<ion-list no-lines *ngIf="empSubordinate && empSubordinate.length>0">
<ion-item no-border *ngFor="let subordinate of empSubordinate;let i=index" (click)="getDetails(i);">
<ion-avatar slot="start">
@ -57,10 +57,17 @@
<ion-badge slot="end" class="badge">{{subordinate.NUM_OF_SUBORDINATES}}</ion-badge>
</ion-item>
</ion-list>
<ion-infinite-scroll (ionInfinite)="doInfinite($event)">
<!-- </div> -->
<!-- <ion-infinite-scroll (ionInfinite)="doInfinite($event)">
<ion-infinite-scroll-content></ion-infinite-scroll-content>
</ion-infinite-scroll> -->
<ion-infinite-scroll (ionInfinite)="doInfinite($event)">
<ion-infinite-scroll-content></ion-infinite-scroll-content>
</ion-infinite-scroll>
</div>
</ion-infinite-scroll>
</ion-content>
<ion-footer *ngIf="isSearch">
<div class="centerDiv">

@ -1,11 +1,11 @@
import { Component, OnInit } from "@angular/core";
import { Component, OnInit, ViewChild } from "@angular/core";
import { Location } from "@angular/common";
import { TranslatorService } from "src/app/hmg-common/services/translator/translator.service";
import { CommonService } from "src/app/hmg-common/services/common/common.service";
import { AuthenticationService } from "src/app/hmg-common/services/authentication/authentication.service";
import { MenuResponse } from "src/app/hmg-common/services/menu/models/menu-response";
import { MyTeamService } from "../service/my-team.service";
import { ModalController } from "@ionic/angular";
import { ModalController, IonInfiniteScroll } from "@ionic/angular";
import { DetailsComponent } from '../details/details.component';
@Component({
selector: "app-home",
@ -13,6 +13,8 @@ import { DetailsComponent } from '../details/details.component';
styleUrls: ["./home.component.scss"]
})
export class HomeComponent implements OnInit {
@ViewChild(IonInfiniteScroll) infiniteScroll: IonInfiniteScroll;
pageNum: number = 1;
pageLimit: number = 50;
empSubordinate: any;
@ -54,6 +56,7 @@ export class HomeComponent implements OnInit {
if (!this.isSearch) this.getEmpSubordinate();
}
getEmpSubordinate() {
console.log("getEmpSubordinate my team home");
this.pageNum = 1;
this.IsReachEnd = false;
let searchEmpNum = "";
@ -115,8 +118,9 @@ export class HomeComponent implements OnInit {
handleEmpResult(result) {
if (this.common.validResponse(result)) {
if (this.common.hasData(result.GetEmployeeSubordinatesList)) {
this.empSubordinate = result.GetEmployeeSubordinatesList;
this.pageNum++;
this.infiniteRequest.P_PAGE_NUM++;
const lastItemIndex = this.empSubordinate.length - 1;
if (result.GetEmployeeSubordinatesList[lastItemIndex]) {
const lastitem = result.GetEmployeeSubordinatesList[lastItemIndex];
@ -131,8 +135,18 @@ export class HomeComponent implements OnInit {
}
}
}
doInfinite(infiniteScroll) {
doInfinite1(infiniteScroll) {
console.log("test");
if (!this.IsReachEnd && this.infiniteRequest) {
console.log("not ReachEnd");
this.infiniteRequest.P_PAGE_NUM = this.pageNum;
this.myTeamService
.getEmployeeSubordinates(this.infiniteRequest)
@ -140,7 +154,7 @@ export class HomeComponent implements OnInit {
(result: any) => {
if (this.common.validResponse(result)) {
this.pageNum++;
if (this.common.hasData(result.GetWorkList)) {
if (this.common.hasData(result.GetEmployeeSubordinatesList)) {
result.GetEmployeeSubordinatesList.forEach(vr => {
if (vr.ROW_NUM == vr.NO_OF_ROWS) {
this.IsReachEnd = true;
@ -169,6 +183,47 @@ export class HomeComponent implements OnInit {
}
}
}
doInfinite(infiniteScroll) {
//this.pageNum= this.pageNum + 1;
console.log("test doInfinite");
if (!this.IsReachEnd) {
console.log("test doInfinite not ReachEnd");
this.myTeamService
.getEmployeeSubordinates(this.infiniteRequest).subscribe(
(result: any) => {
if (this.common.validResponse(result)) {
this.infiniteRequest.P_PAGE_NUM++;
if (this.common.hasData(result.GetEmployeeSubordinatesList)) {
result.GetEmployeeSubordinatesList.forEach(element => {
if (element.ROW_NUM == element.NO_OF_ROWS) {
this.IsReachEnd = true;
} else {
this.IsReachEnd = false;
}
this.empSubordinate.push(element);
});
} // if list length >0
else {
this.IsReachEnd = true;
}
} // if response == 1
//this.pageNum++;
this.infiniteScroll.complete();
}
);
} else {
if (this.infiniteScroll)
this.infiniteScroll.complete();
}
} //end infiniteScroll
getDetails(index) {
this.common.sharedService.setSharedData(
this.empSubordinate[index],

@ -20,7 +20,7 @@ export class ItemHistoryComponent implements OnInit {
itemHistoryRes: any;
IsReachEnd: boolean = false;
P_PAGE_NUM: number = 1;
P_PAGE_LIMIT: number = 100;
P_PAGE_LIMIT: number = 50;
POItemHistoryReq:any;
getPassItemHistoreyList: any;
constructor(
@ -63,6 +63,7 @@ export class ItemHistoryComponent implements OnInit {
if (this.cs.hasData(result.GetPoItemHistoryList)) {
this.itemHistoryRes = result.GetPoItemHistoryList;
this.P_PAGE_NUM++;
this.POItemHistoryReq.P_PAGE_NUM = this.P_PAGE_NUM;
let lastItemIndex = this.itemHistoryRes.length - 1;
if (result.GetPoItemHistoryList[lastItemIndex]) {
let lastitem = result.GetPoItemHistoryList[lastItemIndex];
@ -84,7 +85,7 @@ export class ItemHistoryComponent implements OnInit {
subscribe((result: any) => {
if (this.cs.validResponse(result)) {
if (result.GetPoItemHistoryList != undefined) {
this.P_PAGE_NUM++;
this.POItemHistoryReq.P_PAGE_NUM=this.P_PAGE_NUM++;
(result.GetPoItemHistoryList).forEach(element => {
if (element.ROW_NUM == element.NO_OF_ROWS) {
this.IsReachEnd = true;

@ -25,6 +25,7 @@ export class QutationAnalysisComponent implements OnInit {
getPassPOHeaderID: any;
getPassItemHistoreyList: any;
getQutationAnalysis:any;
doInfiniteReq: any;
constructor(public worklistMainService: WorklistMainService,
private cs: CommonService,
private ts: TranslatorService,
@ -59,8 +60,9 @@ console.log("getPassPOItemID: "+this.getPassPOHeaderID);
const request = new QuotationAnalysisRequest();
request.P_ITEM_ID=parseInt(itemID);
request.P_PO_HEADER_ID=headerID;
request.P_PAGE_LIMIT=100;
request.P_PAGE_NUM=1;
request.P_PAGE_LIMIT=1;
request.P_PAGE_NUM=50;
this.doInfiniteReq=request;
this.worklistMainService.getQutationAnalysis(request).
subscribe((result: QuotationAnalysisResponse) => {
this.handleQutationAnalysisResult(result);
@ -75,7 +77,7 @@ console.log("getPassPOItemID: "+this.getPassPOHeaderID);
//set sheard data
//
this.getQutationAnalysis = result.GetQuotationAnalysisList;
this.P_PAGE_NUM++;
this.doInfiniteReq.P_PAGE_NUM++;
let lastItemIndex = this.getQutationAnalysis.length - 1;
if (result.GetQuotationAnalysisList[lastItemIndex]) {
let lastitem = result.GetQuotationAnalysisList[lastItemIndex];
@ -93,12 +95,13 @@ console.log("getPassPOItemID: "+this.getPassPOHeaderID);
doInfinite(infiniteScroll) {
if (!this.IsReachEnd) {
this.getQutationAnalysis.P_PAGE_NUM = this.P_PAGE_NUM;
this.worklistMainService.getQutationAnalysis(this.getQutationAnalysis).
// this.getQutationAnalysis.P_PAGE_NUM = this.P_PAGE_NUM;
this.worklistMainService.getQutationAnalysis(this.doInfiniteReq).
subscribe((result: any) => {
if (this.cs.validResponse(result)) {
if (result.GetQuotationAnalysisList != undefined) {
this.P_PAGE_NUM++;
this.doInfiniteReq.P_PAGE_NUM = this.P_PAGE_NUM;
(result.GetQuotationAnalysisList).forEach(element => {
if (element.ROW_NUM == element.NO_OF_ROWS) {
this.IsReachEnd = true;

@ -46,7 +46,8 @@ export class WorkListActionHistoryComponent implements OnInit {
if (this.cs.validResponse(result)) {
if (this.cs.hasData(result.GetActionHistoryList)) {
this.actionHistoryRes = result.GetActionHistoryList;
this.P_PAGE_NUM++;
// this.P_PAGE_NUM++;
this.WorkListActionHistoryObj.P_PAGE_NUM++;
let lastItemIndex = this.actionHistoryRes.length - 1;
if (result.GetActionHistoryList[lastItemIndex]) {
let lastitem = result.GetActionHistoryList[lastItemIndex];
@ -75,12 +76,14 @@ export class WorkListActionHistoryComponent implements OnInit {
doInfinite(infiniteScroll) {
if (!this.IsReachEnd) {
this.WorkListActionHistoryObj.P_PAGE_NUM = this.P_PAGE_NUM;
// 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++;
this.WorkListActionHistoryObj.P_PAGE_NUM = this.P_PAGE_NUM;
(result.GetActionHistoryList).forEach(element => {
if (element.ROW_NUM == element.NO_OF_ROWS) {
this.IsReachEnd = true;

@ -665,6 +665,7 @@ export class WorklistMainMRComponent implements OnInit {
if (this.common.hasData(result.GetActionHistoryList)) {
this.actionHistoryRes = result.GetActionHistoryList;
this.P_PAGE_NUM++;
this.WorkListActionHistoryObj.P_PAGE_NUM = this.P_PAGE_NUM;
let lastItemIndex = this.actionHistoryRes.length - 1;
if (result.GetActionHistoryList[lastItemIndex]) {
let lastitem = result.GetActionHistoryList[lastItemIndex];
@ -700,12 +701,13 @@ export class WorklistMainMRComponent implements OnInit {
console.log("doInfinite action history MR");
if (!this.IsReachEnd) {
this.WorkListActionHistoryObj.P_PAGE_NUM = this.P_PAGE_NUM;
this.worklistService.getActionHistory(this.WorkListActionHistoryObj).
subscribe((result: any) => {
if (this.common.validResponse(result)) {
if (result.GetActionHistoryList != undefined) {
this.P_PAGE_NUM++;
this.WorkListActionHistoryObj.P_PAGE_NUM = this.P_PAGE_NUM;
(result.GetActionHistoryList).forEach(element => {
if (element.ROW_NUM == element.NO_OF_ROWS) {
this.IsReachEnd = true;
@ -783,12 +785,12 @@ export class WorklistMainMRComponent implements OnInit {
doInfiniteNotificationBody(infiniteScroll) {
console.log("doInfiniteNotificationBody MR");
if (!this.IsReachEnd) {
this.WorkListBodyObj.P_PAGE_NUM = this.P_PAGE_NUM;
this.worklistMainService.getMONotificationBody(this.WorkListActionHistoryObj).
subscribe((result: any) => {
if (this.common.validResponse(result)) {
if (result.GetMoNotificationBodyList != undefined) {
this.P_PAGE_NUM++;
this.WorkListBodyObj.P_PAGE_NUM = this.P_PAGE_NUM;
(result.GetMoNotificationBodyList).forEach(element => {
if (element.ROW_NUM == element.NO_OF_ROWS) {
this.IsReachEnd = true;
@ -820,12 +822,13 @@ export class WorklistMainMRComponent implements OnInit {
if (!this.IsReachEnd) {
console.log("this.IsReachEnd"+ this.IsReachEnd);
this.WorkListBodyObj.P_PAGE_NUM = this.P_PAGE_NUM;
this.worklistMainService.getMONotificationBody(this.WorkListBodyObj).
subscribe((result: any) => {
if (this.common.validResponse(result)) {
if (result.GetMoNotificationBodyList != undefined) {
this.P_PAGE_NUM++;
this.WorkListBodyObj.P_PAGE_NUM = this.P_PAGE_NUM;
(result.GetMoNotificationBodyList).forEach(element => {
if (element.ROW_NUM == element.NO_OF_ROWS) {
this.IsReachEnd = true;
@ -855,12 +858,13 @@ export class WorklistMainMRComponent implements OnInit {
console.log("doInfinite action history MR");
if (!this.IsReachEnd) {
this.WorkListActionHistoryObj.P_PAGE_NUM = this.P_PAGE_NUM;
this.worklistService.getActionHistory(this.WorkListActionHistoryObj).
subscribe((result: any) => {
if (this.common.validResponse(result)) {
if (result.GetActionHistoryList != undefined) {
this.P_PAGE_NUM++;
this.WorkListActionHistoryObj.P_PAGE_NUM = this.P_PAGE_NUM;
(result.GetActionHistoryList).forEach(element => {
if (element.ROW_NUM == element.NO_OF_ROWS) {
this.IsReachEnd = true;

@ -690,6 +690,7 @@ export class WorklistMainPoComponent implements OnInit {
if (this.common.hasData(result.GetActionHistoryList)) {
this.actionHistoryRes = result.GetActionHistoryList;
this.P_PAGE_NUM++;
this.WorkListActionHistoryObj.P_PAGE_NUM = this.P_PAGE_NUM;
let lastItemIndex = this.actionHistoryRes.length - 1;
if (result.GetActionHistoryList[lastItemIndex]) {
let lastitem = result.GetActionHistoryList[lastItemIndex];
@ -724,12 +725,13 @@ export class WorklistMainPoComponent implements OnInit {
doInfinite(infiniteScroll) {
console.log("doInfinite action history");
if (!this.IsReachEnd) {
this.WorkListActionHistoryObj.P_PAGE_NUM = this.P_PAGE_NUM;
this.worklistService.getActionHistory(this.WorkListActionHistoryObj).
subscribe((result: any) => {
if (this.common.validResponse(result)) {
if (result.GetActionHistoryList != undefined) {
this.P_PAGE_NUM++;
this.WorkListActionHistoryObj.P_PAGE_NUM = this.P_PAGE_NUM;
(result.GetActionHistoryList).forEach(element => {
if (element.ROW_NUM == element.NO_OF_ROWS) {
this.IsReachEnd = true;
@ -867,12 +869,12 @@ export class WorklistMainPoComponent implements OnInit {
if (!this.IsReachEnd) {
console.log("this.IsReachEnd"+ this.IsReachEnd);
this.WorkListBodyObj.P_PAGE_NUM = this.P_PAGE_NUM;
this.worklistMainService.getPONotificationBody(this.WorkListBodyObj).
subscribe((result: any) => {
if (this.common.validResponse(result)) {
if (result.GetPoNotificationBodyList != undefined) {
this.P_PAGE_NUM++;
this.WorkListBodyObj.P_PAGE_NUM = this.P_PAGE_NUM;
(result.GetPoNotificationBodyList).forEach(element => {
if (element.ROW_NUM == element.NO_OF_ROWS) {
this.IsReachEnd = true;
@ -898,17 +900,17 @@ export class WorklistMainPoComponent implements OnInit {
// infiniteScroll.target.complete();
}
}//end infiniteScroll
loadMoreActionHistory() {
console.log("doInfinite action history MR");
if (!this.IsReachEnd) {
this.WorkListActionHistoryObj.P_PAGE_NUM = this.P_PAGE_NUM;
this.worklistService.getActionHistory(this.WorkListActionHistoryObj).
subscribe((result: any) => {
if (this.common.validResponse(result)) {
if (result.GetActionHistoryList != undefined) {
this.P_PAGE_NUM++;
this.WorkListActionHistoryObj.P_PAGE_NUM = this.P_PAGE_NUM;
(result.GetActionHistoryList).forEach(element => {
if (element.ROW_NUM == element.NO_OF_ROWS) {
this.IsReachEnd = true;

@ -810,12 +810,13 @@ export class WorklistMainPRComponent implements OnInit {
if (!this.IsReachEnd) {
console.log("this.IsReachEnd" + this.IsReachEnd);
this.WorkListBodyObj.P_PAGE_NUM = this.P_PAGE_NUM;
this.worklistMainService.getPRNotificationBody(this.WorkListBodyObj).
subscribe((result: any) => {
if (this.common.validResponse(result)) {
if (result.GetPrNotificationBodyList != undefined) {
this.P_PAGE_NUM++;
this.WorkListBodyObj.P_PAGE_NUM = this.P_PAGE_NUM;
(result.GetPrNotificationBodyList).forEach(element => {
if (element.ROW_NUM == element.NO_OF_ROWS) {
this.IsReachEnd = true;
@ -845,12 +846,12 @@ export class WorklistMainPRComponent implements OnInit {
console.log("doInfinite action history MR");
if (!this.IsReachEnd) {
this.WorkListActionHistoryObj.P_PAGE_NUM = this.P_PAGE_NUM;
this.worklistService.getActionHistory(this.WorkListActionHistoryObj).
subscribe((result: any) => {
if (this.common.validResponse(result)) {
if (result.GetActionHistoryList != undefined) {
this.P_PAGE_NUM++;
this.WorkListActionHistoryObj.P_PAGE_NUM = this.P_PAGE_NUM;
(result.GetActionHistoryList).forEach(element => {
if (element.ROW_NUM == element.NO_OF_ROWS) {
this.IsReachEnd = true;

@ -30,6 +30,9 @@ export class HomeComponent implements OnInit {
defultSelected: any;
IsReachEnd: any;
private deductionReq: DeductionRequest;
doinfiniteDedReq:any;
doinfinitEarReq:any;
@ViewChild(IonInfiniteScroll) infiniteScroll: IonInfiniteScroll;
constructor(
@ -85,7 +88,6 @@ export class HomeComponent implements OnInit {
// P_PAGE_NUM: this.P_PAGE_NUM,
// P_PAGE_LIMIT: this.P_PAGE_LIMIT
};
this.payslipService.getPayslip(request, ()=> {} , this.ts.trPK('general', 'retry')).subscribe((result)=>
{
this.handleRespondGetPayslipResult(result);
@ -180,7 +182,7 @@ getEarings(ActionContextID){
P_PAGE_NUM:1,
P_PAGE_LIMIT:100
}
this.doinfinitEarReq=request;
this.payslipService.getEarings(request, ()=> {} , this.ts.trPK('general', 'retry')).subscribe((result)=>
{
this.handleGetEaringsResult(result);
@ -207,7 +209,7 @@ getDeduction(ActionContextID){
// this.deductionReq.P_ACTION_CONTEXT_ID=ActionContextID;
// this.deductionReq.P_PAGE_NUM=1;
// this.deductionReq.P_PAGE_LIMIT=100;
this.doinfiniteDedReq=request;
this.payslipService.getDeduction(request, ()=> {} , this.ts.trPK('general', 'retry')).subscribe((result)=>
{
@ -227,10 +229,10 @@ getDeduction(ActionContextID){
//this.pageNum= this.pageNum + 1;
if (!this.IsReachEnd) {
this.payslipService.getDeduction(this.deductionReq).subscribe(
this.payslipService.getDeduction(this.doinfiniteDedReq).subscribe(
(result: any) => {
if (this.common.validResponse(result)) {
this.deductionReq.P_PAGE_NUM++;
this.doinfiniteDedReq.P_PAGE_NUM++;
if (this.common.hasData(result.GetDeductionsList)) {
result.GetDeductionsList.forEach(element => {
if (element.ROW_NUM == element.NO_OF_ROWS) {
@ -259,10 +261,10 @@ getDeduction(ActionContextID){
//this.pageNum= this.pageNum + 1;
if (!this.IsReachEnd) {
this.payslipService.getEarings(this.deductionReq).subscribe(
this.payslipService.getEarings(this.doinfinitEarReq).subscribe(
(result: any) => {
if (this.common.validResponse(result)) {
this.deductionReq.P_PAGE_NUM++;
this.doinfinitEarReq.P_PAGE_NUM++;
if (this.common.hasData(result.GetEarningsList)) {
result.GetEarningsList.forEach(element => {
if (element.ROW_NUM == element.NO_OF_ROWS) {

@ -37,7 +37,7 @@ export class HomeComponent implements OnInit {
constructor(public vacationRuleService: VacationRuleServiceService, public ts: TranslatorService, public cs: CommonService, private router: Router) {
this.P_PAGE_NUM = 1;
this.P_PAGE_LIMIT = 100;
this.P_PAGE_LIMIT = 1;
//this.button = new ButtonInput('btnSubmit', 'Submit', 'containerDiv', 'Y');
// this.dateTime = new DateTimeInput('Start Date', 'SDate', '', 'containerDiv', 'Y', 'Y', 'Y');
@ -98,6 +98,7 @@ export class HomeComponent implements OnInit {
}, this.ts.trPK('general', 'retry')).subscribe((result) => {
if (this.cs.validResponse(result)) {
this.GetVacationRulesList = result.GetVacationRulesList;
this.P_PAGE_NUM++;
} else {
this.cs.presentAlert(result.ErrorEndUserMessage);
}
@ -168,13 +169,14 @@ export class HomeComponent implements OnInit {
let request: VacationRuleRequest = new VacationRuleRequest();
request.P_PAGE_LIMIT = this.P_PAGE_LIMIT;
request.P_PAGE_NUM = this.P_PAGE_NUM;
if (!this.IsReachEnd) {
this.vacationRuleService.getVacationRule(request, () => {
// this.getVacationRules();
}, this.ts.trPK('general', 'retry')).subscribe((result) => {
if (this.cs.validResponse(result)) {
request.P_PAGE_NUM++;
this.P_PAGE_NUM++;
request.P_PAGE_NUM = this.P_PAGE_NUM;
if (this.cs.hasData(result.GetVacationRulesList)) {
result.GetVacationRulesList.forEach(element => {
if (element.ROW_NUM == element.NO_OF_ROWS) {

Loading…
Cancel
Save