mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-19 04:57:52 +00:00
Fixe duplicated attendess
This commit is contained in:
@@ -72,29 +72,36 @@ export class AttendeeModalPage implements OnInit {
|
||||
|
||||
filterSearchList(itm: EventPerson): boolean {
|
||||
|
||||
if(this.adding == "intervenient"){
|
||||
const result = this.taskParticipants.find((contact, index)=>{
|
||||
|
||||
if(contact.Name == itm.Name && contact.EmailAddress == itm.EmailAddress){
|
||||
index = index;
|
||||
return contact;
|
||||
}
|
||||
});
|
||||
return undefined == result;
|
||||
|
||||
} else if (this.adding == "CC") {
|
||||
|
||||
const result = this.taskParticipantsCc.find((contact, index)=>{
|
||||
|
||||
const result1 = this.taskParticipants.find((contact, index)=>{
|
||||
|
||||
if(contact.Name == itm.Name && contact.EmailAddress == itm.EmailAddress){
|
||||
index = index;
|
||||
return contact;
|
||||
}
|
||||
});
|
||||
index = index;
|
||||
return contact;
|
||||
}
|
||||
});
|
||||
|
||||
return undefined == result;
|
||||
// if to show
|
||||
if(undefined != result1){
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
const result2 = this.taskParticipantsCc.find((contact, index)=>{
|
||||
|
||||
if(contact.Name == itm.Name && contact.EmailAddress == itm.EmailAddress){
|
||||
index = index;
|
||||
return contact;
|
||||
}
|
||||
});
|
||||
|
||||
// if to show
|
||||
if(undefined != result2){
|
||||
return false;
|
||||
}
|
||||
|
||||
// don't show
|
||||
return true;
|
||||
|
||||
}
|
||||
|
||||
remove(itm: EventPerson){
|
||||
|
||||
Reference in New Issue
Block a user