diff options
author | 2020-04-03 00:02:01 +0530 | |
---|---|---|
committer | 2020-04-03 00:03:41 +0530 | |
commit | cd9d1cccb4a9c1179365fe6efe26946063ba4c22 (patch) | |
tree | 349a68192879b6487441918e4aeaffcc41677838 /portal-FE-common/src/app/layout | |
parent | 552f2d06e9a61bb3d93989cb9faef02d1ba15512 (diff) |
Fixed Userbar broken user image
Fixed Userbar broken user image
Issue-ID: PORTAL-872
Change-Id: I62863118e5880c2789acce6416d0ea618fc0857a
Signed-off-by: Sudarshan Kumar <sudarshan.kumar@att.com>
Diffstat (limited to 'portal-FE-common/src/app/layout')
3 files changed, 13 insertions, 3 deletions
diff --git a/portal-FE-common/src/app/layout/components/userbar/userbar.component.html b/portal-FE-common/src/app/layout/components/userbar/userbar.component.html index 0ff5a554..898a8fb4 100644 --- a/portal-FE-common/src/app/layout/components/userbar/userbar.component.html +++ b/portal-FE-common/src/app/layout/components/userbar/userbar.component.html @@ -45,7 +45,10 @@ <nav [ngStyle]="{'right': isOpen ? '18px' : '-75px' }" class="usb-item usb-item-vertical usb-item-right" id="usb-item-s2"> <h3>Online Users</h3> <div *ngFor="let user of userList" style="font-size: 10px;"> - <a [href]="user.linkQ"><img class="activeUserIcon" [src]="user.linkPic" alt="User Link"></a> + <a [href]="user.linkQ" *ngIf="(user.linkPicURL !='')"> + <img class="activeUserIcon" [src]="user.linkPic" alt="User Link"> + </a> + <a [href]="user.linkQ"><i *ngIf="(user.linkPicURL == '')" class="activeUserIcon default-user-icon icon ion-md-person"></i></a> <div class="userId-txt">{{user.userId}}</div> </div> </nav>
\ No newline at end of file diff --git a/portal-FE-common/src/app/layout/components/userbar/userbar.component.scss b/portal-FE-common/src/app/layout/components/userbar/userbar.component.scss index 81801104..451adfc7 100644 --- a/portal-FE-common/src/app/layout/components/userbar/userbar.component.scss +++ b/portal-FE-common/src/app/layout/components/userbar/userbar.component.scss @@ -112,3 +112,9 @@ button { width: 55px; border-radius: 50%; } + +.default-user-icon{ + font-size: 45px; + display: block; + color: black; +}
\ No newline at end of file diff --git a/portal-FE-common/src/app/layout/components/userbar/userbar.component.ts b/portal-FE-common/src/app/layout/components/userbar/userbar.component.ts index 661317bf..2136abb2 100644 --- a/portal-FE-common/src/app/layout/components/userbar/userbar.component.ts +++ b/portal-FE-common/src/app/layout/components/userbar/userbar.component.ts @@ -88,8 +88,9 @@ export class UserbarComponent implements OnInit { for (var i = 0; i < maxItems; i++) { var data = { userId: _res[i], - linkQ: this.api.linkQ, - linkPic: this.api.linkPic + linkQ: this.sanitizer.bypassSecurityTrustResourceUrl(this.api.linkQ + _res[i]), + linkPic: this.api.linkPic + _res[i], + linkPicURL:this.api.linkPic } this.userList.push(data); } |