public ActionResult Index() { string pais = Request.QueryString["Pais"]; if (pais == "PERU" || pais == "MEXICO") { string result = ""; blSede oblSede = new blSede(); result = oblSede.listarSedesxPais(pais); ViewBag.sedexPais = result; ViewBag.pais = pais; ViewBag.sede = 0; return(View("~/Views/Usuarios/Usuarios.cshtml")); } else if (Request.Cookies["role"].Value == "Administrador") { ViewBag.sedexPais = ""; ViewBag.pais = ""; ViewBag.sede = Request.Cookies["sedeId"].Value; return(View("~/Views/Usuarios/Usuarios.cshtml")); } else { return(RedirectToAction("Index", "Home")); } }
public string listarSedesxPais(string pais) { string result = ""; blSede oblSede = new blSede(); result = oblSede.listarSedesxPais(pais); return(result); }
public ActionResult Index() { string pais = Request.QueryString["Pais"]; string tipo = Request.QueryString["tipo"]; if (pais != null && pais != "" && tipo != "") { string result = ""; blSede oblSede = new blSede(); result = oblSede.listarSedesxPais(pais); ViewBag.sedexPais = result; ViewBag.pais = pais; ViewBag.tipo = tipo; return(View("~/Views/SalaJuntas/SalaJuntas.cshtml")); } else { return(RedirectToAction("Index", "Sedes")); } }