Merge branch 'MOE_DEV' into SRCA_DEV

# Conflicts:
#	Mohem/src/app/hmg-common/services/connector/connector.service.ts
#	Mohem/src/app/payslip/home/home.component.ts
SRCA_DEV
umasoodch 3 years ago
commit 2d1867d0b8

@ -1289,6 +1289,15 @@ export class AddEitComponent implements OnInit {
) as HTMLSelectElement;
let val = x.dataset.colmText;
textValue = x.value;
// below code is to handle fields which are hidden and required and has to have default value.
// So if colmText is empty then get value from value attribute which is already been set initially
if (this.eitResponse[i].DISPLAY_FLAG == "N" && this.eitResponse[i].REQUIRED_FLAG == "Y" && !val) {
const attributeValue = x.getAttribute('value');
val = attributeValue ? attributeValue : '';
textValue = val;
}
if (this.eitResponse[i].REQUIRED_FLAG == "Y" && !val) {
x.classList.add("requiredClassElm");
//this.common.showRequiredMsg();

@ -27,11 +27,11 @@ export class ConnectorService {
public static retryTimes = 0;
public static timeOut = 180 * 1000;
public static host = 'https://uat.hmgwebservices.com/';
// public static host = 'https://uat.hmgwebservices.com/';
// public static host = 'https://hmgwebservices.com/';
// public static host = 'http://riyt-mohemm1:1010/' //MOE
// public static host = 'http://riyt-mohemm1.mopm.gov.sa:1010/'
// public static host = 'http://mohemm-app-test.srca.org.sa:1010/'
// public static host = 'http://riyt-mohemm1:1010/' //MOE inside
// public static host = 'http://riyt-mohemm1.mopm.gov.sa:1010/' // MOE vpn
public static host = 'http://mohemm-app-test.srca.org.sa:1010/' // SRCA
// public static host = 'http://10.254.212.41:1010/'

@ -47,18 +47,18 @@
</ion-slide>
</ion-slides>
<!-- <ion-row class="attendance-module" *ngIf="i == 0">
<ion-col [size]="8">
<h3>{{'home,monthly-attendance' | translate}}</h3>
<span>{{'home,monthly-time-sheet-view' | translate}}</span>
<ion-button (click)="openTimeCard()">
{{'home,view-detail' | translate}}
</ion-button>
</ion-col>
<ion-col [size]="4">
<img src="assets/icon/new-design/attendance_button_icon.png"/>
</ion-col>
</ion-row> -->
<ion-row class="attendance-module" *ngIf="i == 0">
<ion-col [size]="8">
<h3>{{'userProfile,personal-informaion' | translate}}</h3>
<span>{{'home,monthly-time-sheet-view' | translate}}</span>
<ion-button (click)="openPersonalInfo()">
{{'home,view-detail' | translate}}
</ion-button>
</ion-col>
<ion-col [size]="4">
<img src="assets/icon/new-design/profile.png"/>
</ion-col>
</ion-row>
</ion-row>
<!-- <ion-row *ngIf="showStaticServices">

@ -12,10 +12,9 @@
<div class="result-graph" >
<div class="user-info">
<div class="user-image-container">
<div (click)="setFavorite(employee)">
<div (click)="setFavorite(employee)" style="visibility: hidden !important;">
<img *ngIf="!isFavorite" [ngClass]="direction == 'en' ? 'favIcon':'favIcon-ar' " src="../assets/imgs/fav.svg">
<img *ngIf="isFavorite" [ngClass]="direction == 'en' ? 'favIcon':'favIcon-ar' " src="../assets/imgs/favFilled.svg">
<!-- <ion-col><img src="../assets/imgs/fav filled.svg"></ion-col> -->
</div>
<div class="user-image">
<img class="img" [src]="employee.EMPLOYEE_IMAGE ? 'data:image/png;base64,'+employee.EMPLOYEE_IMAGE : '../assets/imgs/profile.png'" alt="Team Member Image"/>
@ -52,7 +51,7 @@
<ion-segment
(ionChange)="segmentChanged($event)"
[value]="activeSegment">
<ion-col [size]="3">
<ion-col [size]="4">
<ion-col>
<ion-segment-button
value="About"
@ -65,7 +64,7 @@
<span class="btnTitle">{{ts.trPK('myTeam','profile-details')}}</span>
</ion-col>
</ion-col>
<ion-col [size]="3" (click)="getMenuEntries(employee)">
<ion-col [size]="4" (click)="getMenuEntries(employee)">
<ion-col>
<ion-segment-button
value="create-request"
@ -75,18 +74,17 @@
</ion-col>
<ion-col > <span class="btnTitle">{{ts.trPK('vacation-rule','create-request')}}</span></ion-col>
</ion-col>
<ion-col [size]="3">
<!-- <ion-col [size]="3">
<ion-col>
<ion-segment-button
value="Attendance"
[ngClass]="activeSegment == 'Attendance' ? 'active-Segment' : 'normal-Segment'" >
<!-- <ion-label>{{ts.trPK('attendance','attendance')}}</ion-label> -->
<img class="imgSize" src="../assets/imgs/view-attendance.svg">
</ion-segment-button>
</ion-col>
<ion-col> <span class="btnTitle">{{ts.trPK('myTeam','view-attendence')}} </span></ion-col>
</ion-col>
<ion-col [size]="3">
</ion-col> -->
<ion-col [size]="4">
<ion-col>
<ion-segment-button
value="TeamMembers"

@ -51,6 +51,7 @@ export class HomeComponent implements OnInit {
slidesPerView: 1,
autoplay: true
};
public userData: any;
@ViewChild(IonInfiniteScroll) infiniteScroll: IonInfiniteScroll;
public options = {
@ -111,6 +112,8 @@ export class HomeComponent implements OnInit {
// console.log(" this.selMenu" + this.selMenu);
this.userData =this.common.sharedService.getSharedData(AuthenticatedUser.SHARED_DATA,false);
this.getPayslip();
// this.getProfile();
}
@ -167,16 +170,11 @@ export class HomeComponent implements OnInit {
// }
getPayslip() {
// this.selEmp ="13777";
console.log("this.selEmp????????" + this.selEmp)
this.respID = -999;
getPayslip(){
this.respID=-999;
const request = {
P_SELECTED_EMPLOYEE_NUMBER: this.selEmp,//'125346',//this.selEmp,
P_MENU_TYPE: "E",// 'E',//this.selMenu.List_Menu.MENU_TYPE,
P_SELECTED_EMPLOYEE_NUMBER: this.userData.EMPLOYEE_NUMBER,//'125346',//this.selEmp,
P_MENU_TYPE:"E",// 'E',//this.selMenu.List_Menu.MENU_TYPE,
P_SELECTED_RESP_ID: this.respID//"-999" //this.respID,
// P_PAGE_NUM: this.P_PAGE_NUM,
// P_PAGE_LIMIT: this.P_PAGE_LIMIT

@ -23,7 +23,6 @@ export class PayslipService {
public getPayslip(PayslipRequest: any , onError?: any,errorLabel?: string): Observable<any> {
const request = PayslipRequest;
this.authService.authenticateRequest(request);
request.P_SELECTED_EMPLOYEE_NUMBER = request.UserName;
return this.api.post(PayslipService.getPayslip, request, onError, errorLabel);
}
public getSummeryOFPayment(PayslipRequest: any, onError?: any,errorLabel?: string): Observable<any> {

@ -14,6 +14,7 @@ import { SelectInput } from 'src/app/uI-elements/select.input';
import { TextInput } from 'src/app/uI-elements/text.input';
import { TimeInput } from 'src/app/uI-elements/time.input';
import { ReportServiceService } from '../report-service.service';
import { AuthenticatedUser } from "src/app/hmg-common/services/authentication/models/authenticated-user";
@Component({
selector: 'app-concurrent-report',
@ -42,6 +43,8 @@ export class ConcurrentReportComponent implements OnInit {
selMenu: MenuResponse;
public functionName;
public userData: any;
public headerTitle;
getPassdirfromNotifiPage: boolean = false;
@ -54,6 +57,7 @@ export class ConcurrentReportComponent implements OnInit {
constructor(public cs: CommonService, private elementRef: ElementRef, public reports: ReportServiceService, public ts: TranslatorService, public eitService: EitService) { }
ngOnInit() {
this.userData =this.cs.sharedService.getSharedData(AuthenticatedUser.SHARED_DATA,false);
this.getPassdirfromNotifiPage = this.cs.sharedService.getSharedData('dirfromNotificationPage');
this.selectedMenu = this.cs.sharedService.getSharedData(MenuResponse.SELECTED_MENU, false);
this.getConcurrentProgram();
@ -65,7 +69,8 @@ export class ConcurrentReportComponent implements OnInit {
getConcurrentProgram() {
this.cs.startLoading();
this.reports.getConcurrentProgram({
P_REQUEST_GROUP_ID: this.selectedMenu.REQUEST_GROUP_ID
P_REQUEST_GROUP_ID: this.selectedMenu.REQUEST_GROUP_ID,
P_SELECTED_EMPLOYEE_NUMBER: this.userData.EMPLOYEE_NUMBER
}, () => { }, this.ts.trPK('general', 'retry')).subscribe((response) => {
this.cs.stopLoading();
this.programList = response.GetConcurrentProgramsList;
@ -75,7 +80,8 @@ export class ConcurrentReportComponent implements OnInit {
getCppDiffStructure(programList) {
this.cs.startLoading();
this.reports.getCPPDiffStructure({
P_DESC_FLEX_NAME: programList.CONCURRENT_PROGRAM_NAME
P_DESC_FLEX_NAME: programList.CONCURRENT_PROGRAM_NAME,
P_SELECTED_EMPLOYEE_NUMBER: this.userData.EMPLOYEE_NUMBER
}, () => { }, this.ts.trPK('general', 'retry')).subscribe((response) => {
this.cs.stopLoading();
this.handleDiffStructure(response);
@ -923,7 +929,7 @@ export class ConcurrentReportComponent implements OnInit {
this.eitRequest = new EitRequest();
const list: any = this.getElementsValues();
this.eitRequest.EITTransactionTBL = list;
this.eitRequest.P_SELECTED_EMPLOYEE_NUMBER = this.selEmp;
this.eitRequest.P_SELECTED_EMPLOYEE_NUMBER = this.userData.EMPLOYEE_NUMBER;
this.eitRequest.P_MENU_TYPE = this.selectedMenu.MENU_TYPE;
this.eitRequest.P_SELECTED_RESP_ID = -999;// this.selectedMenu.RESP_ID; // this.selMenu.List_Menu.RESP_ID,//-999,
this.eitRequest.P_FUNCTION_NAME = this.functionName;
@ -956,6 +962,8 @@ export class ConcurrentReportComponent implements OnInit {
request.P_SELECTED_RESP_ID = -999;
request.P_FUNCTION_NAME = this.functionName;
request.P_DESC_FLEX_NAME = this.template.CONCURRENT_PROGRAM_NAME;
request.P_SELECTED_EMPLOYEE_NUMBER = this.userData.EMPLOYEE_NUMBER;
this.reports.getTransaction(this.eitRequest, {}, this.ts.trPK('general', 'retry')).subscribe((result: any) => {
this.cs.stopLoading();

@ -23,7 +23,7 @@ export class ReportServiceService {
getConcurrentProgram(request, onError, errorLabel) {
this.authService.authenticateRequest(request);
request.P_SELECTED_EMPLOYEE_NUMBER = request.UserName;
// request.P_SELECTED_EMPLOYEE_NUMBER = request.UserName;
return this.con.postNoLoad(
ReportServiceService.GET_CONCURRENT_PROGRAM,
request,
@ -33,7 +33,7 @@ export class ReportServiceService {
}
getCPPDiffStructure(request, onError, errorLabel) {
this.authService.authenticateRequest(request);
request.P_SELECTED_EMPLOYEE_NUMBER = request.UserName;
// request.P_SELECTED_EMPLOYEE_NUMBER = request.UserName;
return this.con.postNoLoad(
ReportServiceService.GET_CPP_DIFF_STRUCTURE,
request,
@ -43,7 +43,7 @@ export class ReportServiceService {
}
submitTransaction(request, onError, errorLabel) {
this.authService.authenticateRequest(request);
request.P_SELECTED_EMPLOYEE_NUMBER = request.UserName;
// request.P_SELECTED_EMPLOYEE_NUMBER = request.UserName;
return this.con.postNoLoad(
ReportServiceService.SUBMIT_CPP_REQUEST,
request,
@ -53,7 +53,7 @@ export class ReportServiceService {
}
getTransaction(request, onError, errorLabel) {
this.authService.authenticateRequest(request);
request.P_SELECTED_EMPLOYEE_NUMBER = request.UserName;
// request.P_SELECTED_EMPLOYEE_NUMBER = request.UserName;
return this.con.postNoLoad(
ReportServiceService.SUBMIT_CPP_TRANSACTION,
request,
@ -64,7 +64,7 @@ export class ReportServiceService {
getCppOutput(request, onError, errorLabel) {
this.authService.authenticateRequest(request);
request.P_SELECTED_EMPLOYEE_NUMBER = request.UserName;
// request.P_SELECTED_EMPLOYEE_NUMBER = request.UserName;
return this.con.postNoLoad(
ReportServiceService.GET_CCP_OUTPUT,
request,

@ -6,6 +6,8 @@ import { MenuResponse } from 'src/app/hmg-common/services/menu/models/menu-respo
import { TranslatorService } from 'src/app/hmg-common/services/translator/translator.service';
import { ReportServiceService } from '../report-service.service';
import { FileOpener } from '@ionic-native/file-opener/ngx';
import { AuthenticatedUser } from "src/app/hmg-common/services/authentication/models/authenticated-user";
@Component({
selector: 'app-transaction-list',
templateUrl: './transaction-list.component.html',
@ -16,10 +18,13 @@ export class TransactionListComponent implements OnInit {
selectedMenu: any;
template: any;
direction: any;
public userData: any;
constructor(public cs: CommonService, private elementRef: ElementRef, public reports: ReportServiceService, public ts: TranslatorService, private platform: Platform, private file: File, private opener: FileOpener,
) { }
ngOnInit() {
this.userData =this.cs.sharedService.getSharedData(AuthenticatedUser.SHARED_DATA,false);
this.selectedMenu = this.cs.sharedService.getSharedData(MenuResponse.SELECTED_MENU, false);
this.transactionList = this.cs.sharedService.getSharedData(ReportServiceService.TRANSACTION_LIST, false);
this.template = this.cs.sharedService.getSharedData(ReportServiceService.TEMPLATE, false);
@ -94,6 +99,7 @@ export class TransactionListComponent implements OnInit {
request.P_SELECTED_RESP_ID = -999;
request.P_FUNCTION_NAME = this.selectedMenu.FUNCTION_NAME;
request.P_DESC_FLEX_NAME = this.template.CONCURRENT_PROGRAM_NAME;
request.P_SELECTED_EMPLOYEE_NUMBER = this.userData.EMPLOYEE_NUMBER;
this.reports.getTransaction(request, {}, this.ts.trPK('general', 'retry')).subscribe((result: any) => {
this.cs.stopLoading();

@ -2,10 +2,12 @@ import { Component, ElementRef, OnInit } from '@angular/core';
import { FileOpener } from '@ionic-native/file-opener/ngx';
import { File } from '@ionic-native/file/ngx';
import { Platform } from '@ionic/angular';
import { userInfo } from 'os';
import { CommonService } from 'src/app/hmg-common/services/common/common.service';
import { MenuResponse } from 'src/app/hmg-common/services/menu/models/menu-response';
import { TranslatorService } from 'src/app/hmg-common/services/translator/translator.service';
import { ReportServiceService } from '../report-service.service';
import { AuthenticatedUser } from "src/app/hmg-common/services/authentication/models/authenticated-user";
@Component({
selector: 'app-transactions',
@ -18,6 +20,7 @@ export class TransactionsComponent implements OnInit {
template: any;
direction: any;
programList: any = [];
public userData: any;
constructor(public cs: CommonService, private elementRef: ElementRef, public reports: ReportServiceService, public ts: TranslatorService, private platform: Platform, private file: File, private opener: FileOpener,
) { }
@ -25,10 +28,12 @@ export class TransactionsComponent implements OnInit {
ngOnInit() {
this.selectedMenu = this.cs.sharedService.getSharedData(MenuResponse.SELECTED_MENU, false);
this.userData =this.cs.sharedService.getSharedData(AuthenticatedUser.SHARED_DATA,false);
// this.transactionList = this.cs.sharedService.getSharedData(ReportServiceService.TRANSACTION_LIST, false);
//this.template = this.cs.sharedService.getSharedData(ReportServiceService.TEMPLATE, false);
this.direction = TranslatorService.getCurrentDirection();
this.getConcurrentProgram();
}
getDate(date) {
return this.cs.evaluteDate(date);
@ -99,6 +104,7 @@ export class TransactionsComponent implements OnInit {
request.P_SELECTED_RESP_ID = -999;
request.P_FUNCTION_NAME = this.selectedMenu.FUNCTION_NAME;
request.P_DESC_FLEX_NAME = this.template.CONCURRENT_PROGRAM_NAME;
request.P_SELECTED_EMPLOYEE_NUMBER = this.userData.EMPLOYEE_NUMBER;
this.reports.getTransaction(request, {}, this.ts.trPK('general', 'retry')).subscribe((result: any) => {
this.cs.stopLoading();
@ -108,7 +114,8 @@ export class TransactionsComponent implements OnInit {
getConcurrentProgram() {
this.cs.startLoading();
this.reports.getConcurrentProgram({
P_REQUEST_GROUP_ID: this.selectedMenu.REQUEST_GROUP_ID
P_REQUEST_GROUP_ID: this.selectedMenu.REQUEST_GROUP_ID,
P_SELECTED_EMPLOYEE_NUMBER: this.userData.EMPLOYEE_NUMBER
}, () => { }, this.ts.trPK('general', 'retry')).subscribe((response) => {
this.cs.stopLoading();
this.programList = response.GetConcurrentProgramsList;

Loading…
Cancel
Save