From 4aa2666c98136fe5fb33cdaf5369a77e9edb455e Mon Sep 17 00:00:00 2001 From: Karson Date: Wed, 30 Aug 2023 16:24:11 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96=E5=90=8E=E5=8F=B0=E8=8F=9C?= =?UTF-8?q?=E5=8D=95=E5=88=87=E6=8D=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- public/assets/js/backend/index.js | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/public/assets/js/backend/index.js b/public/assets/js/backend/index.js index cfdbbafa..e3e9e9cf 100755 --- a/public/assets/js/backend/index.js +++ b/public/assets/js/backend/index.js @@ -333,11 +333,13 @@ define(['jquery', 'bootstrap', 'backend', 'addtabs', 'adminlte', 'form'], functi // 切换菜单栏 $(document).on("click", ".sidebar-toggle", function () { - var value = $("body").hasClass("sidebar-collapse") ? 1 : 0; - setTimeout(function () { - $(window).trigger("resize"); - }, 300); - createCookie('sidebar_collapse', value); + setTimeout(function(){ + var value = $("body").hasClass("sidebar-collapse") ? 1 : 0; + setTimeout(function () { + $(window).trigger("resize"); + }, 300); + createCookie('sidebar_collapse', value); + }, 0); }); // 切换多级菜单