public async Task <IActionResult> Edit(int?id) { if (id == null) { return(NotFound()); } var novedad = await _novedadesRepository.GetNovedadByIdAsync(id); if (novedad == null) { return(NotFound()); } var novedadesEditViewModel = new NovedadesEditViewModel { Id = novedad.Id, Cedula = novedad.Cedula, archivoNovedades = novedad.archivoNovedades, Motivo = novedad.Motivo, Novedad = novedad.Observaciones, Placa = novedad.Placa, SubMotivo = novedad.SubMotivo, Via = novedad.ViaIngreso, Solucion = novedad.Solucion, Estados = await _combosHelper.GetComboEstadoNovedad(), //EstadoId=novedad.EstadoSolucion }; return(View(novedadesEditViewModel)); }