/// <summary> /// Update contact Info /// </summary> /// <param name="contactInfo">The general business model</param> /// <returns>The person updated</returns> public async Task <Person> UpdateContactInfoAsync(UpdateContactInfo contactInfo) { var personToUpdate = await GetPersonModelByIdAsync(contactInfo.PersonId); var participant = await GetParticipantByPersonIdAsync(contactInfo.PersonId); if (participant != null) { throwValidationErrorIfParticipantSevisInfoIsLocked(participant); } DoUpdate(contactInfo, personToUpdate); return(personToUpdate); }
// Update contact info HasContactAgreement private void DoUpdate(UpdateContactInfo contactInfo, Person person) { person.HasContactAgreement = contactInfo.HasContactAgreement; }