mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-18 20:47:54 +00:00
save
This commit is contained in:
@@ -16,7 +16,7 @@ export class ChatPopoverPage implements OnInit {
|
||||
private modalController: ModalController,
|
||||
private navParams: NavParams,
|
||||
private chatService: ChatService,
|
||||
) {
|
||||
) {
|
||||
this.roomId = this.navParams.get('roomId');
|
||||
}
|
||||
|
||||
@@ -39,18 +39,18 @@ export class ChatPopoverPage implements OnInit {
|
||||
//Close
|
||||
leaveGroup(){
|
||||
console.log('leave');
|
||||
|
||||
|
||||
let body = { "roomId":this.roomId, }
|
||||
|
||||
this.chatService.getRoomInfo(this.roomId).subscribe(room=>{
|
||||
this.room = room['room'];
|
||||
|
||||
if(this.room.t === 'p'){
|
||||
if(this.room.t === 'p'){
|
||||
this.chatService.leaveGroup(body).subscribe(res=>{
|
||||
console.log(res);
|
||||
});
|
||||
}
|
||||
else{
|
||||
else{
|
||||
this.chatService.leaveChannel(body).subscribe(res=>{
|
||||
console.log(res);
|
||||
});
|
||||
@@ -66,12 +66,12 @@ export class ChatPopoverPage implements OnInit {
|
||||
this.chatService.getRoomInfo(this.roomId).subscribe(room=>{
|
||||
this.room = room['room'];
|
||||
|
||||
if(this.room.t === 'p'){
|
||||
if(this.room.t === 'p'){
|
||||
this.chatService.deleteGroup(body).subscribe(res=>{
|
||||
console.log(res);
|
||||
});
|
||||
}
|
||||
else{
|
||||
else{
|
||||
this.chatService.deleteChannel(body).subscribe(res=>{
|
||||
console.log(res);
|
||||
});
|
||||
@@ -82,6 +82,7 @@ export class ChatPopoverPage implements OnInit {
|
||||
}
|
||||
|
||||
async openChangeGroupName(){
|
||||
this.popoverController.dismiss('edit');
|
||||
this.modalController.dismiss('edit');
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user