private void btnSave_Click(object sender, EventArgs e) { if (txtPass.Text == txtConfirm.Text) { var bll = new Pol_UserBLL(); if (bll.ChangePass(txtPass.Text)) { XtraMessageBox.Show(STR_SUCC, STR_TITLE, MessageBoxButtons.OK, MessageBoxIcon.Information); Extend.Login(); } else { XtraMessageBox.Show(STR_ERR, STR_TITLE, MessageBoxButtons.OK, MessageBoxIcon.Error); txtPass.Focus(); } } else { XtraMessageBox.Show(STR_CONFIRM, STR_TITLE, MessageBoxButtons.OK, MessageBoxIcon.Error); txtConfirm.Focus(); } }
private void btnLogon_Click(object sender, EventArgs e) { var bll = new Pol_UserBLL(); var sss = bll.CheckLogin(txtUser.Text, txtPass.Text); if (sss != null) { BasePRE._sss = sss; //var x = BaseBLL._pol_UserBLL.GetRights(sss.User.Id); //var y = BaseBLL._pol_UserBLL.GetRights(sss.User.Id, this.GetType().Name); NotifyAfterLogon(); Close(); } else BasePRE.ShowMessage(STR_ERR, STR_LOGIN); }
private void btnLogon_Click(object sender, EventArgs e) { try { if (Global.Setting) { if (txtUser.Text == "system" && txtPass.Text == "@sm13579208") { DialogResult = DialogResult.OK; return; } else XtraMessageBox.Show(STR_ERR, STR_LOGIN); return; } var bll = new Pol_UserBLL(); var sss = bll.CheckLogin(txtUser.Text, txtPass.Text); if (sss != null) { Global.Session = sss; NotifyAfterLogon(); Close(); } else XtraMessageBox.Show(STR_ERR, STR_LOGIN); } catch { throw new Exception(); } }
public void Dispose() { _bll.Dispose(); _bll = null; }
private void cmdResetPass_Click(object sender, EventArgs e) { var bll = new Pol_UserBLL(); if (bll.ChangePass("@123456")) XtraMessageBox.Show(STR_SUCC, STR_TITLE, MessageBoxButtons.OK, MessageBoxIcon.Information); else XtraMessageBox.Show(STR_ERR, STR_TITLE, MessageBoxButtons.OK, MessageBoxIcon.Error); }