修改
This commit is contained in:
parent
c5b51eddea
commit
52cd660c26
13
api/pagesC/healthtest/index.js
Normal file
13
api/pagesC/healthtest/index.js
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
import request from "../../request.js"
|
||||||
|
|
||||||
|
// 列表查询
|
||||||
|
export function surveylist(data) {
|
||||||
|
return request({
|
||||||
|
url: '/evaluate/survey/list',
|
||||||
|
method: 'get',
|
||||||
|
data,
|
||||||
|
header: {
|
||||||
|
region: uni.getStorageSync('region'),
|
||||||
|
},
|
||||||
|
})
|
||||||
|
}
|
||||||
44
pages.json
44
pages.json
@ -77,18 +77,14 @@
|
|||||||
"path": "orderlist/orderlist",
|
"path": "orderlist/orderlist",
|
||||||
"style": {
|
"style": {
|
||||||
"navigationBarTitleText": "预约详情",
|
"navigationBarTitleText": "预约详情",
|
||||||
"enablePullDownRefresh": false,
|
"enablePullDownRefresh": false
|
||||||
// "navigationStyle": "default",
|
|
||||||
"navigationBarBackgroundColor": "#4ac4ab"
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"path": "screenorder/screenorder",
|
"path": "screenorder/screenorder",
|
||||||
"style": {
|
"style": {
|
||||||
"navigationBarTitleText": "筛查预约",
|
"navigationBarTitleText": "筛查预约",
|
||||||
"enablePullDownRefresh": false,
|
"enablePullDownRefresh": false
|
||||||
"navigationStyle": "default",
|
|
||||||
"navigationBarBackgroundColor": "#4ac4ab"
|
|
||||||
}
|
}
|
||||||
}, {
|
}, {
|
||||||
"path": "managefamily/managefamily",
|
"path": "managefamily/managefamily",
|
||||||
@ -508,7 +504,8 @@
|
|||||||
"path": "healthtest/healthtest",
|
"path": "healthtest/healthtest",
|
||||||
"style": {
|
"style": {
|
||||||
"navigationBarTitleText": "健康自评",
|
"navigationBarTitleText": "健康自评",
|
||||||
"enablePullDownRefresh": false
|
"onReachBottomDistance": 40, //距离底部多远时触发 单位为px
|
||||||
|
"enablePullDownRefresh": true //设置参数为true
|
||||||
}
|
}
|
||||||
}, {
|
}, {
|
||||||
"path": "Physicalexamination/Physicalexamination",
|
"path": "Physicalexamination/Physicalexamination",
|
||||||
@ -613,6 +610,39 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
}, {
|
||||||
|
"root": "questionnaire",
|
||||||
|
"pages": [{
|
||||||
|
"path": "hypertension/hypertension",
|
||||||
|
"style": {
|
||||||
|
"navigationBarTitleText": "高血压评估问卷",
|
||||||
|
"enablePullDownRefresh": false
|
||||||
|
}
|
||||||
|
}, {
|
||||||
|
"path": "diabetes/diabetes",
|
||||||
|
"style": {
|
||||||
|
"navigationBarTitleText": "糖尿病评估问卷",
|
||||||
|
"enablePullDownRefresh": false
|
||||||
|
}
|
||||||
|
} ,{
|
||||||
|
"path" : "copd/copd",
|
||||||
|
"style" :
|
||||||
|
{
|
||||||
|
"navigationBarTitleText": "慢阻肺评估问卷",
|
||||||
|
"enablePullDownRefresh": false
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
,{
|
||||||
|
"path" : "cerebralapoplexy/cerebralapoplexy",
|
||||||
|
"style" :
|
||||||
|
{
|
||||||
|
"navigationBarTitleText": "脑卒中评估问卷",
|
||||||
|
"enablePullDownRefresh": false
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
]
|
||||||
}],
|
}],
|
||||||
"globalStyle": {
|
"globalStyle": {
|
||||||
"navigationBarTextStyle": "white",
|
"navigationBarTextStyle": "white",
|
||||||
|
|||||||
@ -12,7 +12,7 @@
|
|||||||
请选择城市
|
请选择城市
|
||||||
</text>
|
</text>
|
||||||
</view>
|
</view>
|
||||||
<!-- <view class="address" @tap="city">
|
<!-- <view class="address" @tap="city">
|
||||||
<image src="../../static/pages/address.png" mode=""></image>
|
<image src="../../static/pages/address.png" mode=""></image>
|
||||||
<text v-if="address">
|
<text v-if="address">
|
||||||
{{address}}
|
{{address}}
|
||||||
@ -109,7 +109,7 @@
|
|||||||
uni.setStorageSync("region", 1)
|
uni.setStorageSync("region", 1)
|
||||||
}
|
}
|
||||||
this.userinfo = uni.getStorageSync('userinfo');
|
this.userinfo = uni.getStorageSync('userinfo');
|
||||||
if (this.userinfo) {
|
if (this.userinfo) {
|
||||||
this.patientName = this.userinfo.patientName
|
this.patientName = this.userinfo.patientName
|
||||||
checkSignApply(this.userinfo.cardNo).then(res => {
|
checkSignApply(this.userinfo.cardNo).then(res => {
|
||||||
if (res.data.code != 0) {
|
if (res.data.code != 0) {
|
||||||
|
|||||||
@ -17,11 +17,13 @@
|
|||||||
<span class="name" v-else>
|
<span class="name" v-else>
|
||||||
请先登录!
|
请先登录!
|
||||||
</span>
|
</span>
|
||||||
<view class="signing" v-if="appPersonallist.signNo">
|
<view class="" v-if="appPersonallist.patientName">
|
||||||
已签约
|
<view class="signing" v-if="appPersonallist.signNo">
|
||||||
</view>
|
已签约
|
||||||
<view class="signing" v-else>
|
</view>
|
||||||
未签约
|
<view class="signing" v-else>
|
||||||
|
未签约
|
||||||
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="phone" v-if="appPersonallist.phone">
|
<view class="phone" v-if="appPersonallist.phone">
|
||||||
@ -208,13 +210,13 @@
|
|||||||
showhome: false, //切换
|
showhome: false, //切换
|
||||||
familyList: {}, //切换列表
|
familyList: {}, //切换列表
|
||||||
userinfo: {}, //用户信息
|
userinfo: {}, //用户信息
|
||||||
valueopenid:'',
|
valueopenid: '',
|
||||||
|
|
||||||
|
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
onShow() {
|
onShow() {
|
||||||
|
|
||||||
|
|
||||||
// this.bjimg = baseurl + '/profile/appletPicture/inviteFriendsOne.png'
|
// this.bjimg = baseurl + '/profile/appletPicture/inviteFriendsOne.png'
|
||||||
let that = this
|
let that = this
|
||||||
@ -229,7 +231,7 @@
|
|||||||
that.appPersonallist = null
|
that.appPersonallist = null
|
||||||
}
|
}
|
||||||
this.getpersnoal()
|
this.getpersnoal()
|
||||||
|
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
// 退出登录
|
// 退出登录
|
||||||
@ -265,38 +267,37 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
// 获取成员
|
// 获取成员
|
||||||
getpersnoal(){
|
getpersnoal() {
|
||||||
getCurrentUser(this.valueopenid).then(res => {
|
getCurrentUser(this.valueopenid).then(res => {
|
||||||
console.log(res)
|
console.log(res)
|
||||||
this.familyList = res.data
|
this.familyList = res.data
|
||||||
|
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
// 切换成员
|
// 切换成员
|
||||||
changeFamilyInfo(e) {
|
changeFamilyInfo(e) {
|
||||||
console.log(e,'000')
|
console.log(e, '000')
|
||||||
switchResident(this.valueopenid,e.patientCode).then(res => {
|
switchResident(this.valueopenid, e.patientCode).then(res => {
|
||||||
if (res.code == 200) {
|
if (res.code == 200) {
|
||||||
this.$refs.uToast.show({
|
this.$refs.uToast.show({
|
||||||
title: '切换成功',
|
title: '切换成功',
|
||||||
type: 'success',
|
type: 'success',
|
||||||
duration: '1000',
|
duration: '1000',
|
||||||
})
|
})
|
||||||
uni.setStorageSync('userinfo', res.data);
|
uni.setStorageSync('userinfo', res.data);
|
||||||
uni.setStorageSync('patientId', res.data.id);
|
uni.setStorageSync('patientId', res.data.id);
|
||||||
this.myInfo()
|
this.myInfo()
|
||||||
|
|
||||||
}
|
} else {
|
||||||
else{
|
this.$refs.uToast.show({
|
||||||
this.$refs.uToast.show({
|
title: res.msg,
|
||||||
title: res.msg,
|
type: 'error',
|
||||||
type: 'error',
|
duration: '1000',
|
||||||
duration: '1000',
|
})
|
||||||
})
|
|
||||||
|
}
|
||||||
}
|
})
|
||||||
})
|
this.showhome = false
|
||||||
this.showhome = false
|
|
||||||
},
|
},
|
||||||
removes() {
|
removes() {
|
||||||
this.appPersonallist = null
|
this.appPersonallist = null
|
||||||
|
|||||||
@ -48,7 +48,7 @@
|
|||||||
})
|
})
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
uni.reLaunch({
|
uni.reLaunch({
|
||||||
url: '/pages/medicalservice/medicalservice'
|
url: '/pages/homepage/homepage'
|
||||||
});
|
});
|
||||||
}, 2000);
|
}, 2000);
|
||||||
},
|
},
|
||||||
|
|||||||
@ -187,6 +187,7 @@
|
|||||||
appointmentDate: null,
|
appointmentDate: null,
|
||||||
appointmentStartTime: null,
|
appointmentStartTime: null,
|
||||||
appointmentEndTime: null,
|
appointmentEndTime: null,
|
||||||
|
orderChannel: "WECHAT_APPLET",
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
@ -255,11 +256,57 @@
|
|||||||
info() {
|
info() {
|
||||||
consultationInfo(this.formdata).then(res => {
|
consultationInfo(this.formdata).then(res => {
|
||||||
if (res.code == 200) {
|
if (res.code == 200) {
|
||||||
this.$refs.uToast.show({
|
res.data.payType = "WECHAT_PAY"
|
||||||
title: '新建专家问诊成功',
|
res.data.paymentPrice = res.data.totalPrice
|
||||||
type: 'success',
|
res.data.openid = this.openid
|
||||||
duration: '1500',
|
let id = res.data.id
|
||||||
back: 1
|
appletGoodsOrderPay(res.data).then(response => {
|
||||||
|
if (response.code == 200) {
|
||||||
|
uni.requestPayment({
|
||||||
|
timeStamp: response.data.timeStamp,
|
||||||
|
nonceStr: response.data.nonceStr,
|
||||||
|
package: response.data.prepayId,
|
||||||
|
signType: response.data.signType,
|
||||||
|
paySign: response.data.paySign,
|
||||||
|
success: function(res) {
|
||||||
|
that.$refs.uToast.show({
|
||||||
|
title: '支付成功',
|
||||||
|
type: 'success',
|
||||||
|
duration: 1500,
|
||||||
|
})
|
||||||
|
if (that.timer) {
|
||||||
|
clearTimeout(that.timer)
|
||||||
|
}
|
||||||
|
that.timer = setTimeout(e => {
|
||||||
|
// uni.redirectTo({
|
||||||
|
// url: `/pages/CommodityOrder/CommodityOrder`
|
||||||
|
// // url: `/pages/orderDetails/orderDetails?goodsOrderId=${id}`
|
||||||
|
// })
|
||||||
|
}, 1500)
|
||||||
|
},
|
||||||
|
fail: function(err) {
|
||||||
|
that.$refs.uToast.show({
|
||||||
|
title: '取消支付',
|
||||||
|
type: 'error',
|
||||||
|
duration: 1500,
|
||||||
|
})
|
||||||
|
if (that.timer) {
|
||||||
|
clearTimeout(that.timer)
|
||||||
|
}
|
||||||
|
that.timer = setTimeout(e => {
|
||||||
|
// uni.redirectTo({
|
||||||
|
// url: `/pages/orderDetails/orderDetails?goodsOrderId=${id}`
|
||||||
|
// })
|
||||||
|
}, 1500)
|
||||||
|
}
|
||||||
|
});
|
||||||
|
} else {
|
||||||
|
that.$refs.uToast.show({
|
||||||
|
title: response.msg,
|
||||||
|
type: 'error',
|
||||||
|
duration: 2000
|
||||||
|
})
|
||||||
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|||||||
@ -158,10 +158,10 @@
|
|||||||
|
|
||||||
.hospitalimage {
|
.hospitalimage {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
width: 120rpx;
|
width: 150rpx;
|
||||||
height: 150rpx;
|
height: 150rpx;
|
||||||
top: 30rpx;
|
top: 30rpx;
|
||||||
left: 30rpx;
|
left: 10rpx;
|
||||||
}
|
}
|
||||||
|
|
||||||
.hospitalteacher {
|
.hospitalteacher {
|
||||||
|
|||||||
@ -1,51 +1,30 @@
|
|||||||
.app {
|
.app {
|
||||||
height: 100vh;
|
padding: 15rpx 0 50rpx 0;
|
||||||
background-color: #F7F5F5;
|
|
||||||
padding: 15rpx 0 0 0;
|
|
||||||
overflow: scroll;
|
|
||||||
.tophealth {
|
.tophealth {
|
||||||
font-family: Source Han Sans CN;
|
|
||||||
position: relative;
|
|
||||||
left: 5%;
|
|
||||||
width: 92%;
|
width: 92%;
|
||||||
// background: red;
|
|
||||||
height: 60rpx;
|
height: 60rpx;
|
||||||
margin-bottom: 10rpx;
|
margin: 0 auto;
|
||||||
|
|
||||||
image {
|
image {
|
||||||
position: absolute;
|
margin: 0 10rpx 0 0;
|
||||||
width: 32rpx;
|
width: 32rpx;
|
||||||
height: 36rpx;
|
height: 36rpx;
|
||||||
top: 15%;
|
vertical-align: middle;
|
||||||
// transform: translateY(-50%);
|
|
||||||
// vertical-align: middle;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.health {
|
.health {
|
||||||
font-size: 28rpx;
|
font-size: 28rpx;
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
color: #000000;
|
color: #000000;
|
||||||
line-height: 38rpx;
|
|
||||||
height: 38rpx;
|
|
||||||
position: absolute;
|
|
||||||
top: 50%;
|
|
||||||
transform: translateY(-50%);
|
|
||||||
left: 7%;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.history {
|
.history {
|
||||||
font-size: 26rpx;
|
font-size: 26rpx;
|
||||||
font-weight: 400;
|
font-weight: 400;
|
||||||
color: #26A888;
|
color: #26A888;
|
||||||
line-height: 38rpx;
|
float: right;
|
||||||
height: 38rpx;
|
|
||||||
position: absolute;
|
|
||||||
top: 50%;
|
|
||||||
transform: translateY(-50%);
|
|
||||||
right: 0%;
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.bodyhealth {
|
.bodyhealth {
|
||||||
@ -56,7 +35,6 @@
|
|||||||
border-radius: 5rpx;
|
border-radius: 5rpx;
|
||||||
position: relative;
|
position: relative;
|
||||||
left: 50%;
|
left: 50%;
|
||||||
font-family: Source Han Sans CN;
|
|
||||||
transform: translateX(-50%);
|
transform: translateX(-50%);
|
||||||
margin-bottom: 20rpx;
|
margin-bottom: 20rpx;
|
||||||
|
|
||||||
@ -88,7 +66,5 @@
|
|||||||
left: 30%;
|
left: 30%;
|
||||||
top: 50%;
|
top: 50%;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -5,37 +5,82 @@
|
|||||||
<span class="health">智慧健康驿站自评表</span>
|
<span class="health">智慧健康驿站自评表</span>
|
||||||
<span class="history">历史记录</span>
|
<span class="history">历史记录</span>
|
||||||
</view>
|
</view>
|
||||||
<view class="bodyhealth">
|
<view class="bodyhealth" v-for="item in list" @tap='gosurveySubject(item)'>
|
||||||
<image src="../../static/pages/view_face_background.png" mode=""></image>
|
<image src="../../static/pageC/books.png" mode=""></image>
|
||||||
<view class="risk">高血压风险评估</view>
|
<view class="risk">
|
||||||
|
{{item.surveySubject==1001?'高血压评估问卷':item.surveySubject==1002?'糖尿病评估问卷':item.surveySubject==1003?
|
||||||
|
'脑卒中评估问卷':item.surveySubject==1004?'慢阻肺评估问卷':item.surveySubject==1005?'慢病评估问卷':item.surveySubject==1006?'糖尿病肾病评估问卷':item.surveySubject==1007?
|
||||||
|
'糖尿病眼病评估问卷':item.surveySubject==1008?'糖尿病足病评估问卷':''}}
|
||||||
|
</view>
|
||||||
<view class="estimate">风险评估</view>
|
<view class="estimate">风险评估</view>
|
||||||
|
|
||||||
</view>
|
|
||||||
<view class="bodyhealth">
|
|
||||||
<image src="../../static/pages/view_face_background.png" mode=""></image>
|
|
||||||
<view class="risk">高血压风险评估</view>
|
|
||||||
<view class="estimate">风险评估</view>
|
|
||||||
|
|
||||||
</view>
|
|
||||||
<view class="bodyhealth">
|
|
||||||
<image src="../../static/pages/view_face_background.png" mode=""></image>
|
|
||||||
<view class="risk">高血压风险评估</view>
|
|
||||||
<view class="estimate">风险评估</view>
|
|
||||||
|
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
|
import {
|
||||||
|
surveylist
|
||||||
|
} from '@/api/pagesC/healthtest/index.js'
|
||||||
export default {
|
export default {
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
list: [],
|
||||||
|
total: 0,
|
||||||
|
query: {
|
||||||
|
pageNum: 1,
|
||||||
|
pageSize: 10,
|
||||||
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
onLoad() {
|
||||||
|
this.info();
|
||||||
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
gosurveySubject(item) {
|
||||||
}
|
if (item.surveySubject == 1001) {
|
||||||
|
uni.navigateTo({
|
||||||
|
url: `/questionnaire/hypertension/hypertension?item=${encodeURIComponent(JSON.stringify(item))}`
|
||||||
|
})
|
||||||
|
} else if (item.surveySubject == 1002) {
|
||||||
|
uni.navigateTo({
|
||||||
|
url: `/questionnaire/diabetes/diabetes?item=${encodeURIComponent(JSON.stringify(item))}`
|
||||||
|
})
|
||||||
|
} else if (item.surveySubject == 1003) {
|
||||||
|
uni.navigateTo({
|
||||||
|
url: `/questionnaire/cerebralapoplexy/cerebralapoplexy?item=${encodeURIComponent(JSON.stringify(item))}`
|
||||||
|
})
|
||||||
|
} else if (item.surveySubject == 1004) {
|
||||||
|
uni.navigateTo({
|
||||||
|
url: `/questionnaire/copd/copd?item=${encodeURIComponent(JSON.stringify(item))}`
|
||||||
|
})
|
||||||
|
}
|
||||||
|
},
|
||||||
|
info() {
|
||||||
|
surveylist(this.query).then(res => {
|
||||||
|
this.list = res.rows
|
||||||
|
this.total = res.total
|
||||||
|
})
|
||||||
|
},
|
||||||
|
},
|
||||||
|
onReachBottom() { //下滑加载
|
||||||
|
if (this.list.length >= this.total) {} else {
|
||||||
|
this.query.pageNum++
|
||||||
|
surveylist(this.query).then(res => {
|
||||||
|
if (res.rows) {
|
||||||
|
res.rows.forEach(e => {
|
||||||
|
this.list.push(e)
|
||||||
|
})
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
},
|
||||||
|
onPullDownRefresh() { //下拉刷新
|
||||||
|
this.query.pageNum = 1;
|
||||||
|
this.info();
|
||||||
|
setTimeout(function() {
|
||||||
|
uni.stopPullDownRefresh();
|
||||||
|
}, 1000);
|
||||||
|
},
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|||||||
@ -468,6 +468,14 @@
|
|||||||
content: JSON.parse(res.data).message,
|
content: JSON.parse(res.data).message,
|
||||||
messageType: JSON.parse(res.data).message
|
messageType: JSON.parse(res.data).message
|
||||||
})
|
})
|
||||||
|
setTimeout(() => {
|
||||||
|
let query = uni.createSelectorQuery().in(this);
|
||||||
|
//需要给黄色区域设置一个id标识,在这里是demo
|
||||||
|
query.select('.input-box').boundingClientRect(data => {
|
||||||
|
this.inputboxtop = data.height //赋值,待会要用
|
||||||
|
this.scrollTop = this.scrollTop + 1;
|
||||||
|
}).exec();
|
||||||
|
}, 100)
|
||||||
that.Read()
|
that.Read()
|
||||||
})
|
})
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
@ -756,4 +764,4 @@
|
|||||||
bottom: 38rpx;
|
bottom: 38rpx;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
129
questionnaire/cerebralapoplexy/cerebralapoplexy.vue
Normal file
129
questionnaire/cerebralapoplexy/cerebralapoplexy.vue
Normal file
@ -0,0 +1,129 @@
|
|||||||
|
<template>
|
||||||
|
<view class="app" v-if='list'>
|
||||||
|
<view class="item" v-for="(item,index) in list.questions" :key="index">
|
||||||
|
<view class="title">
|
||||||
|
{{Number(index)+1}}、{{item.questionName}}
|
||||||
|
</view>
|
||||||
|
<u-radio-group v-model="list.answers[index].optionContent" @change="radioGroupChange($event,item)">
|
||||||
|
<u-radio @change="radioChange($event,aitem,index)" v-for="(aitem, aindex) in item.options" :key="aindex"
|
||||||
|
:name="aitem.optionName">
|
||||||
|
{{aitem.optionName}}
|
||||||
|
</u-radio>
|
||||||
|
</u-radio-group>
|
||||||
|
</view>
|
||||||
|
<view class="btns" @tap='updata'>
|
||||||
|
提交
|
||||||
|
</view>
|
||||||
|
<u-toast ref="uToast" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
export default {
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
list: null,
|
||||||
|
};
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
updata() {
|
||||||
|
this.list.answers.forEach(e => {
|
||||||
|
if (!e.optionId) {
|
||||||
|
this.$refs.uToast.show({
|
||||||
|
title: '请选择完全部选项',
|
||||||
|
type: 'error',
|
||||||
|
})
|
||||||
|
return
|
||||||
|
}
|
||||||
|
})
|
||||||
|
var truelist = this.list.answers.filter(e => e.optionContent == '是')
|
||||||
|
if (truelist.length > 0) {
|
||||||
|
if (truelist.length >= 3) {
|
||||||
|
this.list.evaluateResult = `本次评估结果为${truelist.length}分,3分及以上者,为脑卒中高危人群,请尽早到医疗机构进行专业评估和干预。`
|
||||||
|
} else {
|
||||||
|
this.list.evaluateResult = `本次评估结果为${truelist.length}分,3分以下者,没有脑卒中高危风险,请继续保持!`
|
||||||
|
}
|
||||||
|
} else if (truelist.length == 0) {
|
||||||
|
this.list.evaluateResult = '本次评估结果为0分,3分以下者,没有脑卒中高危风险,请继续保持!'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
// 选中某个单选框时,由radio时触发
|
||||||
|
radioChange(e, item, index) {
|
||||||
|
this.list.answers[index].optionId = item.id
|
||||||
|
},
|
||||||
|
// 选中任一radio时,由radio-group触发
|
||||||
|
radioGroupChange(e) {
|
||||||
|
// console.log(e);
|
||||||
|
}
|
||||||
|
},
|
||||||
|
onLoad(options) {
|
||||||
|
let list = JSON.parse(decodeURIComponent(options.item))
|
||||||
|
list.answers = []
|
||||||
|
list.questions.forEach(e => {
|
||||||
|
e.name = '请选择'
|
||||||
|
var obj = {
|
||||||
|
"questionId": e.id,
|
||||||
|
"optionId": null,
|
||||||
|
"optionContent": null,
|
||||||
|
}
|
||||||
|
list.answers.push(obj)
|
||||||
|
})
|
||||||
|
this.list = {
|
||||||
|
userId: uni.getStorageSync('patientId'),
|
||||||
|
surveyId: list.id,
|
||||||
|
surveySubject: list.surveySubject,
|
||||||
|
evaluateResult: null,
|
||||||
|
advice: null,
|
||||||
|
questions: list.questions,
|
||||||
|
answers: list.answers
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style lang="scss">
|
||||||
|
.app {
|
||||||
|
width: 96%;
|
||||||
|
margin: 16rpx auto;
|
||||||
|
background: #FFFFFF;
|
||||||
|
box-shadow: 0rpx 9rpx 31rpx 9rpx rgba(0, 0, 0, 0.03);
|
||||||
|
border-radius: 5rpx;
|
||||||
|
padding-bottom: 200rpx;
|
||||||
|
|
||||||
|
.btns {
|
||||||
|
width: 90%;
|
||||||
|
margin: 100rpx auto;
|
||||||
|
background-color: #26A888;
|
||||||
|
text-align: center;
|
||||||
|
line-height: 60rpx;
|
||||||
|
height: 60rpx;
|
||||||
|
color: #fff;
|
||||||
|
}
|
||||||
|
|
||||||
|
.item {
|
||||||
|
width: 90%;
|
||||||
|
margin: 0 auto;
|
||||||
|
padding: 30rpx 0;
|
||||||
|
|
||||||
|
::v-deep .u-radio {
|
||||||
|
padding: 20rpx;
|
||||||
|
}
|
||||||
|
|
||||||
|
.title {
|
||||||
|
padding: 40rpx 0 20rpx;
|
||||||
|
font-size: 28rpx;
|
||||||
|
font-weight: 400;
|
||||||
|
color: #333333;
|
||||||
|
}
|
||||||
|
|
||||||
|
::v-deep .uni-picker-container {
|
||||||
|
width: 100%;
|
||||||
|
height: 63rpx;
|
||||||
|
background: #A7A7A7;
|
||||||
|
line-height: 63rpx;
|
||||||
|
opacity: 0.1;
|
||||||
|
border-radius: 5rpx;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</style>
|
||||||
125
questionnaire/copd/copd.vue
Normal file
125
questionnaire/copd/copd.vue
Normal file
@ -0,0 +1,125 @@
|
|||||||
|
<template>
|
||||||
|
<view class="app" v-if='list'>
|
||||||
|
<view class="item" v-for="(item,index) in list.questions" :key="index">
|
||||||
|
<view class="title">
|
||||||
|
{{Number(index)+1}}、{{item.questionName}}
|
||||||
|
</view>
|
||||||
|
<u-radio-group v-model="list.answers[index].optionContent" @change="radioGroupChange($event,item)">
|
||||||
|
<u-radio @change="radioChange($event,aitem,index)" v-for="(aitem, aindex) in item.options" :key="aindex"
|
||||||
|
:name="aitem.optionName">
|
||||||
|
{{aitem.optionName}}
|
||||||
|
</u-radio>
|
||||||
|
</u-radio-group>
|
||||||
|
</view>
|
||||||
|
<view class="btns" @tap='updata'>
|
||||||
|
提交
|
||||||
|
</view>
|
||||||
|
<u-toast ref="uToast" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
export default {
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
list: null,
|
||||||
|
};
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
updata() {
|
||||||
|
this.list.answers.forEach(e => {
|
||||||
|
if (!e.optionId) {
|
||||||
|
this.$refs.uToast.show({
|
||||||
|
title: '请选择完全部选项',
|
||||||
|
type: 'error',
|
||||||
|
})
|
||||||
|
return
|
||||||
|
}
|
||||||
|
})
|
||||||
|
var truelist = this.list.answers.filter(e => e.optionContent == '是')
|
||||||
|
if (truelist.length > 0) {
|
||||||
|
this.list.evaluateResult = '您可能存在糖尿病高危风险,建议每年至医疗机构进行一次糖尿病筛查。'
|
||||||
|
} else if (truelist.length == 0) {
|
||||||
|
this.list.evaluateResult = '您没有糖尿病高危风险,请继续保持!'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
// 选中某个单选框时,由radio时触发
|
||||||
|
radioChange(e, item, index) {
|
||||||
|
this.list.answers[index].optionId = item.id
|
||||||
|
},
|
||||||
|
// 选中任一radio时,由radio-group触发
|
||||||
|
radioGroupChange(e) {
|
||||||
|
// console.log(e);
|
||||||
|
}
|
||||||
|
},
|
||||||
|
onLoad(options) {
|
||||||
|
let list = JSON.parse(decodeURIComponent(options.item))
|
||||||
|
list.answers = []
|
||||||
|
list.questions.forEach(e => {
|
||||||
|
e.name = '请选择'
|
||||||
|
var obj = {
|
||||||
|
"questionId": e.id,
|
||||||
|
"optionId": null,
|
||||||
|
"optionContent": null,
|
||||||
|
}
|
||||||
|
list.answers.push(obj)
|
||||||
|
})
|
||||||
|
this.list = {
|
||||||
|
userId: uni.getStorageSync('patientId'),
|
||||||
|
surveyId: list.id,
|
||||||
|
surveySubject: list.surveySubject,
|
||||||
|
evaluateResult: null,
|
||||||
|
advice: null,
|
||||||
|
questions: list.questions,
|
||||||
|
answers: list.answers
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style lang="scss">
|
||||||
|
.app {
|
||||||
|
width: 96%;
|
||||||
|
margin: 16rpx auto;
|
||||||
|
background: #FFFFFF;
|
||||||
|
box-shadow: 0rpx 9rpx 31rpx 9rpx rgba(0, 0, 0, 0.03);
|
||||||
|
border-radius: 5rpx;
|
||||||
|
padding-bottom: 200rpx;
|
||||||
|
|
||||||
|
.btns {
|
||||||
|
width: 90%;
|
||||||
|
margin: 100rpx auto;
|
||||||
|
background-color: #26A888;
|
||||||
|
text-align: center;
|
||||||
|
line-height: 60rpx;
|
||||||
|
height: 60rpx;
|
||||||
|
color: #fff;
|
||||||
|
}
|
||||||
|
|
||||||
|
.item {
|
||||||
|
width: 90%;
|
||||||
|
margin: 0 auto;
|
||||||
|
padding: 30rpx 0;
|
||||||
|
|
||||||
|
::v-deep .u-radio {
|
||||||
|
padding: 20rpx;
|
||||||
|
}
|
||||||
|
|
||||||
|
.title {
|
||||||
|
padding: 40rpx 0 20rpx;
|
||||||
|
font-size: 28rpx;
|
||||||
|
font-weight: 400;
|
||||||
|
color: #333333;
|
||||||
|
}
|
||||||
|
|
||||||
|
::v-deep .uni-picker-container {
|
||||||
|
width: 100%;
|
||||||
|
height: 63rpx;
|
||||||
|
background: #A7A7A7;
|
||||||
|
line-height: 63rpx;
|
||||||
|
opacity: 0.1;
|
||||||
|
border-radius: 5rpx;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</style>
|
||||||
125
questionnaire/diabetes/diabetes.vue
Normal file
125
questionnaire/diabetes/diabetes.vue
Normal file
@ -0,0 +1,125 @@
|
|||||||
|
<template>
|
||||||
|
<view class="app" v-if='list'>
|
||||||
|
<view class="item" v-for="(item,index) in list.questions" :key="index">
|
||||||
|
<view class="title">
|
||||||
|
{{Number(index)+1}}、{{item.questionName}}
|
||||||
|
</view>
|
||||||
|
<u-radio-group v-model="list.answers[index].optionContent" @change="radioGroupChange($event,item)">
|
||||||
|
<u-radio @change="radioChange($event,aitem,index)" v-for="(aitem, aindex) in item.options" :key="aindex"
|
||||||
|
:name="aitem.optionName">
|
||||||
|
{{aitem.optionName}}
|
||||||
|
</u-radio>
|
||||||
|
</u-radio-group>
|
||||||
|
</view>
|
||||||
|
<view class="btns" @tap='updata'>
|
||||||
|
提交
|
||||||
|
</view>
|
||||||
|
<u-toast ref="uToast" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
export default {
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
list: null,
|
||||||
|
};
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
updata() {
|
||||||
|
this.list.answers.forEach(e => {
|
||||||
|
if (!e.optionId) {
|
||||||
|
this.$refs.uToast.show({
|
||||||
|
title: '请选择完全部选项',
|
||||||
|
type: 'error',
|
||||||
|
})
|
||||||
|
return
|
||||||
|
}
|
||||||
|
})
|
||||||
|
var truelist = this.list.answers.filter(e => e.optionContent == '是')
|
||||||
|
if (truelist.length > 0) {
|
||||||
|
this.list.evaluateResult = '您可能存在糖尿病高危风险,建议每年至医疗机构进行一次糖尿病筛查。'
|
||||||
|
} else if (truelist.length == 0) {
|
||||||
|
this.list.evaluateResult = '您没有糖尿病高危风险,请继续保持!'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
// 选中某个单选框时,由radio时触发
|
||||||
|
radioChange(e, item, index) {
|
||||||
|
this.list.answers[index].optionId = item.id
|
||||||
|
},
|
||||||
|
// 选中任一radio时,由radio-group触发
|
||||||
|
radioGroupChange(e) {
|
||||||
|
// console.log(e);
|
||||||
|
}
|
||||||
|
},
|
||||||
|
onLoad(options) {
|
||||||
|
let list = JSON.parse(decodeURIComponent(options.item))
|
||||||
|
list.answers = []
|
||||||
|
list.questions.forEach(e => {
|
||||||
|
e.name = '请选择'
|
||||||
|
var obj = {
|
||||||
|
"questionId": e.id,
|
||||||
|
"optionId": null,
|
||||||
|
"optionContent": null,
|
||||||
|
}
|
||||||
|
list.answers.push(obj)
|
||||||
|
})
|
||||||
|
this.list = {
|
||||||
|
userId: uni.getStorageSync('patientId'),
|
||||||
|
surveyId: list.id,
|
||||||
|
surveySubject: list.surveySubject,
|
||||||
|
evaluateResult: null,
|
||||||
|
advice: null,
|
||||||
|
questions: list.questions,
|
||||||
|
answers: list.answers
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style lang="scss">
|
||||||
|
.app {
|
||||||
|
width: 96%;
|
||||||
|
margin: 16rpx auto;
|
||||||
|
background: #FFFFFF;
|
||||||
|
box-shadow: 0rpx 9rpx 31rpx 9rpx rgba(0, 0, 0, 0.03);
|
||||||
|
border-radius: 5rpx;
|
||||||
|
padding-bottom: 200rpx;
|
||||||
|
|
||||||
|
.btns {
|
||||||
|
width: 90%;
|
||||||
|
margin: 100rpx auto;
|
||||||
|
background-color: #26A888;
|
||||||
|
text-align: center;
|
||||||
|
line-height: 60rpx;
|
||||||
|
height: 60rpx;
|
||||||
|
color: #fff;
|
||||||
|
}
|
||||||
|
|
||||||
|
.item {
|
||||||
|
width: 90%;
|
||||||
|
margin: 0 auto;
|
||||||
|
padding: 30rpx 0;
|
||||||
|
|
||||||
|
::v-deep .u-radio {
|
||||||
|
padding: 20rpx;
|
||||||
|
}
|
||||||
|
|
||||||
|
.title {
|
||||||
|
padding: 40rpx 0 20rpx;
|
||||||
|
font-size: 28rpx;
|
||||||
|
font-weight: 400;
|
||||||
|
color: #333333;
|
||||||
|
}
|
||||||
|
|
||||||
|
::v-deep .uni-picker-container {
|
||||||
|
width: 100%;
|
||||||
|
height: 63rpx;
|
||||||
|
background: #A7A7A7;
|
||||||
|
line-height: 63rpx;
|
||||||
|
opacity: 0.1;
|
||||||
|
border-radius: 5rpx;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</style>
|
||||||
125
questionnaire/hypertension/hypertension.vue
Normal file
125
questionnaire/hypertension/hypertension.vue
Normal file
@ -0,0 +1,125 @@
|
|||||||
|
<template>
|
||||||
|
<view class="app" v-if='list'>
|
||||||
|
<view class="item" v-for="(item,index) in list.questions" :key="index">
|
||||||
|
<view class="title">
|
||||||
|
{{Number(index)+1}}、{{item.questionName}}
|
||||||
|
</view>
|
||||||
|
<u-radio-group v-model="list.answers[index].optionContent" @change="radioGroupChange($event,item)">
|
||||||
|
<u-radio @change="radioChange($event,aitem,index)" v-for="(aitem, aindex) in item.options" :key="aindex"
|
||||||
|
:name="aitem.optionName">
|
||||||
|
{{aitem.optionName}}
|
||||||
|
</u-radio>
|
||||||
|
</u-radio-group>
|
||||||
|
</view>
|
||||||
|
<view class="btns" @tap='updata'>
|
||||||
|
提交
|
||||||
|
</view>
|
||||||
|
<u-toast ref="uToast" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
export default {
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
list: null,
|
||||||
|
};
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
updata() {
|
||||||
|
this.list.answers.forEach(e => {
|
||||||
|
if (!e.optionId) {
|
||||||
|
this.$refs.uToast.show({
|
||||||
|
title: '请选择完全部选项',
|
||||||
|
type: 'error',
|
||||||
|
})
|
||||||
|
return
|
||||||
|
}
|
||||||
|
})
|
||||||
|
var truelist = this.list.answers.filter(e => e.optionContent == '是')
|
||||||
|
if (truelist.length > 0) {
|
||||||
|
this.list.evaluateResult = '您可能存在高血压易患风险,请密切关注血压变化,及时就医。'
|
||||||
|
} else if (truelist.length == 0) {
|
||||||
|
this.list.evaluateResult = '您没有高血压风险,请继续保持!'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
// 选中某个单选框时,由radio时触发
|
||||||
|
radioChange(e, item, index) {
|
||||||
|
this.list.answers[index].optionId = item.id
|
||||||
|
},
|
||||||
|
// 选中任一radio时,由radio-group触发
|
||||||
|
radioGroupChange(e) {
|
||||||
|
// console.log(e);
|
||||||
|
}
|
||||||
|
},
|
||||||
|
onLoad(options) {
|
||||||
|
let list = JSON.parse(decodeURIComponent(options.item))
|
||||||
|
list.answers = []
|
||||||
|
list.questions.forEach(e => {
|
||||||
|
e.name = '请选择'
|
||||||
|
var obj = {
|
||||||
|
"questionId": e.id,
|
||||||
|
"optionId": null,
|
||||||
|
"optionContent": null,
|
||||||
|
}
|
||||||
|
list.answers.push(obj)
|
||||||
|
})
|
||||||
|
this.list = {
|
||||||
|
userId: uni.getStorageSync('patientId'),
|
||||||
|
surveyId: list.id,
|
||||||
|
surveySubject: list.surveySubject,
|
||||||
|
evaluateResult: null,
|
||||||
|
advice: null,
|
||||||
|
questions: list.questions,
|
||||||
|
answers: list.answers
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style lang="scss">
|
||||||
|
.app {
|
||||||
|
width: 96%;
|
||||||
|
margin: 16rpx auto;
|
||||||
|
background: #FFFFFF;
|
||||||
|
box-shadow: 0rpx 9rpx 31rpx 9rpx rgba(0, 0, 0, 0.03);
|
||||||
|
border-radius: 5rpx;
|
||||||
|
padding-bottom: 200rpx;
|
||||||
|
|
||||||
|
.btns {
|
||||||
|
width: 90%;
|
||||||
|
margin: 100rpx auto;
|
||||||
|
background-color: #26A888;
|
||||||
|
text-align: center;
|
||||||
|
line-height: 60rpx;
|
||||||
|
height: 60rpx;
|
||||||
|
color: #fff;
|
||||||
|
}
|
||||||
|
|
||||||
|
.item {
|
||||||
|
width: 90%;
|
||||||
|
margin: 0 auto;
|
||||||
|
padding: 30rpx 0;
|
||||||
|
|
||||||
|
::v-deep .u-radio {
|
||||||
|
padding: 20rpx;
|
||||||
|
}
|
||||||
|
|
||||||
|
.title {
|
||||||
|
padding: 40rpx 0 20rpx;
|
||||||
|
font-size: 28rpx;
|
||||||
|
font-weight: 400;
|
||||||
|
color: #333333;
|
||||||
|
}
|
||||||
|
|
||||||
|
::v-deep .uni-picker-container {
|
||||||
|
width: 100%;
|
||||||
|
height: 63rpx;
|
||||||
|
background: #A7A7A7;
|
||||||
|
line-height: 63rpx;
|
||||||
|
opacity: 0.1;
|
||||||
|
border-radius: 5rpx;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</style>
|
||||||
BIN
static/pageC/books.png
Normal file
BIN
static/pageC/books.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 7.3 KiB |
Loading…
Reference in New Issue
Block a user