private bool DoLogin(string logName, string pwd)
        {
            SaveConnectString();

            if (UpGradeDataBase())
            {//升级数据库
                AppSettings.Current.DatabaseNeedUpgrade = false;
            }

            OperatorBLL authen = new OperatorBLL(AppSettings.Current.ConnStr);

            if (authen.Authentication(logName, pwd))
            {
                this.DialogResult = DialogResult.OK;
                if (AppSettings.Current.RememberLogID)
                {
                    SaveHistoryOperators();
                }
                this.Close();
                return(true);
            }
            else
            {
                return(false);
            }
        }
 private bool DoLogin(string logName, string pwd)
 {
     SaveConnectString();
     UpgradeLocalDB(); //升级本地数据库
     OperatorBLL authen = new OperatorBLL(AppSettings.Current.ConnStr);
     if (authen.Authentication(logName, pwd))
     {
         this.DialogResult = DialogResult.OK;
         if (AppSettings.Current.RememberLogID) SaveHistoryOperators();
         this.Close();
         return true;
     }
     else
     {
         return false;
     }
 }
Example #3
0
        private bool DoLogin(string logName, string pwd)
        {
            OperatorBLL authen = new OperatorBLL(AppSettings.Current.ConnStr);

            if (authen.Authentication(logName, pwd))
            {
                this.DialogResult = DialogResult.OK;
                if (AppSettings.Current.RememberLogID)
                {
                    SaveHistoryOperators();
                }
                this.Close();
                return(true);
            }
            else
            {
                return(false);
            }
        }