From 1201adb5eda09f7b483a23813f85fb3467b98aa6 Mon Sep 17 00:00:00 2001 From: Sultan Khan Date: Wed, 24 Nov 2021 15:52:08 +0300 Subject: [PATCH] Q3 CHANGES --- .../submit-absence.component.ts | 57 +- Mohem/src/app/app-routing.module.ts | 86 +- Mohem/src/app/app.component.html | 19 + Mohem/src/app/app.component.ts | 19 +- Mohem/src/app/eit/home/home.component.ts | 8 +- .../services/common/common.service.ts | 9 + .../services/connector/connector.service.ts | 6 +- .../services/menu/models/menu-response.ts | 14 +- .../hmg-common/services/rate/rate.service.ts | 8 +- Mohem/src/app/home/home.page.html | 2 +- Mohem/src/app/home/home.page.ts | 9 +- .../app/itemforsale/home/home.component.ts | 8 +- .../item-details/item-details.component.html | 34 +- .../item-details/item-details.component.ts | 15 +- .../src/app/itemforsale/itemforsale.module.ts | 6 +- .../itemforsale/items/items.component.html | 114 +- .../itemforsale/items/items.component.scss | 36 +- .../app/itemforsale/items/items.component.ts | 80 +- Mohem/src/app/itemforsale/services/domsafe.ts | 15 + .../services/service.service.spec.ts | 12 + .../itemforsale/services/service.service.ts | 51 + .../home/home.component.html | 94 ++ .../home/home.component.scss | 25 + .../home/home.component.spec.ts | 27 + .../home/home.component.ts | 56 + .../pending-transaction.module.ts | 36 + .../pending-transaction.page.html | 4 + .../pending-transaction.page.scss | 0 .../pending-transaction.page.spec.ts | 27 + .../pending-transaction.page.ts | 15 + .../service/service.service.spec.ts | 12 + .../service/service.service.ts | 44 + .../edit-profile/edit-profile.component.html | 1 + .../src/app/profile/home/home.component.html | 9 + .../src/app/profile/home/home.component.scss | 3 + Mohem/src/app/profile/home/home.component.ts | 22 +- .../app/profile/service/profile.service.ts | 10 +- .../concurrent-report.component.html | 30 + .../concurrent-report.component.scss | 6 + .../concurrent-report.component.spec.ts | 27 + .../concurrent-report.component.ts | 1278 +++++++++++++++++ .../reports/report-service.service.spec.ts | 12 + .../src/app/reports/report-service.service.ts | 49 + Mohem/src/app/reports/reports.module.ts | 39 + Mohem/src/app/reports/reports.page.html | 3 + Mohem/src/app/reports/reports.page.scss | 0 Mohem/src/app/reports/reports.page.spec.ts | 27 + Mohem/src/app/reports/reports.page.ts | 15 + .../termination-service.service.spec.ts | 12 + .../service/termination-service.service.ts | 40 + .../termination-form.component.html | 18 + .../termination-form.component.scss | 0 .../termination-form.component.spec.ts | 27 + .../termination-form.component.ts | 1024 +++++++++++++ .../src/app/termination/termination.module.ts | 39 + .../src/app/termination/termination.page.html | 3 + .../src/app/termination/termination.page.scss | 0 .../app/termination/termination.page.spec.ts | 27 + Mohem/src/app/termination/termination.page.ts | 15 + Mohem/src/assets/imgs/no-images.png | Bin 0 -> 38816 bytes Mohem/src/assets/localization/i18n.json | 69 +- 61 files changed, 3536 insertions(+), 217 deletions(-) create mode 100644 Mohem/src/app/itemforsale/services/domsafe.ts create mode 100644 Mohem/src/app/itemforsale/services/service.service.spec.ts create mode 100644 Mohem/src/app/itemforsale/services/service.service.ts create mode 100644 Mohem/src/app/pending-transaction/home/home.component.html create mode 100644 Mohem/src/app/pending-transaction/home/home.component.scss create mode 100644 Mohem/src/app/pending-transaction/home/home.component.spec.ts create mode 100644 Mohem/src/app/pending-transaction/home/home.component.ts create mode 100644 Mohem/src/app/pending-transaction/pending-transaction.module.ts create mode 100644 Mohem/src/app/pending-transaction/pending-transaction.page.html create mode 100644 Mohem/src/app/pending-transaction/pending-transaction.page.scss create mode 100644 Mohem/src/app/pending-transaction/pending-transaction.page.spec.ts create mode 100644 Mohem/src/app/pending-transaction/pending-transaction.page.ts create mode 100644 Mohem/src/app/pending-transaction/service/service.service.spec.ts create mode 100644 Mohem/src/app/pending-transaction/service/service.service.ts create mode 100644 Mohem/src/app/reports/concurrent-report/concurrent-report.component.html create mode 100644 Mohem/src/app/reports/concurrent-report/concurrent-report.component.scss create mode 100644 Mohem/src/app/reports/concurrent-report/concurrent-report.component.spec.ts create mode 100644 Mohem/src/app/reports/concurrent-report/concurrent-report.component.ts create mode 100644 Mohem/src/app/reports/report-service.service.spec.ts create mode 100644 Mohem/src/app/reports/report-service.service.ts create mode 100644 Mohem/src/app/reports/reports.module.ts create mode 100644 Mohem/src/app/reports/reports.page.html create mode 100644 Mohem/src/app/reports/reports.page.scss create mode 100644 Mohem/src/app/reports/reports.page.spec.ts create mode 100644 Mohem/src/app/reports/reports.page.ts create mode 100644 Mohem/src/app/termination/service/termination-service.service.spec.ts create mode 100644 Mohem/src/app/termination/service/termination-service.service.ts create mode 100644 Mohem/src/app/termination/termination-form/termination-form.component.html create mode 100644 Mohem/src/app/termination/termination-form/termination-form.component.scss create mode 100644 Mohem/src/app/termination/termination-form/termination-form.component.spec.ts create mode 100644 Mohem/src/app/termination/termination-form/termination-form.component.ts create mode 100644 Mohem/src/app/termination/termination.module.ts create mode 100644 Mohem/src/app/termination/termination.page.html create mode 100644 Mohem/src/app/termination/termination.page.scss create mode 100644 Mohem/src/app/termination/termination.page.spec.ts create mode 100644 Mohem/src/app/termination/termination.page.ts create mode 100644 Mohem/src/assets/imgs/no-images.png diff --git a/Mohem/src/app/absence/submit-absence/submit-absence.component.ts b/Mohem/src/app/absence/submit-absence/submit-absence.component.ts index 360a5175..4f331f9f 100644 --- a/Mohem/src/app/absence/submit-absence/submit-absence.component.ts +++ b/Mohem/src/app/absence/submit-absence/submit-absence.component.ts @@ -3,7 +3,7 @@ import { CommonService } from "src/app/hmg-common/services/common/common.service import { TranslatorService } from "src/app/hmg-common/services/translator/translator.service"; import { MenuService } from "src/app/hmg-common/services/menu/menuservice.service"; import { MenuResponse } from "src/app/hmg-common/services/menu/models/menu-response"; -import { ModalController ,IonSelectOption ,IonSelect } from "@ionic/angular"; +import { ModalController, IonSelectOption, IonSelect } from "@ionic/angular"; import { SubmitAbsenceService } from "../service/submit.absence.service"; import { AbsenceAttahcmentResponse } from "../models/abs.attach.response"; import { AbsenceListService } from "../service/service.service"; @@ -23,8 +23,8 @@ import { DatePicker } from "@ionic-native/date-picker/ngx"; import { Request } from '../../hmg-common/services/models/request'; // import { Request } from "../models/request"; import * as moment from "moment"; -import {ReplacementListComponent} from "../../vacation-rule/replacement-list/replacement-list.component"; -import {ReplacmentResponse} from "../models/replacment-response"; +import { ReplacementListComponent } from "../../vacation-rule/replacement-list/replacement-list.component"; +import { ReplacmentResponse } from "../models/replacment-response"; import { AbsenceResponse } from '../models/absence.response'; import { AbsenceReplacementListComponent } from '../absence-replacement-list/absence-replacement-list.component'; import { AbsenceNotificatonBodyResponse } from 'src/app/notification/models/AbsenceNotificationBodyRes'; @@ -99,8 +99,8 @@ export class SubmitAbsenceComponent implements OnInit { this.direction = TranslatorService.getCurrentLanguageName(); ////*new add*///// /**********resubmit************ */ - this.getPassNotificationDetails = this.common.sharedService.getSharedData(AbsenceNotificatonBodyResponse.NOT_WORKLIST, true); - this.getPassdirfromNotifiPage = this.common.sharedService.getSharedData('dirfromNotificationPage'); + this.getPassNotificationDetails = this.common.sharedService.getSharedData(AbsenceNotificatonBodyResponse.NOT_WORKLIST, true); + this.getPassdirfromNotifiPage = this.common.sharedService.getSharedData('dirfromNotificationPage'); //this.getPassNotificationDetails = this.common.sharedService.getSharedData(AbsenceNotificatonBodyResponse.NOT_WORKLIST, true); // this.getPassdirfromNotifiPage = this.navParams.get('dirfromNotificationPage'); if (this.getPassdirfromNotifiPage) { @@ -110,8 +110,8 @@ export class SubmitAbsenceComponent implements OnInit { this.notificationId = this.getPassNotificationDetails.NOTIFICATION_ID; this.selEmp = this.getPassNotificationDetails.SELECTED_EMPLOYEE_NUMBER; this.respID = -999; - this.submitAbsObjList = this.common.sharedService.getSharedData('submitAbsObjList'); - console.log() + this.submitAbsObjList = this.common.sharedService.getSharedData('submitAbsObjList'); + console.log() } else { this.action = "CREATE"; this.selEmp = this.common.sharedService.getSharedData( @@ -185,7 +185,7 @@ export class SubmitAbsenceComponent implements OnInit { } } calcDay() { - console.log("calcDay" ); + console.log("calcDay"); let msg: string = ""; if ( this.startDate == undefined || @@ -233,7 +233,7 @@ export class SubmitAbsenceComponent implements OnInit { this.totalDays = result.CalculateAbsenceDuration.P_ABSENCE_DAYS; } } - async openSearch(){ + async openSearch() { const modal = await this.modalCtrl.create({ component: ReplacementListComponent, keyboardClose: true, @@ -259,7 +259,7 @@ export class SubmitAbsenceComponent implements OnInit { console.log(data) console.log(user); if (data) { - this.employeeName = user.EMPLOYEE_DISPLAY_NAME; + this.employeeName = user.EMPLOYEE_DISPLAY_NAME; this.employeeID = user.USER_NAME; this.employeeSel = this.employeeName + "," + this.employeeID; } @@ -278,12 +278,12 @@ export class SubmitAbsenceComponent implements OnInit { } public onTypeAbsenceChange() { - + if (this.absenceType) { let obj: any = this.absenceTypeList.find( s => s.ABSENCE_ATTENDANCE_TYPE_ID == this.absenceType ); - + if (obj) this.absenceTypeName = obj.DESC_FLEX_CONTEXT_CODE; else this.absenceTypeName = null; @@ -443,7 +443,7 @@ export class SubmitAbsenceComponent implements OnInit { this.textInput = new TextInput( feildsList[i].SEGMENT_PROMPT, feildsList[i].APPLICATION_COLUMN_NAME, - defaultVal, + defaultVal, containerId, defaultValText, feildsList[i].MOBILE_ENABLED, @@ -492,9 +492,9 @@ export class SubmitAbsenceComponent implements OnInit { this.fillAbsStructure(); } } - + bindHtmlElemEvents(id, obj) { - + const elem = document.getElementById(id); elem.addEventListener("change", e => { elem.classList.remove("requiredClassElm"); @@ -1039,20 +1039,20 @@ export class SubmitAbsenceComponent implements OnInit { let elem = document.getElementById( this.absenceDffresponse[i].APPLICATION_COLUMN_NAME ) as HTMLInputElement; - let elemVal=""; + let elemVal = ""; if (elem.classList.contains('onic-date')) { - elemVal = (document.getElementById( + elemVal = (document.getElementById( this.absenceDffresponse[i].APPLICATION_COLUMN_NAME ) as HTMLInputElement).value; - if(elemVal){ + if (elemVal) { elemVal = moment(elemVal).format("YYYY/MM/DD hh:mm:ss"); } - - }else{ - elemVal = (document.getElementById( - this.absenceDffresponse[i].APPLICATION_COLUMN_NAME - ) as HTMLInputElement).value; - } + + } else { + elemVal = (document.getElementById( + this.absenceDffresponse[i].APPLICATION_COLUMN_NAME + ) as HTMLInputElement).value; + } textValue = elemVal; if ( @@ -1060,7 +1060,7 @@ export class SubmitAbsenceComponent implements OnInit { this.absenceDffresponse[i].DISPLAY_FLAG != "N" ) { //date - elemVal = this.common.formatDate(elemVal); + elemVal = this.common.formatDate(elemVal); } else if ( this.absenceDffresponse[i].FORMAT_TYPE == "Y" && this.absenceDffresponse[i].DISPLAY_FLAG != "N" @@ -1323,6 +1323,7 @@ export class SubmitAbsenceComponent implements OnInit { } return isSt; } + validateAbcenseTransaction() { (this.elementRef.nativeElement.querySelectorAll( "ion-item" @@ -1447,9 +1448,9 @@ export class SubmitAbsenceComponent implements OnInit { private handleSubmitAbsence(result) { if (this.common.validResponse(result)) { if (this.getPassdirfromNotifiPage) { - this.common.sharedService.setSharedData(result.ResubmitAbsenceTransactionList.P_TRANSACTION_ID, AbsenceResponse.SHARED_DATA); - this.common.openConfirmAbsece(); - // this.navCtrl.push("SubmitAbsenceConfirmPage", { isResubmit: true }); + this.common.sharedService.setSharedData(result.ResubmitAbsenceTransactionList.P_TRANSACTION_ID, AbsenceResponse.SHARED_DATA); + this.common.openConfirmAbsece(); + // this.navCtrl.push("SubmitAbsenceConfirmPage", { isResubmit: true }); } else { this.common.sharedService.setSharedData(result.SumbitAbsenceTransactionList.P_TRANSACTION_ID, AbsenceResponse.SHARED_DATA); this.common.openConfirmAbsece(); diff --git a/Mohem/src/app/app-routing.module.ts b/Mohem/src/app/app-routing.module.ts index b4b5da86..ce2095cd 100644 --- a/Mohem/src/app/app-routing.module.ts +++ b/Mohem/src/app/app-routing.module.ts @@ -1,42 +1,46 @@ -import { NgModule } from '@angular/core'; -import { PreloadAllModules, RouterModule, Routes } from '@angular/router'; +import { NgModule } from '@angular/core'; +import { PreloadAllModules, RouterModule, Routes } from '@angular/router'; + + +const routes: Routes = [ + { path: '', redirectTo: 'authentication/login', pathMatch: 'full' }, + { + path: 'authentication', loadChildren: './authentication/authentication.module#AuthenticationPageModule' + }, + { path: 'home', loadChildren: './home/home.module#HomePageModule' }, + { path: 'profile', loadChildren: './profile/profile.module#ProfilePageModule' }, + { path: 'vacation-rule', loadChildren: './vacation-rule/vacation-rule.module#VacationRulePageModule' }, + { path: 'accrual-balances', loadChildren: './accrual-balances/accrual-balances.module#AccrualBalancesPageModule' }, + { path: 'my-team', loadChildren: './my-team/my-team.module#MyTeamPageModule' }, + { path: 'attendance', loadChildren: './attendance/attendance.module#AttendancePageModule' }, + { path: 'eit', loadChildren: './eit/eit.module#EITPageModule' }, + { path: 'absence', loadChildren: './absence/absence.module#AbsencePageModule' }, + { path: 'notification', loadChildren: './notification/notification.module#NotificationPageModule' }, + { path: 'my-specialist', loadChildren: './my-specialist/my-specialist.module#MySpecialistPageModule' }, + { path: 'my-subordinate', loadChildren: './my-subordinate/my-subordinate.module#MySubordinatePageModule' }, + { path: 'time-card', loadChildren: './time-card/time-card.module#TimeCardPageModule' }, + { path: 'payslip', loadChildren: './payslip/payslip.module#PayslipPageModule' }, + { path: 'attendance-tracking', loadChildren: './attendance-tracking/attendance-tracking.module#AttendanceTrackingPageModule' }, + { path: 'itemforsale', loadChildren: './itemforsale/itemforsale.module#ItemforsalePageModule' }, + { path: 'offersdiscount', loadChildren: './offersdiscount/offersdiscount.module#OffersdiscountPageModule' }, + { path: 'mowadhafi', loadChildren: './mowadhafi/mowadhafi.module#MowadhafiPageModule' }, + { path: 'erm-channel', loadChildren: './erm-channel/erm-channel.module#ErmChannelPageModule' }, + { path: 'backend-integrations', loadChildren: './backend-integrations/backend-integrations.module#BackendIntegrationsPageModule' }, { path: 'reports', loadChildren: './reports/reports.module#ReportsPageModule' }, + { path: 'concurrent-report', loadChildren: './reports/concurrent-report/concurrent-report.module#ConcurrentReportPageModule' }, + { path: 'termination', loadChildren: './termination/termination.module#TerminationPageModule' }, + { path: 'pending-transaction', loadChildren: './pending-transaction/pending-transaction.module#PendingTransactionPageModule' } - -const routes: Routes = [ - { path: '', redirectTo: 'authentication/login', pathMatch: 'full' }, - { - path: 'authentication', loadChildren: './authentication/authentication.module#AuthenticationPageModule' - }, - { path: 'home', loadChildren: './home/home.module#HomePageModule' }, - { path: 'profile', loadChildren: './profile/profile.module#ProfilePageModule' }, - { path: 'vacation-rule', loadChildren: './vacation-rule/vacation-rule.module#VacationRulePageModule' }, - { path: 'accrual-balances', loadChildren: './accrual-balances/accrual-balances.module#AccrualBalancesPageModule' }, - { path: 'my-team', loadChildren: './my-team/my-team.module#MyTeamPageModule' }, - { path: 'attendance', loadChildren: './attendance/attendance.module#AttendancePageModule' }, - { path: 'eit', loadChildren: './eit/eit.module#EITPageModule' }, - { path: 'absence', loadChildren: './absence/absence.module#AbsencePageModule' }, - { path: 'notification', loadChildren: './notification/notification.module#NotificationPageModule' }, - { path: 'my-specialist', loadChildren: './my-specialist/my-specialist.module#MySpecialistPageModule' }, - { path: 'my-subordinate', loadChildren: './my-subordinate/my-subordinate.module#MySubordinatePageModule' }, - { path: 'time-card', loadChildren: './time-card/time-card.module#TimeCardPageModule' }, - { path: 'payslip', loadChildren: './payslip/payslip.module#PayslipPageModule' }, - { path: 'attendance-tracking', loadChildren: './attendance-tracking/attendance-tracking.module#AttendanceTrackingPageModule' }, - { path: 'itemforsale', loadChildren: './itemforsale/itemforsale.module#ItemforsalePageModule' }, - { path: 'offersdiscount', loadChildren: './offersdiscount/offersdiscount.module#OffersdiscountPageModule' }, - { path: 'mowadhafi', loadChildren: './mowadhafi/mowadhafi.module#MowadhafiPageModule' }, - { path: 'erm-channel', loadChildren: './erm-channel/erm-channel.module#ErmChannelPageModule' }, - { path: 'backend-integrations', loadChildren: './backend-integrations/backend-integrations.module#BackendIntegrationsPageModule' } - - - - -]; - -@NgModule({ - imports: [ - /*RouterModule.forRoot(routes, { preloadingStrategy: PreloadAllModules}),*/ - RouterModule.forRoot(routes), - ], - exports: [RouterModule] -}) -export class AppRoutingModule { } + + + + +]; + +@NgModule({ + imports: [ + /*RouterModule.forRoot(routes, { preloadingStrategy: PreloadAllModules}),*/ + RouterModule.forRoot(routes), + ], + exports: [RouterModule] +}) +export class AppRoutingModule { } diff --git a/Mohem/src/app/app.component.html b/Mohem/src/app/app.component.html index 5b40ba6e..78c03ae2 100644 --- a/Mohem/src/app/app.component.html +++ b/Mohem/src/app/app.component.html @@ -53,7 +53,26 @@ {{ts.trPK('userProfile','HR-Request')}} +
+ + + + + + + {{menu.MENU_NAME}} + + +
+ + + + + + {{ts.trPK('general','pending-transaction')}} + + diff --git a/Mohem/src/app/app.component.ts b/Mohem/src/app/app.component.ts index 47934fec..1648f9ec 100644 --- a/Mohem/src/app/app.component.ts +++ b/Mohem/src/app/app.component.ts @@ -14,6 +14,7 @@ import { DigitalIdComponent } from './authentication/digital-id/digital-id.compo import { checkAndUpdatePureExpressionInline } from '@angular/core/src/view/pure_expression'; import { FirebaseX } from '@ionic-native/firebase-x/ngx'; import { BusinessCardComponent } from './authentication/business-card/business-card.component'; +import { MenuResponse } from './hmg-common/services/menu/models/menu-response'; @Component({ selector: 'app-root', @@ -122,7 +123,7 @@ export class AppComponent implements OnInit { public setScreenNameAnalytics(currentPageName: string) { try { - this.firebasex.setScreenName(currentPageName).then((result)=>{ + this.firebasex.setScreenName(currentPageName).then((result) => { console.log(result); }); } catch (Error) { } @@ -208,7 +209,7 @@ export class AppComponent implements OnInit { let jobTitle = user.POSITION_NAME.split('.'); if (jobTitle && jobTitle.length > 1) { this.User_Job_name = jobTitle[0] + " " + jobTitle[1]; - }​ + } //erm channel // if (!CommonService.SKIP) // this.cs.navigateForward('/erm-channel/survey'); @@ -218,7 +219,10 @@ export class AppComponent implements OnInit { }); }); this.events.subscribe('getNotCount', badge => { this.notBadge = badge; }); - this.events.subscribe('myTeamFlag', myTeamFlag => { this.TeamFlag = myTeamFlag; }); + this.events.subscribe('myTeamFlag', myTeamFlag => { + this.TeamFlag = myTeamFlag; + this.menuList = this.cs.sharedService.getSharedData(MenuResponse.MENU_LIST, false); + }); } private initializeDirection() { @@ -348,4 +352,13 @@ export class AppComponent implements OnInit { } else { } }); } + oepnMyRequest(menu) { + this.cs.sharedService.setSharedData(menu, MenuResponse.SELECTED_MENU); + this.cs.openConcurrentReport(); + this.menu.toggle(); + } + oepnTransaction() { + this.cs.openTransactions(); + this.menu.toggle(); + } } diff --git a/Mohem/src/app/eit/home/home.component.ts b/Mohem/src/app/eit/home/home.component.ts index 7402a672..d145686f 100644 --- a/Mohem/src/app/eit/home/home.component.ts +++ b/Mohem/src/app/eit/home/home.component.ts @@ -2,6 +2,7 @@ import { CommonService } from 'src/app/hmg-common/services/common/common.service import { Component, OnInit } from '@angular/core'; import { MenuResponse } from 'src/app/hmg-common/services/menu/models/menu-response'; import { TranslatorService } from 'src/app/hmg-common/services/translator/translator.service'; +import { TerminationServiceService } from 'src/app/termination/service/termination-service.service'; @Component({ selector: 'app-home', @@ -19,7 +20,7 @@ export class HomeComponent implements OnInit { direction: string; pageType: string; - constructor(private cs: CommonService, private ts: TranslatorService) { + constructor(private cs: CommonService, private ts: TranslatorService, public terminationService: TerminationServiceService) { this.direction = TranslatorService.getCurrentLanguageName(); this.menu = this.cs.sharedService.getSharedData('menuEntries', false); this.pageType = this.cs.sharedService.getSharedData('homemenuentries', false); @@ -45,6 +46,11 @@ export class HomeComponent implements OnInit { this.selectedMenu = index; } } + if (page['FUNCTION_NAME'] == 'HR_TERM_EMP_SS') { + this.cs.sharedService.setSharedData(page, TerminationServiceService.TERMINATION_PAGE); + + this.cs.openTermination(); + } console.log('selected>>>>>>>' + this.selectedMenu); } 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 cac80b88..c3ca3b8a 100644 --- a/Mohem/src/app/hmg-common/services/common/common.service.ts +++ b/Mohem/src/app/hmg-common/services/common/common.service.ts @@ -1302,9 +1302,18 @@ export class CommonService { public openAnnouncement() { this.nav.navigateForward(['/backend-integrations/announcement']); } + public openConcurrentReport() { + this.nav.navigateForward(['/reports/concurrent-report']); + } + public openTermination() { + this.nav.navigateForward(['/termination/termination-form']); + } + public openTransactions() { + this.nav.navigateForward(['/pending-transaction/home']); + } public navigatePage(path) { this.nav.navigateForward([path]); } diff --git a/Mohem/src/app/hmg-common/services/connector/connector.service.ts b/Mohem/src/app/hmg-common/services/connector/connector.service.ts index dc119ce4..62631565 100644 --- a/Mohem/src/app/hmg-common/services/connector/connector.service.ts +++ b/Mohem/src/app/hmg-common/services/connector/connector.service.ts @@ -27,8 +27,8 @@ export class ConnectorService { public static retryTimes = 0; public static timeOut = 120 * 1000; - // public static host = 'https://uat.hmgwebservices.com/'; - public static host = 'https://hmgwebservices.com/'; + public static host = 'https://uat.hmgwebservices.com/'; + // public static host = 'https://hmgwebservices.com/'; constructor(public httpClient: HttpClient, public cs: CommonService, @@ -235,7 +235,7 @@ export class ConnectorService { } return false; } else if (result.ErrorType === 2 || result.ErrorType === 4) { - this.cs.stopLoading(); + this.cs.stopLoading(); } else { this.cs.stopLoading(); if (!fromSMS) { diff --git a/Mohem/src/app/hmg-common/services/menu/models/menu-response.ts b/Mohem/src/app/hmg-common/services/menu/models/menu-response.ts index 1c7a2e1d..07db1f07 100644 --- a/Mohem/src/app/hmg-common/services/menu/models/menu-response.ts +++ b/Mohem/src/app/hmg-common/services/menu/models/menu-response.ts @@ -2,10 +2,12 @@ import { ListMenu } from './list.menu'; import { MenuEntry } from './menu.entry'; export class MenuResponse { public static SHARED_DATA = 'menu_response'; - public static SHARED_SEL_EMP= 'sel_empolyee'; - public static SHARED_SEL_RESP_ID= 'sel_resp_id'; - public userid:string; - public search:boolean; - public List_Menu:ListMenu; - public GetMenuEntriesList:MenuEntry; + public static MENU_LIST = 'menu_list'; + public static SELECTED_MENU = 'selected_menu'; + public static SHARED_SEL_EMP = 'sel_empolyee'; + public static SHARED_SEL_RESP_ID = 'sel_resp_id'; + public userid: string; + public search: boolean; + public List_Menu: ListMenu; + public GetMenuEntriesList: MenuEntry; } \ No newline at end of file diff --git a/Mohem/src/app/hmg-common/services/rate/rate.service.ts b/Mohem/src/app/hmg-common/services/rate/rate.service.ts index f9fef5d7..9176bf13 100644 --- a/Mohem/src/app/hmg-common/services/rate/rate.service.ts +++ b/Mohem/src/app/hmg-common/services/rate/rate.service.ts @@ -20,13 +20,13 @@ export class RateService { } - public rateFeature(ratedFeedBack?: any , featureKey: string = RateService.app , delay: number = 2000) { + public rateFeature(ratedFeedBack?: any, featureKey: string = RateService.app, delay: number = 2000) { if (this.isRated(featureKey)) { if (ratedFeedBack) { ratedFeedBack(true); } } else { - setTimeout( () => { + setTimeout(() => { this.startRating(featureKey, ratedFeedBack); }, delay); } @@ -38,7 +38,7 @@ export class RateService { this.appRate.preferences = { displayAppName: this.ts.trPK('general', 'app-name'), promptAgainForEachNewVersion: true, - inAppReview: true, + // inAppReview: true, storeAppURL: { ios: 'com.ejada.hmg', android: 'market://details?id=com.ejada.hmg', @@ -47,7 +47,7 @@ export class RateService { callbacks: { handleNegativeFeedback: () => { this.setAsRated(featureKey); - //this.cs.openFeedback(); + //this.cs.openFeedback(); }, onButtonClicked: (buttonIndex) => { // when user click rate diff --git a/Mohem/src/app/home/home.page.html b/Mohem/src/app/home/home.page.html index b323351c..00f2cdef 100644 --- a/Mohem/src/app/home/home.page.html +++ b/Mohem/src/app/home/home.page.html @@ -63,7 +63,7 @@ {{'general,other-services' | translate}} - + diff --git a/Mohem/src/app/home/home.page.ts b/Mohem/src/app/home/home.page.ts index 0a882f0f..ed15653a 100644 --- a/Mohem/src/app/home/home.page.ts +++ b/Mohem/src/app/home/home.page.ts @@ -192,11 +192,11 @@ export class HomePage implements OnInit { spaceBetween: 10 }; this.slideOptsTwo = { - slidesPerView: width > 320 ? 3.2 : 2.5, - spaceBetween: width > 320 ? 10 : 5 + slidesPerView: width > 320 ? 3.2 : 2.5, + spaceBetween: width > 320 ? 10 : 5 }; this.showStaticServices = true; -} + } ionViewWillEnter() { this.common.startLoading(); this.slideSettingsTwo(); @@ -408,6 +408,7 @@ export class HomePage implements OnInit { selMenu.List_Menu = item; selMenu.userid = this.userData.EMPLOYEE_NUMBER; this.common.sharedService.setSharedData(selMenu, MenuResponse.SHARED_DATA); + this.common.sharedService.setSharedData(this.menuList, MenuResponse.MENU_LIST); this.getMenuEntries(item); // tslint:disable-next-line: prefer-for-of for (let i = 0; i < this.menuList.length; i++) { @@ -749,7 +750,7 @@ export class HomePage implements OnInit { totalTicketsLeft = totalTicketsLeft + accrualBalance.ACCRUAL_NET_ENTITLEMENT; } } - this.statsButtons[4].statsValue = Number(totalTicketsLeft.toFixed(2)); + this.statsButtons[4].statsValue = Number(totalTicketsLeft.toFixed(2)); } }); } diff --git a/Mohem/src/app/itemforsale/home/home.component.ts b/Mohem/src/app/itemforsale/home/home.component.ts index ace51a36..7ddeddbe 100644 --- a/Mohem/src/app/itemforsale/home/home.component.ts +++ b/Mohem/src/app/itemforsale/home/home.component.ts @@ -1,6 +1,7 @@ import { Component, OnInit } from '@angular/core'; import { CommonService } from 'src/app/hmg-common/services/common/common.service'; import { TranslatorService } from 'src/app/hmg-common/services/translator/translator.service'; +import { ItemForSaleService } from '../services/service.service'; @Component({ selector: 'app-home', @@ -9,9 +10,12 @@ import { TranslatorService } from 'src/app/hmg-common/services/translator/transl }) export class HomeComponent implements OnInit { step: any = 1; - constructor(public ts: TranslatorService, public cs: CommonService,) { } + constructor(public ts: TranslatorService, public cs: CommonService, private itemService: ItemForSaleService) { } - ngOnInit() { } + ngOnInit() { + + + } openItem() { diff --git a/Mohem/src/app/itemforsale/item-details/item-details.component.html b/Mohem/src/app/itemforsale/item-details/item-details.component.html index add7aca6..a6f466e6 100644 --- a/Mohem/src/app/itemforsale/item-details/item-details.component.html +++ b/Mohem/src/app/itemforsale/item-details/item-details.component.html @@ -12,18 +12,21 @@
- + + - - Furniture Table + {{itemDetails.title}} + {{itemDetails.title_Ar}} - Keep close to Nature's heart... and break clear away, once in awhile, - and climb a mountain or spend a week in the woods. Wash your spirit clean. + {{itemDetails.description}} + {{itemDetails.description_Ar}}

New

-

500 SAR

+

+ {{itemDetails.quotePrice}} {{itemDetails.currencyCode}} +

@@ -33,9 +36,9 @@ -

Mohammed Imran

-

Posted on 22 April 2020

-

View Profile

+

{{itemDetails.fullName}}

+

{{getDate(itemDetails.created) }}

+
@@ -50,14 +53,15 @@ \ No newline at end of file diff --git a/Mohem/src/app/itemforsale/item-details/item-details.component.ts b/Mohem/src/app/itemforsale/item-details/item-details.component.ts index cae7ea97..f326a1ad 100644 --- a/Mohem/src/app/itemforsale/item-details/item-details.component.ts +++ b/Mohem/src/app/itemforsale/item-details/item-details.component.ts @@ -1,15 +1,26 @@ import { Component, OnInit } from '@angular/core'; import { CommonService } from 'src/app/hmg-common/services/common/common.service'; import { TranslatorService } from 'src/app/hmg-common/services/translator/translator.service'; - +import { ItemForSaleService } from '../services/service.service'; +import * as moment from 'moment'; @Component({ selector: 'app-item-details', templateUrl: './item-details.component.html', styleUrls: ['./item-details.component.scss'], }) export class ItemDetailsComponent implements OnInit { + itemDetails: any = {}; + direction: any; + constructor(public ts: TranslatorService, public cs: CommonService,) { } - ngOnInit() { } + ngOnInit() { + this.direction = TranslatorService.getCurrentDirection(); + this.itemDetails = this.cs.sharedService.getSharedData(ItemForSaleService.ITEMS_SELECTED, false); + console.log(this.itemDetails); + } + getDate(date) { + return moment(date, "YYYY-MM-DD HH:mm:ss").format("DD-MMM-YYYY"); + } } diff --git a/Mohem/src/app/itemforsale/itemforsale.module.ts b/Mohem/src/app/itemforsale/itemforsale.module.ts index 6a7aea24..e8833935 100644 --- a/Mohem/src/app/itemforsale/itemforsale.module.ts +++ b/Mohem/src/app/itemforsale/itemforsale.module.ts @@ -11,6 +11,8 @@ import { ItemsComponent } from './items/items.component'; import { ItemDetailsComponent } from './item-details/item-details.component'; import { MyAdsComponent } from './my-ads/my-ads.component'; import { HmgCommonModule } from '../hmg-common/hmg-common.module'; +import { ItemForSaleService } from './services/service.service'; +import { SanitizeHtmlPipe } from './services/domsafe'; const routes: Routes = [ { @@ -45,6 +47,8 @@ const routes: Routes = [ HmgCommonModule, RouterModule.forChild(routes) ], - declarations: [ItemforsalePage, HomeComponent, ItemsComponent, ItemDetailsComponent, MyAdsComponent] + declarations: [ItemforsalePage, HomeComponent, ItemsComponent, ItemDetailsComponent, MyAdsComponent, SanitizeHtmlPipe], + providers: [ItemForSaleService], + exports: [SanitizeHtmlPipe] }) export class ItemforsalePageModule { } diff --git a/Mohem/src/app/itemforsale/items/items.component.html b/Mohem/src/app/itemforsale/items/items.component.html index bab28e0c..3334792c 100644 --- a/Mohem/src/app/itemforsale/items/items.component.html +++ b/Mohem/src/app/itemforsale/items/items.component.html @@ -28,7 +28,7 @@ - + @@ -43,67 +43,42 @@
-
-
-
- -
-
-

Mobile & Tablets

-
-
-
-
-
-
- -
-
-

Cars & Vehicle

-
-
-
-
-
-
- -
-
-

Electronic Appliance

-
-
-
-
-
-
- +
+
+
+
-

Fashion & Beauty

+

{{category.title}}

+

{{category.title_Ar}}

+
- + - - - Furniture Table + + + {{item.title}} + {{item.title_Ar}} + - Keep close to Nature's heart... and break + {{getDotted(item.description, 60)}} + {{getDotted(item.description_Ar, 60)}}

Used

- 500 SAR + {{item.quotePrice}} {{item.currencyCode}} @@ -114,53 +89,37 @@
- - - - - - Furniture Table - - - - Keep close to Nature's heart... and break -

- New -

- - - - 500 SAR - - - - - - - -
-
-
+
+ + + +
- + - + + -

Furniture Table

-

- Posted on 24 April 2021 -

-

good condition only 6th month used

+

{{item.title}}

+

{{item.title_Ar}}

+ +

{{getDate(item.created) }}

+ +

{{getDotted(item.description, 30)}}

+

{{getDotted(item.description_Ar, 30)}}

-

Pending Review

+

{{isApproved ? "Appoved" :"Pending"}}

+
@@ -170,6 +129,7 @@
+
diff --git a/Mohem/src/app/itemforsale/items/items.component.scss b/Mohem/src/app/itemforsale/items/items.component.scss index bcba7e10..d83c0aa4 100644 --- a/Mohem/src/app/itemforsale/items/items.component.scss +++ b/Mohem/src/app/itemforsale/items/items.component.scss @@ -10,6 +10,9 @@ .header-toolbar{ --background: #259CB8 !important; } +.top{ + position: relative; +} .bottom{ height: 100%; width: 100%; @@ -51,7 +54,10 @@ margin-top: 5px; margin-bottom: 5px; margin-left: 5px; - font-size: 14px; + font-size: 12px; + text-overflow: ellipsis; + overflow: hidden; + white-space: nowrap; } .bottom-icon{ text-overflow: clip; @@ -69,7 +75,8 @@ ion-card-title{ font-weight: bold; font-size: 14px; - padding: 5px + padding: 5px; + height: 40px; } .orange{ color: #CC9B14; @@ -112,9 +119,10 @@ ion-segment-button{ } ion-segment-button ion-label{ padding: 0; - font-size: 16px; + font-size: 14px; white-space: normal; font-weight: bold; + line-height: 1.1; } .segment-button-checked ion-label{ color: #fff !important; @@ -132,6 +140,7 @@ ion-item h3{ color: #000; font-weight: bold; font-size: 14px; + margin-top:10px; } .yellow{ color:#CC9B14; @@ -155,7 +164,7 @@ ion-item .icon{ --background: #259CB8; } ion-footer{ - position: absolute; + position: fixed; bottom: 0; } ion-footer .footer-button{ @@ -219,4 +228,23 @@ ion-fab-button{ } .grid-row{ margin:10px; +} + +.active .top::before{ + position: absolute; + right: 0px; + top: 2px; + padding: 0px; + background: #3cc353; + padding: 2px 3px 4px 3px; + border-radius: 60%; + font-size: 10px; + color: #fff; + content: '✓'; + width: 12px; + height: 12px; + text-align: center; +} +.space{ + height:100px; } \ No newline at end of file diff --git a/Mohem/src/app/itemforsale/items/items.component.ts b/Mohem/src/app/itemforsale/items/items.component.ts index 73fc2398..a8ddc4a3 100644 --- a/Mohem/src/app/itemforsale/items/items.component.ts +++ b/Mohem/src/app/itemforsale/items/items.component.ts @@ -1,6 +1,9 @@ import { Component, OnInit } from '@angular/core'; import { CommonService } from 'src/app/hmg-common/services/common/common.service'; import { TranslatorService } from 'src/app/hmg-common/services/translator/translator.service'; +import { ItemForSaleService } from '../services/service.service'; +import { deepCopy } from '@angular-devkit/core/src/utils/object'; +import * as moment from 'moment'; @Component({ selector: 'app-items', @@ -9,10 +12,33 @@ import { TranslatorService } from 'src/app/hmg-common/services/translator/transl }) export class ItemsComponent implements OnInit { segment: any = '1'; - constructor(public ts: TranslatorService, public cs: CommonService,) { } + items: any = []; + categories: any = []; + direction: string; + activeClass: any; + pageNo: number = 1; + tempSearch: any = []; + itemsByEmployee: any = []; + constructor(public ts: TranslatorService, public cs: CommonService, private itemService: ItemForSaleService) { } - ngOnInit() { } - openDetails() { + + ngOnInit() { + this.direction = TranslatorService.getCurrentDirection(); + this.getItemsCategories(); + this.getItemsByEmployee(); + } + getItemsCategories() { + this.itemService.getCategories({}, () => { }, this.ts.trPK('general', 'retry')).subscribe((result) => { + this.categories = this.itemService.parser(result); + console.log(this.categories); + }) + this.itemService.getItems({ pageNo: this.pageNo }, () => { }, this.ts.trPK('general', 'retry')).subscribe((result) => { + this.items = this.itemService.parser(result); + this.tempSearch = deepCopy(this.items); + }) + } + openDetails(selected) { + this.cs.sharedService.setSharedData(selected, ItemForSaleService.ITEMS_SELECTED); this.cs.navigateForward('/itemforsale/items-details'); } segmentChanged(value) { @@ -21,5 +47,53 @@ export class ItemsComponent implements OnInit { openSale() { this.cs.navigateForward('/itemforsale/home'); } + selectCategory(item) { + this.activeClass = item.categoryID + + } + getDotted(temp: string, valueCount: number) { + temp = this.stripHtml(temp); + return temp.substring(0, valueCount) + " ..."; + } + stripHtml(html) { + var temporalDivElement = document.createElement("div"); + + temporalDivElement.innerHTML = html; + + return temporalDivElement.textContent || temporalDivElement.innerText || ""; + } + loadData(event) { + this.pageNo = this.pageNo + 1; + this.itemService.getItems({ pageNo: this.pageNo }, () => { }, this.ts.trPK('general', 'retry')).subscribe((result) => { + this.items.concat(this.itemService.parser(result)); + this.tempSearch = deepCopy(this.items); + event.target.complete(); + + }) + } + search(t) { + if (t === '') { + this.items = this.tempSearch; + } else { + this.items = this.tempSearch.filter((post) => { + if (this.direction == 'ltr') + return (post.title.toLowerCase().indexOf(t.toLowerCase()) > -1); + else + return (post.title_Ar.indexOf(t) > -1); + }); + } + + } + getItemsByEmployee() { + + + this.itemService.getItemsByEmployee({}, () => { }, this.ts.trPK('general', 'retry')).subscribe((result) => { + this.itemsByEmployee = this.itemService.parser(result); + console.log(this.itemsByEmployee); + }) + } + getDate(date) { + return moment(date, "YYYY-MM-DD HH:mm:ss").format("DD-MMM-YYYY"); + } } diff --git a/Mohem/src/app/itemforsale/services/domsafe.ts b/Mohem/src/app/itemforsale/services/domsafe.ts new file mode 100644 index 00000000..79b677ac --- /dev/null +++ b/Mohem/src/app/itemforsale/services/domsafe.ts @@ -0,0 +1,15 @@ +import { Pipe, PipeTransform } from "@angular/core"; +import { DomSanitizer, SafeHtml } from '@angular/platform-browser'; + +@Pipe({ + name: 'sanitizeHTMLPipe' +}) +export class SanitizeHtmlPipe implements PipeTransform { + + constructor(private _sanitizer: DomSanitizer) { + } + + transform(v: string): SafeHtml { + return this._sanitizer.bypassSecurityTrustHtml(v); + } +} \ No newline at end of file diff --git a/Mohem/src/app/itemforsale/services/service.service.spec.ts b/Mohem/src/app/itemforsale/services/service.service.spec.ts new file mode 100644 index 00000000..99221043 --- /dev/null +++ b/Mohem/src/app/itemforsale/services/service.service.spec.ts @@ -0,0 +1,12 @@ +import { TestBed } from '@angular/core/testing'; + +import { ItemForSaleService } from './service.service'; + +describe('ServiceService', () => { + beforeEach(() => TestBed.configureTestingModule({})); + + it('should be created', () => { + const service: ItemForSaleService = TestBed.get(ItemForSaleService); + expect(service).toBeTruthy(); + }); +}); diff --git a/Mohem/src/app/itemforsale/services/service.service.ts b/Mohem/src/app/itemforsale/services/service.service.ts new file mode 100644 index 00000000..14b246c1 --- /dev/null +++ b/Mohem/src/app/itemforsale/services/service.service.ts @@ -0,0 +1,51 @@ +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'; + +@Injectable({ + providedIn: 'root' +}) +export class ItemForSaleService { + public static getItemForSale = 'Services/COCWS.svc/REST/Mohemm_ITG_GetItemForSale'; + public static getItemForSaleByEmployee = 'Services/COCWS.svc/REST/Mohemm_ITG_GetItemForSaleByEmployee'; + public static getCategories = 'Services/COCWS.svc/REST/Mohemm_ITG_GetItemSaleCategory'; + public static ITEMS_SELECTED = 'item-selected'; + + constructor( + public con: ConnectorService, + private authService: AuthenticationService + ) { } + public getItems(request: any, onError?: any, errorLabel?: string) { + this.authService.authenticateRequest(request); + request.EmployeeNumber = request.UserName; + request.ItgPageNo = request.pageNo; + request.ItgPageSize = 10; + request.ItgStatus = "Approved"; + return this.con.post(ItemForSaleService.getItemForSale, request, onError, errorLabel); + } + + public getCategories(request: any, onError?: any, errorLabel?: string) { + this.authService.authenticateRequest(request); + request.EmployeeNumber = request.UserName; + + return this.con.post(ItemForSaleService.getCategories, request, onError, errorLabel); + } + parser(response: any) { + try { + var result = JSON.parse(response.Mohemm_ITG_ResponseItem); + if (result.result) + return result.result.data + else + return {} + } catch (res) { + console.log(res); + } + } + + getItemsByEmployee(request: any, onError?: any, errorLabel?: string) { + this.authService.authenticateRequest(request); + request.EmployeeNumber = request.UserName; + request.ItgEmployeeNumber = 111209; + return this.con.post(ItemForSaleService.getItemForSaleByEmployee, request, onError, errorLabel); + } +} diff --git a/Mohem/src/app/pending-transaction/home/home.component.html b/Mohem/src/app/pending-transaction/home/home.component.html new file mode 100644 index 00000000..5169ef68 --- /dev/null +++ b/Mohem/src/app/pending-transaction/home/home.component.html @@ -0,0 +1,94 @@ + + +
+ + + +
+
+
+
+ + + + {{ 'general,select' | translate}} + + + {{ transaction.FUNCTION_PROMPT}} + + + + +
+ + + +
+ {{ 'general,from-date' | translate}} + +
+
+ + +
+ {{ 'general,to-date' | translate}} + +
+
+
+
+ + +
+
+ + + + +

{{'general, noData' | translate}}

+
+
+
+ +
{{transaction.CREATION_DATE}}
+ + +

{{'transaction, created-for' | translate}}

+

{{transaction.TRANSACTION_CREATED_FOR}}

+
+ + +

{{'transaction, request-type' | translate}}

+

{{transaction.REQUEST_TYPE}}

+
+
+
+ +
+
+
+ + +
+ + {{'general, submit' | translate}} +
+
\ No newline at end of file diff --git a/Mohem/src/app/pending-transaction/home/home.component.scss b/Mohem/src/app/pending-transaction/home/home.component.scss new file mode 100644 index 00000000..17285bed --- /dev/null +++ b/Mohem/src/app/pending-transaction/home/home.component.scss @@ -0,0 +1,25 @@ +.display-created{ + display: inline-block; + + color:#000; +} +.padding{ + padding-left:5px; + padding-right: 5px; +} +.bold{ + font-weight: bold; +} +.color-black{ + color:#000; +} +.date{ + position: absolute; + font-size: 12px; + padding: 10px; + right:0; + +} +.transaction-list{ + margin-top:20px; +} \ No newline at end of file diff --git a/Mohem/src/app/pending-transaction/home/home.component.spec.ts b/Mohem/src/app/pending-transaction/home/home.component.spec.ts new file mode 100644 index 00000000..5ec1377b --- /dev/null +++ b/Mohem/src/app/pending-transaction/home/home.component.spec.ts @@ -0,0 +1,27 @@ +import { CUSTOM_ELEMENTS_SCHEMA } from '@angular/core'; +import { async, ComponentFixture, TestBed } from '@angular/core/testing'; + +import { HomeComponent } from './home.component'; + +describe('HomeComponent', () => { + let component: HomeComponent; + let fixture: ComponentFixture; + + beforeEach(async(() => { + TestBed.configureTestingModule({ + declarations: [ HomeComponent ], + schemas: [CUSTOM_ELEMENTS_SCHEMA], + }) + .compileComponents(); + })); + + beforeEach(() => { + fixture = TestBed.createComponent(HomeComponent); + component = fixture.componentInstance; + fixture.detectChanges(); + }); + + it('should create', () => { + expect(component).toBeTruthy(); + }); +}); diff --git a/Mohem/src/app/pending-transaction/home/home.component.ts b/Mohem/src/app/pending-transaction/home/home.component.ts new file mode 100644 index 00000000..51d218e8 --- /dev/null +++ b/Mohem/src/app/pending-transaction/home/home.component.ts @@ -0,0 +1,56 @@ +import { Component, ElementRef, OnInit } from '@angular/core'; +import { EitService } from 'src/app/eit/services/eit.service'; +import { CommonService } from 'src/app/hmg-common/services/common/common.service'; +import { TranslatorService } from 'src/app/hmg-common/services/translator/translator.service'; +import { ServiceService } from '../service/service.service'; + +@Component({ + selector: 'app-home', + templateUrl: './home.component.html', + styleUrls: ['./home.component.scss'], +}) +export class HomeComponent implements OnInit { + public direction: any; + public transactions: any = []; + public selectedTransaction: any; + public dateTo: any; + public dateFrom: any; + public transactionDetails; + constructor(public cs: CommonService, private elementRef: ElementRef, public trServcice: ServiceService, public ts: TranslatorService, public eitService: EitService) { } + + + ngOnInit() { + + + this.getPendingTransaction(); + this.direction = TranslatorService.getCurrentLanguageName(); + + } + getPendingTransaction() { + this.cs.startLoading(); + this.trServcice.getPendingRequests({ + }, () => { }, this.ts.trPK('general', 'retry')).subscribe((response) => { + this.cs.stopLoading(); + this.transactions = response['GetPendingReqFunctionsList']; + }) + } + getPendingRequestDetails() { + this.cs.startLoading(); + this.trServcice.getPendingRequestDetails({ + 'P_FUNCTION_ID': this.selectedTransaction.FUNCTION_ID, + 'P_CREATION_DATE_FROM': "/Date(" + Date.parse(this.dateFrom) + '+0300' + ")/", + 'P_CREATION_DATE_TO': "/Date(" + Date.parse(this.dateTo) + '+0300' + ")/", + 'P_PAGE_NUM': 1, + 'P_PAGE_LIMIT': 20, + + }, () => { }, this.ts.trPK('general', 'retry')).subscribe((response) => { + this.cs.stopLoading(); + this.transactionDetails = response['GetPendingReqDetailsList']; + }) + } + isValid() { + if (this.selectedTransaction && this.dateFrom && this.dateTo) + return true; + else return false + } +} diff --git a/Mohem/src/app/pending-transaction/pending-transaction.module.ts b/Mohem/src/app/pending-transaction/pending-transaction.module.ts new file mode 100644 index 00000000..1d95ebc2 --- /dev/null +++ b/Mohem/src/app/pending-transaction/pending-transaction.module.ts @@ -0,0 +1,36 @@ +import { NgModule } from '@angular/core'; +import { CommonModule } from '@angular/common'; +import { FormsModule } from '@angular/forms'; +import { Routes, RouterModule } from '@angular/router'; + +import { IonicModule } from '@ionic/angular'; + +import { PendingTransactionPage } from './pending-transaction.page'; +import { HomeComponent } from './home/home.component'; +import { ServiceService } from './service/service.service'; +import { HmgCommonModule } from '../hmg-common/hmg-common.module'; +const routes: Routes = [ + { + path: '', + component: PendingTransactionPage, + children: [ + { + path: 'home', + component: HomeComponent + }, + ] + } +]; + +@NgModule({ + imports: [ + CommonModule, + FormsModule, + IonicModule, + RouterModule.forChild(routes), + HmgCommonModule + ], + declarations: [PendingTransactionPage, HomeComponent], + providers: [ServiceService] +}) +export class PendingTransactionPageModule { } diff --git a/Mohem/src/app/pending-transaction/pending-transaction.page.html b/Mohem/src/app/pending-transaction/pending-transaction.page.html new file mode 100644 index 00000000..d26b79fd --- /dev/null +++ b/Mohem/src/app/pending-transaction/pending-transaction.page.html @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git a/Mohem/src/app/pending-transaction/pending-transaction.page.scss b/Mohem/src/app/pending-transaction/pending-transaction.page.scss new file mode 100644 index 00000000..e69de29b diff --git a/Mohem/src/app/pending-transaction/pending-transaction.page.spec.ts b/Mohem/src/app/pending-transaction/pending-transaction.page.spec.ts new file mode 100644 index 00000000..b6a16ed9 --- /dev/null +++ b/Mohem/src/app/pending-transaction/pending-transaction.page.spec.ts @@ -0,0 +1,27 @@ +import { CUSTOM_ELEMENTS_SCHEMA } from '@angular/core'; +import { async, ComponentFixture, TestBed } from '@angular/core/testing'; + +import { PendingTransactionPage } from './pending-transaction.page'; + +describe('PendingTransactionPage', () => { + let component: PendingTransactionPage; + let fixture: ComponentFixture; + + beforeEach(async(() => { + TestBed.configureTestingModule({ + declarations: [ PendingTransactionPage ], + schemas: [CUSTOM_ELEMENTS_SCHEMA], + }) + .compileComponents(); + })); + + beforeEach(() => { + fixture = TestBed.createComponent(PendingTransactionPage); + component = fixture.componentInstance; + fixture.detectChanges(); + }); + + it('should create', () => { + expect(component).toBeTruthy(); + }); +}); diff --git a/Mohem/src/app/pending-transaction/pending-transaction.page.ts b/Mohem/src/app/pending-transaction/pending-transaction.page.ts new file mode 100644 index 00000000..1377c463 --- /dev/null +++ b/Mohem/src/app/pending-transaction/pending-transaction.page.ts @@ -0,0 +1,15 @@ +import { Component, OnInit } from '@angular/core'; + +@Component({ + selector: 'app-pending-transaction', + templateUrl: './pending-transaction.page.html', + styleUrls: ['./pending-transaction.page.scss'], +}) +export class PendingTransactionPage implements OnInit { + + constructor() { } + + ngOnInit() { + } + +} diff --git a/Mohem/src/app/pending-transaction/service/service.service.spec.ts b/Mohem/src/app/pending-transaction/service/service.service.spec.ts new file mode 100644 index 00000000..d2923aa3 --- /dev/null +++ b/Mohem/src/app/pending-transaction/service/service.service.spec.ts @@ -0,0 +1,12 @@ +import { TestBed } from '@angular/core/testing'; + +import { ServiceService } from './service.service'; + +describe('ServiceService', () => { + beforeEach(() => TestBed.configureTestingModule({})); + + it('should be created', () => { + const service: ServiceService = TestBed.get(ServiceService); + expect(service).toBeTruthy(); + }); +}); diff --git a/Mohem/src/app/pending-transaction/service/service.service.ts b/Mohem/src/app/pending-transaction/service/service.service.ts new file mode 100644 index 00000000..f5521403 --- /dev/null +++ b/Mohem/src/app/pending-transaction/service/service.service.ts @@ -0,0 +1,44 @@ +import { Injectable } from '@angular/core'; +import { AuthenticationService } from 'src/app/hmg-common/services/authentication/authentication.service'; +import { CommonService } from 'src/app/hmg-common/services/common/common.service'; +import { ConnectorService } from 'src/app/hmg-common/services/connector/connector.service'; + +@Injectable({ + providedIn: 'root' +}) +export class ServiceService { + + + public static GET_PENDING_REQ_FUNCTIONS = 'Services/ERP.svc/REST/GET_PENDING_REQ_FUNCTIONS'; + public static GET_PENDING_REQ_DETAILS = 'Services/ERP.svc/REST/GET_PENDING_REQ_DETAILS'; + constructor( + public con: ConnectorService, + private authService: AuthenticationService, + public cs: CommonService + ) { } + + getPendingRequests(request, onError, errorLabel) { + this.authService.authenticateRequest(request); + request.P_SELECTED_EMPLOYEE_NUMBER = request.UserName; + return this.con.postNoLoad( + ServiceService.GET_PENDING_REQ_FUNCTIONS, + request, + onError, + errorLabel + ); + } + getPendingRequestDetails(request, onError, errorLabel) { + this.authService.authenticateRequest(request); + request.P_SELECTED_EMPLOYEE_NUMBER = request.UserName; + return this.con.postNoLoad( + ServiceService.GET_PENDING_REQ_DETAILS, + request, + onError, + errorLabel + ); + } + + + + +} diff --git a/Mohem/src/app/profile/edit-profile/edit-profile.component.html b/Mohem/src/app/profile/edit-profile/edit-profile.component.html index 86ee5a08..ff85343c 100644 --- a/Mohem/src/app/profile/edit-profile/edit-profile.component.html +++ b/Mohem/src/app/profile/edit-profile/edit-profile.component.html @@ -74,6 +74,7 @@ + diff --git a/Mohem/src/app/profile/home/home.component.html b/Mohem/src/app/profile/home/home.component.html index 96b8ea1b..8e0f701f 100644 --- a/Mohem/src/app/profile/home/home.component.html +++ b/Mohem/src/app/profile/home/home.component.html @@ -123,10 +123,19 @@

{{personalInfo.EMPLOYMENT_CATEGORY_MEANING}}


+

{{ts.trPK('userProfile','phone-no')}}

+ +

{{personalInfo.EMPLOYEE_MOBILE_NUMBER}}

+
+ + + + +

{{ts.trPK('userProfile','busG')}}

diff --git a/Mohem/src/app/profile/home/home.component.scss b/Mohem/src/app/profile/home/home.component.scss index 97bbfbb6..07c79412 100644 --- a/Mohem/src/app/profile/home/home.component.scss +++ b/Mohem/src/app/profile/home/home.component.scss @@ -1352,4 +1352,7 @@ $actionBtnSize: 36px; letter-spacing: -0.64px; color: #2B353E; opacity: 1; +} +.create-edit{ + font-size: 20px; } \ No newline at end of file diff --git a/Mohem/src/app/profile/home/home.component.ts b/Mohem/src/app/profile/home/home.component.ts index 6c05dd04..4b4c45de 100644 --- a/Mohem/src/app/profile/home/home.component.ts +++ b/Mohem/src/app/profile/home/home.component.ts @@ -149,7 +149,7 @@ export class HomeComponent implements OnInit { let jobTitle = user.POSITION_NAME.split('.'); if (jobTitle && jobTitle.length > 1) { this.jobName = jobTitle[0] + " " + jobTitle[1]; - }​ + } if (this.cs.getUpdateImage().status) { this.user_image = this.sanitizer.bypassSecurityTrustUrl('data:image/png;base64,' + this.cs.getUpdateImage().img); @@ -311,7 +311,7 @@ export class HomeComponent implements OnInit { const modal = await this.modalController.create({ component: EditDetailProfileComponent, cssClass: 'my-custom-modal-css', - componentProps:{ sourceName: source} + componentProps: { sourceName: source } }); modal.onDidDismiss() @@ -323,7 +323,7 @@ export class HomeComponent implements OnInit { this.cs.sharedService.setSharedData(this.addressSubMenu, ProfileService.ADRESS_ENTRIES); this.cs.sharedService.setSharedData(this.employeeAdress, ProfileService.EMP_ADDRESS); this.cs.sharedService.setSharedData(this.country, ProfileService.COUNTRY); - + this.cs.openAddAddress(); } else if (data.data && data.data.data == 2 && source === 'address') { this.cs.openAddAddress(); @@ -356,5 +356,21 @@ export class HomeComponent implements OnInit { this.cs.openAddBasicDetails('correct'); } } + public editPhone() { + this.getObjectValues(); + } + + public createPhone() { + + } + getObjectValues() { + this.profileService.getObjectValue({ + P_OBJECT_TYPE: 'LOOKUP', + P_OBJECT_NAME: 'PHONE_TYPE' + + }, () => { }, this.ts.trPK('general', 'retry')).subscribe((response) => { + console.log(response); + }) + } } diff --git a/Mohem/src/app/profile/service/profile.service.ts b/Mohem/src/app/profile/service/profile.service.ts index 0feb9512..a16ccf89 100644 --- a/Mohem/src/app/profile/service/profile.service.ts +++ b/Mohem/src/app/profile/service/profile.service.ts @@ -32,7 +32,7 @@ export class ProfileService { public static getDiffStructure = "Services/ERP.svc/REST/GET_ADDRESS_DFF_STRUCTURE"; public static submitAddressTransactions = "Services/ERP.svc/REST/SUBMIT_ADDRESS_TRANSACTION"; public static submitBasicDetailsTransaction = "Services/ERP.svc/REST/SUBMIT_BASIC_DET_TRANSACTION"; - + public static getObjectValues = "Services/ERP.svc/REST/GET_OBJECT_VALUES"; public static ADRESS_ENTRIES = 'address-entries'; public static EMP_ADDRESS = 'emp-address'; public static COUNTRY = 'country'; @@ -127,4 +127,12 @@ export class ProfileService { this.authService.authenticateRequest(request); return this.con.post(ProfileService.startBasicProcess, request, onError, errorLabel); } + + public getObjectValue(request: any, onError?: any, errorLabel?: string): Observable { + + this.authService.authenticateRequest(request); + request.P_SELECTED_EMPLOYEE_NUMBER = request.P_USER_NAME; + return this.con.post(ProfileService.getObjectValues, request, onError, errorLabel); + + } } \ No newline at end of file diff --git a/Mohem/src/app/reports/concurrent-report/concurrent-report.component.html b/Mohem/src/app/reports/concurrent-report/concurrent-report.component.html new file mode 100644 index 00000000..c622715f --- /dev/null +++ b/Mohem/src/app/reports/concurrent-report/concurrent-report.component.html @@ -0,0 +1,30 @@ + +
+ + + +
+
+
+ +
+ + {{ 'worklist,template-name' | translate}} + + + {{ program.CONCURRENT_PROGRAM_NAME}} + + +
+
+
+
+
+ + +
+ + {{'vacation-rule, next-label' | translate}} +
+
\ No newline at end of file diff --git a/Mohem/src/app/reports/concurrent-report/concurrent-report.component.scss b/Mohem/src/app/reports/concurrent-report/concurrent-report.component.scss new file mode 100644 index 00000000..71cba989 --- /dev/null +++ b/Mohem/src/app/reports/concurrent-report/concurrent-report.component.scss @@ -0,0 +1,6 @@ +.main-container{ + padding: 10px; +} +.divider{ + height:20px +} \ No newline at end of file diff --git a/Mohem/src/app/reports/concurrent-report/concurrent-report.component.spec.ts b/Mohem/src/app/reports/concurrent-report/concurrent-report.component.spec.ts new file mode 100644 index 00000000..102199fe --- /dev/null +++ b/Mohem/src/app/reports/concurrent-report/concurrent-report.component.spec.ts @@ -0,0 +1,27 @@ +import { CUSTOM_ELEMENTS_SCHEMA } from '@angular/core'; +import { async, ComponentFixture, TestBed } from '@angular/core/testing'; + +import { ConcurrentReportComponent } from './concurrent-report.component'; + +describe('ConcurrentReportComponent', () => { + let component: ConcurrentReportComponent; + let fixture: ComponentFixture; + + beforeEach(async(() => { + TestBed.configureTestingModule({ + declarations: [ ConcurrentReportComponent ], + schemas: [CUSTOM_ELEMENTS_SCHEMA], + }) + .compileComponents(); + })); + + beforeEach(() => { + fixture = TestBed.createComponent(ConcurrentReportComponent); + component = fixture.componentInstance; + fixture.detectChanges(); + }); + + it('should create', () => { + expect(component).toBeTruthy(); + }); +}); diff --git a/Mohem/src/app/reports/concurrent-report/concurrent-report.component.ts b/Mohem/src/app/reports/concurrent-report/concurrent-report.component.ts new file mode 100644 index 00000000..1c583432 --- /dev/null +++ b/Mohem/src/app/reports/concurrent-report/concurrent-report.component.ts @@ -0,0 +1,1278 @@ +import { Component, ElementRef, OnInit } from '@angular/core'; +import * as moment from 'moment'; +import { EitRequest } from 'src/app/eit/models/eit.request'; +import { EIT_ACTION } from 'src/app/eit/models/submit.eit.action'; +import { EitService } from 'src/app/eit/services/eit.service'; +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 { DateTimeInput } from 'src/app/uI-elements/date-time.input'; +import { DateInput } from 'src/app/uI-elements/date.input'; +import { HiddenInput } from 'src/app/uI-elements/hidden.input'; +import { NumberInput } from 'src/app/uI-elements/number.input'; +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'; + +@Component({ + selector: 'app-concurrent-report', + templateUrl: './concurrent-report.component.html', + styleUrls: ['./concurrent-report.component.scss'], +}) +export class ConcurrentReportComponent implements OnInit { + public selectedMenu; + public diffStructure = []; + public isUpdate: boolean; + private eitVALSettoCall: any = []; + private textInput; + private numberInput; + private dateInput; + public direction: string; + private datetimeInput; + private timeInput; + private selectInput; + private hiddenInput; + private validateEitObj: any = []; + public menuType: any; + public respID; + public selEmp; + public eitRequest; + public ExtraObj; + selMenu: MenuResponse; + public functionName; + + public headerTitle; + getPassdirfromNotifiPage: boolean = false; + private validEitTransactionTbl: any = []; + eitSubmitAction: number = 0; + updatedValues: any = []; + comtransNo: any = 0; + programList: any = []; + public template: any; + constructor(public cs: CommonService, private elementRef: ElementRef, public reports: ReportServiceService, public ts: TranslatorService, public eitService: EitService) { } + + ngOnInit() { + this.getPassdirfromNotifiPage = this.cs.sharedService.getSharedData('dirfromNotificationPage'); + this.selectedMenu = this.cs.sharedService.getSharedData(MenuResponse.SELECTED_MENU, false); + this.getConcurrentProgram(); + this.direction = TranslatorService.getCurrentLanguageName(); + // this.effectiveDate = new Date(); + this.functionName = this.selectedMenu.FUNCTION_NAME; + // this.headerTitle = this.selMenu.GetMenuEntriesList.PROMPT; + } + getConcurrentProgram() { + this.reports.getConcurrentProgram({ + P_REQUEST_GROUP_ID: this.selectedMenu.REQUEST_GROUP_ID + }, () => { }, this.ts.trPK('general', 'retry')).subscribe((response) => { + console.log(response); + this.programList = response.GetConcurrentProgramsList; + + }) + } + getCppDiffStructure(programList) { + this.cs.startLoading(); + this.reports.getCPPDiffStructure({ + P_DESC_FLEX_NAME: programList.CONCURRENT_PROGRAM_NAME + }, () => { }, this.ts.trPK('general', 'retry')).subscribe((response) => { + this.cs.stopLoading(); + this.handleDiffStructure(response); + }) + } + handleDiffStructure(result) { + if (result.GetCcpDffStructureList != null) { + this.diffStructure = result.GetCcpDffStructureList; + this.drawEitFields(result.GetCcpDffStructureList); + if (this.isUpdate) { + //this.submitAbsObjList = this.cs.sharedService.getSharedData(ProfileService.EMP_ADDRESS); + //this.fillAbsStructure(); + } + } + } + private drawEitFields(feildsList) { + const containerId = "containerDiv"; + this.eitVALSettoCall = []; + for (let i = 0; i < feildsList.length; i++) { + let defaultVal: string = ""; + let defaultValText: string = ""; + + if (feildsList[i].DISPLAY_FLAG != "N") { + //check if the field should be displayed + if (feildsList[i].VALIDATION_TYPE == "N") { + //text , date , time + if (feildsList[i].FORMAT_TYPE == "C") { + // character + this.textInput = new TextInput( + feildsList[i].SEGMENT_PROMPT, + feildsList[i].APPLICATION_COLUMN_NAME, + defaultVal, + containerId, + defaultValText, + feildsList[i].MOBILE_ENABLED, + feildsList[i].DISPLAY_FLAG, + feildsList[i].REQUIRED_FLAG + ); + } else if (feildsList[i].FORMAT_TYPE == "N") { + // number + this.numberInput = new NumberInput( + feildsList[i].SEGMENT_PROMPT, + feildsList[i].APPLICATION_COLUMN_NAME, + defaultVal, + containerId, + feildsList[i].MOBILE_ENABLED, + feildsList[i].DISPLAY_FLAG, + feildsList[i].REQUIRED_FLAG + ); + } else if (feildsList[i].FORMAT_TYPE == "X") { + // standard date + if ( + feildsList[i].DEFAULT_TYPE == "C" || + feildsList[i].DEFAULT_TYPE == "D" || + feildsList[i].DEFAULT_TYPE == "P" || + feildsList[i].DEFAULT_TYPE == "S" + ) { + //constant + this.dateInput = new DateInput( + feildsList[i].SEGMENT_PROMPT, + feildsList[i].APPLICATION_COLUMN_NAME, + this.cs.reverseFormatDate(defaultVal), + containerId, + feildsList[i].MOBILE_ENABLED, + feildsList[i].DISPLAY_FLAG, + feildsList[i].REQUIRED_FLAG, + this.direction + ); + } else { + this.dateInput = new DateInput( + feildsList[i].SEGMENT_PROMPT, + feildsList[i].APPLICATION_COLUMN_NAME, + "", + containerId, + feildsList[i].MOBILE_ENABLED, + feildsList[i].DISPLAY_FLAG, + feildsList[i].REQUIRED_FLAG, + this.direction + ); + } + } else if (feildsList[i].FORMAT_TYPE == "Y") { + // standard date time + if ( + feildsList[i].DEFAULT_TYPE == "C" || + feildsList[i].DEFAULT_TYPE == "D" || + feildsList[i].DEFAULT_TYPE == "P" || + feildsList[i].DEFAULT_TYPE == "S" + ) { + this.datetimeInput = new DateTimeInput( + feildsList[i].SEGMENT_PROMPT, + feildsList[i].APPLICATION_COLUMN_NAME, + this.cs.reverseFormatStandardDate(defaultVal), + containerId, + feildsList[i].MOBILE_ENABLED, + feildsList[i].DISPLAY_FLAG, + feildsList[i].REQUIRED_FLAG, + this.direction + ); + } else { + this.datetimeInput = new DateTimeInput( + feildsList[i].SEGMENT_PROMPT, + feildsList[i].APPLICATION_COLUMN_NAME, + "", + containerId, + feildsList[i].MOBILE_ENABLED, + feildsList[i].DISPLAY_FLAG, + feildsList[i].REQUIRED_FLAG, + this.direction + ); + } + const elem = document.getElementById( + feildsList[i].APPLICATION_COLUMN_NAME + ); + } else if (feildsList[i].FORMAT_TYPE == "I") { + //time + if ( + feildsList[i].DEFAULT_TYPE == "C" || + feildsList[i].DEFAULT_TYPE == "D" || + feildsList[i].DEFAULT_TYPE == "P" || + feildsList[i].DEFAULT_TYPE == "S" + ) { + this.timeInput = new TimeInput( + feildsList[i].SEGMENT_PROMPT, + feildsList[i].APPLICATION_COLUMN_NAME, + "", + containerId, + feildsList[i].MOBILE_ENABLED, + feildsList[i].DISPLAY_FLAG, + feildsList[i].REQUIRED_FLAG, + this.direction + ); + } else { + this.timeInput = new TimeInput( + feildsList[i].SEGMENT_PROMPT, + feildsList[i].APPLICATION_COLUMN_NAME, + "", + containerId, + feildsList[i].MOBILE_ENABLED, + feildsList[i].DISPLAY_FLAG, + feildsList[i].REQUIRED_FLAG, + this.direction + ); + } + } + } else { + if (feildsList[i].READ_ONLY == "Y") { + this.textInput = new TextInput( + feildsList[i].SEGMENT_PROMPT, + feildsList[i].APPLICATION_COLUMN_NAME, + defaultVal, + containerId, + defaultValText, + feildsList[i].MOBILE_ENABLED, + feildsList[i].DISPLAY_FLAG, + feildsList[i].REQUIRED_FLAG + ); + } else { + this.selectInput = new SelectInput( + feildsList[i].SEGMENT_PROMPT, + feildsList[i].APPLICATION_COLUMN_NAME, + defaultVal, + containerId, + feildsList[i].MOBILE_ENABLED, + feildsList[i].DISPLAY_FLAG, + feildsList[i].REQUIRED_FLAG + ); + this.fillDropdownList( + feildsList[i].SEGMENT_NAME, + feildsList[i].E_SERVICES_VS, + feildsList[i].E_SERVICES_DV + ); + } + } + this.bindHtmlElemEvents( + feildsList[i].APPLICATION_COLUMN_NAME, + feildsList[i] + ); + } else { + this.hiddenInput = new HiddenInput( + defaultVal, + feildsList[i].APPLICATION_COLUMN_NAME, + defaultValText, + containerId + ); + this.bindHtmlElemEvents( + feildsList[i].APPLICATION_COLUMN_NAME, + feildsList[i] + ); + } + } + if (this.validateEitObj && this.validateEitObj.length > 0) { + this.fillEITStructure(); + } + } + fillDropdownList(segmentName, optionList: any = [], DV: any = "") { + let elemID: any = ""; + let eitObj: any; + if (optionList.length > 0) { + for (let i = 0; i < this.diffStructure.length; i++) { + if (this.diffStructure[i].SEGMENT_NAME == segmentName) { + eitObj = this.diffStructure[i]; + if ( + this.diffStructure[i].READ_ONLY == "Y" || + this.diffStructure[i].DISPLAY_FLAG == "N" + ) { + return false; + } + elemID = this.diffStructure[i].APPLICATION_COLUMN_NAME; + break; + } + } + let select = document.getElementById(elemID) as HTMLSelectElement; + document.getElementById(elemID).innerHTML = ""; + if (eitObj.IsEmptyOption && eitObj.REQUIRED_FLAG == "N") { + var firstoption = document.createElement("option"); + firstoption.text = this.ts.trPK("general", "choose"); + firstoption.value = ""; + select.add(firstoption); + } + for (let i = 0; i < optionList.length; i++) { + var option = document.createElement("option"); + option.text = optionList[i].VALUE_COLUMN_NAME; + option.value = optionList[i].ID_COLUMN_NAME; + select.add(option); + } + if (select.dataset.hiddenval) { + select.value = select.dataset.hiddenval; + } else { + select.value = DV.P_ID_COLUMN_NAME; + } + select.disabled = false; + } + } + bindHtmlElemEvents(id, obj) { + const elem = document.getElementById(id); + console.log(elem); + console.log(obj); + const elemType = elem.tagName; + let changeEvent = "ionChange"; + + if (elemType == "SELECT") changeEvent = "change"; + + try { + elem.addEventListener(changeEvent, e => { + elem.classList.remove("requiredClassElm"); + if ( + obj.CHILD_SEGMENTS_VS_Splited && + obj.CHILD_SEGMENTS_VS_Splited.length > 0 + ) { + let listArray: any = obj.CHILD_SEGMENTS_VS_Splited; + listArray.forEach(element => { + this.emptyChildElement(element); + this.getValueSet(element); + }); + } + if ( + obj.CHILD_SEGMENTS_DV_Splited && + obj.CHILD_SEGMENTS_DV_Splited.length > 0 + ) { + let listArray: any = obj.CHILD_SEGMENTS_DV_Splited; + listArray.forEach(element => { + this.emptyChildElement(element); + for (let i = 0; i < this.diffStructure.length; i++) { + if (this.diffStructure[i].SEGMENT_NAME == element) { + this.getDefaultValue( + this.diffStructure[i], + this.diffStructure[i].DESC_FLEX_NAME, + this.diffStructure[i].DESC_FLEX_CONTEXT_CODE, + this.diffStructure[i].SEGMENT_NAME, + this.diffStructure[i].PARENT_SEGMENTS_VS_SplitedVS, + this.diffStructure[i].PARENT_SEGMENTS_DV_Splited + ); + } + } + }); + } + return false; + }); + } catch (e) { + console.log(e.status); + } + } + public getDefaultValue( + obj, + descFlexName, + descFlexContextCode, + segmentName, + parentValue, + ParentsList + ) { + let dependenciesList: any = []; + let parentVal: any = null; + let isStandardDate: boolean = false; + let isStandardTimeDate: boolean = false; + let isStandardTime: boolean = false; + let isHidden: boolean = false; + let isReadOnlyList: boolean = false; + let isSelectElement: boolean = false; + isStandardDate = this.isStandardDate(obj); + isStandardTimeDate = this.isStandardDateTime(obj); + isStandardTime = this.isStandardTime(obj); + if (obj.DISPLAY_FLAG == "N") isHidden = true; + if (obj.VALIDATION_TYPE != "N" && obj.READ_ONLY == "Y") { + isReadOnlyList = true; + } + if (obj.VALIDATION_TYPE != "N" && obj.READ_ONLY == "N") { + isSelectElement = true; + } + if ( + parentValue != "" && + (obj.VALIDATION_TYPE == "D" || obj.VALIDATION_TYPE == "Y") + ) { + let parvalue = this.getDependenciesParams(parentValue); + if (parvalue && parvalue[0]) parentVal = parvalue[0].ID_COLUMN_NAME; + else { + parentVal = null; + } + if (!parentVal) { + return false; + } + } + if (ParentsList != "") { + if (parentValue) ParentsList.concat(parentValue); + dependenciesList = this.getDependenciesParams(ParentsList); + if (!dependenciesList) { + return false; + } + } + + const body = { + P_SELECTED_EMPLOYEE_NUMBER: this.selEmp, + P_MENU_TYPE: this.menuType, + P_SELECTED_RESP_ID: this.respID, //-999, + P_DESC_FLEX_NAME: descFlexName, + P_DESC_FLEX_CONTEXT_CODE: descFlexContextCode, + P_SEGMENT_NAME: segmentName, + P_PARENT_VALUE: parentVal, + GetValueSetValuesTBL: dependenciesList + }; + + this.eitService.getDefaultValue(body).subscribe((result: any) => { + let elem = this.getElementByName(segmentName); + let obj = this.handleDefaultValueResult(result); + let val = obj.value; + let text = obj.text; + if (val == null) { val = ""; } + if (text == null) { text = ""; } + if (isStandardDate) { + console.log("isStandardDate"); + elem.value = this.cs.reverseFormatDate(val); + } else if (isStandardTimeDate) { + console.log("isStandardTimeDate"); + if (val) { + elem.dataset.dtvalue = this.cs.reverseFormatStandardDate(val); + elem.innerHTML = this.cs.reverseFormatStandardDate(val); + } else { + elem.dataset.dtvalue = ""; + elem.innerHTML = ""; + } + } else if (isStandardTime) { + console.log("isStandardTime"); + if (val) { + elem.dataset.dtvalue = val; + elem.innerHTML = val; + elem.value = val; + } else { + elem.dataset.dtvalue = ""; + elem.innerHTML = ""; + } + } else { + if (isSelectElement) { + let elem = this.getSelectElementByName(segmentName); + elem = document.getElementById(elem), + elem.value = val; + } else { + elem.value = val; + elem.innerText = text; + elem.setAttribute("value", val); + } + } + if (isHidden || isReadOnlyList) { + if (val) elem.dataset.colmText = val; + else elem.dataset.colmText = ""; + elem.value = text; + } + var event = new Event("ionChange"); + elem.dispatchEvent(event); + }); + } + + handleDefaultValueResult(result) { + let data = { + text: result.GetDefaultValueList.P_VALUE_COLUMN_NAME, + value: result.GetDefaultValueList.P_ID_COLUMN_NAME + }; + return data; + } + getSelectElementByName(segmentName) { + let elemID: any = ""; + for (let i = 0; i < this.diffStructure.length; i++) { + if (this.diffStructure[i].SEGMENT_NAME == segmentName) { + elemID = this.diffStructure[i].APPLICATION_COLUMN_NAME; + break; + } + } + return elemID; + } + getElementByName(segmentName) { + let elemID: any = ""; + for (let i = 0; i < this.diffStructure.length; i++) { + if (this.diffStructure[i].SEGMENT_NAME == segmentName) { + elemID = this.diffStructure[i].APPLICATION_COLUMN_NAME; + break; + } + } + return document.getElementById(elemID) as HTMLInputElement; + } + + fillEITStructure() { + var obj = { peiObjVer: null, peiExtraInfoID: null }; + for (let i = 0; i < this.validateEitObj.length; i++) { + let val: any; + if (this.validateEitObj[i].VARCHAR2_VALUE) + val = this.validateEitObj[i].VARCHAR2_VALUE; + else if (this.validateEitObj[i].DATE_VALUE) + val = this.validateEitObj[i].DATE_VALUE; + else if (this.validateEitObj[i].NUMBER_VALUE) + val = this.validateEitObj[i].NUMBER_VALUE; + const elem = document.getElementById( + this.validateEitObj[i].APPLICATION_COLUMN_NAME + ) as HTMLInputElement; + //obj.transactionNo=this.validateEitObj[i].TRANSACTION_NUMBER; + if (elem) { + if (val) { + let feldDetails = this.diffStructure.find( + x => + x.APPLICATION_COLUMN_NAME == + this.validateEitObj[i].APPLICATION_COLUMN_NAME + ); + if (feldDetails) { + let isStandardDate = this.isStandardDateVal(feldDetails); + let isStandardDateTime = this.isStandardDateTimeVal(feldDetails); + let isStandardTime = this.isStandardTimeVal(feldDetails); + if (isStandardDate) { + elem.value = this.cs.reverseFormatDate(val); + } else if (isStandardDateTime) { + elem.innerHTML = this.cs.reverseFormatStandardDate(val); + elem.dataset.dtvalue = this.cs.reverseFormatStandardDate(val); + } else if (isStandardTime) { + elem.innerHTML = val; + elem.dataset.dtvalue = val; + } else { + elem.value = val; + elem.setAttribute("value", elem.value); + } + if ( + feldDetails.DISPLAY_FLAG == "N" || + (feldDetails.VALIDATION_TYPE != "N" && + feldDetails.READ_ONLY == "Y") + ) { + elem.dataset.colmText = val; + elem.value = this.validateEitObj[i].SEGMENT_VALUE_DSP; + elem.setAttribute("value", elem.value); + } + } + elem.dataset.hiddenval = val; //hide the value to set it after calling get value set + if ( + feldDetails.CHILD_SEGMENTS_VS_Splited && + feldDetails.CHILD_SEGMENTS_VS_Splited.length > 0 + ) { + let listArray: any = feldDetails.CHILD_SEGMENTS_VS_Splited; + listArray.forEach(element => { + this.getValueSet(element); + }); + } + // var event = new Event('change'); + // elem.dispatchEvent(event); + } + } else { + if ( + this.validateEitObj[i].APPLICATION_COLUMN_NAME == + "PEI_OBJECT_VERSION_NUMBER" + ) + obj.peiObjVer = this.validateEitObj[i].NUMBER_VALUE; + else if ( + this.validateEitObj[i].APPLICATION_COLUMN_NAME == "PEI_EXTRA_INFO_ID" + ) + obj.peiExtraInfoID = this.validateEitObj[i].NUMBER_VALUE; + } + } + this.ExtraObj = obj; + } + public getValueSet(segmentName) { + let descFlexName: any = ""; + let descFlexContextCode: any = ""; + let parentValue: any = []; + let ParentsList: any = []; + let parentVal: any = null; + let dependenciesList: any = []; + let validationType: string = ""; + + for (let i = 0; i < this.diffStructure.length; i++) { + if (this.diffStructure[i].SEGMENT_NAME == segmentName) { + descFlexName = this.diffStructure[i].DESC_FLEX_NAME; + descFlexContextCode = this.diffStructure[i].DESC_FLEX_CONTEXT_CODE; + parentValue = this.diffStructure[i].PARENT_SEGMENTS_VS_SplitedVS; + ParentsList = this.diffStructure[i].PARENT_SEGMENTS_VS_SplitedVS; + validationType = this.diffStructure[i].VALIDATION_TYPE; + break; + } + } + if (parentValue != "" && (validationType == "D" || validationType == "Y")) { + let parvalue = this.getDependenciesParams(parentValue); + if (parvalue && parvalue[0]) parentVal = parvalue[0].ID_COLUMN_NAME; + else { + parentVal = null; + } + if (!parentVal) { + return false; + } + } + if (ParentsList != "") { + dependenciesList = this.getDependenciesParams(ParentsList); + if (!dependenciesList) { + return false; + } + } + const body = { + P_SELECTED_EMPLOYEE_NUMBER: this.selEmp, + P_MENU_TYPE: this.menuType, + P_SELECTED_RESP_ID: this.respID, //-999, + P_DESC_FLEX_NAME: descFlexName, + P_DESC_FLEX_CONTEXT_CODE: descFlexContextCode, + P_SEGMENT_NAME: segmentName, + P_PARENT_VALUE: parentVal, + GetValueSetValuesTBL: dependenciesList, + P_PAGE_NUM: 1, + P_PAGE_LIMIT: 1000 + }; + + this.eitService.getSetValue(body).subscribe((result: any) => { + if (result.GetValueSetValuesList != null) { + this.fillDropdownList(segmentName, result.GetValueSetValuesList); + } + }); + let arr: any = []; + return arr; + } + isStandardDateVal(obj: any): boolean { + let isSt: boolean = false; + if (obj.FORMAT_TYPE == "X") { + + isSt = true; + + } + return isSt; + } + + emptyChildElement(segmentName) { + let elem = this.getElementByName(segmentName); + elem.value = null; + elem.innerHTML = ""; + if ("dtvalue" in elem.dataset) { + elem.dataset.dtvalue = ""; + } + if ("colmText" in elem.dataset) { + elem.dataset.colmText = ""; + } + var event = new Event("change"); + elem.dispatchEvent(event); + elem.classList.remove("requiredClassElm"); + } + getDependenciesParams(parentsList) { + let parentArr: any = []; + for (let i = 0; i < parentsList.length; i++) { + for (let j = 0; j < this.diffStructure.length; j++) { + if (this.diffStructure[j].SEGMENT_NAME == parentsList[i].Name) { + if (this.diffStructure[j].DISPLAY_FLAG != "N") { + if (this.diffStructure[j].VALIDATION_TYPE == "N") { + let idColName: string; + let val: any; + if ( + this.diffStructure[j].FORMAT_TYPE == "Y" || + this.diffStructure[j].FORMAT_TYPE == "I" + ) { + //standard date time or //time + let elem = document.getElementById( + this.diffStructure[j].APPLICATION_COLUMN_NAME + ) as HTMLDivElement; + val = elem.dataset.dtvalue; + if ( + (val == undefined || val == "") && + parentsList[i].IsRequired == "REQUIRED" + ) { + //alert(parentsList[i].Name +" Is required"); + return false; + } + idColName = val; + if (this.diffStructure[j].FORMAT_TYPE == "Y") + idColName = this.cs.formatStandardDate(val); + } else { + val = (document.getElementById( + this.diffStructure[j].APPLICATION_COLUMN_NAME + ) as HTMLInputElement).value; + if ( + (val == undefined || val == "") && + parentsList[i].IsRequired == "REQUIRED" + ) { + //alert(parentsList[i].Name +" Is required"); + return false; + } + idColName = val; + if (this.diffStructure[j].FORMAT_TYPE == "X") { + //date + // idColName = this.cs.formatDate(val); + idColName = this.cs.formatDateNew(val); + } + } + parentArr.push({ + SEGMENT_NAME: this.diffStructure[j].SEGMENT_NAME, + VALUE_COLUMN_NAME: val, + DESCRIPTION: "", + ID_COLUMN_NAME: idColName, + FLEX_VALUE_SET_NAME: this.diffStructure[j].FLEX_VALUE_SET_NAME + }); + break; + } else { + if (this.diffStructure[j].READ_ONLY != "Y") { + let x = document.getElementById( + this.diffStructure[j].APPLICATION_COLUMN_NAME + ) as HTMLSelectElement; + let text = x.options[x.selectedIndex] + ? x.options[x.selectedIndex].text + : ""; + let val = x.options[x.selectedIndex] + ? x.options[x.selectedIndex].value + : undefined; + if ( + (val == undefined || val == "") && + parentsList[i].IsRequired == "REQUIRED" + ) { + //alert(parentsList[i].Name +" Is required"); + return false; + } else { + } + if (text == undefined) { + text = ""; + } + parentArr.push({ + SEGMENT_NAME: this.diffStructure[j].SEGMENT_NAME, + VALUE_COLUMN_NAME: text, + DESCRIPTION: "", + ID_COLUMN_NAME: val, + FLEX_VALUE_SET_NAME: this.diffStructure[j].FLEX_VALUE_SET_NAME + }); + break; + } else { + let x = document.getElementById( + this.diffStructure[j].APPLICATION_COLUMN_NAME + ) as HTMLInputElement; + let text = x.value; + let val = x.dataset.colmText; + if ( + (val == undefined || val == "") && + parentsList[i].IsRequired == "REQUIRED" + ) { + //alert(parentsList[i].Name +" Is required"); + return false; + } else { + } + if (text == undefined) { + text = ""; + } + parentArr.push({ + SEGMENT_NAME: this.diffStructure[j].SEGMENT_NAME, + VALUE_COLUMN_NAME: text, + DESCRIPTION: "", + ID_COLUMN_NAME: val, + FLEX_VALUE_SET_NAME: this.diffStructure[j].FLEX_VALUE_SET_NAME + }); + break; + } + } + } else { + let x = document.getElementById( + this.diffStructure[j].APPLICATION_COLUMN_NAME + ) as HTMLInputElement; + let text = x.value; + let val = x.dataset.colmText; + if ( + (val == undefined || val == "") && + parentsList[i].IsRequired == "REQUIRED" + ) { + //alert(parentsList[i].Name +" Is required"); + return false; + } else { + } + if (text == undefined) { + text = ""; + } + parentArr.push({ + SEGMENT_NAME: this.diffStructure[j].SEGMENT_NAME, + VALUE_COLUMN_NAME: text, + DESCRIPTION: "", + ID_COLUMN_NAME: val, + FLEX_VALUE_SET_NAME: this.diffStructure[j].FLEX_VALUE_SET_NAME + }); + break; + } + } + } + } + return parentArr; + } + + isStandardTimeVal(obj: any): boolean { + let isSt: boolean = false; + if (obj.FORMAT_TYPE == "I") { + // standard time + //if(obj.DEFAULT_TYPE=="C" || obj.DEFAULT_TYPE=="D" || obj.DEFAULT_TYPE=="P"||obj.DEFAULT_TYPE=="S"){//constant + isSt = true; + //} + } + return isSt; + } + isStandardDateTimeVal(obj: any): boolean { + let isSt: boolean = false; + if (obj.FORMAT_TYPE == "Y") { + // standard date time + //if(obj.DEFAULT_TYPE=="C" || obj.DEFAULT_TYPE=="D" || obj.DEFAULT_TYPE=="P"||obj.DEFAULT_TYPE=="S"){//constant + isSt = true; + //} + } + return isSt; + } + + isStandardDateTime(obj: any): boolean { + let isSt: boolean = false; + if (obj.FORMAT_TYPE == "Y") { + // standard date time + if ( + obj.DEFAULT_TYPE == "C" || + obj.DEFAULT_TYPE == "D" || + obj.DEFAULT_TYPE == "P" || + obj.DEFAULT_TYPE == "S" + ) { + //constant + isSt = true; + } + } + return isSt; + } + isStandardTime(obj: any): boolean { + let isSt: boolean = false; + if (obj.FORMAT_TYPE == "I") { + // standard date time + if ( + obj.DEFAULT_TYPE == "C" || + obj.DEFAULT_TYPE == "D" || + obj.DEFAULT_TYPE == "P" || + obj.DEFAULT_TYPE == "S" + ) { + //constant + isSt = true; + } + } + return isSt; + } + + isStandardDate(obj: any): boolean { + let isSt: boolean = false; + if (obj.FORMAT_TYPE == "X") { + // standard date + if ( + obj.DEFAULT_TYPE == "C" || + obj.DEFAULT_TYPE == "D" || + obj.DEFAULT_TYPE == "P" || + obj.DEFAULT_TYPE == "S" + ) { + //constant + isSt = true; + } + } + return isSt; + } + + fixTransactionNo(): any[] { + const list: any = []; + let newIndex = 1; + const length: number = this.validEitTransactionTbl.length; + for (let i = 0; i < length; i++) { + // let item :any={}; + const item = Object.assign({}, this.validEitTransactionTbl[i]); + const transNo: number = item.TRANSACTION_NUMBER; + const obj: any = item; + if (i == 0) { + obj.TRANSACTION_NUMBER = newIndex; + list.push(obj); + } else { + const prevEl: any = this.validEitTransactionTbl[i - 1].TRANSACTION_NUMBER; + if (transNo == prevEl) { + obj.TRANSACTION_NUMBER = newIndex; + list.push(obj); + } else { + newIndex++; + obj.TRANSACTION_NUMBER = newIndex; + list.push(obj); + } + } + } + return list; + } + removeItems(transNo) { + const list = []; + for (let i = 0; i < this.validEitTransactionTbl.length; i++) { + if (this.validEitTransactionTbl[i].TRANSACTION_NUMBER != transNo) { + list.push(this.validEitTransactionTbl[i]); + } + } + this.validEitTransactionTbl = list; + } + submitTransaction() { + // (this.elementRef.nativeElement.querySelectorAll( + // "ion-item" + // ) as HTMLElement[]).forEach(x => { + // x.classList.add("ng-touched"); + // x.classList.remove("ng-untouched"); + // }); + + // let arrValues = this.getElementsValues(); + + // if (arrValues) { + // if (!this.startDate || !this.endDate) { + // //this.common.showRequiredMsg(); + // return false; + // } + // let Sdata = moment(this.startDate).format("MM/DD/YYYY"); + // let Edata = moment(this.endDate).format("MM/DD/YYYY"); + + this.eitRequest = new EitRequest(); + const list: any = this.getElementsValues(); + this.eitRequest.EITTransactionTBL = list; + this.eitRequest.P_SELECTED_EMPLOYEE_NUMBER = this.selEmp; + 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; + this.eitRequest.P_DESC_FLEX_NAME = this.template.CONCURRENT_PROGRAM_NAME; + // this.reportSubmitRequest = {} + this.reports + .submitTransaction(this.eitRequest, {}, this.ts.trPK('general', 'retry')) + .subscribe((result: any) => { + this.handleSubmitAbsence(result); + }); + } + + + + private handleSubmitAbsence(result) { + if (this.cs.validResponse(result)) { + if (this.getPassdirfromNotifiPage) { + //this.cs.sharedService.setSharedData(result.ResubmitAbsenceTransactionList.P_TRANSACTION_ID, AbsenceResponse.SHARED_DATA); + this.cs.openConfirmAbsece(); + + } else { + //this.cs.sharedService.setSharedData(result.SumbitAbsenceTransactionList.P_TRANSACTION_ID, AbsenceResponse.SHARED_DATA); + this.cs.openConfirmAbsece(); + + } + } + } + public getElementsValues(): any { + this.updatedValues = []; //fill updated list + let valuseArr: any = []; + let varcharValue: any = null; + let numbervalue: any = 0; + let dateValue: any = null; + let transNo: number = this.comtransNo; + let textValue: any; + // if(this.ExtraObj.transactionNo) + // transNo=this.ExtraObj.transactionNo; + for (let i = 0; i < this.diffStructure.length; i++) { + varcharValue = null; + numbervalue = null; + dateValue = null; + /*********set transaction No of the updated object ********/ + if (this.getPassdirfromNotifiPage) { + let updatedObj = this.validateEitObj.find( + x => + x.APPLICATION_COLUMN_NAME == + this.diffStructure[i].APPLICATION_COLUMN_NAME + ); + let y = updatedObj; + transNo = y.TRANSACTION_NUMBER; // set the transaction number for all items in the updated loop + } + if (this.diffStructure[i].DISPLAY_FLAG != "N") { + if (this.diffStructure[i].VALIDATION_TYPE == "N") { + let elem = document.getElementById( + this.diffStructure[i].APPLICATION_COLUMN_NAME + ) as HTMLInputElement; + let elemVal = (document.getElementById( + this.diffStructure[i].APPLICATION_COLUMN_NAME + ) as HTMLInputElement).value; + textValue = elemVal; + //let elemVal= (document.getElementById(this.eitResponse[i].APPLICATION_COLUMN_NAME)).value; + if ( + this.diffStructure[i].FORMAT_TYPE == "X" && + this.diffStructure[i].DISPLAY_FLAG != "N" + ) { + //date + elemVal = this.cs.formatDate(elemVal); + } else if ( + this.diffStructure[i].FORMAT_TYPE == "Y" && + this.diffStructure[i].DISPLAY_FLAG != "N" + ) { + //standard date time + // elemVal = elem.dataset.dtvalue; + // elemVal = this.cs.formatStandardDate(elemVal); + elemVal = this.cs.formatDate(elemVal); + } else if ( + this.diffStructure[i].FORMAT_TYPE == "I" && + this.diffStructure[i].DISPLAY_FLAG != "N" + ) { + //time + if (elemVal.length > 5) { + elemVal = elemVal.substring(11, 16); + } else { + elemVal = elemVal; + } + } + if (this.diffStructure[i].REQUIRED_FLAG == "Y" && !elemVal) { + elem.classList.add("requiredClassElm"); + //this.common.showRequiredMsg(); + return false; + } else { + elem.classList.remove("requiredClassElm"); + } + // if (elemVal != 'null'){ + varcharValue = elemVal; + //} else{ + // elemVal = null; + // } + valuseArr.push({ + TRANSACTION_NUMBER: transNo, + NAME: this.diffStructure[i].APPLICATION_COLUMN_NAME, + VARCHAR2_VALUE: varcharValue, + NUMBER_VALUE: numbervalue, + DATE_VALUE: dateValue + }); + } else { + let x = document.getElementById( + this.diffStructure[i].APPLICATION_COLUMN_NAME + ) as HTMLSelectElement; + if (this.diffStructure[i].READ_ONLY == "Y") { + let text = x.value; + let val = x.dataset.colmText; + varcharValue = val; + textValue = text; + } else { + let val = x.options[x.selectedIndex] + ? x.options[x.selectedIndex].value + : null; + let txt = x.options[x.selectedIndex] + ? x.options[x.selectedIndex].text + : null; + varcharValue = val; + textValue = txt; + } + if (this.diffStructure[i].REQUIRED_FLAG == "Y" && !varcharValue) { + x.classList.add("requiredClassElm"); + //this.common.showRequiredMsg(); + return false; + } else { + x.classList.remove("requiredClassElm"); + } + + valuseArr.push({ + TRANSACTION_NUMBER: transNo, + NAME: this.diffStructure[i].APPLICATION_COLUMN_NAME, + VARCHAR2_VALUE: varcharValue, + NUMBER_VALUE: numbervalue, + DATE_VALUE: dateValue + }); + } //end else + } else { + let x = document.getElementById( + this.diffStructure[i].APPLICATION_COLUMN_NAME + ) as HTMLSelectElement; + let val = x.dataset.colmText; + textValue = x.value; + if (this.diffStructure[i].REQUIRED_FLAG == "Y" && !val) { + x.classList.add("requiredClassElm"); + //this.common.showRequiredMsg(); + return false; + } else { + x.classList.remove("requiredClassElm"); + } + if (val) varcharValue = val; + valuseArr.push({ + TRANSACTION_NUMBER: transNo, + NAME: this.diffStructure[i].APPLICATION_COLUMN_NAME, + VARCHAR2_VALUE: varcharValue, + NUMBER_VALUE: numbervalue, + DATE_VALUE: dateValue + }); + } + + if (this.getPassdirfromNotifiPage) { + let updatedObj = this.validateEitObj.find( + x => + x.APPLICATION_COLUMN_NAME == + this.diffStructure[i].APPLICATION_COLUMN_NAME + ); + let y = updatedObj; + y.VARCHAR2_VALUE = varcharValue; + y.NUMBER_VALUE = numbervalue; + y.DATE_VALUE = dateValue; + y.SEGMENT_VALUE_DSP = textValue; + transNo = y.TRANSACTION_NUMBER; // set the transaction number for all items in the updated loop + this.updatedValues.push(y); + } else { + if (this.validateEitObj && this.eitSubmitAction == EIT_ACTION.UPDATE) { + let updatedObj = this.validateEitObj.find( + x => + x.APPLICATION_COLUMN_NAME == + this.diffStructure[i].APPLICATION_COLUMN_NAME + ); + let y = updatedObj; + y.VARCHAR2_VALUE = varcharValue; + y.NUMBER_VALUE = numbervalue; + y.DATE_VALUE = dateValue; + y.SEGMENT_VALUE_DSP = textValue; + transNo = transNo; // set the transaction number for all items in the updated loop + this.updatedValues.push(y); + } else { + let y = { + TRANSACTION_NUMBER: transNo, + VARCHAR2_VALUE: varcharValue, + NUMBER_VALUE: numbervalue, + DATE_VALUE: dateValue, + SEGMENT_VALUE_DSP: textValue, + APPLICATION_COLUMN_NAME: this.diffStructure[i] + .APPLICATION_COLUMN_NAME, + DATATYPE: this.diffStructure[i].DATATYPE, + DESC_FLEX_CONTEXT_CODE: this.diffStructure[i].DESC_FLEX_CONTEXT_CODE, + DESC_FLEX_NAME: this.diffStructure[i].DESC_FLEX_NAME, + DISPLAY_FLAG: this.diffStructure[i].DISPLAY_FLAG, + SEGMENT_NAME: this.diffStructure[i].SEGMENT_NAME, + SEGMENT_PROMPT: this.diffStructure[i].SEGMENT_PROMPT + }; + transNo = transNo; // set the transaction number for all items in the updated loop + this.updatedValues.push(y); + } + } + } // end for + + if (this.getPassdirfromNotifiPage) { + let updatedObj1 = this.validateEitObj.find( + x => x.APPLICATION_COLUMN_NAME === "PEI_ACTION" + ); + let updatedObj2 = this.validateEitObj.find( + x => x.APPLICATION_COLUMN_NAME === "PEI_EXTRA_INFO_ID" + ); + let updatedObj3 = this.validateEitObj.find( + x => x.APPLICATION_COLUMN_NAME === "PEI_OBJECT_VERSION_NUMBER" + ); + this.updatedValues.push(updatedObj1); + this.updatedValues.push(updatedObj2); + this.updatedValues.push(updatedObj3); + valuseArr = this.fillExtraInformation( + valuseArr, + updatedObj1.VARCHAR2_VALUE, + updatedObj2.NUMBER_VALUE, + updatedObj3.NUMBER_VALUE, + transNo + ); + } else { + if (this.eitSubmitAction == EIT_ACTION.ADD) { + this.updatedValues = this.fillExtraValuesUpdated( + this.updatedValues, + "NEW_ROW", + -1, + 0, + transNo + ); + valuseArr = this.fillExtraInformation( + valuseArr, + "NEW_ROW", + -1, + 0, + transNo + ); + } else if (this.eitSubmitAction == EIT_ACTION.UPDATE) { + valuseArr = this.fillExtraInformation( + valuseArr, + "UPDATE_ROW", + this.ExtraObj.peiExtraInfoID, + this.ExtraObj.peiObjVer, + transNo + ); + } else if (this.eitSubmitAction == EIT_ACTION.DELETE) { + valuseArr = this.fillExtraInformation( + valuseArr, + "DELETE_ROW", + this.ExtraObj.peiExtraInfoID, + this.ExtraObj.peiObjVer, + transNo + ); + } + } + return valuseArr; + } // end getElementsValues + fillExtraInformation( + values: any, + peiAction: string, + peiExtraInfoID: number, + peiObjVer: number, + transNo: number + ): any { + values.push({ + TRANSACTION_NUMBER: transNo, + NAME: "PEI_ACTION", + VARCHAR2_VALUE: peiAction, + NUMBER_VALUE: null, + DATE_VALUE: null + }); + values.push({ + TRANSACTION_NUMBER: transNo, + NAME: "PEI_EXTRA_INFO_ID", + VARCHAR2_VALUE: null, + NUMBER_VALUE: peiExtraInfoID, + DATE_VALUE: null + }); + values.push({ + TRANSACTION_NUMBER: transNo, + NAME: "PEI_OBJECT_VERSION_NUMBER", + VARCHAR2_VALUE: null, + NUMBER_VALUE: peiObjVer, + DATE_VALUE: null + }); + return values; + } + fillExtraValuesUpdated( + values: any, + peiAction: string, + peiExtraInfoID: number, + peiObjVer: number, + transNo: number + ): any { + let obj1 = { + TRANSACTION_NUMBER: transNo, + VARCHAR2_VALUE: peiAction, + NUMBER_VALUE: null, + DATE_VALUE: null, + SEGMENT_VALUE_DSP: "", + APPLICATION_COLUMN_NAME: "PEI_ACTION", + DATATYPE: "VARCHAR2", + DESC_FLEX_CONTEXT_CODE: "", + DESC_FLEX_NAME: "", + DISPLAY_FLAG: "N", + SEGMENT_NAME: "", + SEGMENT_PROMPT: "" + }; + let obj2 = { + TRANSACTION_NUMBER: 1, + APPLICATION_COLUMN_NAME: "PEI_OBJECT_VERSION_NUMBER", + VARCHAR2_VALUE: null, + NUMBER_VALUE: peiObjVer, + DATATYPE: "NUMBER", + SEGMENT_VALUE_DSP: "", + DATE_VALUE: null, + DESC_FLEX_CONTEXT_CODE: "", + DESC_FLEX_NAME: "", + DISPLAY_FLAG: "N", + SEGMENT_NAME: "", + SEGMENT_PROMPT: "" + }; + let obj3 = { + APPLICATION_COLUMN_NAME: "PEI_EXTRA_INFO_ID", + DATATYPE: "NUMBER", + DATE_VALUE: null, + DESC_FLEX_CONTEXT_CODE: "", + DESC_FLEX_NAME: "", + DISPLAY_FLAG: "N", + NUMBER_VALUE: peiExtraInfoID, + SEGMENT_NAME: "", + SEGMENT_PROMPT: "", + SEGMENT_VALUE_DSP: "", + TRANSACTION_NUMBER: transNo, + VARCHAR2_VALUE: null + }; + values.push(obj1); + values.push(obj2); + values.push(obj3); + return values; + } + selectTemplates() { + this.elementRef + .nativeElement.querySelectorAll('#containerDiv')[0].innerHTML = ''; + this.getCppDiffStructure(this.template); + } + +} diff --git a/Mohem/src/app/reports/report-service.service.spec.ts b/Mohem/src/app/reports/report-service.service.spec.ts new file mode 100644 index 00000000..dbf6efe5 --- /dev/null +++ b/Mohem/src/app/reports/report-service.service.spec.ts @@ -0,0 +1,12 @@ +import { TestBed } from '@angular/core/testing'; + +import { ReportServiceService } from './report-service.service'; + +describe('ReportServiceService', () => { + beforeEach(() => TestBed.configureTestingModule({})); + + it('should be created', () => { + const service: ReportServiceService = TestBed.get(ReportServiceService); + expect(service).toBeTruthy(); + }); +}); diff --git a/Mohem/src/app/reports/report-service.service.ts b/Mohem/src/app/reports/report-service.service.ts new file mode 100644 index 00000000..d8356223 --- /dev/null +++ b/Mohem/src/app/reports/report-service.service.ts @@ -0,0 +1,49 @@ +import { Injectable } from '@angular/core'; +import { AuthenticationService } from '../hmg-common/services/authentication/authentication.service'; +import { CommonService } from '../hmg-common/services/common/common.service'; +import { ConnectorService } from '../hmg-common/services/connector/connector.service'; + +@Injectable({ + providedIn: 'root' +}) +export class ReportServiceService { + public static GET_CONCURRENT_PROGRAM = 'Services/ERP.svc/REST/GET_CONCURRENT_PROGRAMS'; + public static GET_CPP_DIFF_STRUCTURE = 'Services/ERP.svc/REST/GET_CCP_DFF_STRUCTURE'; + public static SUBMIT_CPP_REQUEST = 'Services/ERP.svc/REST/SUBMIT_CCP_TRANSACTION' + constructor( + public con: ConnectorService, + private authService: AuthenticationService, + public cs: CommonService + ) { } + + getConcurrentProgram(request, onError, errorLabel) { + this.authService.authenticateRequest(request); + request.P_SELECTED_EMPLOYEE_NUMBER = request.UserName; + return this.con.postNoLoad( + ReportServiceService.GET_CONCURRENT_PROGRAM, + request, + onError, + errorLabel + ); + } + getCPPDiffStructure(request, onError, errorLabel) { + this.authService.authenticateRequest(request); + request.P_SELECTED_EMPLOYEE_NUMBER = request.UserName; + return this.con.postNoLoad( + ReportServiceService.GET_CPP_DIFF_STRUCTURE, + request, + onError, + errorLabel + ); + } + submitTransaction(request, onError, errorLabel) { + this.authService.authenticateRequest(request); + request.P_SELECTED_EMPLOYEE_NUMBER = request.UserName; + return this.con.postNoLoad( + ReportServiceService.SUBMIT_CPP_REQUEST, + request, + onError, + errorLabel + ); + } +} diff --git a/Mohem/src/app/reports/reports.module.ts b/Mohem/src/app/reports/reports.module.ts new file mode 100644 index 00000000..41be692b --- /dev/null +++ b/Mohem/src/app/reports/reports.module.ts @@ -0,0 +1,39 @@ +import { NgModule } from '@angular/core'; +import { CommonModule } from '@angular/common'; +import { FormsModule } from '@angular/forms'; +import { Routes, RouterModule } from '@angular/router'; + +import { IonicModule } from '@ionic/angular'; + +import { ReportsPage } from './reports.page'; +import { ConcurrentReportComponent } from './concurrent-report/concurrent-report.component'; +import { ReportServiceService } from './report-service.service'; +import { HmgCommonModule } from '../hmg-common/hmg-common.module'; + + +const routes: Routes = [ + { + path: '', + component: ReportsPage, + children: [ + { + path: 'concurrent-report', + component: ConcurrentReportComponent + }, + + ], + } +]; + +@NgModule({ + imports: [ + CommonModule, + FormsModule, + IonicModule, + RouterModule.forChild(routes), + HmgCommonModule + ], + declarations: [ReportsPage, ConcurrentReportComponent], + providers: [ReportServiceService] +}) +export class ReportsPageModule { } diff --git a/Mohem/src/app/reports/reports.page.html b/Mohem/src/app/reports/reports.page.html new file mode 100644 index 00000000..67cbe279 --- /dev/null +++ b/Mohem/src/app/reports/reports.page.html @@ -0,0 +1,3 @@ + + + \ No newline at end of file diff --git a/Mohem/src/app/reports/reports.page.scss b/Mohem/src/app/reports/reports.page.scss new file mode 100644 index 00000000..e69de29b diff --git a/Mohem/src/app/reports/reports.page.spec.ts b/Mohem/src/app/reports/reports.page.spec.ts new file mode 100644 index 00000000..94e66db4 --- /dev/null +++ b/Mohem/src/app/reports/reports.page.spec.ts @@ -0,0 +1,27 @@ +import { CUSTOM_ELEMENTS_SCHEMA } from '@angular/core'; +import { async, ComponentFixture, TestBed } from '@angular/core/testing'; + +import { ReportsPage } from './reports.page'; + +describe('ReportsPage', () => { + let component: ReportsPage; + let fixture: ComponentFixture; + + beforeEach(async(() => { + TestBed.configureTestingModule({ + declarations: [ ReportsPage ], + schemas: [CUSTOM_ELEMENTS_SCHEMA], + }) + .compileComponents(); + })); + + beforeEach(() => { + fixture = TestBed.createComponent(ReportsPage); + component = fixture.componentInstance; + fixture.detectChanges(); + }); + + it('should create', () => { + expect(component).toBeTruthy(); + }); +}); diff --git a/Mohem/src/app/reports/reports.page.ts b/Mohem/src/app/reports/reports.page.ts new file mode 100644 index 00000000..13faa7bd --- /dev/null +++ b/Mohem/src/app/reports/reports.page.ts @@ -0,0 +1,15 @@ +import { Component, OnInit } from '@angular/core'; + +@Component({ + selector: 'app-reports', + templateUrl: './reports.page.html', + styleUrls: ['./reports.page.scss'], +}) +export class ReportsPage implements OnInit { + + constructor() { } + + ngOnInit() { + } + +} diff --git a/Mohem/src/app/termination/service/termination-service.service.spec.ts b/Mohem/src/app/termination/service/termination-service.service.spec.ts new file mode 100644 index 00000000..f9172295 --- /dev/null +++ b/Mohem/src/app/termination/service/termination-service.service.spec.ts @@ -0,0 +1,12 @@ +import { TestBed } from '@angular/core/testing'; + +import { TerminationServiceService } from './termination-service.service'; + +describe('TerminationServiceService', () => { + beforeEach(() => TestBed.configureTestingModule({})); + + it('should be created', () => { + const service: TerminationServiceService = TestBed.get(TerminationServiceService); + expect(service).toBeTruthy(); + }); +}); diff --git a/Mohem/src/app/termination/service/termination-service.service.ts b/Mohem/src/app/termination/service/termination-service.service.ts new file mode 100644 index 00000000..d980c9d3 --- /dev/null +++ b/Mohem/src/app/termination/service/termination-service.service.ts @@ -0,0 +1,40 @@ +import { Injectable } from '@angular/core'; +import { AuthenticationService } from 'src/app/hmg-common/services/authentication/authentication.service'; +import { CommonService } from 'src/app/hmg-common/services/common/common.service'; +import { ConnectorService } from 'src/app/hmg-common/services/connector/connector.service'; + +@Injectable({ + providedIn: 'root' +}) +export class TerminationServiceService { + + public static GET_TERM_COLS_STRUCTURE = 'Services/ERP.svc/REST/GET_TERM_COLS_STRUCTURE'; + public static GET_TERM_DIFF_STRUCTURE = 'Services/ERP.svc/REST/GET_TERM_DFF_STRUCTURE'; + public static TERMINATION_PAGE = 'termination-page'; + + constructor( + public con: ConnectorService, + private authService: AuthenticationService, + public cs: CommonService + ) { } + getTerminationColStructure(request, onError, errorLabel) { + this.authService.authenticateRequest(request); + request.P_SELECTED_EMPLOYEE_NUMBER = request.UserName; + return this.con.postNoLoad( + TerminationServiceService.GET_TERM_COLS_STRUCTURE, + request, + onError, + errorLabel + ); + } + getTermDiffStructure(request, onError, errorLabel) { + this.authService.authenticateRequest(request); + request.P_SELECTED_EMPLOYEE_NUMBER = request.UserName; + return this.con.postNoLoad( + TerminationServiceService.GET_TERM_DIFF_STRUCTURE, + request, + onError, + errorLabel + ); + } +} diff --git a/Mohem/src/app/termination/termination-form/termination-form.component.html b/Mohem/src/app/termination/termination-form/termination-form.component.html new file mode 100644 index 00000000..f8fa6523 --- /dev/null +++ b/Mohem/src/app/termination/termination-form/termination-form.component.html @@ -0,0 +1,18 @@ + +
+ + + +
+
+
+
+
+
+ + +
+ + {{'vacation-rule, next-label' | translate}} +
+
\ No newline at end of file diff --git a/Mohem/src/app/termination/termination-form/termination-form.component.scss b/Mohem/src/app/termination/termination-form/termination-form.component.scss new file mode 100644 index 00000000..e69de29b diff --git a/Mohem/src/app/termination/termination-form/termination-form.component.spec.ts b/Mohem/src/app/termination/termination-form/termination-form.component.spec.ts new file mode 100644 index 00000000..bb916661 --- /dev/null +++ b/Mohem/src/app/termination/termination-form/termination-form.component.spec.ts @@ -0,0 +1,27 @@ +import { CUSTOM_ELEMENTS_SCHEMA } from '@angular/core'; +import { async, ComponentFixture, TestBed } from '@angular/core/testing'; + +import { TerminationFormComponent } from './termination-form.component'; + +describe('TerminationFormComponent', () => { + let component: TerminationFormComponent; + let fixture: ComponentFixture; + + beforeEach(async(() => { + TestBed.configureTestingModule({ + declarations: [ TerminationFormComponent ], + schemas: [CUSTOM_ELEMENTS_SCHEMA], + }) + .compileComponents(); + })); + + beforeEach(() => { + fixture = TestBed.createComponent(TerminationFormComponent); + component = fixture.componentInstance; + fixture.detectChanges(); + }); + + it('should create', () => { + expect(component).toBeTruthy(); + }); +}); diff --git a/Mohem/src/app/termination/termination-form/termination-form.component.ts b/Mohem/src/app/termination/termination-form/termination-form.component.ts new file mode 100644 index 00000000..f175165a --- /dev/null +++ b/Mohem/src/app/termination/termination-form/termination-form.component.ts @@ -0,0 +1,1024 @@ +import { Component, ElementRef, OnInit } from '@angular/core'; + +import * as moment from 'moment'; +import { EitService } from 'src/app/eit/services/eit.service'; +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 { DateTimeInput } from 'src/app/uI-elements/date-time.input'; +import { DateInput } from 'src/app/uI-elements/date.input'; +import { HiddenInput } from 'src/app/uI-elements/hidden.input'; +import { NumberInput } from 'src/app/uI-elements/number.input'; +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 { TerminationServiceService } from '../service/termination-service.service'; + + +@Component({ + selector: 'app-termination-form', + templateUrl: './termination-form.component.html', + styleUrls: ['./termination-form.component.scss'], +}) +export class TerminationFormComponent implements OnInit { + public selectedMenu; + public diffStructure = []; + public termColStructure = []; + public isUpdate: boolean; + private eitVALSettoCall: any = []; + private textInput; + private numberInput; + private dateInput; + public direction: string; + private datetimeInput; + private timeInput; + private selectInput; + private hiddenInput; + private validateEitObj: any = []; + public menuType: any; + public respID; + public selEmp; + public eitRequest; + private ExtraObj: any = {}; + private arrValues: any = []; + selMenu: MenuResponse; + private country; + private updatedValues; + private effectiveDate; + private comtransNo; + private reportSubmitRequest = {}; + getPassdirfromNotifiPage: boolean = false; + private startDate; + private endDate; + constructor(public cs: CommonService, private elementRef: ElementRef, public terminationFormService: TerminationServiceService, public ts: TranslatorService, public eitService: EitService) { } + + ngOnInit() { + this.getPassdirfromNotifiPage = this.cs.sharedService.getSharedData('dirfromNotificationPage'); + this.selectedMenu = this.cs.sharedService.getSharedData(TerminationServiceService.TERMINATION_PAGE, false); + this.getTerminationCol(); + this.direction = TranslatorService.getCurrentLanguageName(); + this.effectiveDate = new Date(); + } + getTerminationCol() { + this.terminationFormService.getTerminationColStructure({ + P_FUNCTION_NAME: this.selectedMenu.P_FUNCTION_NAME + }, () => { }, this.ts.trPK('general', 'retry')).subscribe((response) => { + this.termColStructure = response; + console.log(response); + this.getTermDiffStructure(); + }) + } + getTermDiffStructure() { + this.terminationFormService.getTermDiffStructure({ + P_DESC_FLEX_CONTEXT_CODE: null, + P_FUNCTION_NAME: this.selectedMenu.FUNCTION_NAME + }, () => { }, this.ts.trPK('general', 'retry')).subscribe((response) => { + console.log("Diff Structure"); + console.log(response); + this.handleDiffStructure(response); + }) + } + handleDiffStructure(result) { + if (result.GetCcpDffStructureList != null) { + this.diffStructure = result.GetCcpDffStructureList; + this.drawEitFields(result.GetCcpDffStructureList); + if (this.isUpdate) { + //this.submitAbsObjList = this.cs.sharedService.getSharedData(ProfileService.EMP_ADDRESS); + //this.fillAbsStructure(); + } + } + } + private drawEitFields(feildsList) { + const containerId = "containerDiv"; + this.eitVALSettoCall = []; + for (let i = 0; i < feildsList.length; i++) { + let defaultVal: string = ""; + let defaultValText: string = ""; + + if (feildsList[i].DISPLAY_FLAG != "N") { + //check if the field should be displayed + if (feildsList[i].VALIDATION_TYPE == "N") { + //text , date , time + if (feildsList[i].FORMAT_TYPE == "C") { + // character + this.textInput = new TextInput( + feildsList[i].SEGMENT_PROMPT, + feildsList[i].APPLICATION_COLUMN_NAME, + defaultVal, + containerId, + defaultValText, + feildsList[i].MOBILE_ENABLED, + feildsList[i].DISPLAY_FLAG, + feildsList[i].REQUIRED_FLAG + ); + } else if (feildsList[i].FORMAT_TYPE == "N") { + // number + this.numberInput = new NumberInput( + feildsList[i].SEGMENT_PROMPT, + feildsList[i].APPLICATION_COLUMN_NAME, + defaultVal, + containerId, + feildsList[i].MOBILE_ENABLED, + feildsList[i].DISPLAY_FLAG, + feildsList[i].REQUIRED_FLAG + ); + } else if (feildsList[i].FORMAT_TYPE == "X") { + // standard date + if ( + feildsList[i].DEFAULT_TYPE == "C" || + feildsList[i].DEFAULT_TYPE == "D" || + feildsList[i].DEFAULT_TYPE == "P" || + feildsList[i].DEFAULT_TYPE == "S" + ) { + //constant + this.dateInput = new DateInput( + feildsList[i].SEGMENT_PROMPT, + feildsList[i].APPLICATION_COLUMN_NAME, + this.cs.reverseFormatDate(defaultVal), + containerId, + feildsList[i].MOBILE_ENABLED, + feildsList[i].DISPLAY_FLAG, + feildsList[i].REQUIRED_FLAG, + this.direction + ); + } else { + this.dateInput = new DateInput( + feildsList[i].SEGMENT_PROMPT, + feildsList[i].APPLICATION_COLUMN_NAME, + "", + containerId, + feildsList[i].MOBILE_ENABLED, + feildsList[i].DISPLAY_FLAG, + feildsList[i].REQUIRED_FLAG, + this.direction + ); + } + } else if (feildsList[i].FORMAT_TYPE == "Y") { + // standard date time + if ( + feildsList[i].DEFAULT_TYPE == "C" || + feildsList[i].DEFAULT_TYPE == "D" || + feildsList[i].DEFAULT_TYPE == "P" || + feildsList[i].DEFAULT_TYPE == "S" + ) { + this.datetimeInput = new DateTimeInput( + feildsList[i].SEGMENT_PROMPT, + feildsList[i].APPLICATION_COLUMN_NAME, + this.cs.reverseFormatStandardDate(defaultVal), + containerId, + feildsList[i].MOBILE_ENABLED, + feildsList[i].DISPLAY_FLAG, + feildsList[i].REQUIRED_FLAG, + this.direction + ); + } else { + this.datetimeInput = new DateTimeInput( + feildsList[i].SEGMENT_PROMPT, + feildsList[i].APPLICATION_COLUMN_NAME, + "", + containerId, + feildsList[i].MOBILE_ENABLED, + feildsList[i].DISPLAY_FLAG, + feildsList[i].REQUIRED_FLAG, + this.direction + ); + } + const elem = document.getElementById( + feildsList[i].APPLICATION_COLUMN_NAME + ); + } else if (feildsList[i].FORMAT_TYPE == "I") { + //time + if ( + feildsList[i].DEFAULT_TYPE == "C" || + feildsList[i].DEFAULT_TYPE == "D" || + feildsList[i].DEFAULT_TYPE == "P" || + feildsList[i].DEFAULT_TYPE == "S" + ) { + this.timeInput = new TimeInput( + feildsList[i].SEGMENT_PROMPT, + feildsList[i].APPLICATION_COLUMN_NAME, + "", + containerId, + feildsList[i].MOBILE_ENABLED, + feildsList[i].DISPLAY_FLAG, + feildsList[i].REQUIRED_FLAG, + this.direction + ); + } else { + this.timeInput = new TimeInput( + feildsList[i].SEGMENT_PROMPT, + feildsList[i].APPLICATION_COLUMN_NAME, + "", + containerId, + feildsList[i].MOBILE_ENABLED, + feildsList[i].DISPLAY_FLAG, + feildsList[i].REQUIRED_FLAG, + this.direction + ); + } + } + } else { + if (feildsList[i].READ_ONLY == "Y") { + this.textInput = new TextInput( + feildsList[i].SEGMENT_PROMPT, + feildsList[i].APPLICATION_COLUMN_NAME, + defaultVal, + containerId, + defaultValText, + feildsList[i].MOBILE_ENABLED, + feildsList[i].DISPLAY_FLAG, + feildsList[i].REQUIRED_FLAG + ); + } else { + this.selectInput = new SelectInput( + feildsList[i].SEGMENT_PROMPT, + feildsList[i].APPLICATION_COLUMN_NAME, + defaultVal, + containerId, + feildsList[i].MOBILE_ENABLED, + feildsList[i].DISPLAY_FLAG, + feildsList[i].REQUIRED_FLAG + ); + this.fillDropdownList( + feildsList[i].SEGMENT_NAME, + feildsList[i].E_SERVICES_VS, + feildsList[i].E_SERVICES_DV + ); + } + } + this.bindHtmlElemEvents( + feildsList[i].APPLICATION_COLUMN_NAME, + feildsList[i] + ); + } else { + this.hiddenInput = new HiddenInput( + defaultVal, + feildsList[i].APPLICATION_COLUMN_NAME, + defaultValText, + containerId + ); + this.bindHtmlElemEvents( + feildsList[i].APPLICATION_COLUMN_NAME, + feildsList[i] + ); + } + } + if (this.validateEitObj && this.validateEitObj.length > 0) { + this.fillEITStructure(); + } + } + fillDropdownList(segmentName, optionList: any = [], DV: any = "") { + let elemID: any = ""; + let eitObj: any; + if (optionList.length > 0) { + for (let i = 0; i < this.diffStructure.length; i++) { + if (this.diffStructure[i].SEGMENT_NAME == segmentName) { + eitObj = this.diffStructure[i]; + if ( + this.diffStructure[i].READ_ONLY == "Y" || + this.diffStructure[i].DISPLAY_FLAG == "N" + ) { + return false; + } + elemID = this.diffStructure[i].APPLICATION_COLUMN_NAME; + break; + } + } + let select = document.getElementById(elemID) as HTMLSelectElement; + document.getElementById(elemID).innerHTML = ""; + if (eitObj.IsEmptyOption && eitObj.REQUIRED_FLAG == "N") { + var firstoption = document.createElement("option"); + firstoption.text = this.ts.trPK("general", "choose"); + firstoption.value = ""; + select.add(firstoption); + } + for (let i = 0; i < optionList.length; i++) { + var option = document.createElement("option"); + option.text = optionList[i].VALUE_COLUMN_NAME; + option.value = optionList[i].ID_COLUMN_NAME; + select.add(option); + } + if (select.dataset.hiddenval) { + select.value = select.dataset.hiddenval; + } else { + select.value = DV.P_ID_COLUMN_NAME; + } + select.disabled = false; + } + } + bindHtmlElemEvents(id, obj) { + const elem = document.getElementById(id); + console.log(elem); + console.log(obj); + const elemType = elem.tagName; + let changeEvent = "ionChange"; + + if (elemType == "SELECT") changeEvent = "change"; + + try { + elem.addEventListener(changeEvent, e => { + elem.classList.remove("requiredClassElm"); + if ( + obj.CHILD_SEGMENTS_VS_Splited && + obj.CHILD_SEGMENTS_VS_Splited.length > 0 + ) { + let listArray: any = obj.CHILD_SEGMENTS_VS_Splited; + listArray.forEach(element => { + this.emptyChildElement(element); + this.getValueSet(element); + }); + } + if ( + obj.CHILD_SEGMENTS_DV_Splited && + obj.CHILD_SEGMENTS_DV_Splited.length > 0 + ) { + let listArray: any = obj.CHILD_SEGMENTS_DV_Splited; + listArray.forEach(element => { + this.emptyChildElement(element); + for (let i = 0; i < this.diffStructure.length; i++) { + if (this.diffStructure[i].SEGMENT_NAME == element) { + this.getDefaultValue( + this.diffStructure[i], + this.diffStructure[i].DESC_FLEX_NAME, + this.diffStructure[i].DESC_FLEX_CONTEXT_CODE, + this.diffStructure[i].SEGMENT_NAME, + this.diffStructure[i].PARENT_SEGMENTS_VS_SplitedVS, + this.diffStructure[i].PARENT_SEGMENTS_DV_Splited + ); + } + } + }); + } + return false; + }); + } catch (e) { + console.log(e.status); + } + } + public getDefaultValue( + obj, + descFlexName, + descFlexContextCode, + segmentName, + parentValue, + ParentsList + ) { + let dependenciesList: any = []; + let parentVal: any = null; + let isStandardDate: boolean = false; + let isStandardTimeDate: boolean = false; + let isStandardTime: boolean = false; + let isHidden: boolean = false; + let isReadOnlyList: boolean = false; + let isSelectElement: boolean = false; + isStandardDate = this.isStandardDate(obj); + isStandardTimeDate = this.isStandardDateTime(obj); + isStandardTime = this.isStandardTime(obj); + if (obj.DISPLAY_FLAG == "N") isHidden = true; + if (obj.VALIDATION_TYPE != "N" && obj.READ_ONLY == "Y") { + isReadOnlyList = true; + } + if (obj.VALIDATION_TYPE != "N" && obj.READ_ONLY == "N") { + isSelectElement = true; + } + if ( + parentValue != "" && + (obj.VALIDATION_TYPE == "D" || obj.VALIDATION_TYPE == "Y") + ) { + let parvalue = this.getDependenciesParams(parentValue); + if (parvalue && parvalue[0]) parentVal = parvalue[0].ID_COLUMN_NAME; + else { + parentVal = null; + } + if (!parentVal) { + return false; + } + } + if (ParentsList != "") { + if (parentValue) ParentsList.concat(parentValue); + dependenciesList = this.getDependenciesParams(ParentsList); + if (!dependenciesList) { + return false; + } + } + + const body = { + P_SELECTED_EMPLOYEE_NUMBER: this.selEmp, + P_MENU_TYPE: this.menuType, + P_SELECTED_RESP_ID: this.respID, //-999, + P_DESC_FLEX_NAME: descFlexName, + P_DESC_FLEX_CONTEXT_CODE: descFlexContextCode, + P_SEGMENT_NAME: segmentName, + P_PARENT_VALUE: parentVal, + GetValueSetValuesTBL: dependenciesList + }; + + this.eitService.getDefaultValue(body).subscribe((result: any) => { + let elem = this.getElementByName(segmentName); + let obj = this.handleDefaultValueResult(result); + let val = obj.value; + let text = obj.text; + if (val == null) { val = ""; } + if (text == null) { text = ""; } + if (isStandardDate) { + console.log("isStandardDate"); + elem.value = this.cs.reverseFormatDate(val); + } else if (isStandardTimeDate) { + console.log("isStandardTimeDate"); + if (val) { + elem.dataset.dtvalue = this.cs.reverseFormatStandardDate(val); + elem.innerHTML = this.cs.reverseFormatStandardDate(val); + } else { + elem.dataset.dtvalue = ""; + elem.innerHTML = ""; + } + } else if (isStandardTime) { + console.log("isStandardTime"); + if (val) { + elem.dataset.dtvalue = val; + elem.innerHTML = val; + elem.value = val; + } else { + elem.dataset.dtvalue = ""; + elem.innerHTML = ""; + } + } else { + if (isSelectElement) { + let elem = this.getSelectElementByName(segmentName); + elem = document.getElementById(elem), + elem.value = val; + } else { + elem.value = val; + elem.innerText = text; + elem.setAttribute("value", val); + } + } + if (isHidden || isReadOnlyList) { + if (val) elem.dataset.colmText = val; + else elem.dataset.colmText = ""; + elem.value = text; + } + var event = new Event("ionChange"); + elem.dispatchEvent(event); + }); + } + + handleDefaultValueResult(result) { + let data = { + text: result.GetDefaultValueList.P_VALUE_COLUMN_NAME, + value: result.GetDefaultValueList.P_ID_COLUMN_NAME + }; + return data; + } + getSelectElementByName(segmentName) { + let elemID: any = ""; + for (let i = 0; i < this.diffStructure.length; i++) { + if (this.diffStructure[i].SEGMENT_NAME == segmentName) { + elemID = this.diffStructure[i].APPLICATION_COLUMN_NAME; + break; + } + } + return elemID; + } + getElementByName(segmentName) { + let elemID: any = ""; + for (let i = 0; i < this.diffStructure.length; i++) { + if (this.diffStructure[i].SEGMENT_NAME == segmentName) { + elemID = this.diffStructure[i].APPLICATION_COLUMN_NAME; + break; + } + } + return document.getElementById(elemID) as HTMLInputElement; + } + + fillEITStructure() { + var obj = { peiObjVer: null, peiExtraInfoID: null }; + for (let i = 0; i < this.validateEitObj.length; i++) { + let val: any; + if (this.validateEitObj[i].VARCHAR2_VALUE) + val = this.validateEitObj[i].VARCHAR2_VALUE; + else if (this.validateEitObj[i].DATE_VALUE) + val = this.validateEitObj[i].DATE_VALUE; + else if (this.validateEitObj[i].NUMBER_VALUE) + val = this.validateEitObj[i].NUMBER_VALUE; + const elem = document.getElementById( + this.validateEitObj[i].APPLICATION_COLUMN_NAME + ) as HTMLInputElement; + //obj.transactionNo=this.validateEitObj[i].TRANSACTION_NUMBER; + if (elem) { + if (val) { + let feldDetails = this.diffStructure.find( + x => + x.APPLICATION_COLUMN_NAME == + this.validateEitObj[i].APPLICATION_COLUMN_NAME + ); + if (feldDetails) { + let isStandardDate = this.isStandardDateVal(feldDetails); + let isStandardDateTime = this.isStandardDateTimeVal(feldDetails); + let isStandardTime = this.isStandardTimeVal(feldDetails); + if (isStandardDate) { + elem.value = this.cs.reverseFormatDate(val); + } else if (isStandardDateTime) { + elem.innerHTML = this.cs.reverseFormatStandardDate(val); + elem.dataset.dtvalue = this.cs.reverseFormatStandardDate(val); + } else if (isStandardTime) { + elem.innerHTML = val; + elem.dataset.dtvalue = val; + } else { + elem.value = val; + elem.setAttribute("value", elem.value); + } + if ( + feldDetails.DISPLAY_FLAG == "N" || + (feldDetails.VALIDATION_TYPE != "N" && + feldDetails.READ_ONLY == "Y") + ) { + elem.dataset.colmText = val; + elem.value = this.validateEitObj[i].SEGMENT_VALUE_DSP; + elem.setAttribute("value", elem.value); + } + } + elem.dataset.hiddenval = val; //hide the value to set it after calling get value set + if ( + feldDetails.CHILD_SEGMENTS_VS_Splited && + feldDetails.CHILD_SEGMENTS_VS_Splited.length > 0 + ) { + let listArray: any = feldDetails.CHILD_SEGMENTS_VS_Splited; + listArray.forEach(element => { + this.getValueSet(element); + }); + } + // var event = new Event('change'); + // elem.dispatchEvent(event); + } + } else { + if ( + this.validateEitObj[i].APPLICATION_COLUMN_NAME == + "PEI_OBJECT_VERSION_NUMBER" + ) + obj.peiObjVer = this.validateEitObj[i].NUMBER_VALUE; + else if ( + this.validateEitObj[i].APPLICATION_COLUMN_NAME == "PEI_EXTRA_INFO_ID" + ) + obj.peiExtraInfoID = this.validateEitObj[i].NUMBER_VALUE; + } + } + this.ExtraObj = obj; + } + public getValueSet(segmentName) { + let descFlexName: any = ""; + let descFlexContextCode: any = ""; + let parentValue: any = []; + let ParentsList: any = []; + let parentVal: any = null; + let dependenciesList: any = []; + let validationType: string = ""; + + for (let i = 0; i < this.diffStructure.length; i++) { + if (this.diffStructure[i].SEGMENT_NAME == segmentName) { + descFlexName = this.diffStructure[i].DESC_FLEX_NAME; + descFlexContextCode = this.diffStructure[i].DESC_FLEX_CONTEXT_CODE; + parentValue = this.diffStructure[i].PARENT_SEGMENTS_VS_SplitedVS; + ParentsList = this.diffStructure[i].PARENT_SEGMENTS_VS_SplitedVS; + validationType = this.diffStructure[i].VALIDATION_TYPE; + break; + } + } + if (parentValue != "" && (validationType == "D" || validationType == "Y")) { + let parvalue = this.getDependenciesParams(parentValue); + if (parvalue && parvalue[0]) parentVal = parvalue[0].ID_COLUMN_NAME; + else { + parentVal = null; + } + if (!parentVal) { + return false; + } + } + if (ParentsList != "") { + dependenciesList = this.getDependenciesParams(ParentsList); + if (!dependenciesList) { + return false; + } + } + const body = { + P_SELECTED_EMPLOYEE_NUMBER: this.selEmp, + P_MENU_TYPE: this.menuType, + P_SELECTED_RESP_ID: this.respID, //-999, + P_DESC_FLEX_NAME: descFlexName, + P_DESC_FLEX_CONTEXT_CODE: descFlexContextCode, + P_SEGMENT_NAME: segmentName, + P_PARENT_VALUE: parentVal, + GetValueSetValuesTBL: dependenciesList, + P_PAGE_NUM: 1, + P_PAGE_LIMIT: 1000 + }; + + this.eitService.getSetValue(body).subscribe((result: any) => { + if (result.GetValueSetValuesList != null) { + this.fillDropdownList(segmentName, result.GetValueSetValuesList); + } + }); + let arr: any = []; + return arr; + } + isStandardDateVal(obj: any): boolean { + let isSt: boolean = false; + if (obj.FORMAT_TYPE == "X") { + + isSt = true; + + } + return isSt; + } + + emptyChildElement(segmentName) { + let elem = this.getElementByName(segmentName); + elem.value = null; + elem.innerHTML = ""; + if ("dtvalue" in elem.dataset) { + elem.dataset.dtvalue = ""; + } + if ("colmText" in elem.dataset) { + elem.dataset.colmText = ""; + } + var event = new Event("change"); + elem.dispatchEvent(event); + elem.classList.remove("requiredClassElm"); + } + getDependenciesParams(parentsList) { + let parentArr: any = []; + for (let i = 0; i < parentsList.length; i++) { + for (let j = 0; j < this.diffStructure.length; j++) { + if (this.diffStructure[j].SEGMENT_NAME == parentsList[i].Name) { + if (this.diffStructure[j].DISPLAY_FLAG != "N") { + if (this.diffStructure[j].VALIDATION_TYPE == "N") { + let idColName: string; + let val: any; + if ( + this.diffStructure[j].FORMAT_TYPE == "Y" || + this.diffStructure[j].FORMAT_TYPE == "I" + ) { + //standard date time or //time + let elem = document.getElementById( + this.diffStructure[j].APPLICATION_COLUMN_NAME + ) as HTMLDivElement; + val = elem.dataset.dtvalue; + if ( + (val == undefined || val == "") && + parentsList[i].IsRequired == "REQUIRED" + ) { + //alert(parentsList[i].Name +" Is required"); + return false; + } + idColName = val; + if (this.diffStructure[j].FORMAT_TYPE == "Y") + idColName = this.cs.formatStandardDate(val); + } else { + val = (document.getElementById( + this.diffStructure[j].APPLICATION_COLUMN_NAME + ) as HTMLInputElement).value; + if ( + (val == undefined || val == "") && + parentsList[i].IsRequired == "REQUIRED" + ) { + //alert(parentsList[i].Name +" Is required"); + return false; + } + idColName = val; + if (this.diffStructure[j].FORMAT_TYPE == "X") { + //date + // idColName = this.cs.formatDate(val); + idColName = this.cs.formatDateNew(val); + } + } + parentArr.push({ + SEGMENT_NAME: this.diffStructure[j].SEGMENT_NAME, + VALUE_COLUMN_NAME: val, + DESCRIPTION: "", + ID_COLUMN_NAME: idColName, + FLEX_VALUE_SET_NAME: this.diffStructure[j].FLEX_VALUE_SET_NAME + }); + break; + } else { + if (this.diffStructure[j].READ_ONLY != "Y") { + let x = document.getElementById( + this.diffStructure[j].APPLICATION_COLUMN_NAME + ) as HTMLSelectElement; + let text = x.options[x.selectedIndex] + ? x.options[x.selectedIndex].text + : ""; + let val = x.options[x.selectedIndex] + ? x.options[x.selectedIndex].value + : undefined; + if ( + (val == undefined || val == "") && + parentsList[i].IsRequired == "REQUIRED" + ) { + //alert(parentsList[i].Name +" Is required"); + return false; + } else { + } + if (text == undefined) { + text = ""; + } + parentArr.push({ + SEGMENT_NAME: this.diffStructure[j].SEGMENT_NAME, + VALUE_COLUMN_NAME: text, + DESCRIPTION: "", + ID_COLUMN_NAME: val, + FLEX_VALUE_SET_NAME: this.diffStructure[j].FLEX_VALUE_SET_NAME + }); + break; + } else { + let x = document.getElementById( + this.diffStructure[j].APPLICATION_COLUMN_NAME + ) as HTMLInputElement; + let text = x.value; + let val = x.dataset.colmText; + if ( + (val == undefined || val == "") && + parentsList[i].IsRequired == "REQUIRED" + ) { + //alert(parentsList[i].Name +" Is required"); + return false; + } else { + } + if (text == undefined) { + text = ""; + } + parentArr.push({ + SEGMENT_NAME: this.diffStructure[j].SEGMENT_NAME, + VALUE_COLUMN_NAME: text, + DESCRIPTION: "", + ID_COLUMN_NAME: val, + FLEX_VALUE_SET_NAME: this.diffStructure[j].FLEX_VALUE_SET_NAME + }); + break; + } + } + } else { + let x = document.getElementById( + this.diffStructure[j].APPLICATION_COLUMN_NAME + ) as HTMLInputElement; + let text = x.value; + let val = x.dataset.colmText; + if ( + (val == undefined || val == "") && + parentsList[i].IsRequired == "REQUIRED" + ) { + //alert(parentsList[i].Name +" Is required"); + return false; + } else { + } + if (text == undefined) { + text = ""; + } + parentArr.push({ + SEGMENT_NAME: this.diffStructure[j].SEGMENT_NAME, + VALUE_COLUMN_NAME: text, + DESCRIPTION: "", + ID_COLUMN_NAME: val, + FLEX_VALUE_SET_NAME: this.diffStructure[j].FLEX_VALUE_SET_NAME + }); + break; + } + } + } + } + return parentArr; + } + + isStandardTimeVal(obj: any): boolean { + let isSt: boolean = false; + if (obj.FORMAT_TYPE == "I") { + // standard time + //if(obj.DEFAULT_TYPE=="C" || obj.DEFAULT_TYPE=="D" || obj.DEFAULT_TYPE=="P"||obj.DEFAULT_TYPE=="S"){//constant + isSt = true; + //} + } + return isSt; + } + isStandardDateTimeVal(obj: any): boolean { + let isSt: boolean = false; + if (obj.FORMAT_TYPE == "Y") { + // standard date time + //if(obj.DEFAULT_TYPE=="C" || obj.DEFAULT_TYPE=="D" || obj.DEFAULT_TYPE=="P"||obj.DEFAULT_TYPE=="S"){//constant + isSt = true; + //} + } + return isSt; + } + + isStandardDateTime(obj: any): boolean { + let isSt: boolean = false; + if (obj.FORMAT_TYPE == "Y") { + // standard date time + if ( + obj.DEFAULT_TYPE == "C" || + obj.DEFAULT_TYPE == "D" || + obj.DEFAULT_TYPE == "P" || + obj.DEFAULT_TYPE == "S" + ) { + //constant + isSt = true; + } + } + return isSt; + } + isStandardTime(obj: any): boolean { + let isSt: boolean = false; + if (obj.FORMAT_TYPE == "I") { + // standard date time + if ( + obj.DEFAULT_TYPE == "C" || + obj.DEFAULT_TYPE == "D" || + obj.DEFAULT_TYPE == "P" || + obj.DEFAULT_TYPE == "S" + ) { + //constant + isSt = true; + } + } + return isSt; + } + + isStandardDate(obj: any): boolean { + let isSt: boolean = false; + if (obj.FORMAT_TYPE == "X") { + // standard date + if ( + obj.DEFAULT_TYPE == "C" || + obj.DEFAULT_TYPE == "D" || + obj.DEFAULT_TYPE == "P" || + obj.DEFAULT_TYPE == "S" + ) { + //constant + isSt = true; + } + } + return isSt; + } + + validateAbcenseTransaction() { + (this.elementRef.nativeElement.querySelectorAll( + "ion-item" + ) as HTMLElement[]).forEach(x => { + x.classList.add("ng-touched"); + x.classList.remove("ng-untouched"); + }); + + let arrValues = this.getElementsValues(); + + if (arrValues) { + if (!this.startDate || !this.endDate) { + //this.common.showRequiredMsg(); + return false; + } + let Sdata = moment(this.startDate).format("MM/DD/YYYY"); + let Edata = moment(this.endDate).format("MM/DD/YYYY"); + this.reportSubmitRequest = {} + // this.reports + // .submitTransaction(this.reportSubmitRequest, {}, this.ts.trPK('general', 'retry')) + // .subscribe((result: any) => { + // this.handleSubmitAbsence(result); + // }); + } + } + + + private handleSubmitAbsence(result) { + if (this.cs.validResponse(result)) { + if (this.getPassdirfromNotifiPage) { + //this.cs.sharedService.setSharedData(result.ResubmitAbsenceTransactionList.P_TRANSACTION_ID, AbsenceResponse.SHARED_DATA); + this.cs.openConfirmAbsece(); + + } else { + //this.cs.sharedService.setSharedData(result.SumbitAbsenceTransactionList.P_TRANSACTION_ID, AbsenceResponse.SHARED_DATA); + this.cs.openConfirmAbsece(); + + } + } + } getElementsValues() { + //this.updatedValues=[];//fill updated list + let valuseArr: any = []; + let varcharValue: any = null; + let numbervalue: any = 0; + let dateValue: any = null; + let textValue = ""; + let key: string = ""; + let obj: any = {}; + for (let i = 0; i < this.diffStructure.length; i++) { + varcharValue = null; + numbervalue = null; + dateValue = null; + if (this.diffStructure[i].DISPLAY_FLAG != "N") { + if (this.diffStructure[i].VALIDATION_TYPE == "N") { + let elem = document.getElementById( + this.diffStructure[i].APPLICATION_COLUMN_NAME + ) as HTMLInputElement; + let elemVal = ""; + if (elem.classList.contains('onic-date')) { + elemVal = (document.getElementById( + this.diffStructure[i].APPLICATION_COLUMN_NAME + ) as HTMLInputElement).value; + if (elemVal) { + elemVal = moment(elemVal).format("YYYY/MM/DD hh:mm:ss"); + } + + } else { + elemVal = (document.getElementById( + this.diffStructure[i].APPLICATION_COLUMN_NAME + ) as HTMLInputElement).value; + } + textValue = elemVal; + + if ( + this.diffStructure[i].FORMAT_TYPE == "X" && + this.diffStructure[i].DISPLAY_FLAG != "N" + ) { + //date + elemVal = this.cs.formatDate(elemVal); + } else if ( + this.diffStructure[i].FORMAT_TYPE == "Y" && + this.diffStructure[i].DISPLAY_FLAG != "N" + ) { + //standard date time + elemVal = elem.dataset.dtvalue; + // elemVal = this.common.formatStandardDate(elemVal); + } else if ( + this.diffStructure[i].FORMAT_TYPE == "I" && + this.diffStructure[i].DISPLAY_FLAG != "N" + ) { + //time + elemVal = elem.dataset.dtvalue; + } + if (this.diffStructure[i].REQUIRED_FLAG == "Y" && !elemVal) { + elem.classList.add("requiredClassElm"); + return false; + } else { + elem.classList.remove("requiredClassElm"); + } + if (elemVal) varcharValue = elemVal; + key = "P_" + this.diffStructure[i].APPLICATION_COLUMN_NAME; + // obj = {}; + obj[key] = varcharValue; + } else { + let x = document.getElementById( + this.diffStructure[i].APPLICATION_COLUMN_NAME + ) as HTMLSelectElement; + if (this.diffStructure[i].READ_ONLY == "Y") { + let text = x.value; + let val = x.dataset.colmText; + varcharValue = val; + textValue = text; + } else { + let val = x.options[x.selectedIndex] + ? x.options[x.selectedIndex].value + : null; + let txt = x.options[x.selectedIndex] + ? x.options[x.selectedIndex].text + : null; + varcharValue = val; + textValue = txt; + } + if ( + this.diffStructure[i].REQUIRED_FLAG == "Y" && + !varcharValue + ) { + x.classList.add("requiredClassElm"); + // this.common.showRequiredMsg(); + return false; + } else { + x.classList.remove("requiredClassElm"); + } + + key = "P_" + this.diffStructure[i].APPLICATION_COLUMN_NAME; + //obj = {}; + obj[key] = varcharValue; + } //end else + } else { + let x = document.getElementById( + this.diffStructure[i].APPLICATION_COLUMN_NAME + ) as HTMLSelectElement; + let val = x.dataset.colmText; + textValue = x.value; + if (this.diffStructure[i].REQUIRED_FLAG == "Y" && !varcharValue) { + x.classList.add("requiredClassElm"); + // this.common.showRequiredMsg(); + return false; + } else { + x.classList.remove("requiredClassElm"); + } + if (val) varcharValue = val; + key = "P_" + this.diffStructure[i].APPLICATION_COLUMN_NAME; + //obj = {}; + obj[key] = varcharValue; + } + } // end for + + valuseArr.push(obj); + return valuseArr; + } + + +} diff --git a/Mohem/src/app/termination/termination.module.ts b/Mohem/src/app/termination/termination.module.ts new file mode 100644 index 00000000..aadbde53 --- /dev/null +++ b/Mohem/src/app/termination/termination.module.ts @@ -0,0 +1,39 @@ +import { NgModule } from '@angular/core'; +import { CommonModule } from '@angular/common'; +import { FormsModule } from '@angular/forms'; +import { Routes, RouterModule } from '@angular/router'; + +import { IonicModule } from '@ionic/angular'; + +import { TerminationPage } from './termination.page'; +import { TerminationFormComponent } from './termination-form/termination-form.component'; +import { TerminationServiceService } from './service/termination-service.service'; +import { HmgCommonModule } from '../hmg-common/hmg-common.module'; + + +const routes: Routes = [ + { + path: '', + component: TerminationPage, + children: [ + { + path: 'termination-form', + component: TerminationFormComponent + }, + + ], + } +]; + +@NgModule({ + imports: [ + CommonModule, + FormsModule, + IonicModule, + RouterModule.forChild(routes), + HmgCommonModule + ], + declarations: [TerminationPage, TerminationFormComponent], + providers: [TerminationServiceService] +}) +export class TerminationPageModule { } diff --git a/Mohem/src/app/termination/termination.page.html b/Mohem/src/app/termination/termination.page.html new file mode 100644 index 00000000..67cbe279 --- /dev/null +++ b/Mohem/src/app/termination/termination.page.html @@ -0,0 +1,3 @@ + + + \ No newline at end of file diff --git a/Mohem/src/app/termination/termination.page.scss b/Mohem/src/app/termination/termination.page.scss new file mode 100644 index 00000000..e69de29b diff --git a/Mohem/src/app/termination/termination.page.spec.ts b/Mohem/src/app/termination/termination.page.spec.ts new file mode 100644 index 00000000..04fa359a --- /dev/null +++ b/Mohem/src/app/termination/termination.page.spec.ts @@ -0,0 +1,27 @@ +import { CUSTOM_ELEMENTS_SCHEMA } from '@angular/core'; +import { async, ComponentFixture, TestBed } from '@angular/core/testing'; + +import { TerminationPage } from './termination.page'; + +describe('TerminationPage', () => { + let component: TerminationPage; + let fixture: ComponentFixture; + + beforeEach(async(() => { + TestBed.configureTestingModule({ + declarations: [ TerminationPage ], + schemas: [CUSTOM_ELEMENTS_SCHEMA], + }) + .compileComponents(); + })); + + beforeEach(() => { + fixture = TestBed.createComponent(TerminationPage); + component = fixture.componentInstance; + fixture.detectChanges(); + }); + + it('should create', () => { + expect(component).toBeTruthy(); + }); +}); diff --git a/Mohem/src/app/termination/termination.page.ts b/Mohem/src/app/termination/termination.page.ts new file mode 100644 index 00000000..f821ad78 --- /dev/null +++ b/Mohem/src/app/termination/termination.page.ts @@ -0,0 +1,15 @@ +import { Component, OnInit } from '@angular/core'; + +@Component({ + selector: 'app-termination', + templateUrl: './termination.page.html', + styleUrls: ['./termination.page.scss'], +}) +export class TerminationPage implements OnInit { + + constructor() { } + + ngOnInit() { + } + +} diff --git a/Mohem/src/assets/imgs/no-images.png b/Mohem/src/assets/imgs/no-images.png new file mode 100644 index 0000000000000000000000000000000000000000..e4578a1229351f2e1830c421288e9b26a6c94095 GIT binary patch literal 38816 zcmce;cT`i|w>C;qKoPKlQdJaGNDyh#RTPw}(nF|94K<;6Mc_pQR3vl|5fBoJAc4?} zNC^Z12^|CpEfguCmv4plckVdclEpn7xsMKe6|l1@C+0z$tzy0yipRpIGeaQo0c}q&u)AB^R=f6 zSG)RNqeTa9U1=+J#99`Z=JW6w6Li$}k_AQPwQopB)7M5U_ll?qgJ^RM6~p z(D3lb$~>}8-@eS2a%u85J6&B;t;fumv#9fhqJo35qyv%ZV{{*12Kmo)O7Sagh3AB^ z6dp8BoTIz*;9!M%kiDgsowPqMP`H=1tDJI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