Code development platform for open source projects from the European Union institutions

Skip to content
Snippets Groups Projects
Commit b761db72 authored by Joze RIHTARSIC's avatar Joze RIHTARSIC
Browse files

[EDELIVERY-13758] UI show session extension in minutes and seconds

parent 53a7c0e6
No related branches found
No related tags found
No related merge requests found
Pipeline #208571 failed
<h2 mat-dialog-title>{{ "session.expiration.dialog.title" | translate }}</h2>
<mat-dialog-content>
<div innerHTML='{{"session.expiration.dialog.label.session.about.to.expire" | translate:{timeLeft: data.timeLeft, timeout: data.timeout} }}'></div>
<div innerHTML='{{"session.expiration.dialog.label.session.about.to.expire" | translate:{timeLeft: data.timeLeft,
timeoutMinutes: sessionDurationInMinutes, timeoutSeconds: sessionDurationInMinutesReminder} }}'></div>
</mat-dialog-content>
<mat-dialog-actions>
<button mat-raised-button mat-dialog-close (click)="onLogoutClicked()" tabindex="-1">
......
......@@ -24,5 +24,13 @@ export class SessionExpirationDialogComponent {
this.securityService.logout();
this.dialogRef.close();
}
get sessionDurationInMinutes() {
return Math.floor(this.data.timeout / 60);
}
get sessionDurationInMinutesReminder() {
return this.data.timeout % 60;
}
}
......@@ -92,7 +92,7 @@
"session.expiration.dialog.button.expire": "Extend",
"session.expiration.dialog.button.logout": "Logout",
"session.expiration.dialog.title": "Extend session",
"session.expiration.dialog.label.session.about.to.expire": "Your session is about to expire in <b>{{timeLeft}}</b> seconds!<br />Would you like to logout now or extend it for another <b>{{timeout}}</b> seconds?",
"session.expiration.dialog.label.session.about.to.expire": "Your session is about to expire in <b>{{timeLeft}}</b> seconds!<br />Would you like to logout now or extend it<br /> for another <b>{{timeoutMinutes}}</b> minute(s) and <b>{{timeoutSeconds}}</b> second(s)?",
"session.alert.message.logout.expired": "Your session has expired, and you have been logged out",
"alert.panel.title": "Alerts",
"alert.panel.user.title": "{{value}} (Email: '{{mailTo}}')",
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment