protected void Page_Load(object sender, EventArgs e)
        {
            if (Session["UidClienteMaster"] != null)
            {
                ViewState["UidClienteLocal"] = Session["UidClienteMaster"];
            }
            else
            {
                ViewState["UidClienteLocal"] = Guid.Empty;
            }

            if (!IsPostBack)
            {
                ViewState["gvCicloEscolar"] = SortDirection.Ascending;

                Session["usuariosCompletosServices"] = usuariosCompletosServices;
                //Session["telefonosUsuariosServices"] = telefonosUsuariosServices;
                Session["estatusService"] = estatusService;

                //usuariosCompletosServices.CargarUsuariosFinales(new Guid(ViewState["UidClienteLocal"].ToString()), new Guid("E39FF705-8A01-4302-829A-7CFB9615CC8F"));
                gvCicloEscolar.DataSource = usuariosCompletosServices.lsUsuariosCompletos;
                gvCicloEscolar.DataBind();

                estatusService.CargarEstatus();
                ddlEstatus.DataSource     = estatusService.lsEstatus;
                ddlEstatus.DataTextField  = "VchDescripcion";
                ddlEstatus.DataValueField = "UidEstatus";
                ddlEstatus.DataBind();

                FiltroEstatus.DataSource = estatusService.lsEstatus;
                FiltroEstatus.Items.Insert(0, new ListItem("Seleccione", "00000000-0000-0000-0000-000000000000"));
                FiltroEstatus.DataTextField  = "VchDescripcion";
                FiltroEstatus.DataValueField = "UidEstatus";
                FiltroEstatus.DataBind();

                tiposTelefonosServices.CargarTiposTelefonos();
                ddlTipoTelefono.DataSource     = tiposTelefonosServices.lsTiposTelefonos;
                ddlTipoTelefono.DataTextField  = "VchDescripcion";
                ddlTipoTelefono.DataValueField = "UidTipoTelefono";
                ddlTipoTelefono.DataBind();
            }
            else
            {
                usuariosCompletosServices = (UsuariosCompletosServices)Session["usuariosCompletosServices"];
                //telefonosUsuariosServices = (TelefonosUsuariosServices)Session["telefonosUsuariosServices"];

                estatusService         = (EstatusServices)Session["estatusService"];
                tiposTelefonosServices = (TiposTelefonosServices)Session["tiposTelefonosServices"];

                lblValidar.Text = string.Empty;

                lblMensajeAlert.Text = "";
                divAlert.Attributes.Add("class", "alert alert-danger alert-dismissible fade");
            }
        }
        protected void Page_Load(object sender, EventArgs e)
        {
            //modulosServices.CargarAccesosPermitidos();

            if (!IsPostBack)
            {
                ViewState["gvFranquiciatarios"] = SortDirection.Ascending;

                #region Direccion
                Session["paisesServices"]     = paisesServices;
                Session["estadosServices"]    = estadosServices;
                Session["municipiosServices"] = municipiosServices;
                Session["ciudadesServices"]   = ciudadesServices;
                Session["coloniasServices"]   = coloniasServices;
                #endregion

                Session["franquiciatariosServices"]          = franquiciatariosServices;
                Session["telefonosFranquiciatariosServices"] = telefonosFranquiciatariosServices;
                Session["estatusService"]            = estatusService;
                Session["parametrosEntradaServices"] = parametrosEntradaServices;
                Session["promocionesServices"]       = promocionesServices;

                franquiciatariosServices.CargarFranquiciatarios();
                gvFranquiciatarios.DataSource = franquiciatariosServices.lsFranquiciasGridViewModel;
                gvFranquiciatarios.DataBind();

                estatusService.CargarEstatus();
                ddlEstatus.DataSource     = estatusService.lsEstatus;
                ddlEstatus.DataTextField  = "VchDescripcion";
                ddlEstatus.DataValueField = "UidEstatus";
                ddlEstatus.DataBind();

                tiposTelefonosServices.CargarTiposTelefonos();
                ddlTipoTelefono.DataSource     = tiposTelefonosServices.lsTiposTelefonos;
                ddlTipoTelefono.DataTextField  = "VchDescripcion";
                ddlTipoTelefono.DataValueField = "UidTipoTelefono";
                ddlTipoTelefono.DataBind();

                paisesServices.CargarPaises();
                ddlPais.DataSource     = paisesServices.lsPaises;
                ddlPais.DataTextField  = "VchPais";
                ddlPais.DataValueField = "UidPais";
                ddlPais.DataBind();
            }
            else
            {
                #region Direccion
                paisesServices     = (PaisesServices)Session["paisesServices"];
                estadosServices    = (EstadosServices)Session["estadosServices"];
                municipiosServices = (MunicipiosServices)Session["municipiosServices"];
                ciudadesServices   = (CiudadesServices)Session["ciudadesServices"];
                coloniasServices   = (ColoniasServices)Session["coloniasServices"];
                #endregion

                franquiciatariosServices          = (FranquiciatariosServices)Session["franquiciatariosServices"];
                telefonosFranquiciatariosServices = (TelefonosFranquiciatariosServices)Session["telefonosFranquiciatariosServices"];
                estatusService            = (EstatusServices)Session["estatusService"];
                tiposTelefonosServices    = (TiposTelefonosServices)Session["tiposTelefonosServices"];
                parametrosEntradaServices = (ParametrosEntradaServices)Session["parametrosEntradaServices"];
                promocionesServices       = (PromocionesServices)Session["promocionesServices"];

                pnlAlert.Visible     = false;
                lblMensajeAlert.Text = "";
                divAlert.Attributes.Add("class", "alert alert-danger alert-dismissible fade");

                pnlAlertCredenciales.Visible  = false;
                lblMnsjAlertCredenciales.Text = "";
                divAlertCredenciales.Attributes.Add("class", "alert alert-danger alert-dismissible fade");
            }
        }
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack)
            {
                ViewState["gvAdministradores"] = SortDirection.Ascending;

                #region Direccion
                Session["paisesServices"]     = paisesServices;
                Session["estadosServices"]    = estadosServices;
                Session["municipiosServices"] = municipiosServices;
                Session["ciudadesServices"]   = ciudadesServices;
                Session["coloniasServices"]   = coloniasServices;
                #endregion

                Session["usuariosCompletosServices"] = usuariosCompletosServices;
                //Session["telefonosUsuariosServices"] = telefonosUsuariosServices;
                Session["estatusService"]           = estatusService;
                Session["franquiciatariosServices"] = franquiciatariosServices;

                usuariosCompletosServices.CargarAdministradores(Guid.Parse("7F5587BF-10C7-4164-A3F8-3D17962AB17E"));
                gvAdministradores.DataSource = usuariosCompletosServices.lsUsuariosCompletos;
                gvAdministradores.DataBind();

                estatusService.CargarEstatus();
                ddlEstatus.DataSource     = estatusService.lsEstatus;
                ddlEstatus.DataTextField  = "VchDescripcion";
                ddlEstatus.DataValueField = "UidEstatus";
                ddlEstatus.DataBind();

                tiposTelefonosServices.CargarTiposTelefonos();
                ddlTipoTelefono.DataSource     = tiposTelefonosServices.lsTiposTelefonos;
                ddlTipoTelefono.DataTextField  = "VchDescripcion";
                ddlTipoTelefono.DataValueField = "UidTipoTelefono";
                ddlTipoTelefono.DataBind();

                paisesServices.CargarPaises();
                ddlPais.DataSource     = paisesServices.lsPaises;
                ddlPais.DataTextField  = "VchPais";
                ddlPais.DataValueField = "UidPais";
                ddlPais.DataBind();

                perfilesServices.CargarPerfilesDropDownListModel(Guid.Parse("7F5587BF-10C7-4164-A3F8-3D17962AB17E"));
                ddlPerfil.DataSource     = perfilesServices.lsPerfilesDropDownListModel;
                ddlPerfil.DataTextField  = "VchNombre";
                ddlPerfil.DataValueField = "UidSegPerfil";
                ddlPerfil.DataBind();
            }
            else
            {
                #region Direccion
                paisesServices     = (PaisesServices)Session["paisesServices"];
                estadosServices    = (EstadosServices)Session["estadosServices"];
                municipiosServices = (MunicipiosServices)Session["municipiosServices"];
                ciudadesServices   = (CiudadesServices)Session["ciudadesServices"];
                coloniasServices   = (ColoniasServices)Session["coloniasServices"];
                #endregion

                usuariosCompletosServices = (UsuariosCompletosServices)Session["usuariosCompletosServices"];
                //telefonosUsuariosServices = (TelefonosUsuariosServices)Session["telefonosUsuariosServices"];
                franquiciatariosServices = (FranquiciatariosServices)Session["franquiciatariosServices"];

                estatusService         = (EstatusServices)Session["estatusService"];
                tiposTelefonosServices = (TiposTelefonosServices)Session["tiposTelefonosServices"];

                lblValidar.Text = string.Empty;

                pnlAlert.Visible     = false;
                lblMensajeAlert.Text = "";
                divAlert.Attributes.Add("class", "alert alert-danger alert-dismissible fade");

                txtPassword.Attributes.Add("value", txtPassword.Text);
                txtRepetirPassword.Attributes.Add("value", txtRepetirPassword.Text);
            }
        }
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack)
            {
                #region Direccion
                Session["paisesServices"]     = paisesServices;
                Session["estadosServices"]    = estadosServices;
                Session["municipiosServices"] = municipiosServices;
                Session["ciudadesServices"]   = ciudadesServices;
                Session["coloniasServices"]   = coloniasServices;
                #endregion

                Session["usuariosCompletosServices"] = usuariosCompletosServices;
                //Session["telefonosUsuariosServices"] = telefonosUsuariosServices;
                Session["estatusService"]   = estatusService;
                Session["clientesServices"] = clientesServices;

                if (Session["UidFranquiciaMaster"] != null)
                {
                    ViewState["UidFranquiciaLocal"] = Session["UidFranquiciaMaster"];
                }
                else
                {
                    ViewState["UidFranquiciaLocal"] = Guid.Empty;
                }

                usuariosCompletosServices.CargarAdministradoresCliente(new Guid(ViewState["UidFranquiciaLocal"].ToString()), new Guid("4EF31BD5-95AB-4172-AF94-E25A3CADAD74"));
                gvAdministradores.DataSource = usuariosCompletosServices.lsUsuariosCompletos;
                gvAdministradores.DataBind();

                estatusService.CargarEstatus();
                ddlEstatus.DataSource     = estatusService.lsEstatus;
                ddlEstatus.DataTextField  = "VchDescripcion";
                ddlEstatus.DataValueField = "UidEstatus";
                ddlEstatus.DataBind();

                tiposTelefonosServices.CargarTiposTelefonos();
                ddlTipoTelefono.DataSource     = tiposTelefonosServices.lsTiposTelefonos;
                ddlTipoTelefono.DataTextField  = "VchDescripcion";
                ddlTipoTelefono.DataValueField = "UidTipoTelefono";
                ddlTipoTelefono.DataBind();

                paisesServices.CargarPaises();
                ddlPais.DataSource     = paisesServices.lsPaises;
                ddlPais.DataTextField  = "VchPais";
                ddlPais.DataValueField = "UidPais";
                ddlPais.DataBind();

                perfilesServices.CargarPerfilesFranquiciaDropDownListModel(new Guid(ViewState["UidFranquiciaLocal"].ToString()), new Guid("4EF31BD5-95AB-4172-AF94-E25A3CADAD74"));
                ddlPerfil.DataSource     = perfilesServices.lsPerfilesDropDownListModel;
                ddlPerfil.DataTextField  = "VchNombre";
                ddlPerfil.DataValueField = "UidSegPerfil";
                ddlPerfil.DataBind();
            }
            else
            {
                #region Direccion
                paisesServices     = (PaisesServices)Session["paisesServices"];
                estadosServices    = (EstadosServices)Session["estadosServices"];
                municipiosServices = (MunicipiosServices)Session["municipiosServices"];
                ciudadesServices   = (CiudadesServices)Session["ciudadesServices"];
                coloniasServices   = (ColoniasServices)Session["coloniasServices"];
                #endregion

                usuariosCompletosServices = (UsuariosCompletosServices)Session["usuariosCompletosServices"];
                //telefonosUsuariosServices = (TelefonosUsuariosServices)Session["telefonosUsuariosServices"];

                estatusService         = (EstatusServices)Session["estatusService"];
                tiposTelefonosServices = (TiposTelefonosServices)Session["tiposTelefonosServices"];
                clientesServices       = (ClientesServices)Session["clientesServices"];

                lblValidar.Text = string.Empty;

                pnlAlert.Visible     = false;
                lblMensajeAlert.Text = "";
                divAlert.Attributes.Add("class", "alert alert-danger alert-dismissible fade");

                txtPassword.Attributes.Add("value", txtPassword.Text);
                txtRepetirPassword.Attributes.Add("value", txtRepetirPassword.Text);
            }
        }
Esempio n. 5
0
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack)
            {
                //ScriptManager.RegisterStartupScript(this, this.GetType(), "FormScript", "hideAlert()", true);

                #region Direccion
                Session["paisesServices"]     = paisesServices;
                Session["estadosServices"]    = estadosServices;
                Session["municipiosServices"] = municipiosServices;
                Session["ciudadesServices"]   = ciudadesServices;
                Session["coloniasServices"]   = coloniasServices;
                #endregion

                Session["clientesServices"]          = clientesServices;
                Session["telefonosClientesServices"] = telefonosClientesServices;
                Session["estatusService"]            = estatusService;

                if (Session["UidFranquiciaMaster"] != null)
                {
                    ViewState["UidFranquiciaLocal"] = Session["UidFranquiciaMaster"];
                }
                else
                {
                    ViewState["UidFranquiciaLocal"] = Guid.Empty;
                }

                clientesServices.CargarClientes(Guid.Parse(ViewState["UidFranquiciaLocal"].ToString()));
                gvClientes.DataSource = clientesServices.lsClientesGridViewModel;
                gvClientes.DataBind();

                ddlZonaHoraria.DataSource     = TimeZoneInfo.GetSystemTimeZones();
                ddlZonaHoraria.DataTextField  = "DisplayName";
                ddlZonaHoraria.DataValueField = "Id";
                ddlZonaHoraria.DataBind();

                estatusService.CargarEstatus();
                ddlEstatus.DataSource     = estatusService.lsEstatus;
                ddlEstatus.DataTextField  = "VchDescripcion";
                ddlEstatus.DataValueField = "UidEstatus";
                ddlEstatus.DataBind();

                tiposTelefonosServices.CargarTiposTelefonos();
                ddlTipoTelefono.DataSource     = tiposTelefonosServices.lsTiposTelefonos;
                ddlTipoTelefono.DataTextField  = "VchDescripcion";
                ddlTipoTelefono.DataValueField = "UidTipoTelefono";
                ddlTipoTelefono.DataBind();

                paisesServices.CargarPaises();
                ddlPais.DataSource     = paisesServices.lsPaises;
                ddlPais.DataTextField  = "VchPais";
                ddlPais.DataValueField = "UidPais";
                ddlPais.DataBind();
            }
            else
            {
                #region Direccion
                paisesServices     = (PaisesServices)Session["paisesServices"];
                estadosServices    = (EstadosServices)Session["estadosServices"];
                municipiosServices = (MunicipiosServices)Session["municipiosServices"];
                ciudadesServices   = (CiudadesServices)Session["ciudadesServices"];
                coloniasServices   = (ColoniasServices)Session["coloniasServices"];
                #endregion

                clientesServices          = (ClientesServices)Session["clientesServices"];
                telefonosClientesServices = (TelefonosClientesServices)Session["telefonosClientesServices"];

                estatusService         = (EstatusServices)Session["estatusService"];
                tiposTelefonosServices = (TiposTelefonosServices)Session["tiposTelefonosServices"];

                pnlAlert.Visible     = false;
                lblMensajeAlert.Text = "";
                divAlert.Attributes.Add("class", "alert alert-danger alert-dismissible fade");
            }
        }