From c2b88a03f3d0d5ebe92949e64d17ee4d0ac3f6b7 Mon Sep 17 00:00:00 2001
From: skyouc
Date: 星期二, 09 九月 2025 15:14:00 +0800
Subject: [PATCH] 发货清空缓存站点

---
 zy-asrs-admin/src/views/IndexView.vue |   21 +++++++++++++++++++--
 1 files changed, 19 insertions(+), 2 deletions(-)

diff --git a/zy-asrs-admin/src/views/IndexView.vue b/zy-asrs-admin/src/views/IndexView.vue
index 10cdd64..f615790 100644
--- a/zy-asrs-admin/src/views/IndexView.vue
+++ b/zy-asrs-admin/src/views/IndexView.vue
@@ -204,13 +204,31 @@
 const licenseDays = ref(365);
 getLicenseDays();
 function getLicenseDays() {
+ const currentDate = new Date();
+ const newDate = new Date(currentDate);
   post('/api/license/getLicenseDays', {}).then((resp) => {
     let result = resp.data;
     let data = result.data;
     if (result.code == 200) {
       licenseDays.value = data;
+      if(data <= 15) {
+       newDate.setDate(currentDate.getDate() + data);
+      銆�alert("璁稿彲璇佹湁鏁堟湡锛�" + data + "澶╋紝"銆�+銆�"鍒版湡鏃ユ湡锛�"銆�+銆�formatDate(newDate))
+      }
     }
   })
+}
+
+// 瀹屾暣鐨勬棩鏈熸牸寮忓寲鍑芥暟
+function formatDate(date, format = 'yyyy-MM-dd') {
+    const year = date.getFullYear();
+    const month = String(date.getMonth() + 1).padStart(2, '0');
+    const day = String(date.getDate()).padStart(2, '0');
+
+    return format
+        .replace('yyyy', year)
+        .replace('MM', month)
+        .replace('dd', day);
 }
 
 const switchHost = (item) => {
@@ -252,7 +270,6 @@
     }
     console.log(state.openKeys)
 }
-
 
 </script>
 
@@ -387,7 +404,7 @@
 
 <style scoped>
   .ant-layout-sider ant-layout-sider-dark main-sider {
-     min-height: 100vh;
+     max-height: 100vh;
     background: #01101E;
   }
 

--
Gitblit v1.9.1