mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-21 05:45:50 +00:00
save
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
import { Component, ElementRef, OnInit, ViewChild } from '@angular/core';
|
||||
import { Component, ElementRef, OnInit, ViewChild, AfterViewChecked } from '@angular/core';
|
||||
import { ActionSheetController, MenuController, ModalController, NavParams, PopoverController } from '@ionic/angular';
|
||||
import { AlertService } from 'src/app/services/alert.service';
|
||||
import { AuthService } from 'src/app/services/auth.service';
|
||||
@@ -14,7 +14,7 @@ import { GroupContactsPage } from './group-contacts/group-contacts.page';
|
||||
templateUrl: './group-messages.page.html',
|
||||
styleUrls: ['./group-messages.page.scss'],
|
||||
})
|
||||
export class GroupMessagesPage implements OnInit {
|
||||
export class GroupMessagesPage implements OnInit, AfterViewChecked {
|
||||
showLoader: boolean;
|
||||
isGroupCreated:boolean;
|
||||
loggedUser: any;
|
||||
@@ -51,6 +51,7 @@ export class GroupMessagesPage implements OnInit {
|
||||
console.log(this.roomId);
|
||||
this.loggedUser=this.loggedUserChat;
|
||||
this.getRoomInfo();
|
||||
this.scrollToBottom();
|
||||
}
|
||||
|
||||
ngAfterViewChecked() {
|
||||
@@ -127,12 +128,8 @@ export class GroupMessagesPage implements OnInit {
|
||||
}
|
||||
}
|
||||
sendMessage(){
|
||||
|
||||
let body = {
|
||||
"message":
|
||||
{
|
||||
"rid": this.roomId, "msg": this.message
|
||||
}
|
||||
"message": { "rid": this.roomId, "msg": this.message }
|
||||
}
|
||||
|
||||
this.chatService.sendMessage(body).subscribe(res=> {
|
||||
|
||||
Reference in New Issue
Block a user