public async Task <IActionResult> Edit(int id, [Bind("Id_calificacion,calificacion")] Calificaciones calificaciones) { if (id != calificaciones.Id_calificacion) { return(NotFound()); } if (ModelState.IsValid) { try { _context.Update(calificaciones); await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!CalificacionesExists(calificaciones.Id_calificacion)) { return(NotFound()); } else { throw; } } return(RedirectToAction(nameof(Index))); } return(View(calificaciones)); }
public async Task <IActionResult> Edit(int id, [Bind("Id_curso,Nombre,Lenguaje_programacion")] Cursos cursos) { if (id != cursos.Id_curso) { return(NotFound()); } if (ModelState.IsValid) { try { _context.Update(cursos); await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!CursosExists(cursos.Id_curso)) { return(NotFound()); } else { throw; } } return(RedirectToAction(nameof(Index))); } return(View(cursos)); }
public async Task <IActionResult> Edit(int id, [Bind("Id_alumno,nombre,correo_electronico")] Alumnos alumnos) { if (id != alumnos.Id_alumno) { return(NotFound()); } if (ModelState.IsValid) { try { _context.Update(alumnos); await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!AlumnosExists(alumnos.Id_alumno)) { return(NotFound()); } else { throw; } } return(RedirectToAction(nameof(Index))); } return(View(alumnos)); }
public async Task <IActionResult> Edit(int id, [Bind("Id_etapa,Nivel")] Etapas etapas) { if (id != etapas.Id_etapa) { return(NotFound()); } if (ModelState.IsValid) { try { _context.Update(etapas); await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!EtapasExists(etapas.Id_etapa)) { return(NotFound()); } else { throw; } } return(RedirectToAction(nameof(Index))); } return(View(etapas)); }