From 5f47d581f4926936a05123117f31f13dee14f05d Mon Sep 17 00:00:00 2001
From: chenyc <501753378@qq.com>
Date: 星期二, 25 三月 2025 15:38:24 +0800
Subject: [PATCH] gx

---
 src/views/deviceWindoes2.vue |   66 ++++++++++++++++++++++++++------
 src/img/xinlv.png            |    0 
 2 files changed, 53 insertions(+), 13 deletions(-)

diff --git a/src/img/xinlv.png b/src/img/xinlv.png
index 1a96ea5..00c4bb0 100644
--- a/src/img/xinlv.png
+++ b/src/img/xinlv.png
Binary files differ
diff --git a/src/views/deviceWindoes2.vue b/src/views/deviceWindoes2.vue
index 173eda8..596029a 100644
--- a/src/views/deviceWindoes2.vue
+++ b/src/views/deviceWindoes2.vue
@@ -169,15 +169,20 @@
                             <div class="container-cord" style="height: 100%;">
                               <img style="width: 25px;" referrerpolicy="no-referrer" :src="xinlv"
                               />
-                              <span class="text-group_3">透前血压、心率</span>
+                              <span class="text-group_3">异常指标</span>
                             </div>
                           </div>
-                          <div style="height: 75%; text-align: center;font-weight: 600;font-size: 50px;color: #333333;" class="grid-container" >
-                            <div>
+                          <div style="height: 75%; text-align: center;font-weight: 600;font-size: 50px;color: #333333; color: #CA7070;" >
+                            <el-row>
+                              <el-col v-for="(row,index) in deviceData.异常检验指标" :span="8" style="font-weight: 700;" :key="index">
+                                {{getItemName(row?.项目名称)}} <b v-if="row?.结果标记==='g'" style="font-weight:bold">⬆</b> <b v-else style="font-weight:bold">⬇</b> 
+                              </el-col> 
+                            </el-row>
+                            <!-- <div>
                               <span v-if="deviceData.透前血压_伸缩压" :style="{ color: tqXygj ? 'red' : '#303133' }">{{ deviceData.透前血压_伸缩压 }}/</span >
                               <span :style="{ color: tqXygj ? 'red' : '#303133' }" style="font-weight: 800; font-size: 200%; white-space: nowrap">{{ deviceData.透前血压_舒张压 }}</span>
                               <span v-if="deviceData.透前脉搏" :style="{ color: tqMbgj ? 'red' : '#303133' }" style="font-weight: 800; font-size: 200%; white-space: nowrap">   {{ deviceData.透前脉搏 }}</span>
-                            </div>
+                            </div> -->
                           </div>
                         </div>
                         <div class="item" style="background-color: #ffffff;">
@@ -350,17 +355,16 @@
                       <div class="container-cord" style="height: 100%;">
                         <img style="width: 25px;" referrerpolicy="no-referrer" :src="xinlv"
                         />
-                        <span class="text-group_3">收缩压/舒张压</span>
+                        <span class="text-group_3">异常指标</span>
                       </div>
                     
                     </div>
-                    <div style="height: 75%; text-align: center;font-weight: 600;font-size: 50px;color: #333333;" class="grid-container" >
-                      <div>
-                        <span v-if="deviceData.透前血压_伸缩压" :style="{ color: tqXygj ? 'red' : '#303133' }">{{ deviceData.透前血压_伸缩压 }}/</span >
-                        <span :style="{ color: tqXygj ? 'red' : '#303133' }" style="font-weight: 800; white-space: nowrap">{{ deviceData.透前血压_舒张压 }}</span>
-                         <!-- <span @click="initTupiao" v-if="deviceData.iot_静脉压" style="color: #409eff">{{ deviceData.iot_静脉压 }}</span> /
-                        <span v-if="deviceData.iot_跨膜压" :style="{ color: deviceData.iot_跨膜压 > 200 ? 'red' : '', }" >{{ deviceData.iot_跨膜压 }}</span> -->
-                      </div>
+                    <div style="height: 75%; text-align: center;font-weight: 600;font-size: 50px;color: #333333;color: #CA7070;"  >
+                      <el-row>
+                        <el-col v-for="(row,index) in deviceData.异常检验指标" :span="8" style="font-weight: 700;" :key="index">
+                          {{getItemName(row?.项目名称)}} <b v-if="row?.结果标记==='g'" style="font-weight:bold">⬆</b> <b v-else style="font-weight:bold">⬇</b> 
+                        </el-col> 
+                      </el-row>
                     
                     </div>
                   </div>
@@ -537,6 +541,7 @@
     实时脱水量: 1.65,
     干体重: 69.5,
     年龄: 59,
+    异常检验指标:[],
     性别: "男",
     患者头像:
       "http://dhimg.leon056.com/hemodialysis/face/PAT9090070832211PyVq/face-IMG_20240413_112705.jpg-202404131127536157.jpg",
@@ -890,13 +895,15 @@
   //创建链接对象
   const creatSource = () => {
     // http://testbs.ihemodialysis.com/sse/sseEvent
+    const test='http://testbs.ihemodialysis.com/sse/sseEvent/'
+    // const test='https://backend.ihemodialysis.com/sse/sseEvent/'
           const stateArr = [
           { key: 0, value: "正在链接中" },
           { key: 1, value: "已经链接并且可以通讯" },
           { key: 2, value: "连接已关闭或者没有链接成功" },
           ];
           try {
-          source.value=  new EventSourcePolyfill(`https://backend.ihemodialysis.com/sse/sseEvent/${deviceCode.value}`,{
+          source.value=  new EventSourcePolyfill(`${test}${deviceCode.value}`,{
               heartbeatTimeout:60000
           });
           source.value.onopen = (e) => {
@@ -1414,6 +1421,39 @@
       console.log(deviceData.value);
     }
   };
+  const getItemName=(name:string)=>{
+    if(name){
+      if(name==='血红蛋白测定'){
+        return 'Hgb '
+      }
+      else if(name==='铁蛋白'){
+        return 'Fer '
+      }
+      else if(name==='白蛋白'){
+        return 'Alb '
+      }
+      else if(name==='血清铁蛋白'){
+        return 'SF '
+      }
+      else if(name==='钙'){
+        return 'Ga '
+      }
+      else if(name==='钾'){
+        return 'K '
+      }
+      else if(name==='无机磷'){
+        return 'pi '
+      }
+      else if(name==='甲状旁腺激素'){
+        return 'PTH '
+      }else{
+        return name
+      }
+ 
+    }else{
+      return ''
+    }
+  }
   </script>
 <style lang="less" scoped>
   .divice{

--
Gitblit v1.8.0