Explorar o código

[Mod 0000]优化项目菜单

hongrunxia hai 1 día
pai
achega
c5957978cd

+ 29 - 24
src/layouts/default/sider/bottomSideder.vue

@@ -1,31 +1,33 @@
 <template>
   <div v-if="isShowMenu == -1" class="bottom-side" :class="{ 'bottom-size-show': isShowMenu }">
     <div class="menu-container">
-      <template v-for="(menu, index) in currentParentRoute.children" :key="index">
-        <FourBorderBg class="four-border-bg" v-if="!menu.hideMenu">
-          <div class="vent-flex-row">
-            <div class="parent-menu">
-              {{ menu.name }}
-            </div>
-            <div class="vent-flex-row-wrap child-menu">
-              <template v-for="(childMenu, childIndex) in menu.children" :key="childIndex">
-                <template v-if="!childMenu.hideMenu">
-                  <template v-if="childMenu['ver'] == 1">
-                    <div class="child-menu-item" @click.stop="handleMenuClick(childMenu)">
-                      {{ childMenu.name }}
-                    </div>
-                  </template>
-                  <template v-else>
-                    <div class="child-menu-item-disabled" @click.stop="handleMenuClick(childMenu)" :style="{ backgroundColor: '#314671' }">
-                      {{ childMenu.name }}
-                    </div>
+      <div class="menu-items">
+        <template v-for="(menu, index) in currentParentRoute.children" :key="index">
+          <FourBorderBg class="four-border-bg" v-if="!menu.hideMenu">
+            <div class="vent-flex-row">
+              <div class="parent-menu">
+                {{ menu.name }}
+              </div>
+              <div class="vent-flex-row-wrap child-menu">
+                <template v-for="(childMenu, childIndex) in menu.children" :key="childIndex">
+                  <template v-if="!childMenu.hideMenu">
+                    <template v-if="childMenu['ver'] == 1">
+                      <div class="child-menu-item" @click.stop="handleMenuClick(childMenu)">
+                        {{ childMenu.name }}
+                      </div>
+                    </template>
+                    <template v-else>
+                      <div class="child-menu-item-disabled" @click.stop="handleMenuClick(childMenu)" :style="{ backgroundColor: '#314671' }">
+                        {{ childMenu.name }}
+                      </div>
+                    </template>
                   </template>
                 </template>
-              </template>
+              </div>
             </div>
-          </div>
-        </FourBorderBg>
-      </template>
+          </FourBorderBg>
+        </template>
+      </div>
 
       <div class="vent-flex-row-between menu-button-group">
         <div class="vent-flex-row program-group">
@@ -202,8 +204,11 @@
       background-color: #0c1e2b;
       z-index: 999;
       max-height: 900px;
-      overflow-y: auto;
-      // backdrop-filter: blur(8px);
+      .menu-items {
+        max-height: 840px;
+        overflow-y: auto;
+      }
+
       .four-border-bg {
         margin: 5px;
         background-color: #ffffff00;

+ 1 - 1
src/utils/http/axios/axiosCancel.ts

@@ -14,7 +14,7 @@ export class AxiosCanceler {
    */
   public addPending(config: AxiosRequestConfig): void {
     this.removePending(config);
-    const url = getPendingUrl(config)
+    const url = getPendingUrl(config);
     const controller = new AbortController();
     config.signal = config.signal || controller.signal;
     if (!pendingMap.has(url)) {

+ 4 - 5
src/utils/http/axios/index.ts

@@ -107,12 +107,11 @@ const transform: AxiosTransform = {
         config.url = `${urlPrefix}${config.url}`;
       }
       if (apiUrl && isString(apiUrl)) {
-        if(config.url?.startsWith('/gasServerImg')){
-        config.url=`/sw${config.url}`
-        }else {
-           config.url = `${apiUrl}${config.url}`;
+        if (config.url?.startsWith('/gasServerImg')) {
+          config.url = `/sw${config.url}`;
+        } else {
+          config.url = `${apiUrl}${config.url}`;
         }
-      
       }
       const params = config.params || {};
       const data = config.data || false;