mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-18 20:47:54 +00:00
improve
This commit is contained in:
@@ -44,7 +44,6 @@ export class ChatPage implements OnInit {
|
||||
X_Auth_Token: any;
|
||||
|
||||
loggedUser: any;
|
||||
/* Set segment variable */
|
||||
segment: string;
|
||||
allGroups: any[];
|
||||
privateGroups: any[];
|
||||
@@ -90,8 +89,6 @@ export class ChatPage implements OnInit {
|
||||
"support": ["1"]
|
||||
};
|
||||
|
||||
|
||||
/* Fim websockets variables*/
|
||||
loggedUserChat: any;
|
||||
hideRefreshBtn = true;
|
||||
|
||||
@@ -128,7 +125,6 @@ export class ChatPage implements OnInit {
|
||||
|
||||
this.showLoader = true;
|
||||
|
||||
//this.load()
|
||||
}
|
||||
|
||||
ngOnInit() {
|
||||
@@ -497,16 +493,11 @@ export class ChatPage implements OnInit {
|
||||
}
|
||||
|
||||
async getChatMembers() {
|
||||
//return await this.chatService.getMembers(roomId).toPromise();
|
||||
|
||||
this.chatService.getAllUsers().subscribe(res => {
|
||||
//
|
||||
this.transformDataUserList(res['users'])
|
||||
|
||||
/* if (this.platform.is('desktop') || this.platform.is('mobileweb')) {
|
||||
this.dmUsers = res['users'].filter(data => data.username != this.loggedUserChat.me.username);
|
||||
//
|
||||
}*/
|
||||
|
||||
});
|
||||
}
|
||||
|
||||
@@ -563,23 +554,6 @@ export class ChatPage implements OnInit {
|
||||
|
||||
})
|
||||
|
||||
/* this.sqlservice.getAllChatUsers().then((userslist: any) => {
|
||||
|
||||
let chatusersArray = [];
|
||||
userslist.forEach(element => {
|
||||
|
||||
let userListDB = {
|
||||
_id: element.Id,
|
||||
name: element.Name,
|
||||
username: element.Username
|
||||
}
|
||||
|
||||
chatusersArray.push(userListDB);
|
||||
});
|
||||
|
||||
this.dmUsers = chatusersArray.filter(data => data.username != this.loggedUserChat.me.username);
|
||||
|
||||
}) */
|
||||
}
|
||||
|
||||
}
|
||||
@@ -635,16 +609,7 @@ export class ChatPage implements OnInit {
|
||||
|
||||
this.privateGroups = res.groups;
|
||||
|
||||
/* this.result = this.chatService.getAllUserChannels().subscribe((res:any)=>{
|
||||
this.publicGroups = res.channels; */
|
||||
//let all = this.privateGroups.concat(this.publicGroups);
|
||||
/* this.allGroups = this.privateGroups.sort((a, b) => {
|
||||
var dateA = new Date(a._updatedAt).getTime();
|
||||
var dateB = new Date(b._updatedAt).getTime();
|
||||
return dateB - dateA;
|
||||
}); */
|
||||
//
|
||||
/* }); */
|
||||
|
||||
if (this.route.url != "/home/chat") {
|
||||
//
|
||||
}
|
||||
@@ -735,10 +700,5 @@ export class ChatPage implements OnInit {
|
||||
modal.onDidDismiss();
|
||||
}
|
||||
|
||||
// this.crop.crop('path/to/image.jpg', {quality: 75})
|
||||
// .then(
|
||||
// newImage =>
|
||||
// error => console.error('Error cropping image', error)
|
||||
// );
|
||||
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user