Add attendees for edit event modal

This commit is contained in:
Peter Maquiran
2021-04-07 10:04:58 +01:00
parent 3ca5d0c8fe
commit 9718a9f98d
3 changed files with 10 additions and 10 deletions
@@ -37,7 +37,7 @@ export class EditEventPage implements OnInit {
private eventsService: EventsService,
private alertService: AlertService,
public alertController: AlertController,
) {
) {
this.isEventEdited = false;
this.postEvent = this.navParams.get('event');
@@ -75,7 +75,6 @@ export class EditEventPage implements OnInit {
this.modalController.dismiss();
}
save(){
console.log(this.postEvent);
this.eventsService.editEvent(this.postEvent, 2, 3).subscribe(async () => {
const alert = await this.alertController.create({
@@ -89,12 +88,11 @@ export class EditEventPage implements OnInit {
this.modalController.dismiss(this.isEventEdited);
}
async openAttendees()
{
async openAttendees() {
this.adding = 'intervenient';
if(window.innerWidth == 1024) {
if(window.innerWidth <= 1024) {
const modal = await this.modalController.create({
component: AttendeesPage,
componentProps: {
@@ -115,7 +113,6 @@ export class EditEventPage implements OnInit {
});
}
}
async dynamicSetIntervenient(data){
@@ -125,7 +122,6 @@ export class EditEventPage implements OnInit {
async setIntervenient(data){
this.taskParticipants = data;
this.postEvent.Attendees = data;
}
@@ -135,11 +131,15 @@ export class EditEventPage implements OnInit {
async addParticipants(){
this.adding = 'intervenient'
this.openAttendees();
}
async addParticipantsCC(){
this.adding = 'CC'
this.openAttendees();
}
async closeComponent(){}
}
}