Commit 8b0953ae authored by gengchunlei's avatar gengchunlei

医生端小程序 v1.2 1、复筛表单

parent 7821a959
......@@ -15,6 +15,16 @@ export function getLastScreen(params) {
return fetchBase({ url: `/chronic-admin/v1/chronic-screening-rescreen/last-info`, body: params, loading: true})
}
// 保存复筛
export function saveSecondScreening(params) {
return fetchBase({ url: `/chronic-admin/v1/chronic-screening-rescreen/save`,body: params,loading: true})
}
// 修改复筛
export function updateSecondScreening(params) {
return fetchBase({ url: `/chronic-admin/v1/chronic-screening-rescreen/update`,body: params,loading: true})
}
// 保存初筛
export function saveFirstScreening(params) {
return fetchBase({ url: `/chronic-admin/v1/chronic-screening-record/save`,body: params,loading: true})
......
......@@ -66,7 +66,7 @@ export default {
if (!token) {
token = sessionStorage.getItem('token')
if (process.env.NODE_ENV !== 'production') {
token = '779099b2-3d34-41ef-b14a-4a435fb48adb'
token = 'f0c1b081-b6d8-4958-a40f-0750cc272271'
}
}
if (token) {
......
......@@ -141,7 +141,7 @@ export default {
this.$refs.form.validate().then(() => {
let par = {
residentsRecord: {
...this.info,
// ...this.info,
...baseInfo,
id: this.info.personId
},
......
<template>
<div>
<van-form ref='form'>
<div class='no-req-label' v-if='showPush'>请选择推送渠道</div>
<van-field
v-model='form.isSmsIsWxStr'
style='padding: 0px'
:rules='rules.isSmsIsWxStr'
>
<template #input>
<div class='w-full'>
<div>
<checkBtn class='mt-3'
column-1
text-align='left'
:options='vxList'
v-model:value='checkVx'
:fieldNames="{text: 'name', value: 'value'}"
>
</checkBtn>
<div class='vx-cb'>
<van-checkbox-group v-model='checkVxCb' shape='square' icon-size='18px'>
<van-checkbox :name='1' />
</van-checkbox-group>
</div>
</div>
<div class='push-lab'>随访信息将通过小程序消息推送给居民</div>
<checkBtn class='mt-3'
column-1
text-align='left'
:options='messageList'
v-model:value='checkMessage'
:fieldNames="{text: 'name', value: 'value'}"
></checkBtn>
<div class='ms-cb'>
<van-checkbox-group v-model='checkMessageCb' shape='square' icon-size='18px'>
<van-checkbox :name='1' />
</van-checkbox-group>
</div>
<div class='push-lab'>随访信息将通过短信方式发送给居民</div>
</div>
</template>
</van-field>
<div :class="['label-title', {'mt-5': showPush}]">随访单位</div>
<div :class="['label-title', 'mt-5']">随访单位</div>
<van-field
v-model='form.visitUnitName'
v-model='form.screenUnitName'
is-link
readonly
placeholder='随访单位'
class='input-back mt-2 form-input'
:rules='rules.visitUnitName'
:rules='rules.screenUnitName'
@click='show1 = true'
/>
<DocUnit v-model:show='show1' v-model:value='form.visitUnitId' @change='changeUnit' />
<DocUnit v-model:show='show1' v-model:value='form.screenUnitId' @change='changeUnit' />
<div class='label-title mt-5'>随访科室</div>
<van-field
v-model='form.visitOfficeName'
v-model='form.screenOfficeName'
is-link
readonly
placeholder='随访科室'
class='input-back mt-2 form-input'
:rules='rules.visitOfficeName'
:rules='rules.screenOfficeName'
@click='show2 = true'
/>
<DocOffice v-model:show='show2' v-model:value='form.visitOfficeId' @change='changeOffice'
:unitId='form.visitUnitId' />
<DocOffice v-model:show='show2' v-model:value='form.screenOfficeId' @change='changeOffice'
:unitId='form.screenUnitId' />
<div class='label-title mt-5'>随访医生</div>
<van-field
v-model='form.visitDoctorName'
v-model='form.screenDoctorName'
is-link
readonly
placeholder='随访医生'
class='input-back mt-2 form-input'
:rules='rules.visitDoctorName'
:rules='rules.screenDoctorName'
@click='show3 = true'
/>
<DocOfficeDoctor v-model:show='show3' v-model:value='form.visitDoctorId' @change='changeDoctor'
:unitId='form.visitUnitId' :officeId='form.visitOfficeId' />
<DocOfficeDoctor v-model:show='show3' v-model:value='form.screenDoctorId' @change='changeDoctor'
:unitId='form.screenUnitId' :officeId='form.screenOfficeId' />
</van-form>
</div>
</template>
......@@ -92,27 +51,18 @@ import DocUnit from '@/doctor/components/docUnit/DocUnit'
import DocOffice from '@/doctor/components/docOffice/DocOffice'
import DocOfficeDoctor from '@/doctor/components/docOfficeDoctor/DocOfficeDoctor'
import CheckBtn from '@/doctor/components/checkBtn/CheckBtn'
import DocImageUpload from '@/doctor/components/docImageUpload/DocImageUpload'
export default {
name: 'CommonBottom',
components: { CheckBtn, DocOfficeDoctor, DocOffice, DocUnit },
components: { DocImageUpload, CheckBtn, DocOfficeDoctor, DocOffice, DocUnit },
props: {
info: {
default: () => {
return {}
}
},
firstForm: {
default: () => {
return {}
}
},
modeEnumList: {
default: () => {
return {}
}
}
},
data() {
return {
......@@ -120,20 +70,9 @@ export default {
show1: false,
show2: false,
show3: false,
vxList: [],
checkVx: 1,
checkVxCb: [1],
messageList: [],
checkMessage: undefined,
checkMessageCb: [],
form: {
isSmsIsWx: [1]
},
rules: {
isSmsIsWxStr: [{ required: false, message: '请选择' }],
visitUnitName: [{ required: true, message: '请选择' }],
visitOfficeName: [{ required: true, message: '请选择' }],
visitDoctorName: [{ required: true, message: '请选择' }]
}
}
},
......@@ -144,113 +83,26 @@ export default {
},
immediate: true
},
'firstForm.residentsRecord': {
handler() {
this.vxList = this.getVxEnum(this.firstForm)
this.messageList = this.getMessageEnum(this.firstForm.residentsRecord)
},
immediate: true,
deep: true
},
'checkMessage': {
handler() {
this.form.isSms = 2
if (this.checkMessage) {
this.form.isSms = 1
this.form.isSmsIsWx.push(2)
this.form.isSmsIsWxStr = 2
this.checkMessageCb = [1]
} else {
this.form.isSmsIsWx = this.form.isSmsIsWx.filter(item => item != 2)
this.checkMessageCb = []
//判断推送渠道是否存在值
if (!this.checkVx) {
this.form.isSmsIsWxStr = ''
}
}
}
},
'checkVx': {
handler() {
this.form.isWx = 2
if (this.checkVx) {
this.form.isWx = 1
this.form.isSmsIsWx.push(1)
this.form.isSmsIsWxStr = 1
this.checkVxCb = [1]
} else {
this.form.isSmsIsWx = this.form.isSmsIsWx.filter(item => item != 1)
this.checkVxCb = []
//判断推送渠道是否存在值
if (!this.checkMessage) {
this.form.isSmsIsWxStr = ''
}
}
}
},
'checkVxCb': {
handler() {
if (this.checkVxCb && this.checkVxCb.length) {
this.checkVx = 1
} else {
this.checkVx = undefined
}
}
},
'checkMessageCb': {
handler() {
if (this.checkMessageCb && this.checkMessageCb.length) {
this.checkMessage = 2
} else {
this.checkMessage = undefined
}
}
}
},
computed: {
authInfo() {
return this.store.$state.authInfo
},
//是否显示推送渠道
showPush() {
let res = false
let list = []
if (this.firstForm.visitWayRules) {
list = this.firstForm.visitWayRules.split(',').map(item => Number(item))
}
if (list && list.length && (list.includes(2) || list.includes(3) || list.includes(4))) {
res = true
}
return res
}
},
methods: {
//微信
getVxEnum(patientInfo = {}) {
return [{
name: `微信 ${patientInfo.sendNumber ? `(${this.$phoneHide(patientInfo.sendNumber)}已注册小程序)` : `(未注册小程序)`}`,
value: 1
}]
},
getMessageEnum(patientInfo = {}) {
return [{
name: `短信 ${patientInfo.telephone ? `(手机号 ${this.$phoneHide(patientInfo.telephone)})` : `(手机号 不存在)`}`,
value: 2
}]
},
setForm(info) {
const form = {
visitDate: new dayjs(),
createDate: new dayjs(),
screenDate: new dayjs().format("YYYY-MM-DD"),
createDate: new dayjs().format("YYYY-MM-DD"),
// 随访单位
visitUnitId: this.authInfo.unitId,
visitUnitName: this.authInfo.unitName,
screenUnitId: this.authInfo.unitId,
screenUnitName: this.authInfo.unitName,
// 随访科室
visitOfficeId: this.authInfo.officeId,
visitOfficeName: this.authInfo.officeName,
screenOfficeId: this.authInfo.officeId,
screenOfficeName: this.authInfo.officeName,
// 随访医生
visitDoctorId: this.authInfo.relationId,
visitDoctorName: this.authInfo.nickName,
screenDoctorId: this.authInfo.relationId,
screenDoctorName: this.authInfo.nickName,
// 录入单位
createUnitId: this.authInfo.unitId,
createUnitName: this.authInfo.unitName,
......@@ -260,9 +112,6 @@ export default {
// 录入医生
createDoctorId: this.authInfo.relationId,
createDoctorName: this.authInfo.nickName,
isSms: 2,
isWx: 1,
isSmsIsWx: [1]
}
Reflect.ownKeys(form).forEach(key => {
if (info[key] != undefined) {
......@@ -272,52 +121,35 @@ export default {
return form
},
changeUnit(val) {
this.form.visitUnitName = val.unitName
this.form.visitUnitId = val.id
this.form.visitOfficeId = undefined
this.form.visitOfficeName = undefined
this.form.visitDoctorId = undefined
this.form.visitDoctorName = undefined
this.form.screenUnitName = val.unitName
this.form.screenUnitId = val.id
this.form.screenOfficeId = undefined
this.form.screenOfficeName = undefined
this.form.screenDoctorId = undefined
this.form.screenDoctorName = undefined
this.show1 = false
},
changeOffice(val) {
this.form.visitOfficeId = val.id
this.form.visitOfficeName = val.officeName
this.form.visitDoctorId = undefined
this.form.visitDoctorName = undefined
this.form.screenOfficeId = val.id
this.form.screenOfficeName = val.officeName
this.form.screenDoctorId = undefined
this.form.screenDoctorName = undefined
this.show2 = false
},
changeDoctor(val) {
this.form.visitDoctorId = val.id
this.form.visitDoctorName = val.staffName
this.form.screenDoctorId = val.id
this.form.screenDoctorName = val.staffName
this.show3 = false
},
onSubmit() {
return new Promise((resolve, reject) => {
this.$refs.form.validate().then(() => {
const { isSmsIsWx = [], ...others } = this.form
let isSms = 2
let isWx = 2
let wxTel = ''
if (isSmsIsWx.length && this.showPush) {
if (isSmsIsWx.includes(1)) {
isWx = 1
wxTel = this.modeEnumList.weixinTel
}
if (isSmsIsWx.includes(2)) {
isSms = 1
}
}
let par = {
...others,
isSms,
isWx,
isSmsIsWx,
sendNumber: wxTel
...this.form,
}
resolve(par)
}).catch((e) => {
console.warn('ArchiveCommon error', e)
console.warn('error', e)
})
})
}
......
......@@ -143,7 +143,7 @@
<div class='no-req-label mt-5'>BMI</div>
<van-field
v-model='form.bmi'
clear-icon
readonly
placeholder='请输入'
class='input-back mt-2 form-input'
>
......@@ -504,11 +504,231 @@
<div v-if='drinkShow'>
<div class='label-title mt-5'>饮酒情况</div>
<div class='bg-fa mt-2'>
<div class='label-title lh-24'>饮酒频率</div>
<van-field
class='form-input mt-2'
style='padding: 0'
>
<template #input>
<van-radio-group v-model='form.drinkFrequency'
direction='horizontal'
class='w-full doc-radio-group-now'
@change='drinkFrequencyChange'
>
<van-radio v-for="item in store.getDict('CP00132')"
:key='item.value' :name='item.value'
label-position='left'>{{ item.name }}
</van-radio>
</van-radio-group>
</template>
</van-field>
</div>
<div class='bg-f5 mt-2' v-if='[2,3,4].includes(form.drinkFrequency)'>
<div class='label-title lh-24'>饮酒种类</div>
<van-field
class='form-input mt-2'
style='padding: 0'
>
<template #input>
<div class='flex justify-between gap-x-2.5 w-full' style='background: #F5F5F5'>
<div v-for="(item, index) in store.getDict('CP00133')" :key='item.value' class='bg-ff'>
<div
@click='toggleDrink(item)'
:class="['form-input', 'flex', 'justify-between', this.form.drinkKind.includes(item.value) ? 'active-drinkKind' : '' ]"
>
<div>{{ item.name }}</div>
</div>
</div>
</div>
</template>
</van-field>
<div class='mt-2' v-if='form?.drinkKind?.includes(99)'>
<van-field
v-model='form.drinkKindOther'
clear-icon
placeholder='请输入饮酒种类名称'
class=' mt-2 form-input'
>
</van-field>
</div>
</div>
<div class='bg-f5 mt-2' v-if='[2,3,4].includes(form.drinkFrequency)'>
<div class='no-req-label lh-24'>请输入日酒饮量</div>
<div class='flex flex-wrap justify-between gap-x-2.5 gap-y-2.5 mt-2'
v-if='drinkKindCapacityList.length'>
<div v-for='(item,index) in drinkKindCapacityList' :key='index'
style='width: 48%;'>
<div>
<van-field
colon
label-width='42px'
v-model='item.drinkCapacity'
:label='item.drinkKindName'
placeholder='请输入'
style='padding: 8px;border-radius: 4px'
>
<template #extra>
<span class='mr-2'>mL</span>
</template>
</van-field>
</div>
</div>
</div>
<div class='mt-2'>
<van-field
colon
label-width='40%'
v-model='form.dayDrink'
label='平均日饮酒量'
placeholder='请输入'
style='padding: 8px;border-radius: 4px'
>
<template #extra>
<span class='mr-2'>mL</span>
</template>
</van-field>
</div>
</div>
<div class='bg-f5 mt-2' v-if='[2,3,4].includes(form.drinkFrequency)'>
<div class='no-req-label lh-24'>请输入开始饮酒年龄</div>
<van-field
colon
v-model='form.startDrinkAge'
placeholder='请输入'
class='mt-2'
style='padding: 8px;border-radius: 4px'
>
<template #extra>
<span class='mr-2'></span>
</template>
</van-field>
</div>
<div class='bg-f5 mt-2' v-if='[2,3,4].includes(form.drinkFrequency)'>
<div class='label-title lh-24'>是否戒酒</div>
<van-field
class='form-input mt-2'
style='padding: 0'
>
<template #input>
<van-radio-group v-model='form.giveDrink'
direction='horizontal'
class='w-full doc-radio-group-now'
style='background: #F5F5F5'
>
<van-radio v-for="item in store.getDict('CP00120')"
:key='item.value' :name='item.value'
label-position='left'>{{ item.name }}
</van-radio>
</van-radio-group>
</template>
</van-field>
</div>
<div class='bg-f5 mt-2' v-if='[2,3,4].includes(form.drinkFrequency) && form.giveDrink == 1'>
<div class='no-req-label lh-24'>请输入开始戒酒年龄</div>
<van-field
colon
v-model='form.giveDrinkStart'
placeholder='请输入'
class='mt-2'
style='padding: 8px;border-radius: 4px'
>
<template #extra>
<span class='mr-2'></span>
</template>
</van-field>
</div>
</div>
<div v-if='smokeShow'>
<div class='label-title mt-5'>吸烟情况</div>
<div class='bg-fa mt-2'>
<div class='label-title lh-24'>吸烟情况</div>
<van-field
class='form-input mt-2'
style='padding: 0'
>
<template #input>
<van-radio-group v-model='form.isSmoking'
direction='horizontal'
class='w-full doc-radio-group-now'
>
<van-radio v-for="item in store.getDict('CP00162')"
:key='item.value' :name='item.value'
label-position='left'>{{ item.name }}
</van-radio>
</van-radio-group>
</template>
</van-field>
</div>
<div class='bg-f5 mt-2' v-if='form.isSmoking === 3'>
<div class='label-title lh-24'>日吸烟量</div>
<van-field
colon
v-model='form.daySmoking'
placeholder='请输入'
class='mt-2'
style='padding: 8px;border-radius: 4px'
>
</van-field>
</div>
<div class='bg-f5 mt-2' v-if='form.isSmoking === 3'>
<div class='label-title lh-24'>开始吸烟年龄</div>
<van-field
colon
v-model='form.startSmoking'
placeholder='请输入'
class='mt-2'
style='padding: 8px;border-radius: 4px'
>
<template #extra>
<span class='mr-2'></span>
</template>
</van-field>
</div>
<div class='bg-f5 mt-2' v-if='form.isSmoking === 2'>
<div class='label-title lh-24'>戒烟年龄</div>
<van-field
colon
v-model='form.giveSmokingAge'
placeholder='请输入'
class='mt-2'
style='padding: 8px;border-radius: 4px'
>
<template #extra>
<span class='mr-2'></span>
</template>
</van-field>
</div>
<div class='bg-f5 mt-2' v-if='form.diseaseArrays?.includes(1)'>
<div class='label-title lh-24'>经常吸入二手烟(家中有吸烟者,且经常吸入二手烟)</div>
<van-field
class='form-input mt-2'
style='padding: 0'
>
<template #input>
<van-radio-group v-model='form.secondSmoking'
direction='horizontal'
class='w-full doc-radio-group-now'
style='background: #F5F5F5'
>
<van-radio v-for="item in store.getDict('CP00120')"
:key='item.value' :name='item.value'
label-position='left'>{{ item.name }}
</van-radio>
</van-radio-group>
</template>
</van-field>
</div>
</div>
<div v-if='blackSpinySkinShow'>
......@@ -606,6 +826,39 @@
</van-field>
</div>
<div>
<div class='no-req-label mt-5'>知情同意书</div>
<DocImageUpload
description='支持上传jpg、png、jpeg文件,大小请在10M以内'
lengthMessage='抱歉,最多可上传6个文件。'
:imageData='[]'
@change='(ids, option) => form.informedConsent = ids'
:maxLength='6'
class='mt-2'
/>
</div>
<div>
<div class='label-title lh-24'>专病高危评估结果</div>
<van-field
class='form-input mt-2'
style='padding: 0'
>
<template #input>
<div class='flex gap-x-2.5 gap-y-2.5 w-full flex-wrap' style='background: #FFFFFF'>
<div v-for="(item, index) in store.getDict('CP00137')" :key='item.value' class='bg-ff'>
<div
@click='toggleResult(item)'
:class="['form-input', 'bg-fa', this.specialScreenResultSelect.includes(item.value) ? 'active-drinkKind' : '' ]"
>
<div>{{ item.name }}</div>
</div>
</div>
</div>
</template>
</van-field>
</div>
</van-form>
</div>
</template>
......@@ -613,10 +866,11 @@
<script>
import { useStore } from '@/doctor/store'
import { checkboxReject } from '@/utils/common'
import { checkboxReject, fetchDataHandle } from '@/utils/common'
import CheckBtn from '@/doctor/components/checkBtn/CheckBtn'
import BloodPressureBt from '@/doctor/components/bloodPressure/BloodPressureBt'
import BloodPressurePanel from '@/doctor/components/bloodPressure/BloodPressurePanel'
import DocImageUpload from '@/doctor/components/docImageUpload/DocImageUpload'
const defaultForm = (info = {}) => {
const form = {
......@@ -652,7 +906,7 @@ const defaultForm = (info = {}) => {
dietaryHabitName: undefined,
drinkFrequency: undefined,
startDrinkAge: undefined,
drinkKind: undefined,
drinkKind: [],
drinkKindOther: undefined,
dayDrink: undefined,
giveDrink: undefined,
......@@ -694,7 +948,7 @@ const defaultForm = (info = {}) => {
return form
}
export default {
components: { BloodPressurePanel, BloodPressureBt, CheckBtn },
components: { DocImageUpload, BloodPressurePanel, BloodPressureBt, CheckBtn },
props: {
info: Object,
diseaseArraysInfo: Array
......@@ -717,6 +971,7 @@ export default {
showExerciseFrequency: false,
checkboxRefs: [],
checkboxDrinkRefs: [],
form: {},
formRight: {
hypertensionHighItemSelect: [],
......@@ -1189,15 +1444,11 @@ export default {
exerciseFrequencyList() {
let res = []
let listOne = this.store.getDict(`CP00126`)
let listTwo = this.store.getDict(`CP00163`)
listTwo.forEach(item => {
if (item.value == 1) {
item.value = 5
}
if (item.value == 2) {
item.value = 6
}
})
// let listTwo = this.store.getDict(`CP00163`)
let listTwo = [
{ value: 5, name: '每周5次及以上' },
{ value: 6, name: '每周不到5次' }
]
return res = [...listOne, ...listTwo]
}
......@@ -1221,6 +1472,16 @@ export default {
},
deep: true
},
'form.height': {
handler() {
this.calculateBMI()
}
},
'form.weight': {
handler() {
this.calculateBMI()
}
},
//右侧高危选项变化监测
'formRight': {
handler(now, old) {
......@@ -1289,6 +1550,12 @@ export default {
//初始化表单
initForm() {
this.form = defaultForm(this.info)
if (this.info.isExerciseFive == 1) {
this.form.exerciseFrequency = 5
}
if (this.info.isExerciseFive == 2) {
this.form.exerciseFrequency = 6
}
if (!this.info.id) {
//是否是引用上一次复筛数据
if (this.info.flag && this.info.flag == 'lastInfo') {
......@@ -2163,27 +2430,56 @@ export default {
this.form.pressureTwoDbp = val.diastolicPressure
},
//家族史多选
toggle(index) {
this.checkboxRefs[index].toggle()
this.changeFamilyHis()
},
//饮酒种类
toggleDrink(val) {
if (this.form.drinkKind.includes(val.value)) {
this.form.drinkKind = this.form.drinkKind.filter(e => e !== val.value)
} else {
this.form.drinkKind.push(val.value)
}
this.drinkKindChange(this.form.drinkKind)
},
//专病高危评估结果
toggleResult(val) {
if (this.specialScreenResultSelect.includes(val.value)) {
this.specialScreenResultSelect = this.specialScreenResultSelect.filter(e => e !== val.value)
} else {
this.specialScreenResultSelect.push(val.value)
}
this.specialScreenResultSelect = this.checkboxReject(this.specialScreenResultSelect, [9])
},
//提交
submit() {
onSubmit() {
return new Promise((resolve, reject) => {
this.$refs.form.validate().then(() => {
if (!this.specialScreenResultSelect.length) {
this.$message.info('请选择专病高危评估结果')
reject(e)
return
}
let flag = this.familyHistoryReq()
if (flag > 0) {
return
let exerciseFrequencyInfo = ''
let isExerciseFiveInfo = ''
const { exerciseFrequency } = this.form
if (exerciseFrequency == 5) {
exerciseFrequencyInfo = 1
isExerciseFiveInfo = 1
} else if (exerciseFrequency == 6) {
exerciseFrequencyInfo = 1
isExerciseFiveInfo = 2
} else {
exerciseFrequencyInfo = exerciseFrequency
}
let res = {
...this.form,
exerciseFrequency: exerciseFrequencyInfo,
isExerciseFive: isExerciseFiveInfo,
hypertensionHighItem: this.formRight.hypertensionHighItemSelect,
diabetesHighItem: this.formRight.diabetesHighItemSelect,
coronaryHighItem: this.formRight.coronaryHighItemSelect,
......@@ -2219,8 +2515,7 @@ export default {
})
)
}).catch((e) => {
console.warn('SecondScreenForm error', e)
reject(e)
console.warn('FormCont error', e)
})
})
}
......@@ -2289,6 +2584,49 @@ export default {
}
}
.bg-fa {
background: #FAFAFA;
border-radius: 8px;
padding: 8px;
}
.bg-ff {
background: #FFFFFF;
border-radius: 8px;
}
.bg-f5 {
background: #F5F5F5;
border-radius: 8px;
padding: 8px;
}
.doc-radio-group-now {
column-gap: 10px;
row-gap: 10px;
background-color: #FAFAFA;
.van-radio {
background-color: #FFFFFF;
width: 48%;
padding: 8px 12px;
border-radius: 8px;
justify-content: space-between;
margin-right: 0;
flex-grow: 1;
}
}
.active-drinkKind {
//border: 1px solid var(--van-primary-color);
background-color: #F0F6FF;
color: var(--van-primary-color);
}
.lh-24 {
line-height: 24px;
}
:deep(.van-popup) {
height: 50% !important;
}
......
......@@ -4,12 +4,9 @@
<div class="mt-3">筛查完成</div>
<div class="text-start mt-5">
<span style="color: #595959;">通过筛查,您的慢病高危评估结果为:</span>
<span class="text-red">高危人群</span>
<div class="text-red mt-2" style='line-height: 24px'>{{specialScreenResultList.join("、")}}</div>
</div>
<div style="margin-top: .48rem">
<van-button type='primary' block round plain
@click='toScreen'>专病高危筛查</van-button>
<div class="pt-3"></div>
<van-button type='primary' block round plain
@click='toDetail'>查看居民详情</van-button>
<div class="text-16 pt-5" style="color: #8c8c8c;"
......@@ -21,7 +18,8 @@
<script>
export default {
props: {
residentInfoId: String
residentInfoId: String,
specialScreenResultList: Array,
},
methods: {
toScreen() {
......
......@@ -12,7 +12,12 @@
v-show='step == 2'
ref='formInfo'
></form-cont>
<common-bottom
v-if='step == 3'
ref='commonBottom'
></common-bottom>
<result :residentInfoId='residentInfoId'
:specialScreenResultList='specialScreenResultList'
v-show='step == 4'
></result>
</div>
......@@ -44,17 +49,20 @@
<script>
import DocNavBar from '@/doctor/components/docNavBar/DocNavBar.vue'
import ArchiveCommon from '@/doctor/components/archiveCommon/archiveCommon'
import { fetchCurrencyById, getChronicResidentsId } from '@/api/doctor/generalFU'
import { getChronicResidentsId } from '@/api/doctor/generalFU'
import FormCont from '@/doctor/screening/second/FormCont'
import Result from '@/doctor/screening/second/Result'
import DiseaseSelect from '@/doctor/screening/second/DiseaseSelect'
import BaseInfo from '@/doctor/screening/second/BaseInfo'
import { fetchDataHandle } from '@/utils/common'
import { getLastScreen, secondScreenDetail } from '@/api/doctor/screening'
import { getLastScreen, saveSecondScreening, secondScreenDetail, updateSecondScreening } from '@/api/doctor/screening'
import { showToast } from 'vant'
import CommonBottom from '@/doctor/screening/second/CommonBottom'
import { useStore } from '@/doctor/store'
export default {
components: {
CommonBottom,
BaseInfo,
DiseaseSelect,
Result,
......@@ -64,10 +72,12 @@ export default {
},
data() {
return {
store: useStore(),
step: 1,
info: {},
residentInfo: {},
diseaseArraysInfo: []
diseaseArraysInfo: [],
specialScreenResultList: [],
}
},
computed: {
......@@ -179,7 +189,37 @@ export default {
this.step = val
},
//提交所有表单
onsubmit() {
async onsubmit() {
let baseInfo = await this.$refs.baseInfo.onSubmit()
let formInfo = await this.$refs.formInfo.onSubmit()
let commonBottom = await this.$refs.commonBottom.onSubmit()
let params = {
...formInfo,
...commonBottom,
...baseInfo,
diseaseArrays: baseInfo.diseaseArrays ? baseInfo.diseaseArrays.join() : '',
source: 2
}
if (formInfo.specialScreenResult) {
let list = formInfo.specialScreenResult.split(",")
list.forEach(item => {
let res = this.store.getDict(`CP00137`).filter(e => e.value == item)
if (res && res.length) {
this.specialScreenResultList.push(res[0].name)
}
})
}
if (!params.id) {
saveSecondScreening(params).then(res => {
this.$message.success('新增成功')
this.toNext(4)
})
} else {
updateSecondScreening(params).then(res => {
this.$message.success('修改成功')
this.toNext(4)
})
}
},
onBack() {
......
......@@ -31,7 +31,7 @@ module.exports = defineConfig({
},
'/chronic-admin': {
target: 'https://beta-tumour.zmnyjk.com',
// target: 'http://192.168.1.163:8900',
// target: 'http://192.168.1.125:8900',
changOrigin: true,
pathRewrite: {
// '^/chronic-admin': '/'
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment