Beispiel #1
0
 public ActionResult ConsultaTiquete()
 {
     using (var sofiaContext = new SofiaContext())
     {
         ViewBag.TipoDocumento = sofiaContext.Tipo.Where(x => x.IdClaseTipo == 15).ToList().Select(x => new SelectListItem() { Text = x.Nombre, Value = x.IdTipo.ToString() });
     }
     return View();
 }
Beispiel #2
0
 public JsonResult ActualizarTiquete(string Tiquete)
 {
     try
     {
         using (var sofiaContext = new SofiaContext())
         {
             var IdUsuario = sofiaContext.Usuario.First(x => x.Nombre == HttpContext.User.Identity.Name).IdUsuario;
             var IdPuntoVenta = sofiaContext.UsuarioXPuntoVenta.First(x => x.IdUsuario == IdUsuario).IdPuntoVenta;
             sofiaContext.spActualizarDocumentoValorMigracion(Tiquete, IdUsuario, IdPuntoVenta);
         }
         return Json(new { Status = "OK" }, JsonRequestBehavior.AllowGet);
     }
     catch
     {
         return Json(new { Status = "ERROR" }, JsonRequestBehavior.AllowGet);
     }
 }
Beispiel #3
0
 public ActionResult GetReservasMigradas(string Record, string Documento, string Tiquete)
 {
     try
     {
         JsonNetResult jsonNetResult = new JsonNetResult();
         jsonNetResult.Formatting = Newtonsoft.Json.Formatting.Indented;
         using (var sofiaContext = new SofiaContext())
         {
             jsonNetResult.Data = new
                 {
                     Status = "OK",
                     Migraciones = sofiaContext.MigracionReservasKiu.Where(x => x.RecordSofia == Record
                                    || x.Identificacion == Documento
                                    || x.Tiquete == Tiquete).ToList()
                 };
         }
         return jsonNetResult;
     }
     catch
     {
         return Json(new { Status = "ERROR" }, JsonRequestBehavior.AllowGet);
     }
 }
Beispiel #4
0
        public ActionResult GetTiquetesMigrados(string IdDocumentoValor, string IdTipoDocumento, string Identificacion)
        {
            try
            {

                JsonNetResult jsonNetResult = new JsonNetResult();
                jsonNetResult.Formatting = Newtonsoft.Json.Formatting.Indented;
                using (var sofiaContext = new SofiaContext())
                {
                    jsonNetResult.Data = new
                    {
                        Status = "OK",
                        Migraciones = sofiaContext.spMigracionTiquete(IdDocumentoValor == string.Empty ? null : IdDocumentoValor,
                                                                  IdTipoDocumento == string.Empty ? null : IdTipoDocumento,
                                                                  Identificacion == string.Empty ? null : Identificacion).ToList()
                    };
                }
                return jsonNetResult;
            }
            catch
            {
                return Json(new { Status = "ERROR" }, JsonRequestBehavior.AllowGet);
            }
        }
Beispiel #5
0
 public ActionResult ViewHistorialDocumentoValor(string IdDocumentoValor)
 {
     using (var sofiaContext = new SofiaContext())
     {
         return PartialView("_HistorialDocumentoValor",
             sofiaContext.spSeleccionarHistorialDocumentoValor(IdDocumentoValor).ToList());
     }
 }