Example #1
0
 public ActionResult Delete(int id, EventoParticipante collection)
 {
     try
     {
         // TODO: Add delete logic here
         var result = _eventoParticipanteRepository.ObterPorId(collection.EventoParticipanteId);
         _eventoParticipanteRepository.Remover(result);
         return(RedirectToAction("Listar", new { msg = "Inscrição cancelada." }));
     }
     catch
     {
         return(View());
     }
 }
 public void Remover(EventoParticipante entity)
 {
     _eventoParticipanteRepository.Remover(entity);
 }