mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-19 21:06:06 +00:00
add timebomb to mobile view
This commit is contained in:
@@ -42,12 +42,16 @@ export class NewGroupPage implements OnInit {
|
||||
_ionChange(event){
|
||||
console.log(event);
|
||||
console.log(event.detail.checked);
|
||||
this.showDuration = event.detail.checked;
|
||||
|
||||
this.showDuration = event.detail.checked;
|
||||
//this.thedate = new Date(2021, 10, 1, 10, 33, 30, 0);
|
||||
this.thedate = new Date();
|
||||
|
||||
if(event.detail.checked){
|
||||
this.thedate = new Date();
|
||||
}
|
||||
else{
|
||||
this.thedate = '';
|
||||
}
|
||||
}
|
||||
|
||||
close(){
|
||||
//this.modalController.dismiss();
|
||||
console.log('close');
|
||||
@@ -63,13 +67,15 @@ export class NewGroupPage implements OnInit {
|
||||
|
||||
this.addGroupMessage.emit(res['group']._id);
|
||||
|
||||
let countDownBody = {
|
||||
"roomId": res['group']._id,
|
||||
"customFields":{"countDownDate":this.thedate}
|
||||
if(this.thedate){
|
||||
let countDownBody = {
|
||||
"roomId": res['group']._id,
|
||||
"customFields":{"countDownDate":this.thedate}
|
||||
}
|
||||
this.chatService.setGroupCustomFields(countDownBody).subscribe(res=>{
|
||||
console.log(res);
|
||||
});
|
||||
}
|
||||
this.chatService.setGroupCustomFields(countDownBody).subscribe(res=>{
|
||||
console.log(res);
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user