This commit is contained in:
tiago.kayaya
2021-08-20 11:58:28 +01:00
parent 55ebb0219e
commit 80c7560867
7 changed files with 41 additions and 38 deletions
@@ -51,7 +51,7 @@
<div class="container width-100 d-flex">
<div>
<button class="btn-no-color" (click)="openSendMessageOptions()">
<ion-icon class="chat-icon-options" src="assets/icon/icons-chat-options.svg"></ion-icon>
<ion-icon class="chat-icon-options" src="assets/images/icons-add-new-event.svg"></ion-icon>
</button>
</div>
<div class="width-80">
@@ -165,9 +165,9 @@
.chat-icon-options{
display:block !important;
font-size: 25px;
font-size: 35px;
float: right !important;
margin-top: 10px;
margin-top: 5px;
}
.chat-icon-send{
+27 -6
View File
@@ -1,4 +1,4 @@
import { AfterViewChecked, Component, ElementRef, Input, OnChanges, OnInit, SimpleChanges, ViewChild } from '@angular/core';
import { AfterViewChecked, Component, ElementRef, EventEmitter, Input, OnChanges, OnInit, Output, SimpleChanges, ViewChild } from '@angular/core';
import { AnimationController, ModalController, PopoverController } from '@ionic/angular';
import { AlertService } from 'src/app/services/alert.service';
import { AuthService } from 'src/app/services/auth.service';
@@ -29,10 +29,13 @@ export class MessagesPage implements OnInit, AfterViewChecked, OnChanges {
userPresence='';
dmUsers:any;
checktimeOut: boolean;
members:any;
@Input() roomId:string;
@Input() showMessages:string;
@Output() openNewEventPage:EventEmitter<any> = new EventEmitter<any>();
connection = connection
@@ -67,15 +70,11 @@ export class MessagesPage implements OnInit, AfterViewChecked, OnChanges {
console.log(this.roomId);
console.log("Chat route", this.route.url)
}
ngOnDestroy(){
this.checktimeOut = false;
console.log('On Destroy')
}
notImplemented(){
@@ -106,6 +105,14 @@ export class MessagesPage implements OnInit, AfterViewChecked, OnChanges {
}
}
openBookMeetingComponent(){
let data = {
roomId: this.roomId,
members: this.members
}
this.openNewEventPage.emit(data);
}
sendMessage() {
this.connection.$send({})
@@ -141,6 +148,7 @@ export class MessagesPage implements OnInit, AfterViewChecked, OnChanges {
//this.showLoader = true;
this.chatService.getMembers(this.roomId).subscribe(res=> {
this.members = res['members'];
this.dmUsers = res['members'].filter(data => data.username != this.loggedUser.me.username)
console.log(res);
console.log(this.dmUsers);
@@ -280,9 +288,22 @@ export class MessagesPage implements OnInit, AfterViewChecked, OnChanges {
cssClass: 'model profile-modal search-submodal',
componentProps: {
roomId: this.roomId,
members: this.members,
}
});
return await modal.present();
await modal.present();
modal.onDidDismiss().then((res)=>{
console.log(res['data']);
if(res['data'] == 'meeting'){
//this.closeAllDesktopComponents.emit();
let data = {
roomId: this.roomId,
members: this.members
}
this.openNewEventPage.emit(data);
}
});
}
async serverLongPull(){