diff --git a/Mohem/src/app/app.scss b/Mohem/src/app/app.scss index 49bf94d3..34043d9e 100644 --- a/Mohem/src/app/app.scss +++ b/Mohem/src/app/app.scss @@ -7,12 +7,12 @@ .alert-radio-label.sc-ion-alert-md, .alert-radio-label.sc-ion-alert-ios { - white-space: normal; + //white-space: normal; } .alert-tappable.sc-ion-alert-md, .alert-tappable.sc-ion-alert-ios { - height: 50px; + //height: 50px; } .main-badge{ position: absolute; 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 e1ce2293..043f3322 100644 --- a/Mohem/src/app/hmg-common/services/connector/connector.service.ts +++ b/Mohem/src/app/hmg-common/services/connector/connector.service.ts @@ -21,7 +21,7 @@ export class ConnectorService { headers: new HttpHeaders({ 'Content-Type': 'application/json' }) }; public static retryTimes = 0; - public static timeOut = 120 * 1000; + public static timeOut = 240 * 1000; // public static host = 'http://10.50.100.113:6060/'; // development service public static host = 'https://uat.hmgwebservices.com/'; diff --git a/Mohem/src/app/notification/work-list-replacement-roll/work-list-replacement-roll.component.ts b/Mohem/src/app/notification/work-list-replacement-roll/work-list-replacement-roll.component.ts index 705bd712..e456a8b8 100644 --- a/Mohem/src/app/notification/work-list-replacement-roll/work-list-replacement-roll.component.ts +++ b/Mohem/src/app/notification/work-list-replacement-roll/work-list-replacement-roll.component.ts @@ -42,16 +42,21 @@ export class WorkListReplacementRollComponent implements OnInit { searchKeyEnter: boolean = false; messageSuccess: boolean =false; public direction: string; + P_RESPOND_ATTRIBUTES_TBL: any[]; constructor(public worklistService: WorklistService, private cs: CommonService, private ts: TranslatorService, public workListMainService: WorklistMainService, public modalCtrl: ModalController) { this.P_PAGE_NUM = 1; this.P_PAGE_LIMIT = 50; this.getPassActionMode = this.cs.sharedService.getSharedData('passActionMode', false); + console.log(this.getPassActionMode); + this.getPassNotificationDetails = this.cs.sharedService.getSharedData('passNotificationInfo', false); this.getpassResAttr = this.cs.sharedService.getSharedData('passResAttr', false); + console.log(this.getpassResAttr); this.pQuestion = this.cs.sharedService.getSharedData('pQuestion', false); if (this.getPassActionMode == "ANSWER_INFO") { this.isAnswer = true; } + this.WorkListReplacmentEmployeeObj.P_PAGE_NUM = this.P_PAGE_NUM; this.WorkListReplacmentEmployeeObj.P_PAGE_LIMIT = this.P_PAGE_LIMIT; @@ -210,17 +215,42 @@ export class WorkListReplacementRollComponent implements OnInit { console.log("selEmp "+ this.selEmp.USER_NAME); if (this.selectedUserInf && this.selectedUserInf.USER_NAME) { + console.log("userInfo "+this.selectedUserInf.USER_NAME); if (this.userNote) { + + if(this.getPassActionMode == "APPROVE_AND_FORWARD" || this.getPassActionMode == "FORWARD"){ + + let index_FORWARD = this.getpassResAttr.findIndex(x => x.ATTRIBUTE_NAME === "FORWARD_TO_USERNAME_RESPONSE"); + this.getpassResAttr[index_FORWARD].ATTRIBUTE_TEXT_VALUE = this.selectedUserInf.USER_NAME; + // this.userNote; + let index_Note = this.getpassResAttr.findIndex(x => x.ATTRIBUTE_NAME === "NOTE"); + this.getpassResAttr[index_Note].ATTRIBUTE_TEXT_VALUE = this.userNote; + + this.P_RESPOND_ATTRIBUTES_TBL= this.getpassResAttr; + console.log(this.P_RESPOND_ATTRIBUTES_TBL); + this.WorkListActionObj.P_FORWARD_TO_USER_NAME = this.selectedUserInf.USER_NAME; + this.WorkListActionObj.P_ACTION_MODE = this.getPassActionMode; + this.WorkListActionObj.P_COMMENTS =""// response Attr + this.WorkListActionObj.RespondAttributeList = this.P_RESPOND_ATTRIBUTES_TBL; + + }else{ + + + + + this.WorkListActionObj.P_FORWARD_TO_USER_NAME = this.selectedUserInf.USER_NAME; this.WorkListActionObj.P_ACTION_MODE = this.getPassActionMode; this.WorkListActionObj.P_COMMENTS = this.userNote;// response Attr // this.modalCtrl.dismiss(); + } this.workListMainService.actionButton(this.WorkListActionObj). subscribe((result: any) => { this.handleApplayActionResult(result); }); + } else { let msg: string = this.ts.trPK("replacementRoll", "enterNote"); this.cs.showErrorMessageDialog(() => { @@ -237,12 +267,13 @@ export class WorkListReplacementRollComponent implements OnInit { this.WorkListActionObj.P_FORWARD_TO_USER_NAME = null; this.WorkListActionObj.P_ACTION_MODE = this.getPassActionMode; this.WorkListActionObj.P_COMMENTS = this.userNote;// response Attr + // here must send response attr // this.modalCtrl.dismiss(); - this.workListMainService.actionButton(this.WorkListActionObj). - subscribe((result: any) => { - this.handleApplayActionResult(result); - }); + // this.workListMainService.actionButton(this.WorkListActionObj). + // subscribe((result: any) => { + // this.handleApplayActionResult(result); + // }); } else { let msg: string = this.ts.trPK("replacementRoll", "enterNote"); this.cs.showErrorMessageDialog(() => { diff --git a/Mohem/src/app/notification/worklist-main-mr/worklist-main-mr.component.html b/Mohem/src/app/notification/worklist-main-mr/worklist-main-mr.component.html index 576f9d2b..15fbfdae 100644 --- a/Mohem/src/app/notification/worklist-main-mr/worklist-main-mr.component.html +++ b/Mohem/src/app/notification/worklist-main-mr/worklist-main-mr.component.html @@ -185,24 +185,7 @@ - -
- -
-
- -
- - -
+ @@ -509,8 +492,8 @@ {{actionHistory.ACTION}} + [ngClass]="{'bg-blue-txt' : actionHistory.ACTION_CODE === 'SUBMIT' ,'bg-orange-txt' : actionHistory.ACTION_CODE === 'PENDING' ,'bg-red-txt' : actionHistory.ACTION_CODE === 'REJECT','bg-green-txt' : actionHistory.ACTION_CODE != 'PENDING' && actionHistory.ACTION_CODE != 'REJECT' && actionHistory.ACTION_CODE != 'SUBMIT'}" + class=""> {{actionHistory.ACTION}} @@ -571,14 +554,13 @@ --> - + -
+
@@ -597,12 +579,7 @@ - + - + @@ -359,7 +343,7 @@ {{actionHistory.ACTION}} @@ -421,7 +405,7 @@ -
+
diff --git a/Mohem/src/app/notification/worklist-main-pr/worklist-main-pr.component.ts b/Mohem/src/app/notification/worklist-main-pr/worklist-main-pr.component.ts index b3f12921..d581b7e7 100644 --- a/Mohem/src/app/notification/worklist-main-pr/worklist-main-pr.component.ts +++ b/Mohem/src/app/notification/worklist-main-pr/worklist-main-pr.component.ts @@ -144,7 +144,7 @@ export class WorklistMainPRComponent implements OnInit { intializeNotificationDetail() { if (this.messageSuccess) { - document.getElementById('notificationDynamicFields').innerHTML = ''; + document.getElementById('notificationDynamicFieldsPR').innerHTML = ''; } console.log('intializeNotificationDetail'); @@ -375,6 +375,11 @@ export class WorklistMainPRComponent implements OnInit { public nextNotfification() { //let itemExist = false; + if( document.getElementById("notificationDynamicFieldsPR") != null){ + + document.getElementById("notificationDynamicFieldsPR").innerHTML = ""; + + } let itemNo = this.getPassNotificationDetails.ROW_NUM; console.log(itemNo); let index = this.notificationArray.findIndex(x => x.ROW_NUM === itemNo); @@ -637,6 +642,8 @@ export class WorklistMainPRComponent implements OnInit { } getNotificationResAttr(notificationButtonsObj) { + console.log("getNotificationResAttr"); + this.worklistMainService .notificationResponseAttr(notificationButtonsObj) .subscribe((result: NotificatonButtonResponse) => { @@ -671,10 +678,12 @@ export class WorklistMainPRComponent implements OnInit { } // End handleWorkListButtonsResult notificationDynamicFields(notificationAttr) { - const containerId = 'notificationDynamicFields'; + const containerId = 'notificationDynamicFieldsPR'; for (let i = 0; i < notificationAttr.length; i++) { if (notificationAttr[i].ATTRIBUTE_TYPE == 'VARCHAR2') { this.textArea = new TextAreaInput(notificationAttr[i].ATTRIBUTE_DISPLAY_NAME, notificationAttr[i].ATTRIBUTE_NAME, '', containerId, '', '', ''); + console.log(this.textArea ); + } else if (notificationAttr[i].ATTRIBUTE_TYPE == 'ROLE') { } else if (notificationAttr[i].ATTRIBUTE_TYPE == 'DATE') { diff --git a/Mohem/src/app/notification/worklist-main/worklist-main.component.html b/Mohem/src/app/notification/worklist-main/worklist-main.component.html index fe27a6d1..b58a7b22 100644 --- a/Mohem/src/app/notification/worklist-main/worklist-main.component.html +++ b/Mohem/src/app/notification/worklist-main/worklist-main.component.html @@ -368,7 +368,7 @@
{{actionHistory.ACTION}} @@ -429,26 +429,7 @@ -
- - -
-
- -
- + @@ -457,6 +438,8 @@ + +
diff --git a/Mohem/src/app/notification/worklist-main/worklist-main.component.ts b/Mohem/src/app/notification/worklist-main/worklist-main.component.ts index 0a2eb0fc..44c227a5 100644 --- a/Mohem/src/app/notification/worklist-main/worklist-main.component.ts +++ b/Mohem/src/app/notification/worklist-main/worklist-main.component.ts @@ -138,6 +138,14 @@ export class WorklistMainComponent implements OnInit { }); } + //name=document.getElementById('notificationDynamicFields').value; + //removeElement('parentDiv', name);" + + + //var navbar = document.getElementById("notificationDynamicFields").value; + // document.querySelector('svg .gauge.chart > text').remove(); + // var inputValue = (document.getElementById("notificationDynamicFields")).value; + console.log(" this.selEmp" + this.selEmp); this.intializeNotificationDetail(); @@ -149,9 +157,11 @@ export class WorklistMainComponent implements OnInit { } intializeNotificationDetail() { + if (this.messageSuccess) { document.getElementById("notificationDynamicFields").innerHTML = ""; } + this.getPassNotificationDetails = this.common.sharedService.getSharedData( HomeComponent.NOTIFICATION_DATA, false @@ -355,6 +365,7 @@ export class WorklistMainComponent implements OnInit { setTimeout(() => { this.messageSuccess = false; this.openNotificationsDashboard(); + this.nextNotfification(); }, 5000); @@ -390,6 +401,11 @@ export class WorklistMainComponent implements OnInit { public nextNotfification() { //let itemExist = false; + if( document.getElementById("notificationDynamicFields") != null){ + + document.getElementById("notificationDynamicFields").innerHTML = ""; + + } let itemNo = this.getPassNotificationDetails.ROW_NUM; console.log(itemNo); let index = this.notificationArray.findIndex(x => x.ROW_NUM === itemNo); @@ -409,6 +425,7 @@ export class WorklistMainComponent implements OnInit { if(this.notificationArray[index].REQUEST_TYPE == "MR" ){ this.common.openWorklistMainMRPage() }else{ + this.intializeNotificationDetail(); } @@ -444,6 +461,8 @@ export class WorklistMainComponent implements OnInit { } this.P_RESPOND_ATTRIBUTES_TBL.push(obj); } + console.log("a"+ this.P_RESPOND_ATTRIBUTES_TBL); + let repUserName = this.selEmployeeID; if (this.hideForwordEmployee && this.hideForwordEmployee.ATTRIBUTE_NAME) { let obj: any = {}; @@ -452,6 +471,8 @@ export class WorklistMainComponent implements OnInit { obj.ATTRIBUTE_TEXT_VALUE = this.selEmployeeID; this.P_RESPOND_ATTRIBUTES_TBL.push(obj); } + + console.log( "b"+ this.P_RESPOND_ATTRIBUTES_TBL); if ( ButtonAction == "APPROVED" || @@ -576,6 +597,8 @@ export class WorklistMainComponent implements OnInit { this.P_RESPOND_ATTRIBUTES_TBL, WorklistMainComponent.PASS_RES_ATTR ); + console.log("c"+ this.P_RESPOND_ATTRIBUTES_TBL); + // this.common.openWorklistRollReplacement(); this.openRepRolModal(); } else if ( @@ -660,6 +683,7 @@ export class WorklistMainComponent implements OnInit { } getNotificationResAttr(notificationButtonsObj) { + console.log("getNotificationResAttr"); this.worklistMainService .notificationResponseAttr(notificationButtonsObj) .subscribe((result: NotificatonButtonResponse) => { @@ -696,6 +720,7 @@ export class WorklistMainComponent implements OnInit { for (let i = 0; i < notificationAttr.length; i++) { if (notificationAttr[i].ATTRIBUTE_TYPE == "VARCHAR2") { this.textArea = new TextAreaInput(notificationAttr[i].ATTRIBUTE_DISPLAY_NAME, notificationAttr[i].ATTRIBUTE_NAME, "", containerId, "", "", ""); + console.log(this.textArea ); } else if (notificationAttr[i].ATTRIBUTE_TYPE == "ROLE") { } else if (notificationAttr[i].ATTRIBUTE_TYPE == "DATE") { diff --git a/Mohem/src/app/uI-elements/text-area.input.ts b/Mohem/src/app/uI-elements/text-area.input.ts index b16fa4f6..a2e9e07b 100644 --- a/Mohem/src/app/uI-elements/text-area.input.ts +++ b/Mohem/src/app/uI-elements/text-area.input.ts @@ -15,6 +15,7 @@ export class TextAreaInput extends UiElement { } public getTemplate() { + console.log("getTemplate"); let requiredClass: string = ""; if (this.required == 'Y') requiredClass = "requiredClass" @@ -30,6 +31,7 @@ export class TextAreaInput extends UiElement { "" + this.label + "" + "" + this.value + "" + ""; + console.log("template"+ template); return template; } diff --git a/Mohem/src/app/vacation-rule/vacation-type/vacation-type.component.html b/Mohem/src/app/vacation-rule/vacation-type/vacation-type.component.html index 1706f90d..99e995af 100644 --- a/Mohem/src/app/vacation-rule/vacation-type/vacation-type.component.html +++ b/Mohem/src/app/vacation-rule/vacation-type/vacation-type.component.html @@ -72,10 +72,10 @@ - + {{'vacation-rule, notification' | translate}} - {{x.NOTIFICATION_DISPLAY_NAME}} diff --git a/Mohem/src/app/vacation-rule/vacation-type/vacation-type.component.scss b/Mohem/src/app/vacation-rule/vacation-type/vacation-type.component.scss index c42fe244..2edaaec8 100644 --- a/Mohem/src/app/vacation-rule/vacation-type/vacation-type.component.scss +++ b/Mohem/src/app/vacation-rule/vacation-type/vacation-type.component.scss @@ -91,6 +91,12 @@ color: black !important; .stepHeaderLebal{ margin:0; } + +.select-full-width { + max-width: 100% !important; + width: 100% !important; + padding-left: 0 !important; +} // .progcontainer { // margin: auto; // text-align: center; diff --git a/Mohem/src/theme/styles.scss b/Mohem/src/theme/styles.scss index 8dcf9cc4..e53c9d69 100644 --- a/Mohem/src/theme/styles.scss +++ b/Mohem/src/theme/styles.scss @@ -1514,3 +1514,8 @@ table.monthview-datetable th small { background: #094875; } } + +.alert-wrapper { + min-width: 80px;//what ever you like + } +