zhaobao 3 lat temu
rodzic
commit
e011cfc4e5
1 zmienionych plików z 18 dodań i 4 usunięć
  1. 18 4
      src/layout/components/Navbar.vue

+ 18 - 4
src/layout/components/Navbar.vue

@@ -3,7 +3,15 @@
     <div class="hos-name">
     <div class="hos-name">
       <img :src="logo" alt="logo">
       <img :src="logo" alt="logo">
       <hamburger id="hamburger-container" :is-active="sidebar.opened" class="hamburger-container" @toggleClick="toggleSideBar" />
       <hamburger id="hamburger-container" :is-active="sidebar.opened" class="hamburger-container" @toggleClick="toggleSideBar" />
-      <!-- <span v-if="userData.ocName" class="tag">/{{ userData.ocName }}</span> -->
+      <span v-if="userData.ocName" class="tag">{{ userData.ocName }}</span>
+      <countdown v-if="userData.licExpiredTime" :end-time="userData.licExpiredTime">
+        <div
+          slot="process"
+          slot-scope="{ timeObj }"
+          class="tag authorization"
+        >(授权时长:{{ `${timeObj.d}天${timeObj.h}:${timeObj.m}:${timeObj.s}` }})</div>
+        <div slot="finish" class="tag authorization error">(请续费使用)</div>
+      </countdown>
     </div>
     </div>
     <!-- 隐藏标签 -->
     <!-- 隐藏标签 -->
     <breadcrumb v-if="0" id="breadcrumb-container" class="breadcrumb-container" />
     <breadcrumb v-if="0" id="breadcrumb-container" class="breadcrumb-container" />
@@ -206,10 +214,16 @@ export default {
   }
   }
   .tag{
   .tag{
     font-size: 16px;
     font-size: 16px;
-    line-height: 16px;
+    line-height: 1;
     font-weight: 600;
     font-weight: 600;
-    padding-left: 10px;
-    margin-top: 10px;
+    padding-left: 5px;
+    margin-top: 15px;
+    &.authorization{
+      font-size: 12px;
+      margin-top: 20px;
+      color: #a33e3e;
+      // color: rgba(255, 255, 255, 0.7);
+    }
   }
   }
 }
 }
   .hamburger-container {
   .hamburger-container {