This commit is contained in:
tiago.kayaya
2021-09-06 16:53:58 +01:00
parent d0fee13402
commit 5e4229e210
7 changed files with 84 additions and 7 deletions
@@ -42,7 +42,7 @@
<div *ngIf="msg.t != 'r'" class='incoming-{{msg.u.username!=loggedUser.me.username}} max-width-45'>
<div class="title">
<ion-label>{{msg.u.name}}</ion-label>
<span class="time">{{msg._updatedAt | date: 'HH:mm' }}</span>
<span class="time">{{showDateDuration(msg._updatedAt)}}</span>
</div>
<div>
<ion-label>{{msg.msg}}</ion-label>
@@ -10,6 +10,7 @@ import { GroupContactsPage } from './group-contacts/group-contacts.page';
import { Router } from '@angular/router'
import { ChatOptionsPopoverPage } from '../../popover/chat-options-popover/chat-options-popover.page';
import { ChatOptionsFeaturesPage } from 'src/app/modals/chat-options-features/chat-options-features.page';
import { TimeService } from 'src/app/services/functions/time.service';
@Component({
selector: 'app-group-messages',
@@ -54,7 +55,8 @@ export class GroupMessagesPage implements OnInit, OnChanges, AfterViewInit, OnDe
private authService: AuthService,
private animationController: AnimationController,
private alertService: AlertService,
private route: Router
private route: Router,
private timeService: TimeService,
) {
this.loggedUserChat = authService.ValidatedUserChat['data'];
this.isGroupCreated = true;
@@ -140,6 +142,9 @@ export class GroupMessagesPage implements OnInit, OnChanges, AfterViewInit, OnDe
console.log('here watching');
return this.roomId;
}
showDateDuration(start:any){
return this.timeService.showDateDuration(start);
}
getRoomInfo(){
this.showLoader = true;