From 53195cc5c26a71b8db47eb2dd42b12e737c1d9c5 Mon Sep 17 00:00:00 2001
From: wx <645899409@qq.com>
Date: Tue, 16 Dec 2025 18:46:11 +0800
Subject: [PATCH] =?UTF-8?q?update=201.=E6=A0=B9=E6=8D=AE=E6=96=B0=E7=96=86?=
=?UTF-8?q?=E5=8F=8D=E9=A6=88=EF=BC=8C=E4=BF=AE=E6=94=B9=E7=9B=B8=E5=85=B3?=
=?UTF-8?q?=E9=97=AE=E9=A2=98?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.env.development | 2 +-
src/views/indexSun.vue | 24 +-
src/views/indexSun/emerModal.vue | 300 ++++++++++++++++++
src/views/indexSun/heartModal.vue | 245 ++++++++++++++
src/views/indexSun/indexSun.api.ts | 2 +
src/views/indexSun/indexSun.ts | 54 ++++
src/views/indexSun/threeLeftNew.vue | 104 +++++-
.../indexSun/threeLeftNewItem/item-d.vue | 10 +
.../indexSun/threeLeftNewItem/stepItem.vue | 8 +
.../threeLeftNewItem/threeLeftNewItem.vue | 30 +-
src/views/indexSun/twoL.vue | 98 ++++--
11 files changed, 830 insertions(+), 47 deletions(-)
create mode 100644 src/views/indexSun/emerModal.vue
create mode 100644 src/views/indexSun/heartModal.vue
diff --git a/.env.development b/.env.development
index 3d2e7c3..b8dcfd2 100644
--- a/.env.development
+++ b/.env.development
@@ -1,7 +1,7 @@
# 王昊地址
#VITE_GLOB_API_URL=http://192.168.1.98
#开发环境
-VITE_GLOB_API_URL=https://api-jkglpt.iosp.ydpt.tech
+VITE_GLOB_API_URL=http://api-xj.tri.dt.io
#VITE_GLOB_API_URL=https://api.cqygjk.com
#健康监测工具报警-websocket
#VITE_GLOB_API_YIN_JI=ws://cqyt.dev.yg.dt.io/health-watch/websocket/watchMonitor
diff --git a/src/views/indexSun.vue b/src/views/indexSun.vue
index 6470a8f..2cf7ed1 100644
--- a/src/views/indexSun.vue
+++ b/src/views/indexSun.vue
@@ -20,7 +20,7 @@
![]()
{{ tabList[chooseType].label }}
-
参考范围: {{ tabList[chooseType].tips }}
+
{{ tabList[chooseType].tips }}
+
参考范围: {{ tabList[chooseType].tips }}
@@ -66,6 +67,7 @@
import item4Png from '/@/assets/images/threeLeftNew/item4.png';
import item5Png from '/@/assets/images/threeLeftNew/item5.png';
import item6Png from '/@/assets/images/threeLeftNew/item6.png';
+ import dayjs from 'dayjs';
const { getCenterInfo } = useUserStore();
const props = defineProps({
@@ -79,12 +81,13 @@
{
label: '心率',
value: 0,
- tips: '正常60~100次/分',
+ // tips: localStorage.getItem('monitorDataOne') ? JSON.parse(localStorage.getItem('monitorDataOne') || '{}')[0].tips : '',
+ tips: localStorage.getItem('monitorDataOne') ? JSON.parse(localStorage.getItem('monitorDataOne') || '{}')[0].tips : '',
},
{
label: '血氧',
value: 1,
- tips: '血氧饱和度95%~100%',
+ tips: '血氧饱和度90%~100%',
},
{
label: '压力',
@@ -145,6 +148,93 @@
// getData();
// });
+ const emit = defineEmits(['handleView']);
+
+ function clickPie(params: any) {
+ let p: any = {
+ endTime: dayjs().format('YYYY-MM-DD'),
+ };
+ switch (selectValue1.value) {
+ case 'week':
+ p['startTime'] = dayjs().subtract(1, 'week').format('YYYY-MM-DD');
+ break;
+ case 'month':
+ p['startTime'] = dayjs().subtract(1, 'month').format('YYYY-MM-DD');
+ break;
+ case 'year':
+ p['startTime'] = dayjs().subtract(1, 'year').format('YYYY-MM-DD');
+ break;
+ }
+ switch (chooseType.value) {
+ case 0:
+ p['type'] = 1;
+ p['search'] = heart(params);
+ p['title'] = `心率${params.name}`;
+ break;
+ case 1:
+ p['type'] = 2;
+ p['search'] = oxygen(params);
+ p['title'] = `血氧${params.name}`;
+ break;
+ case 2:
+ p['type'] = 3;
+ p['search'] = pressure(params);
+ p['title'] = `压力${params.name}`;
+ break;
+ case 3:
+ p['type'] = 5;
+ p['search'] = temperature(params);
+ p['title'] = `体温${params.name}`;
+ break;
+ case 5:
+ p['type'] = 7;
+ p['search'] = step(params);
+ p['title'] = `步数${params.name}`;
+ break;
+ }
+
+ if (p['search'] !== -1) {
+ emit('handleView', p);
+ }
+ }
+
+ function heart(params: any) {
+ if (params.dataIndex === 1) {
+ return 0;
+ }
+ return -1;
+ }
+ function oxygen(params: any) {
+ if (params.dataIndex === 1) {
+ return 0;
+ }
+ return -1;
+ }
+ function pressure(params: any) {
+ if (params.dataIndex === 3) {
+ return 0;
+ }
+ if (params.dataIndex === 2) {
+ return 1;
+ }
+ return -1;
+ }
+ function temperature(params: any) {
+ if (params.dataIndex === 2) {
+ return 0;
+ }
+ if (params.dataIndex === 1) {
+ return 1;
+ }
+ return -1;
+ }
+ function step(params: any) {
+ if (params.dataIndex === 0) {
+ return 0;
+ }
+ return -1;
+ }
+
function setTimer() {
if (timer.value) {
clearInterval(timer.value);
@@ -225,10 +315,6 @@
// });
// });
// }
- const emit = defineEmits(['handleView']);
- function handleView() {
- emit('handleView');
- }