public ActionResult Edit(ContactInformationEditModel modelContactInformation)
 {
     ContactInformation myContactInformation = _contactInformationRepository.GetById(modelContactInformation.Id);
     myContactInformation.Type = modelContactInformation.Type;
     myContactInformation.Value = modelContactInformation.Value;
     ContactInformation contactInformation = _contactInformationRepository.Update(myContactInformation);
     const string title = "Contacto Actualizado";
     _viewMessageLogic.SetNewMessage(title, "", ViewMessageType.InformationMessage);
     return RedirectToAction("Details/" + contactInformation.People.Id, modelContactInformation.Controller);
 }
Beispiel #2
0
 public ActionResult ContactEdit(long id)
 {
     ContactInformation thisContactInformation = _contactInformationRepository.GetById(id);
     var contactInformation = new ContactInformationEditModel
                              {
                                  Type = thisContactInformation.Type,
                                  Value = thisContactInformation.Value,
                                  Id = thisContactInformation.Id,
                                  People = thisContactInformation.People,
                                  Controller = "Parent"
                              };
     return View("ContactEdit", contactInformation);
 }