From e906b8ad0a8a0bd8112fbd63ae62993dae75ad26 Mon Sep 17 00:00:00 2001
From: 疯狂的狮子Li <15040126243@163.com>
Date: 星期一, 14 八月 2023 12:56:31 +0800
Subject: [PATCH] update 优化 全局移除cookie使用 避免安全问题

---
 src/layout/index.vue |   43 +++++++++++++++++++------------------------
 1 files changed, 19 insertions(+), 24 deletions(-)

diff --git a/src/layout/index.vue b/src/layout/index.vue
index 4c6ab94..8239ed7 100644
--- a/src/layout/index.vue
+++ b/src/layout/index.vue
@@ -1,17 +1,23 @@
 <template>
   <div :class="classObj" class="app-wrapper" :style="{ '--current-color': theme }">
-    <el-scrollbar>
-      <div v-if="device === 'mobile' && sidebar.opened" class="drawer-bg" @click="handleClickOutside"/>
-      <side-bar v-if="!sidebar.hide" class="sidebar-container" />
-      <div :class="{ hasTagsView: needTagsView, sidebarHide: sidebar.hide }" class="main-container">
+    <div v-if="device === 'mobile' && sidebar.opened" class="drawer-bg" @click="handleClickOutside" />
+    <side-bar v-if="!sidebar.hide" class="sidebar-container" />
+    <div :class="{ hasTagsView: needTagsView, sidebarHide: sidebar.hide }" class="main-container">
+      <!-- <el-scrollbar>
         <div :class="{ 'fixed-header': fixedHeader }">
-            <navbar ref="navbarRef" @setLayout="setLayout" />
-            <tags-view v-if="needTagsView" />
+          <navbar ref="navbarRef" @setLayout="setLayout" />
+          <tags-view v-if="needTagsView" />
         </div>
         <app-main />
         <settings ref="settingRef" />
+      </el-scrollbar> -->
+      <div :class="{ 'fixed-header': fixedHeader }">
+        <navbar ref="navbarRef" @setLayout="setLayout" />
+        <tags-view v-if="needTagsView" />
       </div>
-    </el-scrollbar>
+      <app-main />
+      <settings ref="settingRef" />
+    </div>
   </div>
 </template>
 
@@ -54,17 +60,17 @@
 const settingRef = ref(Settings);
 
 onMounted(() => {
-    nextTick(() => {
-        navbarRef.value.initTenantList();
-    })
+  nextTick(() => {
+    navbarRef.value.initTenantList();
+  })
 })
 
 const handleClickOutside = () => {
-    useAppStore().closeSideBar({ withoutAnimation: false })
+  useAppStore().closeSideBar({ withoutAnimation: false })
 }
 
 const setLayout = () => {
-    settingRef.value.openSetting();
+  settingRef.value.openSetting();
 }
 </script>
 
@@ -77,18 +83,6 @@
   position: relative;
   height: 100%;
   width: 100%;
-
-  .el-scrollbar {
-    height: 100%;
-  }
-
-  :deep(.el-scrollbar__bar).is-vertical {
-    z-index: 10;
-  }
-
-  :deep(.el-scrollbar__wrap) {
-    overflow-x: hidden;
-  }
 
   &.mobile.openSidebar {
     position: fixed;
@@ -113,6 +107,7 @@
   z-index: 9;
   width: calc(100% - #{$base-sidebar-width});
   transition: width 0.28s;
+  background: $fixed-header-bg;
 }
 
 .hideSidebar .fixed-header {

--
Gitblit v1.9.3