Skip to content
Snippets Groups Projects
Commit 188ff5a7 authored by Sebastian Wittek's avatar Sebastian Wittek
Browse files

change name of field lang in language

parent 8120dd10
No related merge requests found
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
<div fxLayout="row"> <div fxLayout="row">
<span class="fill-remaining-space"></span> <span class="fill-remaining-space"></span>
<div id="date"> <div id="date">
<div *ngIf="lang === 'de'; else englishDate"> <div *ngIf="language === 'de'; else englishDate">
{{comment.timestamp | date: ' HH:mm:ss '}}Uhr,{{comment.timestamp | date: ' M.d.yy'}} {{comment.timestamp | date: ' HH:mm:ss '}}Uhr,{{comment.timestamp | date: ' M.d.yy'}}
</div> </div>
<ng-template #englishDate> <ng-template #englishDate>
......
...@@ -21,7 +21,7 @@ export class CommentComponent implements OnInit { ...@@ -21,7 +21,7 @@ export class CommentComponent implements OnInit {
isStudent = false; isStudent = false;
isLoading = true; isLoading = true;
hasVoted = 0; hasVoted = 0;
lang: string; language: string;
constructor(protected authenticationService: AuthenticationService, constructor(protected authenticationService: AuthenticationService,
private route: ActivatedRoute, private route: ActivatedRoute,
...@@ -34,7 +34,7 @@ export class CommentComponent implements OnInit { ...@@ -34,7 +34,7 @@ export class CommentComponent implements OnInit {
private wsCommentService: WsCommentServiceService) { private wsCommentService: WsCommentServiceService) {
langService.langEmitter.subscribe(lang => { langService.langEmitter.subscribe(lang => {
translateService.use(lang); translateService.use(lang);
this.lang = lang; this.language = lang;
} ); } );
} }
...@@ -42,8 +42,8 @@ export class CommentComponent implements OnInit { ...@@ -42,8 +42,8 @@ export class CommentComponent implements OnInit {
if (this.authenticationService.getRole() === 0) { if (this.authenticationService.getRole() === 0) {
this.isStudent = true; this.isStudent = true;
} }
this.lang = localStorage.getItem('currentLang'); this.language = localStorage.getItem('currentLang');
this.translateService.use(this.lang); this.translateService.use(this.language);
} }
setRead(comment: Comment): void { setRead(comment: Comment): void {
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment