diff --git a/src/app/pages/agenda/agenda.page.html b/src/app/pages/agenda/agenda.page.html index e6b055576..20181704c 100644 --- a/src/app/pages/agenda/agenda.page.html +++ b/src/app/pages/agenda/agenda.page.html @@ -380,22 +380,15 @@ > + - - - - diff --git a/src/app/shared/event/attendee-modal/attendee-modal.page.html b/src/app/shared/event/attendee-modal/attendee-modal.page.html index d8fe8f3c3..07e98b94f 100644 --- a/src/app/shared/event/attendee-modal/attendee-modal.page.html +++ b/src/app/shared/event/attendee-modal/attendee-modal.page.html @@ -6,21 +6,46 @@ - - - - - - - -

{{ attendee.Name }}

-

{{ attendee.EmailAddress }}

-
-
-
-
-
+ + + + + +
+ +
+ +
+ +

{{ attendee.Name }}

+

{{ attendee.EmailAddress }}

+
+
+
+ +
+
+
+ + + +
+ +
+ +

{{ attendee.Name }}

+

{{ attendee.EmailAddress }}

+
+
+ X +
+
+
+
+
+
+ diff --git a/src/app/shared/event/attendee-modal/attendee-modal.page.scss b/src/app/shared/event/attendee-modal/attendee-modal.page.scss index 9cee55e1d..a7688a8e7 100644 --- a/src/app/shared/event/attendee-modal/attendee-modal.page.scss +++ b/src/app/shared/event/attendee-modal/attendee-modal.page.scss @@ -1,6 +1,9 @@ ion-item-group{ - margin: 15px; + } ion-searchbar{ --border-radius: 20px; -} \ No newline at end of file +} +.item-inner{ + border-style: unset !important; + } \ No newline at end of file diff --git a/src/app/shared/event/attendee-modal/attendee-modal.page.ts b/src/app/shared/event/attendee-modal/attendee-modal.page.ts index 90c08513e..b99bd5059 100644 --- a/src/app/shared/event/attendee-modal/attendee-modal.page.ts +++ b/src/app/shared/event/attendee-modal/attendee-modal.page.ts @@ -1,4 +1,4 @@ -import { Component, EventEmitter, OnInit, Output } from '@angular/core'; +import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core'; import { ModalController } from '@ionic/angular'; import { ContactsService } from 'src/app/services/contacts.service'; import { EventPerson } from 'src/app/models/eventperson.model'; @@ -12,22 +12,27 @@ export class AttendeeModalPage implements OnInit { contacts: EventPerson[]; showLoader: boolean = false; + selectedContact: EventPerson[] =[]; eventPersons: EventPerson[]; + @Input() eventAttendees: EventPerson[]; + constructor(private modalCtrl: ModalController, private contactsService: ContactsService) { } @Output() openAttendeesComponent = new EventEmitter(); + @Output() GoBackEditOrAdd = new EventEmitter(); ngOnInit() { this.fetchContacts(""); + this.selectedContact = this.eventAttendees; } save(){ - - this.openAttendeesComponent.emit(this.contacts.filter(function(contact) { - return contact.IsRequired == true; - })); + // set data to agenda component + this.openAttendeesComponent.emit(this.selectedContact); + // got back + this.GoBackEditOrAdd.emit(); } close(){ @@ -39,8 +44,45 @@ export class AttendeeModalPage implements OnInit { this.fetchContacts(evt.detail.value); } - selectContact(itm: EventPerson){ - itm.IsRequired = !itm.IsRequired; + + checkbox(itm: EventPerson): boolean { + const result = this.selectedContact.find((contact, index)=>{ + + if(contact.Name == itm.Name && contact.EmailAddress == itm.EmailAddress){ + index = index; + return contact; + } + }); + + return undefined == result; + } + + remove(itm: EventPerson){ + + this.selectedContact = this.selectedContact.filter((contact, index) =>{ + + if(contact.Name != itm.Name && contact.EmailAddress != itm.EmailAddress){ + return contact; + } + return false; + + }); + + } + + async selectContact(itm: EventPerson){ + + const index = 0; + const findIndex = this.selectedContact.find((contact, index)=>{ + + if(contact.Name == itm.Name && contact.EmailAddress == itm.EmailAddress){ + index = index; + return contact; + } + }); + + this.selectedContact.push(itm); + } async fetchContacts(filter: string) { diff --git a/src/assets/images/icons-userprofile.svg b/src/assets/images/icons-userprofile.svg new file mode 100644 index 000000000..d02f18900 --- /dev/null +++ b/src/assets/images/icons-userprofile.svg @@ -0,0 +1,27 @@ + + + + + + + + + + + + + + + + + + + SE + + + + + + + + diff --git a/src/global.scss b/src/global.scss index 9827908ce..c9f4d20a5 100644 --- a/src/global.scss +++ b/src/global.scss @@ -487,7 +487,7 @@ td.monthview-secondary-with-event, td.monthview-secondary-with-event[_ngcontent- .timeline-box{ left: -13%; position: relative; - width: 115%; + width: 113%; } }