예제 #1
0
        public JsonResult EliminarSancion(int idSancion)
        {
            //bool exito = this.Eliminar(codModelo);
            bool exito = BLSancion.Eliminar(idSancion);

            return(Json(new { success = exito, oldval = "" }));
        }
예제 #2
0
        public JsonResult ActualizarSancion(Sancion nuevoSancion)
        {
            bool exito = true;

            try
            {
                //this.Eliminar(nuevoSancion.Id_Sancion);
                //this.Grabar(nuevoSancion);
                BLSancion.Eliminar(nuevoSancion.Id_Sancion);
                BLSancion.Registrar(nuevoSancion);
            }
            catch
            {
                exito = false;
            }


            return(Json(new { success = exito, oldval = "" }));
        }