From e00905e53ee5d91d9e488ecf5ece3e25b9889436 Mon Sep 17 00:00:00 2001
From: gaoluyang <2820782392@qq.com>
Date: 星期二, 20 一月 2026 16:14:44 +0800
Subject: [PATCH] 湟水峡 1.采购模块不要项目名称 2.加一个有待回款登记的提示 3.回款登记、付款登记改成和销售订单价格关联,并且可以多个一起回款或付款 4.合同管理不要下载合同了,跟合同相关的字段可以去掉了 5.重构生产模块 6.测试流程并修改bug

---
 src/layout/components/Navbar.vue |  129 +++++++++++++++++++++++++++++--------------
 1 files changed, 87 insertions(+), 42 deletions(-)

diff --git a/src/layout/components/Navbar.vue b/src/layout/components/Navbar.vue
index e0e2df8..633024f 100644
--- a/src/layout/components/Navbar.vue
+++ b/src/layout/components/Navbar.vue
@@ -1,34 +1,11 @@
 <template>
   <div class="navbar">
-    <hamburger id="hamburger-container" :is-active="appStore.sidebar.opened" class="hamburger-container" @toggleClick="toggleSideBar" />
-    <breadcrumb id="breadcrumb-container" class="breadcrumb-container" v-if="!settingsStore.topNav" />
-    <top-nav id="topmenu-container" class="topmenu-container" v-if="settingsStore.topNav" />
-
-    <div class="right-menu">
-      <template v-if="appStore.device !== 'mobile'">
-        <header-search id="header-search" class="right-menu-item" />
-
-        <el-tooltip content="婧愮爜鍦板潃" effect="dark" placement="bottom">
-          <ruo-yi-git id="ruoyi-git" class="right-menu-item hover-effect" />
-        </el-tooltip>
-
-        <el-tooltip content="鏂囨。鍦板潃" effect="dark" placement="bottom">
-          <ruo-yi-doc id="ruoyi-doc" class="right-menu-item hover-effect" />
-        </el-tooltip>
-
-        <screenfull id="screenfull" class="right-menu-item hover-effect" />
-
-        <el-tooltip content="涓婚妯″紡" effect="dark" placement="bottom">
-          <div class="right-menu-item hover-effect theme-switch-wrapper" @click="toggleTheme">
-            <svg-icon v-if="settingsStore.isDark" icon-class="sunny" />
-            <svg-icon v-if="!settingsStore.isDark" icon-class="moon" />
-          </div>
-        </el-tooltip>
-
-        <el-tooltip content="甯冨眬澶у皬" effect="dark" placement="bottom">
-          <size-select id="size-select" class="right-menu-item hover-effect" />
-        </el-tooltip>
-      </template>
+    <div>
+      <hamburger id="hamburger-container" :is-active="appStore.sidebar.opened" class="hamburger-container"
+        @toggleClick="toggleSideBar" />
+      <breadcrumb v-if="!settingsStore.topNav" id="breadcrumb-container" class="breadcrumb-container" />
+    </div>
+    <!--    <top-nav v-if="settingsStore.topNav" id="topmenu-container" class="topmenu-container" />-->
       <div class="avatar-container">
         <el-dropdown @command="handleCommand" class="right-menu-item hover-effect" trigger="click">
           <div class="avatar-wrapper">
@@ -51,7 +28,6 @@
         </el-dropdown>
       </div>
     </div>
-  </div>
 </template>
 
 <script setup>
@@ -71,21 +47,25 @@
 const appStore = useAppStore()
 const userStore = useUserStore()
 const settingsStore = useSettingsStore()
-
+const factoryList = ref([])
 function toggleSideBar() {
   appStore.toggleSideBar()
 }
+// const redirect = ref(undefined)
+// watch(route, (newRoute) => {
+//   redirect.value = newRoute.query && newRoute.query.redirect
+// }, { immediate: true })
 
 function handleCommand(command) {
   switch (command) {
     case "setLayout":
-      setLayout();
-      break;
+      setLayout()
+      break
     case "logout":
-      logout();
-      break;
+      logout()
+      break
     default:
-      break;
+      break
   }
 }
 
@@ -96,18 +76,52 @@
     type: 'warning'
   }).then(() => {
     userStore.logOut().then(() => {
-      location.href = '/index';
+      location.href = '/index'
     })
-  }).catch(() => { });
+  }).catch(() => { })
 }
 
 const emits = defineEmits(['setLayout'])
 function setLayout() {
-  emits('setLayout');
+  emits('setLayout')
 }
 
 function toggleTheme() {
   settingsStore.toggleTheme()
+}
+
+// function getUserLoginFacotryList() {
+//   if (userStore.id) {
+//     userLoginFacotryList({ userId: userStore.id }).then(res => {
+//       console.log('res', res)
+//       factoryList.value = res.data
+//     })
+//   } else {
+//     factoryList.value = []
+//   }
+// }
+
+function handleFactoryChange(command) {
+  console.log('command', command)
+  handleLogin(command.deptId);
+}
+
+function handleLogin(currentFatoryId) {
+  const loginForm = {
+    username: Cookies.get("username"),
+    password: Cookies.get("password") === undefined ? null : decrypt(Cookies.get("password")),
+    currentFatoryId: currentFatoryId
+  }
+  userStore.loginCheckFactory(loginForm).then(res => {
+    forceReload();
+  }).catch((err) => {
+    console.log(err)
+  })
+}
+function forceReload() {
+  const currentUrl = window.location.origin + window.location.pathname;
+  const timestamp = new Date().getTime();
+  window.location.href = `${currentUrl}?reload=${timestamp}`;
 }
 </script>
 
@@ -179,10 +193,23 @@
 
         svg {
           transition: transform 0.3s;
-          
+
           &:hover {
             transform: scale(1.15);
           }
+        }
+      }
+    }
+
+    .notification-container {
+      margin-right: 20px;
+      display: flex;
+      align-items: center;
+      cursor: pointer;
+
+      .notification-badge {
+        :deep(.el-badge__content) {
+          border: none;
         }
       }
     }
@@ -198,18 +225,36 @@
           cursor: pointer;
           width: 40px;
           height: 40px;
-          border-radius: 10px;
+          border-radius: 50px;
         }
 
         i {
           cursor: pointer;
           position: absolute;
           right: -20px;
-          top: 25px;
+          top: 14px;
           font-size: 12px;
         }
       }
     }
   }
 }
+
+</style>
+
+<style lang="scss">
+.notification-popover {
+  padding: 0 !important;
+  
+  .el-popover__title {
+    display: none;
+  }
+  
+  .el-popover__body {
+    padding: 0 !important;
+  }
+}
+.el-badge__content.is-fixed{
+  top: 12px;
+}
 </style>

--
Gitblit v1.9.3