From fb34ba28cb908bd328cf6690ab0b19a56428f4e2 Mon Sep 17 00:00:00 2001
From: WXL (wul) <wl_5969728@163.com>
Date: 星期五, 13 十一月 2026 10:56:55 +0800
Subject: [PATCH] 测试完成

---
 src/views/patient/follow/index.vue |   42 +++++++++++++++++++++++++++++++++++-------
 1 files changed, 35 insertions(+), 7 deletions(-)

diff --git a/src/views/patient/follow/index.vue b/src/views/patient/follow/index.vue
index ffe4cdf..2e403ef 100644
--- a/src/views/patient/follow/index.vue
+++ b/src/views/patient/follow/index.vue
@@ -188,12 +188,12 @@
           <el-table-column
             label="寤烘。鏃ユ湡"
             align="center"
-            key="createTime"
-            prop="createTime"
+            key="createTimeStart"
+            prop="createTimeStart"
             width="160"
           >
             <template slot-scope="scope">
-              <span>{{ formatTime(scope.row.createTime) }}</span>
+              <span>{{ formatTime(scope.row.createTimeStart) }}</span>
             </template>
           </el-table-column>
 
@@ -374,8 +374,8 @@
         status: undefined,
         tagIds: undefined,
         telcode: undefined,
-        createTime: undefined,
-        endTime: undefined,
+        createTimeStart: undefined,
+        createTimeEnd: undefined,
       },
       // 琛ㄥ崟鏍¢獙
       rules: {},
@@ -388,11 +388,39 @@
     },
   },
   created() {
+    // 褰撳墠鏈烘瀯涓轰附姘村競涓尰闄㈡椂锛屽缓妗f棩鏈熼粯璁ゆ渶杩戜竴涓湀
+    if (localStorage.getItem("orgname") == "涓芥按甯備腑鍖婚櫌") {
+      this.dateRange = this.getLastMonthRange();
+      this.queryParams.createTimeStart = this.dateRange[0];
+      this.queryParams.createTimeEnd = this.dateRange[1];
+    }
     this.getList();
     this.gettabList();
     this.Filterreason = store.getters.Filterreason;
   },
   methods: {
+    /** 鑾峰彇鏈�杩戜竴涓湀鏃堕棿鑼冨洿 */
+    getLastMonthRange() {
+      const end = new Date();
+      const start = new Date();
+      start.setTime(start.getTime() - 3600 * 1000 * 24 * 30);
+
+      const formatDate = (date) => {
+        const year = date.getFullYear();
+        const month = String(date.getMonth() + 1).padStart(2, "0");
+        const day = String(date.getDate()).padStart(2, "0");
+        return `${year}-${month}-${day} 00:00:00`;
+      };
+
+      const formatEndDate = (date) => {
+        const year = date.getFullYear();
+        const month = String(date.getMonth() + 1).padStart(2, "0");
+        const day = String(date.getDate()).padStart(2, "0");
+        return `${year}-${month}-${day} 23:59:59`;
+      };
+
+      return [formatDate(start), formatEndDate(end)];
+    },
     /** 鏌ヨ鎮h�呭垪琛� */
     getList() {
       this.loading = true;
@@ -460,8 +488,8 @@
     /** 鎼滅储鎸夐挳鎿嶄綔 */
     handleQuery() {
       this.queryParams.pageNum = 1;
-      this.queryParams.createTime = this.dateRange[0];
-      this.queryParams.endTime = this.dateRange[1];
+      this.queryParams.createTimeStart = this.dateRange[0];
+      this.queryParams.createTimeEnd = this.dateRange[1];
       this.getList();
     },
     /** 閲嶇疆鎸夐挳鎿嶄綔 */

--
Gitblit v1.9.3