| | |
| | | { |
| | | "appid": "wx0edc9a56412f6b5e", |
| | | "compileType": "miniprogram", |
| | | "libVersion": "3.0.0", |
| | | "libVersion": "3.8.9", |
| | | "packOptions": { |
| | | "ignore": [], |
| | | "include": [] |
| | |
| | | document.title = to.meta.title |
| | | } |
| | | // 看看有没有toke |
| | | const token = Session.get('token'); |
| | | console.log(!token) |
| | | const token = Session.get('token') |
| | | console.log(!token) |
| | | if (to.path === '/login') { |
| | | next(); |
| | | |
| | | }else{ |
| | | next() |
| | | |
| | | } else { |
| | | if (!token){ |
| | | next('/login'); |
| | | }else{ |
| | | next('/login') |
| | | } else { |
| | | console.log('---') |
| | | await userInfo.setPatientApi() |
| | | next(); |
| | | if (to.path === '/'){ |
| | | await userInfo.setPatientApi() |
| | | |
| | | await userInfo.setPatientApi() |
| | | } |
| | | next() |
| | | } |
| | | } |
| | | }) |
| | |
| | | pressure:'', |
| | | weight:'' |
| | | }) |
| | | |
| | | const 最近体重血压 = ref({ |
| | | 血压: '', |
| | | 体重: '' |
| | | }) |
| | | function setInfo(userInfo:{openid:string, headimgurl:string,nickname:string}) { |
| | | info.value.openid=userInfo.openid |
| | | info.value.headimgurl=userInfo.headimgurl |
| | |
| | | } |
| | | function setPatient(userInfo:any) { |
| | | patient.value=userInfo |
| | | set最近体重血压(userInfo.patientInfo.code) |
| | | } |
| | | const setPatientApi= async()=>{ |
| | | const res= await ajaxPost('/patient/info/getPatientInfo','') |
| | | setPatient(res) |
| | | } |
| | | const set最近体重血压 = async(patientCode:any)=>{ |
| | | const data= await ajaxPost('/patient/info/getPatientBodyWeightBloodPressure?patientCode='+patientCode,'') |
| | | console.log(data,'最近体重血压数据') |
| | | 最近体重血压.value = { |
| | | 血压: data.透前血压, |
| | | 体重: data.透前称重 |
| | | } |
| | | console.log(最近体重血压.value,'最近体重血压数据') |
| | | } |
| | | |
| | | return { info,patient,setPatient, setInfo,setPatientApi } |
| | | return { info,patient,最近体重血压,setPatient, setInfo,setPatientApi } |
| | | }) |
| | |
| | | .crainfo{ |
| | | border-radius: 50%; |
| | | border: 2.5px solid rgba(101, 170, 255, 1); |
| | | width: 70px; |
| | | height: 70px; |
| | | width: 80px; |
| | | height: 80px; |
| | | text-align: center;margin:auto; |
| | | .tizhong{ |
| | | overflow-wrap: break-word; |
| | |
| | | font-family: PingFangSC-Medium; |
| | | text-align: center; |
| | | white-space: nowrap; |
| | | margin-top: 20px; |
| | | margin-top: 25px; |
| | | line-height: 28px; |
| | | } |
| | | .xueya{ |
| | |
| | | font-family: PingFangSC-Medium; |
| | | text-align: center; |
| | | white-space: nowrap; |
| | | margin-top: 20px; |
| | | margin-top: 15px; |
| | | line-height: 28px; |
| | | } |
| | | } |
| | |
| | | <div class="viewInfo"> |
| | | <div class="box"> |
| | | <div class="crainfo"> |
| | | <div class="tizhong">{{patientInfo.weight}}</div> |
| | | <div class="tizhong">{{最近体重血压.体重}}</div> |
| | | </div> |
| | | <div class="hanzhi">体重(kg)</div> |
| | | <div class="yinyu">Patient weight data</div> |
| | | </div> |
| | | <div class="box"> |
| | | <div class="crainfo"> |
| | | <div class="xueya">{{patientInfo.pressure}}</div> |
| | | <div class="xueya"> |
| | | <div v-if="最近体重血压.血压">{{最近体重血压.血压.split('/')[0]}}</div> |
| | | <div style="height: 1px;background-color: #909399;"></div> |
| | | <div v-if="最近体重血压.血压">{{最近体重血压.血压.split('/')[1]}}</div> |
| | | </div> |
| | | </div> |
| | | <div class="hanzhi">血压(mmHg)</div> |
| | | <div class="yinyu">Patient blood pressure data</div> |
| | |
| | | const patientInfo=computed(() => { |
| | | return userInfo.patient |
| | | }) |
| | | const 最近体重血压=computed(() => { |
| | | return userInfo.最近体重血压 |
| | | }) |
| | | const Info=computed(() => { |
| | | return userInfo.info |
| | | }) |
| | |
| | | } |
| | | onMounted(()=>{ |
| | | // userInfo.setInfo({openid:'odFja56xfwSZDHhAEMn-JotSzlRc',nickname:'大橙子',headimgurl:'https://thirdwx.qlogo.cn/mmopen/vi_32/Q0j4TwGTfTJB…ibLYic7qC9cm0Yjia3VkHRPVa12N0OK6dgdz984biceWg/132'}) |
| | | // Session.set('token', 'eyJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJQQVRfU0ZfUEFUOTE0MzE2NDAyMTk1N0pOcUMiLCJhdXRoIjpbeyJhdXRob3JpdHkiOiJhZG1pbiJ9XSwiaWF0IjoxNzQwNzM2Nzg2LCJleHAiOjE3NDEwOTY3ODZ9.stAHeAJ_pB4qWL4W-1rv0UUnBV3Wn2vsSH-td2j26cw') |
| | | // Session.set('token', 'eyJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJQQVRfU0ZfUEFUOTE0MzE2NDAyMTk1N0pOcUMiLCJhdXRoIjpbeyJhdXRob3JpdHkiOiJhZG1pbiJ9XSwiaWF0IjoxNzUyMDU5ODk0LCJleHAiOjE3NTI0MTk4OTR9.a-Zw910bXendD9Oq7jxjDYfaWLf693maoh7MgAfqK9Y') |
| | | // getUserinfo() |
| | | Session.remove('token') |
| | | if (isWechat()){ |
| | |
| | | title: '提示', |
| | | message: '请在微信中打开浏览', |
| | | }).then(() => { |
| | | // on close |
| | | }) |
| | | } |
| | | }) |
| | |
| | | <span style="color: #777;">状态:</span> |
| | | <span v-if="pageInfo.medState === 0" style="color: #769aff;">未签到</span> |
| | | <span v-if="pageInfo.medState === 1" style="color: #769aff;">已签到</span> |
| | | <span v-if="pageInfo.medState === 2" style="color: #769aff;">透析中</span> |
| | | <span v-if="pageInfo.medState === 2 || pageInfo.medState === 2.5" style="color: #769aff;">透析中</span> |
| | | <span v-if="pageInfo.medState === 3" style="color: #769aff;">已检查</span> |
| | | <span v-if="pageInfo.medState === 4" style="color: #769aff;">已归档</span> |
| | | </van-col> |
| | | <van-col span="8"> |
| | | <span style="color: #777;">上机:</span> |
| | | <span style="color: #769aff;">{{pageInfo.detailForPatientMedStartTime}}</span> |
| | | <span style="color: #769aff;">{{pageInfo.detailForPatientMedStartTime.substring(11,16)}}</span> |
| | | </van-col> |
| | | <van-col span="8"> |
| | | <span style="color: #777;">下机:</span> |
| | | <span style="color: #769aff;">{{pageInfo.detailForPatientMedEndTime}}</span> |
| | | <span style="color: #769aff;">{{pageInfo.detailForPatientMedEndTime.substring(11,16)}}</span> |
| | | </van-col> |
| | | </van-row> |
| | | <van-row class="lable"> |
| | |
| | | <van-row class="lable2"> |
| | | <van-col span="8"> |
| | | <span style="color: #777;">次数:</span> |
| | | <span style="color: #769aff;">{{pageInfo.detailForPatientMedCount}}</span> |
| | | <span style="color: #769aff;">{{pageInfo.historyCount}}</span> |
| | | </van-col> |
| | | <van-col span="8"> |
| | | <span style="color: #777;">本次费用:</span> |
| | |
| | | <script lang="ts" setup> |
| | | import {ref} from 'vue' |
| | | import {ajaxPost} from '@/utils/axios' |
| | | import { Calendar as vanCalendar } from 'vant' |
| | | import { Calendar as vanCalendar, Toast } from 'vant' |
| | | import {useRouter} from 'vue-router' |
| | | import { userInfoStore } from '@/stores/userInfo' |
| | | const userInfo = userInfoStore() |
| | |
| | | const d = day.getDate() |
| | | const x=selectDate.value.findIndex(e=>{return e.y===y&&e.m===m&&e.d===d}) |
| | | console.log(selectDate.value[x],'找到了') |
| | | getDetail(selectDate.value[x].id) |
| | | if (x===-1){ |
| | | |
| | | Toast('没有排班信息,请选择其他日期!') |
| | | } |
| | | else { |
| | | getDetail(selectDate.value[x].id) |
| | | } |
| | | |
| | | |
| | | } |
| | | const fanhui=()=>{ |
| | |
| | | } |
| | | const getDetail=(id:any)=>{ |
| | | loand.value=true |
| | | ajaxPost('/patient/hemo/med/record/detail',`id=${id}`).then((re:any)=>{ |
| | | ajaxPost('/patient/hemo/med/record/detailForMobile',`id=${id}`).then((re:any)=>{ |
| | | console.log(re) |
| | | pageInfo.value=re |
| | | loand.value=false |