From 1e5738ab09f30d4669cb863a78c17b777455c6ec Mon Sep 17 00:00:00 2001 From: zhaoxiang Date: Wed, 25 Mar 2020 17:40:00 +0800 Subject: [PATCH 1/2] =?UTF-8?q?modified=20=E5=AE=9E=E6=97=B6=E5=88=B7?= =?UTF-8?q?=E6=96=B0AccessToken=E6=9D=83=E9=99=90?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- application/admin/controller/App.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/application/admin/controller/App.php b/application/admin/controller/App.php index ae8f984..8ae8aa3 100644 --- a/application/admin/controller/App.php +++ b/application/admin/controller/App.php @@ -138,7 +138,7 @@ class App extends Base { return $this->buildFailed(ReturnCode::DB_SAVE_ERROR); } $appInfo = AdminApp::get($id); - cache('AccessToken:' . $appInfo['app_secret'], null); + cache('AccessToken:Easy:' . $appInfo['app_secret'], null); if($oldWiki = cache('WikiLogin:' . $id)) { cache('WikiLogin:' . $oldWiki, null); } @@ -174,7 +174,7 @@ class App extends Base { return $this->buildFailed(ReturnCode::DB_SAVE_ERROR); } $appInfo = AdminApp::get($postData['id']); - cache('AccessToken:' . $appInfo['app_secret'], null); + cache('AccessToken:Easy:' . $appInfo['app_secret'], null); if($oldWiki = cache('WikiLogin:' . $postData['id'])) { cache('WikiLogin:' . $oldWiki, null); } @@ -194,7 +194,7 @@ class App extends Base { return $this->buildFailed(ReturnCode::EMPTY_PARAMS, '缺少必要参数'); } $appInfo = AdminApp::get($id); - cache('AccessToken:' . $appInfo['app_secret'], null); + cache('AccessToken:Easy:' . $appInfo['app_secret'], null); AdminApp::destroy($id); if($oldWiki = cache('WikiLogin:' . $id)) { From a2e7ebffa60d19e7dcf024e4951ef7cbe4bdf4f4 Mon Sep 17 00:00:00 2001 From: zhaoxiang Date: Thu, 26 Mar 2020 14:16:07 +0800 Subject: [PATCH 2/2] =?UTF-8?q?modified=20=E4=BC=98=E5=8C=96=E7=9B=AE?= =?UTF-8?q?=E5=BD=95=E5=88=9D=E5=A7=8B=E6=95=B0=E6=8D=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../migrations/20200324080953_update_admin_menu_data.php | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/database/migrations/20200324080953_update_admin_menu_data.php b/database/migrations/20200324080953_update_admin_menu_data.php index d41c998..fd43a64 100644 --- a/database/migrations/20200324080953_update_admin_menu_data.php +++ b/database/migrations/20200324080953_update_admin_menu_data.php @@ -25,8 +25,11 @@ class UpdateAdminMenuData extends Migrator { * with the Table class. */ public function up() { - $this->execute('UPDATE admin_menu SET show = 2 WHERE show = 0;'); - $this->execute('UPDATE admin_menu SET show = 0 WHERE show = 1;'); - $this->execute('UPDATE admin_menu SET show = 1 WHERE show = 2;'); + $this->execute('UPDATE `admin_menu` SET `show` = 2 WHERE `show` = 0;'); + $this->execute('UPDATE `admin_menu` SET `show` = 0 WHERE `show` = 1;'); + $this->execute('UPDATE `admin_menu` SET `show` = 1 WHERE `show` = 2;'); + $this->execute('UPDATE `admin_menu` SET `level` = 1 WHERE `fid` = 0;'); + $this->execute('UPDATE `admin_menu` SET `level` = 3 WHERE `url` != "";'); + $this->execute('UPDATE `admin_menu` SET `level` = 2 WHERE `level` = 0;'); } }