From a2e7ebffa60d19e7dcf024e4951ef7cbe4bdf4f4 Mon Sep 17 00:00:00 2001
From: zhaoxiang <zhaoxiang051405@gmail.com>
Date: Thu, 26 Mar 2020 14:16:07 +0800
Subject: [PATCH] =?UTF-8?q?modified=20=E4=BC=98=E5=8C=96=E7=9B=AE=E5=BD=95?=
 =?UTF-8?q?=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;');
     }
 }