初始化仓库

This commit is contained in:
2024-09-19 12:57:55 +08:00
commit ddac24aa35
228 changed files with 34703 additions and 0 deletions

View File

@@ -0,0 +1,432 @@
<template>
<view class="safe-area-inset-bottom">
<!-- 状态 -->
<view class="states_"
:class="infoList.status==1&&'bg_blue'||infoList.status==2&&'bg_green'||infoList.status==3&&'bg_plus'||infoList.status==7&&'bg_red'">
<text>{{infoList.status==1&&'待接诊'||infoList.status==2&&'已接诊'||infoList.status==3&&'已完成'||infoList.status==7&&'已拒诊'}}</text>
<image
:src="infoList.status==1&&'/static/info/djz.png'||infoList.status==2&&'/static/info/yjz.png'||infoList.status==3&&'/static/info/ywc.png'||infoList.status==7&&'/static/info/jz.png'"
mode=""></image>
</view>
<!-- 信息 -->
<view class="card">
<view class="title">
就诊人
</view>
<view class="info">
<view class="info_title">
</view>
<text>{{infoList.patient.name}}</text>
</view>
<view class="info">
<view class="info_title">
</view>
<text>{{infoList.patient.sex%2==0?'女':'男'}}</text>
</view>
<view class="info">
<view class="info_title">
:
</view>
<text>{{infoList.patient.age}}</text>
</view>
<view class="info">
<view class="info_title">
</view>
<text>{{infoList.patient.mobile}}</text>
</view>
<view class="info">
<view class="info_title">
身份证号
</view>
<text>{{infoList.patient.id_card}}</text>
</view>
</view>
<view class="card">
<view class="title">
挂号信息
</view>
<view class="info">
<view class="info_title">
就诊时间
</view>
<text>{{ $u.timeFormat(infoList.created_at, 'yyyy-mm-dd')}}</text>
</view>
<view class="info">
<view class="info_title">
就诊诊所
</view>
<text>{{ infoList.store.name}}</text>
</view>
<view class="info">
<view class="info_title">
</view>
<text>{{infoList.depart.name}}</text>
</view>
<view class="info">
<view class="info_title">
</view>
<text>{{infoList.doctor.name}}</text>
</view>
<view class="info">
<view class="info_title">
挂号费用
</view>
<text>{{infoList.price}}</text>
</view>
<view class="info">
<view class="info_title">
挂号单号
</view>
<text>{{infoList.order_no}}</text>
</view>
</view>
<view class="card">
<view class="title">
健康信息
</view>
<view class="info">
<view class="info_title">
既往史
</view>
<text>{{infoList.healthInquery.person_status==0?'无':infoList.healthInquery.person_history}}</text>
</view>
<view class="info">
<view class="info_title">
过敏史
</view>
<text>{{infoList.healthInquery.allergic_status==0?'无':infoList.healthInquery.allergic_history}}</text>
</view>
<view class="info">
<view class="info_title">
家族遗传史
</view>
<text>{{infoList.healthInquery.family_status==0?'无':infoList.healthInquery.family_history}}</text>
</view>
<view class="info">
<view class="info_title">
肝功能异常
</view>
<text>{{infoList.healthInquery.liver_function==0?'正常':'异常'}}</text>
</view>
<view class="info">
<view class="info_title">
肾功能异常
</view>
<text>{{infoList.healthInquery.renal_function==0?'正常':'异常'}}</text>
</view>
</view>
<view class="card">
<view class="title">
{{ infoList.status==7&&'拒诊原因' ||'处方信息'}}
</view>
<!-- 处方编号 -->
<view class="info_" v-if="infoList.prescription.length>0" v-for="item in infoList.prescription"
:key="item.id">
<view class="cf_">
<view class="info_title">
处方编号
</view>
<text>{{item.prescription_no}}</text>
</view>
<!-- @click="$go('/pages/my/prescriptionDetail?id=' +item.id)" -->
<view class="cf_btn" @click="$go('/pages/my/prescriptionDetail?id=' +item.id)">
查看处方
</view>
</view>
<view class="info" v-if="infoList.status==7">
<view class="info_title">
</view>
<text>{{infoList.refuse_reason}}</text>
</view>
<view class="info" v-if="infoList.status==7">
<view class="info_title">
拒诊时间
</view>
<text>{{$u.timeFormat(infoList.updated_at, 'yyyy-mm-dd')}}</text>
</view>
<!-- 该患者并未开处方 -->
<view class="info" v-if="infoList.status!=7&&infoList.prescription.length==0">
该患者并未开处方
</view>
</view>
<u-modal v-model="show" title="操作提示" :show-cancel-button="true" :content="content" @confirm="confirm"
confirm-color="#6ACDBB"></u-modal>
<view class="empty"></view>
<d-loading-page :loading="loading"></d-loading-page>
<view class="fun" v-if="flag&&infoList.status!=3">
<u-button v-if="infoList.status==1" @click="$go('workbench_reason?id='+infoList.id)" shape="circle"
:custom-style="{
heigth: '86rpx',
width: '327rpx',
backgroundColor: 'transparent !important',
backgroundColor:'#fff',color:'#6ACDBB',marginRight:'20rpx'
}" plain :ripple="true">拒绝
</u-button>
<u-button v-if="infoList.status==1" @click="accept(infoList.id,infoList.user_patient_id)" shape="circle"
:custom-style="{ heigth: '86rpx', width: '327rpx',backgroundColor:'#6ACDBB',color:'#fff' }">接诊
</u-button>
<u-button v-if="infoList.status==2" @click="acceptEnds(infoList.id,infoList.user_patient_id)" shape="circle"
:custom-style="{ heigth: '86rpx', width: '327rpx', backgroundColor: 'transparent !important', backgroundColor:'#fff',border:'1rpx solid #6ACDBB',color:'#6ACDBB',marginRight:'20rpx'}"
plain :ripple="true">结束问诊
</u-button>
<u-button v-if="infoList.status==2"
@click="$go(`../../subPackages/sub_workbench/workbench_recipe/index?id=` + infoList.user_patient_id+'&r_id='+infoList.id)"
shape="circle"
:custom-style="{ heigth: '86rpx', width: '327rpx',backgroundColor:'#6ACDBB',color:'#fff' }">开处方
</u-button>
</view>
</view>
</template>
<script>
import {
storePatientInfo,
storePatientRefuse,
accessEnd
} from '@/api/consult.js'
export default {
data() {
return {
flag: true,
item: {},
status: "loading",
infoList: [],
loading: true,
id: "",
re_id: "",
show: false,
content: '确认结束本次问诊吗?'
};
},
computed: {
},
created() {
this.getList();
},
onLoad(op) {
this.id = op["id"]
this.re_id = op['re_id']
this.getList();
},
methods: {
// 接诊
accept(e, id) {
storePatientRefuse({
store_id: uni.getStorageSync('store_id') || '11001',
status: 1,
register_id: e
}).then((res) => {
// console.log(res, "12");
if (res.errcode === 0) {
this.$toast('已接诊');
this.getList()
setTimeout(() => {
this.$go(`../../subPackages/sub_workbench/workbench_recipe/index?r_id=` + e +
'&id=' + id);
}, 800)
} else {
this.$toast(res.msg);
}
})
},
// 结束问诊
acceptEnds(e) {
uni.setStorageSync('register_id_', e)
this.show = true;
},
confirm() {
accessEnd({
store_id: uni.getStorageSync('store_id') || '11001',
register_id: uni.getStorageSync('register_id_')
}).then((res) => {
// console.log(res, "12");
if (res.errcode === 0) {
this.$toast('已结束问诊');
setTimeout(() => {
this.getList()
}, 1000)
} else {
this.$toast(res.msg);
}
})
},
// 信息
getList() {
storePatientInfo({
patient_id: this.id,
register_id: this.re_id,
store_id: uni.getStorageSync('store_id') || '11001'
}).then((res) => {
if (res.errcode == 0) {
this.loading = false;
this.infoList = res.data
}
});
},
},
onShow() {
this.getList();
}
};
</script>
<style>
page {
background-color: #eeeeef;
}
</style>
<style lang="scss" scoped>
view {
position: relative;
}
.bg_blue {
background: #2979FF;
}
.bg_green {
background: #6ACDBB;
}
.bg_plus {
background: #8178FF;
}
.bg_red {
background: #F44437;
}
.states_ {
width: 750rpx;
height: 84rpx;
display: flex;
align-items: center;
justify-content: space-between;
color: #fff;
font-size: 28rpx;
font-family: PingFang SC-Bold, PingFang SC;
font-weight: bold;
color: #FFFFFF;
padding: 0 42rpx;
image {
width: 36rpx;
height: 36rpx;
}
}
.card {
width: 750rpx;
padding: 20rpx 42rpx;
background: #FFFFFF;
margin: 20rpx auto;
.title {
height: 64rpx;
font-size: 32rpx;
font-family: PingFang SC-Bold, PingFang SC;
font-weight: 600;
color: #333333;
line-height: 64rpx;
letter-spacing: 4px;
}
.info {
display: flex;
align-items: center;
flex-wrap: wrap;
.info_title {
width: 188rpx;
height: 60rpx;
font-size: 28rpx;
font-family: PingFang SC-Bold, PingFang SC;
font-weight: 400;
color: #232323;
line-height: 60rpx;
}
text {
font-size: 28rpx;
font-family: PingFang SC-Regular, PingFang SC;
font-weight: 400;
color: #666666;
margin-left: 10rpx;
flex: 1;
}
}
.info_ {
display: flex;
justify-content: space-between;
align-items: center;
flex-wrap: wrap;
.cf_ {
display: flex;
align-items: center;
.info_title {
height: 60rpx;
font-size: 28rpx;
font-family: PingFang SC-Bold, PingFang SC;
font-weight: 400;
color: #232323;
line-height: 60rpx;
}
text {
font-size: 28rpx;
font-family: PingFang SC-Regular, PingFang SC;
font-weight: 400;
color: #666666;
margin-left: 10rpx;
flex: 1;
}
}
.cf_btn {
color: #4175EE;
}
}
}
.empty {
height: 80rpx;
margin-bottom: 30rpx;
}
.fun {
position: fixed;
left: 0;
z-index: 99;
width: 750rpx;
background-color: #fff;
padding: 12rpx 32rpx;
display: flex;
flex-direction: row;
justify-content: flex-end;
text-align: center;
bottom: env(safe-area-inset-bottom);
}
</style>