Пример #1
0
        public static bool ChangePassword(int uid, string oldpwd, string newpwd)
        {
            bool retValue = false;

            using (MySqlConnection conn = DBUtility.OpenConnection())
            {
                if (EmployeeDal.CheckPwd(uid, oldpwd, conn))
                {
                    retValue = EmployeeDal.UpdatePwd(uid, newpwd, conn) > 0;
                }
            }
            return(true);
        }