This commit is contained in:
Peter Maquiran
2022-01-14 12:16:09 +01:00
6 changed files with 8 additions and 155 deletions
-13
View File
@@ -39,18 +39,6 @@ export class RoomService {
}
receiveMessage() {
this.WsChatService.receiveMyMessageConfirmation(
this.id,
(ChatMessage:ChatMessage) => {
ChatMessage = this.fix_updatedAt(ChatMessage)
const message = new MessageService()
message.setData(ChatMessage.result)
// this.massages.push(message)
this.calDateDuration(ChatMessage.result._updatedAt)
//this.ToastService.presentToast('nova mensagem')
}
)
this.WsChatService.receiveLiveMessageFromRoom(
this.id,
@@ -62,7 +50,6 @@ export class RoomService {
const message = new MessageService()
message.setData(ChatMessage)
this.lastMessage.msg = message.msg
console.log('ChatMessage.result._updatedAt', ChatMessage._updatedAt)
this.calDateDuration(ChatMessage._updatedAt)
this.massages.push(message)
}
@@ -24,7 +24,6 @@ export class WsChatMethodsService {
constructor(
private WsChatService: WsChatService
) {
(async()=>{
await this.getAllRooms();
this.subscribeToRoom()