Пример #1
0
        public IHttpActionResult UpdateEmergencyContact(string ClientId, EmergencyContact emergencyContact)
        {
            EmergencyContact eContact = _emergencyContactRepository.Find(x => x.clientId == ClientId).FirstOrDefault();

            eContact.FirstName       = emergencyContact.FirstName;
            eContact.LastName        = emergencyContact.LastName;
            eContact.Gender          = emergencyContact.Gender;
            eContact.Relationship    = emergencyContact.Relationship;
            eContact.Email           = emergencyContact.Email;
            eContact.Mobile          = emergencyContact.Mobile;
            eContact.AlternateNumber = emergencyContact.AlternateNumber;
            eContact.WorkNumber      = emergencyContact.WorkNumber;
            eContact.Address         = emergencyContact.Address;
            return(Ok(_emergencyContactRepository.Update(eContact)));
        }