From c7a95dae2c8c0a2fed4ceb8f7acb097598d346df Mon Sep 17 00:00:00 2001
From: chenyc <501753378@qq.com>
Date: 星期五, 22 七月 2022 12:59:43 +0800
Subject: [PATCH] up

---
 src/views/home/index.vue |   27 ++++++++++++++++++---------
 1 files changed, 18 insertions(+), 9 deletions(-)

diff --git a/src/views/home/index.vue b/src/views/home/index.vue
index f4964cb..1416729 100644
--- a/src/views/home/index.vue
+++ b/src/views/home/index.vue
@@ -21,6 +21,7 @@
         const AudioRef = ref()
         const AudioRef2 = ref()
         const AudioRef3 = ref()
+        const AudioRef4=ref()
         const isLink = computed(() => {
             return !sockte.isLink
         })
@@ -52,6 +53,7 @@
                 }
                 else {
                     clearInterval(timer)
+                    const datetimeCON=patientInfoStore().patientInfo.datetime
                     patientInfoStore().setpatientInfo({
                         id: 0,
                         code: '',
@@ -59,7 +61,8 @@
                         patientAvatarIcon: '',
                         deviceCode: '',
                         hemoCode: '',
-                        pureWeight: ''
+                        pureWeight: '',
+                        datetime:datetimeCON
                     })
                     state.clockNum = patientInfoStore().viewNumber
                     sockteStore().setweightSockte({
@@ -103,9 +106,8 @@
             mai_bu: ""//脉搏
         })
         watch(
-            () => patientInfo.value.id,
+            () => patientInfo.value.datetime,
             () => {
-                console.log('患者变化了', patientInfo)
                 if (patientInfo.value.id !== 0) {
                     AudioRef.value.play();
                     sockteStore().setweightSockte({
@@ -124,6 +126,11 @@
                     })
                     settime()
 
+                }else{
+                  if(patientInfo.value.name===''){
+                    AudioRef4.value.play();
+                  }
+                  
                 }
             }
         )
@@ -209,7 +216,7 @@
             }, 1000)
         })
         return {
-            ...toRefs(state), isLink, netLink, weightInfo, patientInfo, xyjInfo, inputRef, AudioRef0, AudioRef, AudioRef2, AudioRef3, inputChabge
+            ...toRefs(state), isLink, netLink, weightInfo, patientInfo, xyjInfo, inputRef, AudioRef0, AudioRef, AudioRef4, AudioRef2, AudioRef3, inputChabge
         }
     }
 }
@@ -217,13 +224,15 @@
 <template>
     <div class="page flex-col">
          <!-- 提醒刷卡 -->
-        <audio src="https://dhcdn.leon056.com/hemo/autoselfsign/step1.mp3" ref="AudioRef0" id="eventAudio"></audio>
+        <audio src="https://dhcdn.leon056.com/hemo/autoselfsign/step1.mp3" ref="AudioRef0" id="eventAudio2"></audio>
         <!-- 患者信息读取成功 -->
-        <audio src="https://dhcdn.leon056.com/hemo/autoselfsign/step2.mp3" ref="AudioRef" id="eventAudio"></audio>
+        <audio src="https://dhcdn.leon056.com/hemo/autoselfsign/step2.mp3" ref="AudioRef" id="eventAudio2"></audio>
         <!-- 体重结果回传成功 -->
-        <audio src="https://dhcdn.leon056.com/hemo/autoselfsign/step3.mp3" ref="AudioRef2" id="eventAudio"></audio>
+        <audio src="https://dhcdn.leon056.com/hemo/autoselfsign/step3.mp3" ref="AudioRef2" id="eventAudio3"></audio>
         <!-- 血压结果回传成功 -->
-        <audio src="https://dhcdn.leon056.com/hemo/autoselfsign/step4.mp3" ref="AudioRef3" id="eventAudio"></audio>
+        <audio src="https://dhcdn.leon056.com/hemo/autoselfsign/step4.mp3" ref="AudioRef3" id="eventAudio4"></audio>
+        <!-- 没有找到患者 -->
+        <audio src="https://dhcdn.leon056.com/hemo/autoselfsign/step5.mp3" ref="AudioRef4" id="eventAudio5"></audio>
         <el-dialog title="提示" v-model="netLink" width="30%">
             <span>无法链接到网络!</span>
         </el-dialog>
@@ -287,7 +296,7 @@
               />
             </div>
             <div class="text-wrapper_15 flex-row">
-              <span class="text_8">120/88</span>
+              <span class="text_8">{{ gao_ya }}/{{ di_ya }}</span>
             </div>
           </div>
           <div class="section_5 flex-col">

--
Gitblit v1.8.0