(js,html) Allow the removable of attendees

This commit is contained in:
Francis Lachapelle
2015-10-02 11:21:43 -04:00
parent 42d306a24b
commit d27c792324
4 changed files with 31 additions and 1 deletions

View File

@@ -739,6 +739,19 @@
return angular.isDefined(attendee);
};
/**
* @function deleteAttendee
* @memberof Component.prototype
* @desc Remove an attendee from the component
* @param {Object} attendee - an object literal defining an attendee
*/
Component.prototype.deleteAttendee = function(attendee) {
var index = _.findIndex(this.attendees, function(currentAttendee) {
return currentAttendee.email == attendee.email;
});
this.attendees.splice(index, 1);
};
/**
* @function canRemindAttendeesByEmail
* @memberof Component.prototype