Esempio n. 1
0
    protected void Page_Load(object sender, EventArgs e)
    {
        ScriptManager sm = ScriptManager.GetCurrent(this.Page);

        if (sm != null)
        {
            sm.Scripts.Add(new ScriptReference(ArquivoJS.CamposData));
        }

        if (!IsPostBack)
        {
            UCComboPais1._Label.Text        = "Nacionalidade";
            UCComboPais1._EnableValidator   = false;
            UCComboPais1._ShowSelectMessage = true;
            UCComboPais1._Load(0);

            UCComboTipoEscolaridade1._Label.Text        = "Escolaridade";
            UCComboTipoEscolaridade1._EnableValidator   = false;
            UCComboTipoEscolaridade1._ShowSelectMessage = true;
            UCComboTipoEscolaridade1._Load(0);


            UCComboTipoDeficiencia1._EnableValidator   = false;
            UCComboTipoDeficiencia1._ShowSelectMessage = true;
            UCComboTipoDeficiencia1._Load(Guid.Empty, 0);

            UCComboEstadoCivil1.Inicialize("Estado civil");
            UCComboEstadoCivil1._EnableValidator = false;

            UCComboSexo1.Inicialize("Sexo");
            UCComboSexo1._EnableValidator = false;
            UCComboSexo1._ValidationGroup = "Pessoa";
        }
    }
Esempio n. 2
0
    protected void Page_Load(object sender, EventArgs e)
    {
        ScriptManager sm = ScriptManager.GetCurrent(Page);

        if (sm != null)
        {
            sm.Scripts.Add(new ScriptReference(ArquivoJS.JQueryValidation));
            sm.Scripts.Add(new ScriptReference(ArquivoJS.JqueryMask));
            sm.Scripts.Add(new ScriptReference(ArquivoJS.MascarasCampos));
            sm.Scripts.Add(new ScriptReference(ArquivoJS.MsgConfirmBtn));
            sm.Scripts.Add(new ScriptReference("~/Includes/jsCadastroAlunoMatricula.js"));
        }

        string script = String.Format("SetConfirmDialogButton('{0}','{1}');",
                                      String.Concat("#", btnExcluir.ClientID), "Confirma a exclusão da foto?<br/> Atenção, essa operação não poderá ser desfeita e as alterações realizadas serão perdidas.");

        Page.ClientScript.RegisterStartupScript(GetType(), btnExcluir.ClientID, script, true);

        if (!IsPostBack)
        {
            try
            {
                string pessoa = string.Empty;

                if (_VS_tipoPessoa == 1)
                {
                    pessoa = " do aluno";
                }
                if (_VS_tipoPessoa == 2)
                {
                    pessoa = " do docente";
                }
                if (_VS_tipoPessoa == 3)
                {
                    pessoa = " do colaborador";
                }

                cvDataNascimento.ErrorMessage = GestaoEscolarUtilBO.RetornaMsgValidacaoData("Data de nascimento" + pessoa);

                ComboNacionalidade1.Carregar();

                ComboTipoDeficiencia1.Carregar();
                ComboTipoDeficiencia1.Titulo = GestaoEscolarUtilBO.nomePadraoTipoDeficiencia(__SessionWEB.__UsuarioWEB.Usuario.ent_id);

                UCComboTipoEscolaridade1._MostrarMessageSelecione = true;
                UCComboTipoEscolaridade1._Load(0);
            }
            catch (Exception ex)
            {
                ApplicationWEB._GravaErro(ex);
            }
        }

        if (_VS_alu_id > 0)
        {
            ComboTipoDeficiencia1.OnSeletedIndexChanged += UCComboTipoDeficiencia1_IndexChanged;
        }
    }
Esempio n. 3
0
 /// <summary>
 /// Carrega os dados iniciais necessários no user control.
 /// </summary>
 public void InicializarUserControl()
 {
     try
     {
         UCComboTipoEscolaridade1._MostrarMessageSelecione = true;
         UCComboTipoEscolaridade1._Load(1);
     }
     catch (Exception ex)
     {
         ApplicationWEB._GravaErro(ex);
         lblMensagem.Text = UtilBO.GetErroMessage("Erro ao tentar carregar o sistema.", UtilBO.TipoMensagem.Erro);
     }
 }