diff --git a/application/admin/controller/Index.php b/application/admin/controller/Index.php index 4e0701f..934d21b 100644 --- a/application/admin/controller/Index.php +++ b/application/admin/controller/Index.php @@ -170,6 +170,7 @@ class Index extends Backend $html = "
"; $html .= ""; + return $html; } /** @@ -177,6 +178,7 @@ class Index extends Backend */ public function sendSms() { + $mobile = $this->request->get('mobile', ''); if(!$mobile){ diff --git a/application/admin/controller/qingdong/customer/Customer.php b/application/admin/controller/qingdong/customer/Customer.php index ae38a45..d17b1c5 100644 --- a/application/admin/controller/qingdong/customer/Customer.php +++ b/application/admin/controller/qingdong/customer/Customer.php @@ -1532,7 +1532,9 @@ class Customer extends Base return json($result); } + $token = cache("baidu_api_token"); + $token = ""; if(!$token){ $resStr = $this->get_token(); $res = json_decode($resStr,true); @@ -1609,7 +1611,8 @@ class Customer extends Base public function get_token(){ $curl = curl_init(); curl_setopt_array($curl, array( - CURLOPT_URL => "https://aip.baidubce.com/oauth/2.0/token?client_id=VBgaZy6xOiHsWVRMTuOqRynw&client_secret=fe6OOmXCZzt2B7BDGo6ctyR3TPEZkmws&grant_type=client_credentials", +// CURLOPT_URL => "https://aip.baidubce.com/oauth/2.0/token?client_id=VBgaZy6xOiHsWVRMTuOqRynw&client_secret=fe6OOmXCZzt2B7BDGo6ctyR3TPEZkmws&grant_type=client_credentials", + CURLOPT_URL => "https://aip.baidubce.com/oauth/2.0/token?client_id=PzVHnlfCX0GEX2YMYST4fCHU&client_secret=kquRpqe7EVZrDecRWdR9fMzUGfS3Lz2C&grant_type=client_credentials", CURLOPT_TIMEOUT => 30, CURLOPT_RETURNTRANSFER => true, CURLOPT_CUSTOMREQUEST => 'POST', diff --git a/application/admin/library/Auth.php b/application/admin/library/Auth.php index 64de757..0c6d0b8 100644 --- a/application/admin/library/Auth.php +++ b/application/admin/library/Auth.php @@ -156,6 +156,7 @@ class Auth extends \fast\Auth { $admin = Admin::get(intval($this->id)); if ($admin) { + var_dump(111122222); $admin->token = ''; $admin->save(); } diff --git a/application/common/controller/Backend.php b/application/common/controller/Backend.php index 6c55789..1055c2c 100644 --- a/application/common/controller/Backend.php +++ b/application/common/controller/Backend.php @@ -123,6 +123,7 @@ class Backend extends Controller $actionname = strtolower($this->request->action()); $admin = Session::get('admin')?Session::get('admin'):Session::get('member'); + $checkcid = $this->request->request('changecid'); if($checkcid && $admin['id']!=$checkcid){ $update = [ @@ -153,9 +154,11 @@ class Backend extends Controller // 设置当前请求的URI $this->auth->setRequestUri($path); + // 检测是否需要验证登录 if (!$this->auth->match($this->noNeedLogin)) { //检测是否登录 + var_dump($admin); if (!$this->auth->isLogin() && !$this->auth->isMemberLogin()) { Hook::listen('admin_nologin', $this); $url = Session::get('referer'); diff --git a/application/config.php b/application/config.php index 2eb1224..0695ec5 100644 --- a/application/config.php +++ b/application/config.php @@ -269,11 +269,11 @@ return [ //登录验证码 'login_captcha' => true, //登录失败超过10次则1天后重试 - 'login_failure_retry' => true, + 'login_failure_retry' => false, //是否同一账号同一时间只能在一个地方登录 'login_unique' => false, //是否开启IP变动检测 - 'loginip_check' => true, + 'loginip_check' => false, //登录页默认背景图 'login_background' => "", //是否启用多级菜单导航