mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-20 05:16:07 +00:00
Remove relevant console log,
This commit is contained in:
@@ -55,7 +55,7 @@ export class ContactsPage implements OnInit {
|
||||
headers: this.headers,
|
||||
};
|
||||
this.chatService.getAllUsers().subscribe((res:any)=>{
|
||||
console.log('All users',res.users);
|
||||
|
||||
this.contacts = res.users.filter(data => data.username != this.sessionStore.user.UserName);
|
||||
this.users = this.contacts.sort((a,b) => {
|
||||
if(a.name < b.name){
|
||||
@@ -92,7 +92,7 @@ export class ContactsPage implements OnInit {
|
||||
}
|
||||
|
||||
clicked(){
|
||||
console.log('clicked');
|
||||
|
||||
}
|
||||
|
||||
createRoom(username:string){
|
||||
@@ -100,29 +100,29 @@ export class ContactsPage implements OnInit {
|
||||
username: username,
|
||||
}
|
||||
this.chatService.createRoom(body).subscribe(res => {
|
||||
console.log(res);
|
||||
|
||||
this.room = res['room'];
|
||||
console.log(this.room._id);
|
||||
|
||||
|
||||
this.getDirectMessage(this.room._id);
|
||||
this.WsChatMethodsService.getAllRooms()
|
||||
});
|
||||
}
|
||||
getDirectMessage(roomId:any){
|
||||
console.log(roomId);
|
||||
|
||||
|
||||
this.chatService.getAllDirectMessages().subscribe(res=>{
|
||||
let result = res['ims'].filter(data => data._id == roomId);
|
||||
console.log(result[0]);
|
||||
|
||||
|
||||
this.dm = result[0];
|
||||
console.log(this.dm);
|
||||
|
||||
this.openModal(this.dm._id);
|
||||
});
|
||||
}
|
||||
async openModal(roomId:any){
|
||||
this.close();
|
||||
console.log(roomId);
|
||||
|
||||
|
||||
const modal = await this.modalController.create({
|
||||
component: MessagesPage,
|
||||
@@ -143,7 +143,7 @@ export class ContactsPage implements OnInit {
|
||||
this.createRoom(username);
|
||||
//Get direct messages (dm)
|
||||
/* this.getDirectMessage(this.room._id); */
|
||||
console.log(this.dm);
|
||||
|
||||
|
||||
|
||||
/* const modal = await this.modalController.create({
|
||||
|
||||
Reference in New Issue
Block a user