public ActionResult CrearPais(PAICES objpais)
        {
            try
            {
                bool   respuesta;
                string mensaje = "País creado correctamente";
                if (objpais.PAICODIGOI == 0)
                {
                    respuesta = objPaisesDAL.Crear_Pais(objpais, true);
                }
                else
                {
                    respuesta = objPaisesDAL.Crear_Pais(objpais, false);
                    mensaje   = "País editado correctamente";
                }
                if (respuesta)
                {
                    Request.Flash("success", mensaje);
                }
            }
            catch (Exception exc)
            {
                Request.Flash("danger", "Ha ocurrido un error: " + exc.Message);
            }

            return(RedirectToAction("Index", "Paises"));
        }
        public ActionResult CrearPais(int paiCodigoI = 0)
        {
            PAICES objPais = new PAICES();

            if (paiCodigoI != 0)
            {
                objPais = objPaisesDAL.Buscar_Pais(paiCodigoI);
            }
            return(View(objPais));
        }