From b893b03cf704214ce952c5ed2c28c6d741d3ea0a Mon Sep 17 00:00:00 2001
From: qinxianzhangyao <11053546+qinxianzhangyao@user.noreply.gitee.com>
Date: 星期三, 26 六月 2024 09:35:57 +0800
Subject: [PATCH] qxtj

---
 src/views/doctor/examination/index.vue |   39 +++++++++++++++++++++++----------------
 1 files changed, 23 insertions(+), 16 deletions(-)

diff --git a/src/views/doctor/examination/index.vue b/src/views/doctor/examination/index.vue
index 155f69a..d46045d 100644
--- a/src/views/doctor/examination/index.vue
+++ b/src/views/doctor/examination/index.vue
@@ -49,6 +49,7 @@
           icon="el-icon-search"
           size="mini"
           @click="handleQuery"
+          style="margin-right: 15px"
           >鏌ヨ</el-button
         >
         <el-button icon="el-icon-refresh" size="mini" @click="resetQuery"
@@ -149,10 +150,7 @@
           <!--   v-hasPermi="['reservation:reservation:edit']" -->
           <el-table-column label="鎿嶄綔" align="center" width="120px">
             <template slot-scope="scope">
-              <el-button
-                size="mini"
-                type="text"  
-                @click="tongbu(scope.row)"
+              <el-button size="mini" type="text" @click="tongbu(scope.row)"
                 >鍚屾</el-button
               >
               <el-button
@@ -353,7 +351,6 @@
     };
   },
   created() {
-    this.getList();
     this.getdate();
     // this.getNowTime();
   },
@@ -369,6 +366,7 @@
           moment(res.data).format("YYYY-MM-DD 00:00:00"),
           moment(res.data).format("YYYY-MM-DD 23:59:00"),
         ];
+        this.getList();
       });
     },
     // / 澶勭悊榛樿閫変腑褰撳墠鏃ユ湡
@@ -409,8 +407,14 @@
     getList() {
       this.loading = true;
       this.queryParams.checkStatus = this.checkStatus;
-      this.queryParams.beginTime = this.createTimeList[0];
-      this.queryParams.endTime = this.createTimeList[1];
+      if (this.createTimeList) {
+        this.queryParams.beginTime = this.createTimeList[0];
+        this.queryParams.endTime = this.createTimeList[1];
+      } else if (this.createTimeList == null) {
+        this.queryParams.beginTime = null;
+        this.queryParams.endTime = null;
+      }
+
       getCsList(this.queryParams).then((res) => {
         if (res.code == 200) {
           this.loading = false;
@@ -454,7 +458,7 @@
     },
 
     hb() {
-      console.log(this.queryParams.tjNumber);
+      // console.log(this.queryParams.tjNumber);
       if (this.queryParams.tjNumber != null) {
         this.handleQuery();
       }
@@ -466,12 +470,14 @@
     },
     /** 閲嶇疆鎸夐挳鎿嶄綔 */
     resetQuery() {
+      this.createTimeList = [];
       this.resetForm("queryForm");
       this.handleQuery();
       this.loading = true;
     },
     // 鍗曢�夋閫変腑鏁版嵁
     handleSelectionChange(selection) {
+      console.log(11111);
       this.selectList = selection;
       this.multipleSelection = [];
       if (selection.length > 1) {
@@ -487,12 +493,12 @@
         cSWebGetPro(tjNumber).then((res) => {
           this.xiangmuList = res.data;
           this.xiangmuList.forEach((item) => {
-            console.log(item);
-            if (item.type == 0) {
-              this.dis = true;
-            } else {
-              this.dis = false;
-            }
+            // console.log(item);
+            // if (item.type == 0) {
+            //   this.dis = true;
+            // } else {
+            //   this.dis = false;
+            // }
           });
         });
       });
@@ -520,18 +526,19 @@
           if (res.code == 200) {
             // this.$forceUpdate();
             this.getList();
-            this.xiangmuList = []
+            this.xiangmuList = [];
             this.$modal.msgSuccess("鎻愪氦鎴愬姛锛�");
           }
         });
       });
     },
     tongbu(row) {
+      this.$refs.tb.toggleRowSelection(row);
       let tjNumber = row.tjNumber;
       dataSynchronization(tjNumber).then((res) => {
         if (res.code == 200) {
           // this.$forceUpdate();
-          this.getList();
+          // this.getList();
           this.$modal.msgSuccess("鍚屾鎴愬姛锛�");
         }
       });

--
Gitblit v1.8.0