From a6b4fd6c0219bb41415cd232daa12ca28eb8add7 Mon Sep 17 00:00:00 2001
From: chenyc <501753378@qq.com>
Date: 星期二, 20 九月 2022 13:19:39 +0800
Subject: [PATCH] up123

---
 src/views/home/index.vue |   47 ++++++++++++++++++++++++++++++++++-------------
 1 files changed, 34 insertions(+), 13 deletions(-)

diff --git a/src/views/home/index.vue b/src/views/home/index.vue
index 8a5f84a..a9ff12f 100644
--- a/src/views/home/index.vue
+++ b/src/views/home/index.vue
@@ -11,6 +11,12 @@
 import state2 from '@/assets/state2.png'
 import state3 from '@/assets/state3.png'
 import logo from '@/assets/LOGO.png'
+import step6 from '@/assets/mp3/step6.mp3'
+import step5 from '@/assets/mp3/step5.mp3'
+import step4 from '@/assets/mp3/step4.mp3'
+import step3 from '@/assets/mp3/step3.mp3'
+import step2 from '@/assets/mp3/step2.mp3'
+import step1 from '@/assets/mp3/step1.mp3'
 
 export default {
     setup() {
@@ -23,6 +29,7 @@
         const AudioRef2 = ref()
         const AudioRef3 = ref()
         const AudioRef4=ref()
+        const AudioRef5=ref()
         const isLink = computed(() => {
             return !sockte.isLink
         })
@@ -96,6 +103,12 @@
         const state = reactive({
             caozuo:0,// 点击10下才能关闭
             logo:logo,
+            step5:step5,
+            step4:step4,
+            step3:step3,
+            step2:step2,
+            step1:step1,
+            step6:step6,
             state1:state1,
             state2:state2,
             state3:state3,
@@ -114,6 +127,11 @@
         watch(
             () => patientInfo.value.datetime,
             () => {
+              console.log('患者信息变化',patientInfo.value)
+                if(patientInfo.value.isScheduled===0){
+                      AudioRef5.value.play();
+                      return
+                }
                 if (patientInfo.value.id !== 0) {
                     AudioRef.value.play();
                     sockteStore().setweightSockte({
@@ -132,7 +150,7 @@
                     })
                     settime()
 
-                }else{
+                }else{ 
                   if(patientInfo.value.name===''){
                     AudioRef4.value.play();
                   }
@@ -141,13 +159,14 @@
             }
         )
         watch(
-            () => weightInfo.value.resultTime,
+            () => weightInfo.value.result,
             () => {
                 settime()
-                console.log("体重变化了")
+                console.log("体重变化了",weightInfo.value)
                 // AudioRef2.value.play()
                 if (patientInfo.value.id === 0) {
                     AudioRef0.value.play()
+                    inputRef.value.focus();
                 }
                 else {
                     AudioRef2.value.play()
@@ -179,6 +198,7 @@
                     }
                     if (patientInfo.value.id === 0) {
                         AudioRef0.value.play()
+                        inputRef.value.focus();
                         settime()
                     } else {
                         AudioRef3.value.play()
@@ -242,7 +262,7 @@
             }, 1000)
         })
         return {
-            ...toRefs(state), guyanbi,isLink, netLink, weightInfo, patientInfo, xyjInfo, inputRef, AudioRef0, AudioRef, AudioRef4, AudioRef2, AudioRef3, inputChabge
+            ...toRefs(state), guyanbi,isLink, netLink, weightInfo, patientInfo, xyjInfo, inputRef, AudioRef0, AudioRef, AudioRef4,AudioRef5, AudioRef2, AudioRef3, inputChabge
         }
     }
 }
@@ -259,12 +279,14 @@
         <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%">
+         <!-- 没有找到排班 -->
+         <audio :src="step6" ref="AudioRef5" id="eventAudio6"></audio>
+        <!-- <el-dialog title="提示" v-model="netLink" width="30%">
             <span>无法链接到网络!</span>
-        </el-dialog>
-        <el-dialog title="提示" v-model="isLink" width="30%">
+        </el-dialog> -->
+        <!-- <el-dialog title="提示" v-model="isLink" width="30%">
             <span>sockte连接失败正在重连。。。。。。</span>
-        </el-dialog>
+        </el-dialog> -->
         <el-row class="header">
           <el-col :span="8">
               <img 
@@ -498,6 +520,7 @@
 }
 .rowdiv{
   /* background: #769AFF; */
+  font-size: 300%;
   height: 15%;
   margin-top: 5%;
 }
@@ -507,7 +530,7 @@
 }
 .tilaft{
   text-align: left;
-  font-size: 2.5rem;
+  font-size: 300%;
   font-family: AlibabaPuHuiTi-Regular, AlibabaPuHuiTi;
   font-weight: 400;
   color: #333333;
@@ -528,7 +551,7 @@
   vertical-align:middle;
   width: 100%;
   text-align: center;
-  font-size: 120px;
+  font-size: 800%;
   font-family: DINAlternate-Bold, DINAlternate;
   font-weight: bold;
   color: #769AFF;
@@ -543,11 +566,10 @@
 .userinfo{
   padding-top: 6%;
   /* background: #769AFF; */
-  font-size: 2.5rem;
+  font-size: 300%;
   text-align: right;
 }
 .lableclass{
-  font-size: 2.5rem;
   text-align: right;
   font-weight: 400;
   color: #777777;
@@ -555,7 +577,6 @@
 
 }
 .textclass{
-  font-size: 2.5rem;
   text-align: left;
   font-family: AlibabaPuHuiTi-Medium, AlibabaPuHuiTi;
   font-weight: 500;

--
Gitblit v1.8.0