优化体征检测,新增选择用户1/2

This commit is contained in:
2024-02-23 11:13:21 +08:00
parent ba1c0dbd6f
commit bdfc2aabe8
5 changed files with 117 additions and 40 deletions

View File

@ -130,7 +130,7 @@
}
],
DeptList: [],
cardNo:null,
cardNo: null,
ProList: [],
hospitalId: '',
test1: [{
@ -201,7 +201,7 @@
onLoad(e) {
if (e) {
this.userInfo = JSON.parse(e.userinfo)
this.cardNo=this.userInfo.cardNo
this.cardNo = this.userInfo.cardNo
if (this.userInfo.sex == 'MALE') {
this.userInfo.sex = '男'
} else if (this.userInfo.sex == 'FEMALE') {
@ -256,7 +256,7 @@
}
},
getDeptAndPro() {
getDeptList(this.formData.hospitalName,this.cardNo).then(res => {
getDeptList(this.formData.hospitalName, this.cardNo).then(res => {
this.DeptList = []
res.data.map((item) => {
var obj = {
@ -426,6 +426,12 @@
// z-index: 99;
// }
// }
::v-deep .uni-select {
border: 2rpx solid #e5e5e5;
height: 70rpx !important;
line-height: 70rpx !important;
}
::v-deep .inputBox .focusBox .inputStyle.data-v-36ae0e32 {
height: 70rpx !important;
// color: #006DF7;

View File

@ -28,6 +28,9 @@
</view>
<view class="bottomlist">
<view class="timelist">
<uni-data-select class="item" v-model="deviceUserId" :localdata="deviceUserslist" @change="changePro"
:clear="false">
</uni-data-select>
<view class="item" v-for="(item,index) in timelist" :class="timeindex == index?'timeitem':''"
@tap='taptimeindex(index)'>
{{item.name}}
@ -108,25 +111,34 @@
data() {
return {
timelist: [{
name: '全部',
id: 0
},
{
name: '周',
id: 1
}, {
name: '月',
id: 2
}, {
name: '年',
id: 3
},
],
name: '全部',
id: 0
}, {
name: '周',
id: 1
}, {
name: '月',
id: 2
}, {
name: '年',
id: 3
}, ],
timeindex: 0,
socketOpen: false,
timer: null,
datalist: null,
datalisttwo: null,
deviceUserId: '',
deviceUserslist: [{
value: '',
text: '全部',
}, {
value: 1,
text: '用户1',
}, {
value: 2,
text: '用户2',
}],
pie_opts: {
color: ["#1890FF", "#91CB74", "#FAC858", "#EE6666", "#73C0DE", "#3CA272", "#FC8452", "#9A60B4",
"#ea7ccc"
@ -212,6 +224,9 @@
}
},
methods: {
changePro(e) {
this.$emit('tapdeviceUser', e);
},
taptimeindex(index) {
this.timeindex = index
this.$emit('taptimeindex', index);
@ -336,6 +351,10 @@
background-color: #F7F5F5;
}
::v-deep .uni-select {
border: none !important;
}
.app {
width: 96%;
margin: 0 auto;
@ -382,7 +401,7 @@
.item {
width: 25%;
height: 56rpx;
// height: 56rpx;
border-radius: 5rpx 0rpx 0rpx 5rpx;
text-align: center;
line-height: 56rpx;

View File

@ -20,6 +20,9 @@
</view>
<view class="bottomlist">
<view class="timelist">
<uni-data-select class="item" v-model="deviceUserId" :localdata="deviceUserslist" @change="changePro"
:clear="false">
</uni-data-select>
<view class="item" v-for="(item,index) in timelist" :class="timeindex == index?'timeitem':''"
@tap='taptimeindex(index)'>
{{item.name}}
@ -111,6 +114,17 @@
timer: null,
datalist: null,
datalisttwo: null,
deviceUserId: '',
deviceUserslist: [{
value: '',
text: '全部',
}, {
value: 1,
text: '用户1',
}, {
value: 2,
text: '用户2',
}],
pie_opts: {
color: ["#1890FF", "#91CB74", "#FAC858", "#EE6666", "#73C0DE", "#3CA272", "#FC8452", "#9A60B4",
"#ea7ccc"
@ -196,6 +210,9 @@
}
},
methods: {
changePro(e) {
this.$emit('tapdeviceUser', e);
},
taptimeindex(index) {
this.timeindex = index
this.$emit('taptimeindex', index);
@ -314,6 +331,10 @@
background-color: #F7F5F5;
}
::v-deep .uni-select {
border: none !important;
}
.app {
width: 96%;
margin: 0 auto;
@ -360,7 +381,7 @@
.item {
width: 25%;
height: 56rpx;
// height: 56rpx;
border-radius: 5rpx 0rpx 0rpx 5rpx;
text-align: center;
line-height: 56rpx;

View File

@ -8,8 +8,9 @@
v-on:websocket-message="handleWebSocketMessage"></blood-sugar>
</view>
<view v-if="tabindex == 1">
<blood-pressure :current="tabindex" :echartData="list" @taptimeindex='taptimeindex'
:tablelist='tablelist' v-on:websocket-message="handleWebSocketMessage"></blood-pressure>
<blood-pressure :tablelist='tablelist' @tapdeviceUser='tapdeviceUser' :current="tabindex"
:echartData="list" @taptimeindex='taptimeindex'
v-on:websocket-message="handleWebSocketMessage"></blood-pressure>
</view>
<view v-if="tabindex == 2">
<BloodFat :current="tabindex" :echartData="list" @taptimeindex='taptimeindex' :tablelist='tablelist'
@ -25,7 +26,7 @@
</view>
<view v-if="tabindex == 5">
<Heart-rate :current="tabindex" :echartData="list" @taptimeindex='taptimeindex' :tablelist='tablelist'
v-on:websocket-message="handleWebSocketMessage"></Heart-rate>
@tapdeviceUser='tapdeviceUser' v-on:websocket-message="handleWebSocketMessage"></Heart-rate>
</view>
<view v-if="tabindex == 6">
<Temperature :current="tabindex" :echartData="list" @taptimeindex='taptimeindex' :tablelist='tablelist'
@ -77,6 +78,7 @@
}, ],
list: null,
type: 0,
deviceUser: '',
tabletotal: 0,
tablelist: [],
pageNum: 1,
@ -90,6 +92,11 @@
this.getinfo();
},
methods: {
tapdeviceUser(e) {
this.deviceUser = e
this.info()
this.getinfo();
},
taptimeindex(e) {
this.type = e
this.info()
@ -97,10 +104,20 @@
},
info() {
let userinfo = uni.getStorageSync('userinfo');
var obj = {
label: Number(this.tabindex) + 1,
identity: userinfo.cardNo,
type: this.type,
var obj
if (this.tabindex == 1 || this.tabindex == 5) {
obj = {
label: Number(this.tabindex) + 1,
identity: userinfo.cardNo,
type: this.type,
deviceUser: this.deviceUser,
}
} else {
obj = {
label: Number(this.tabindex) + 1,
identity: userinfo.cardNo,
type: this.type,
}
}
record(obj).then(res => {
this.list = res.data
@ -121,12 +138,24 @@
this.tabletotal = 0
this.pageNum = 1
let userinfo = uni.getStorageSync('userinfo');
var obj = {
label: Number(this.tabindex) + 1,
identity: userinfo.cardNo,
type: this.type,
pageNum: this.pageNum,
pageSize: 15,
var obj
if (this.tabindex == 1 || this.tabindex == 5) {
obj = {
label: Number(this.tabindex) + 1,
identity: userinfo.cardNo,
type: this.type,
deviceUser: this.deviceUser,
pageNum: this.pageNum,
pageSize: 15,
}
} else {
obj = {
label: Number(this.tabindex) + 1,
identity: userinfo.cardNo,
type: this.type,
pageNum: this.pageNum,
pageSize: 15,
}
}
getList(obj).then(res => {
this.tablelist = res.data.list.list
@ -145,6 +174,7 @@
},
tabchange(e) {
this.type = 0
this.deviceUser = ''
this.list = null
this.tabindex = e
setTimeout(() => {

View File

@ -357,8 +357,10 @@
}
.uni-select {
height: 56rpx;
font-size: 14px;
border: 1px solid $uni-border-3;
line-height: 56rpx;
// border: 1px solid $uni-border-3;
box-sizing: border-box;
border-radius: 4px;
padding: 0 5px;
@ -370,10 +372,9 @@
/* #endif */
flex-direction: row;
align-items: center;
border-bottom: solid 1px $uni-border-3;
// border-bottom: solid 1px $uni-border-3;
width: 100%;
flex: 1;
height: 35px;
&--disabled {
background-color: #f5f7fa;
@ -384,13 +385,13 @@
.uni-select__label {
font-size: 16px;
// line-height: 22px;
height: 35px;
height: 56rpx;
padding-right: 10px;
color: $uni-secondary-color;
}
.uni-select__input-box {
height: 35px;
height: 56rpx;
position: relative;
/* #ifndef APP-NVUE */
display: flex;
@ -449,7 +450,7 @@
display: flex;
cursor: pointer;
/* #endif */
line-height: 35px;
line-height: 56rpx;
font-size: 14px;
text-align: center;
/* border-bottom: solid 1px $uni-border-3; */