diff --git a/Mohem/src/app/app.component.ts b/Mohem/src/app/app.component.ts
index 9cdfc021..2c882ac2 100644
--- a/Mohem/src/app/app.component.ts
+++ b/Mohem/src/app/app.component.ts
@@ -57,6 +57,7 @@ export class AppComponent implements OnInit, AfterViewInit {
ngOnInit() {
this.initializeApp();
+
}
ngAfterViewInit() {}
initializeApp() {
@@ -94,9 +95,13 @@ export class AppComponent implements OnInit, AfterViewInit {
? user.CompanyImageDescription
: "Powered By Cloud Solutions";
this.User_name_Emp = user.EMPLOYEE_DISPLAY_NAME;
+ if(this.cs.getUpdateImage().status){
+ this.user_image =this.sanitizer.bypassSecurityTrustUrl("data:image/png;base64,"+this.cs.getUpdateImage().img);
+ }else{
this.user_image = user.EMPLOYEE_IMAGE
? "data:image/png;base64," + user.EMPLOYEE_IMAGE
: "../assets/imgs/profile.png";
+ }
this.User_Job_name=user.JOB_NAME;
console.log(user);
diff --git a/Mohem/src/app/home/home.page.ts b/Mohem/src/app/home/home.page.ts
index 02bde739..64d54133 100644
--- a/Mohem/src/app/home/home.page.ts
+++ b/Mohem/src/app/home/home.page.ts
@@ -320,9 +320,13 @@ export class HomePage implements OnInit {
this.userData,
AuthenticatedUser.SHARED_DATA
);
+ if(this.common.getUpdateImage().status){
+ this.userImage =this.sanitizer.bypassSecurityTrustUrl("data:image/png;base64,"+this.common.getUpdateImage().img);
+ }else{
this.userImage = user.EMPLOYEE_IMAGE
? 'data:image/png;base64,' + user.EMPLOYEE_IMAGE
: this.userImage;
+ }
this.callDashboardServices();
} else {
console.log(user);
diff --git a/Mohem/src/app/payslip/home/home.component.html b/Mohem/src/app/payslip/home/home.component.html
index 142a36a5..cb9a57a0 100644
--- a/Mohem/src/app/payslip/home/home.component.html
+++ b/Mohem/src/app/payslip/home/home.component.html
@@ -257,6 +257,7 @@
{{ts.trPK('payslip','payment-information')}}
+
@@ -265,7 +266,7 @@
-
+
@@ -276,7 +277,7 @@
-
+
@@ -285,7 +286,7 @@
-
+
@@ -297,7 +298,7 @@
-
+
@@ -306,10 +307,11 @@
-
+
+
\ No newline at end of file
diff --git a/Mohem/src/app/payslip/home/home.component.ts b/Mohem/src/app/payslip/home/home.component.ts
index 7fd9b363..8f826d99 100644
--- a/Mohem/src/app/payslip/home/home.component.ts
+++ b/Mohem/src/app/payslip/home/home.component.ts
@@ -257,7 +257,7 @@ getPaymentInfo(ActionContextID){
handleGetPaymentInfoResult(result){
if (result.GetPaymentInformationList != null) {
- this.GetPaymentInformationList = result.GetPaymentInformationList[0];
+ this.GetPaymentInformationList = result.GetPaymentInformationList;
}
}
diff --git a/Mohem/src/app/profile/edit-profile/edit-profile.component.ts b/Mohem/src/app/profile/edit-profile/edit-profile.component.ts
index 58c888f3..61b0d210 100644
--- a/Mohem/src/app/profile/edit-profile/edit-profile.component.ts
+++ b/Mohem/src/app/profile/edit-profile/edit-profile.component.ts
@@ -7,6 +7,7 @@ import { AuthenticatedUser } from "src/app/hmg-common/services/authentication/mo
import { PerformanceAppraisalResponse } from 'src/app/hmg-common/services/dashbored/performance-appraisal.response';
import { DashboredService } from 'src/app/hmg-common/services/dashbored/dashbored.service';
import { SharedDataService } from 'src/app/hmg-common/services/shared-data-service/shared-data.service';
+import { DomSanitizer } from '@angular/platform-browser';
// import { DomSanitizer } from '@angular/platform-browser';
@@ -35,17 +36,19 @@ export class EditProfileComponent implements OnInit {
public cs: CommonService,
public authService: AuthenticationService,
public DS :DashboredService,
- public sharedData: SharedDataService
+ public sharedData: SharedDataService,
+ public events: Events,
+ private sanitizer: DomSanitizer,
// private events: Events,
// private sanitizer: DomSanitizer,
)
{
- // this.events.subscribe("img-change", displayImg => {
- // console.log("app compont: "+displayImg);
- // this.user_image = this.sanitizer.bypassSecurityTrustUrl("data:Image/*;base64,"+displayImg);
+ this.events.subscribe("img-change", displayImg => {
+ console.log("app compont: "+displayImg);
+ this.user_image = this.sanitizer.bypassSecurityTrustUrl("data:Image/*;base64,"+displayImg);
- // });
+ });
}
@@ -63,9 +66,13 @@ export class EditProfileComponent implements OnInit {
this.personalInfo = user;
this.User_name_Emp=this.personalInfo.EMPLOYEE_NAME;
this.User_Job_name=this.personalInfo.JOB_NAME;
+ if(this.cs.getUpdateImage().status){
+ this.user_image =this.sanitizer.bypassSecurityTrustUrl("data:image/png;base64,"+this.cs.getUpdateImage().img);
+ }else{
this.user_image = user.EMPLOYEE_IMAGE
? "data:image/png;base64," + user.EMPLOYEE_IMAGE
: "../assets/imgs/profile.png";
+ }
console.log("name: "+ this.personalInfo.EMPLOYEE_NAME);
console.log("user name: "+ user.EMPLOYEE_NAME);
console.log("name: "+ this.personalInfo.JOB_NAME);
diff --git a/Mohem/src/app/profile/home/home.component.ts b/Mohem/src/app/profile/home/home.component.ts
index 2e192b1f..25192f94 100644
--- a/Mohem/src/app/profile/home/home.component.ts
+++ b/Mohem/src/app/profile/home/home.component.ts
@@ -51,8 +51,7 @@ export class HomeComponent implements OnInit {
if(this.cs.getUpdateImage().status){
// this.imageSrc = this.sanitizer.bypassSecurityTrustUrl("data:Image/*;base64,"+this.cs.getUpdateImage().img);
- this.imageSrc = "data:image/png;base64,"+this.cs.getUpdateImage().img;
- // alert("this.imageSrc"+ this.imageSrc);
+ this.imageSrc =this.sanitizer.bypassSecurityTrustUrl("data:image/png;base64,"+this.cs.getUpdateImage().img);
}else{
this.imageSrc = user.EMPLOYEE_IMAGE
? "data:image/png;base64," + user.EMPLOYEE_IMAGE