public ActionResult DevolverHerramienta(DevolucionHerramientaDetalleModels Models) { try { _PrestamoHerramienta_Datos Datos = new _PrestamoHerramienta_Datos(); DevolucionHerramientaDetalleModels ModelD = new DevolucionHerramientaDetalleModels { IDPrestamo = Models.IDPrestamo, IDPrestamoDetalle = Models.IDPrestamoDetalle, CantDevolver = Models.CantDevolver, Usuario = User.Identity.Name, Conexion = Conexion }; RespuestaAjax respuesta = new RespuestaAjax(); string usuario = User.Identity.Name; respuesta = Datos.ACDevolucionHerramientasAlmacenDetalle(ModelD); return(Content(respuesta.ToJSON(), "application/json")); } catch (Exception ex) { throw ex; } }
public ActionResult Finalizar(int id4) { try { _PrestamoHerramienta_Datos Datos = new _PrestamoHerramienta_Datos(); DevolucionHerramientaDetalleModels Prestamo = Datos.FinalizarDevolucionHerramientasAlmacen(Conexion, id4, User.Identity.Name); if (Prestamo.Completado) { return(Json("true")); } else { return(Json("")); } } catch (Exception) { return(Json("")); } }