This commit is contained in:
ChenQiuYu 2025-05-15 09:33:00 +08:00
parent 2814cc4da7
commit acb47d04ce
2 changed files with 188 additions and 169 deletions

View File

@ -53,10 +53,11 @@
<GoodsDetail v-model="formData.goodsDetail" :status="formData.status == 0" <GoodsDetail v-model="formData.goodsDetail" :status="formData.status == 0"
@totalPriceChange="getOrderTotalPrice" :statusDisabled="statusDisabled==1"></GoodsDetail> @totalPriceChange="getOrderTotalPrice" :statusDisabled="statusDisabled==1"></GoodsDetail>
</div> </div>
<div class="bottom">
<TotalPrice v-model="formData.totalPrice" @save="charge" :status="formData.status ==0" @openSettlement="charge" @openCheckOut ="openCheckoutDetail(formData.goodsDetail,formData.patientRegistration.psnNo)"></TotalPrice>
</div>
</el-scrollbar> </el-scrollbar>
<div class="bottom">
<TotalPrice v-model="formData.totalPrice" @save="charge" :status="formData.status ==0" @openSettlement="charge"
@openCheckOut="openCheckoutDetail(formData.goodsDetail,formData.patientRegistration.psnNo)"></TotalPrice>
</div>
</div> </div>
<div class="right"> <div class="right">
<div class="top"> <div class="top">
@ -67,7 +68,7 @@
</div> </div>
</div> </div>
</div> </div>
<CheckoutDetail ref="checkoutDetailRef" @confirm ="saveAndCharge"></CheckoutDetail> <CheckoutDetail ref="checkoutDetailRef" @confirm="saveAndCharge"></CheckoutDetail>
<Settlement <Settlement
ref="settlementRef" ref="settlementRef"
@orderCompleted="orderCompleted" @orderCompleted="orderCompleted"
@ -117,7 +118,7 @@ const charge = () => {
saveAndCharge() saveAndCharge()
} else { } else {
// //
openCheckoutDetail(formData.value.goodsDetail,formData.value.patientRegistration.psnNo) openCheckoutDetail(formData.value.goodsDetail, formData.value.patientRegistration.psnNo)
} }
} }
@ -137,89 +138,89 @@ const checkTraceCode = (goodsList: any[]) => {
return true; return true;
} }
const checkoutDetailRef = ref() const checkoutDetailRef = ref()
const openCheckoutDetail = (goodsList: any[],psnNo:string) => { const openCheckoutDetail = (goodsList: any[], psnNo: string) => {
if (!goodsList || goodsList.length == 0) { if (!goodsList || goodsList.length == 0) {
ElMessage({ ElMessage({
message: '没有商品信息,请先选择需要售卖的商品', message: '没有商品信息,请先选择需要售卖的商品',
type: 'info', type: 'info',
plain: true, plain: true,
}); });
return return
} }
nextTick(() => {
checkoutDetailRef.value.init(goodsList, psnNo);
})
}
const saveAndCharge = () => {
post('charge/save', {data: {...formData.value, doctorId: doctorId.value}}).then((res: any) => {
formData.value.code = res
nextTick(() => { nextTick(() => {
checkoutDetailRef.value.init(goodsList,psnNo); settlementRef.value?.init(res, formData.value.patientRegistration.psnNo)
}) })
})
}
const diagnosisSearchRef = ref()
const diagnosisSearchApi = "social/diagnose/search"
const diagnosisShowConfig = [
{
label: "诊断名称",
prop: "name",
},
{
label: "诊断编码",
prop: "code",
}
]
const diagnosisSelect = (list: any) => {
const diagnosisNames = list.map((item: any) => item.name).join(',')
formData.value.diagnosisMedicalRecord.diagnosisDetail = JSON.stringify(list)
formData.value.diagnosisMedicalRecord.diagnosisSummary = diagnosisNames
}
const recordsConsumptionRef = ref<any>("")
const patientCardRef = ref()
const clickItem = async (item: any, status: any) => {
statusDisabled.value = status
formData.value = await post('medical/record/getByDiagnosisCode', {diagnosisCode: item.code})
//
for (let i = 0; i < formData.value.goodsDetail.length; i++) {
let goodsItem = formData.value.goodsDetail[i]
if (goodsItem.packagingUnit == goodsItem.selectedUnit) {
goodsItem.shouldNumber = goodsItem.selectedNum;
} else {
goodsItem.shouldNumber = Math.ceil(goodsItem.selectedNum / goodsItem.minPackagingNumber);
}
goodsItem.idCode = goodsItem.idCode ? goodsItem.idCode == "" ? null : goodsItem.idCode.split(",") : null
} }
const saveAndCharge = () => { getOrderTotalPrice()
post('charge/save', {data: {...formData.value, doctorId: doctorId.value}}).then((res: any) => { nextTick(() => {
formData.value.code = res let list = JSON.parse(formData.value.diagnosisMedicalRecord.diagnosisDetail)
nextTick(() => { let nList = formData.value.diagnosisMedicalRecord.diagnosisSummary.split(',')
settlementRef.value?.init(res, formData.value.patientRegistration.psnNo) diagnosisSearchRef.value?.init(list, nList);
}) recordsConsumptionRef.value?.init(formData.value.patientInfo.id);
}) patientCardRef.value?.init(formData.value.registrationId);
})
}
const dockerList = ref<any[]>([])
const getDockerList = () => {
let query = {
role: 1
} }
const diagnosisSearchRef = ref() post('organization/member/search', {query: query}).then((res: any) => {
const diagnosisSearchApi = "social/diagnose/search" dockerList.value = res
const diagnosisShowConfig = [ })
{ }
label: "诊断名称", const orderCompleted = () => {
prop: "name", nextTick(() => {
}, chargeQueueRef.value?.getOrderList()
{ })
label: "诊断编码", }
prop: "code", const orderCanceled = () => {
} nextTick(() => {
] chargeQueueRef.value?.getOrderList()
const diagnosisSelect = (list: any) => { })
const diagnosisNames = list.map((item: any) => item.name).join(',')
formData.value.diagnosisMedicalRecord.diagnosisDetail = JSON.stringify(list)
formData.value.diagnosisMedicalRecord.diagnosisSummary = diagnosisNames
}
const recordsConsumptionRef = ref<any>("")
const patientCardRef = ref()
const clickItem = async (item: any, status: any) => {
statusDisabled.value = status
formData.value = await post('medical/record/getByDiagnosisCode', {diagnosisCode: item.code})
//
for (let i =0;i<formData.value.goodsDetail.length;i++){
let goodsItem =formData.value.goodsDetail[i]
if (goodsItem.packagingUnit == goodsItem.selectedUnit){
goodsItem.shouldNumber = goodsItem.selectedNum;
}else {
goodsItem.shouldNumber = Math.ceil(goodsItem.selectedNum / goodsItem.minPackagingNumber);
}
goodsItem.idCode = goodsItem.idCode?goodsItem.idCode==""?null:goodsItem.idCode.split(","):null
}
getOrderTotalPrice()
nextTick(() => {
let list = JSON.parse(formData.value.diagnosisMedicalRecord.diagnosisDetail)
let nList = formData.value.diagnosisMedicalRecord.diagnosisSummary.split(',')
diagnosisSearchRef.value?.init(list, nList);
recordsConsumptionRef.value?.init(formData.value.patientInfo.id);
patientCardRef.value?.init(formData.value.registrationId);
})
}
const dockerList = ref<any[]>([])
const getDockerList = () => {
let query = {
role: 1
}
post('organization/member/search', {query: query}).then((res: any) => {
dockerList.value = res
})
}
const orderCompleted = () => {
nextTick(() => {
chargeQueueRef.value?.getOrderList()
})
}
const orderCanceled = () => {
nextTick(() => {
chargeQueueRef.value?.getOrderList()
})
} }
@ -260,7 +261,7 @@ const list = () => {
doctorList.value = res doctorList.value = res
}) })
} }
const getStatus=(status:any)=>{ const getStatus = (status: any) => {
statusDisabled.value = status statusDisabled.value = status
formData.value = { formData.value = {
patientInfo: {}, patientInfo: {},

View File

@ -9,31 +9,34 @@
</div> </div>
<div class="left-bottom"> <div class="left-bottom">
<Panel title="医生列表"> <Panel title="医生列表">
<div class="search" style="padding: 0 24px ;height: 42px"> <div class="panel-content" style="display: flex;flex-direction: column;height: 100%">
<el-input style="height: 100%" v-model="keyword" placeholder="搜索医生姓名" <div class="search">
@keydown.enter="initDoctor" :prefix-icon="Search"></el-input> <el-input style="height: 100%" v-model="keyword" placeholder="搜索医生姓名"
</div> @keydown.enter="initDoctor" :prefix-icon="Search"></el-input>
<div class="content_list" style="padding: 0 24px"> </div>
<div class="role_list"> <div class="content_list" style="padding: 0 24px">
<ul> <ul class="role_list">
<li v-for="(item, index) in roleList" :key="index" <el-scrollbar style="height: 100%">
:class="{active:isShowNum==index}"> <li v-for="(item, index) in roleList" :key="index"
<span class="name">{{ item.name }}</span> :class="{active:isShowNum==index}">
<span class="section_name">{{ item.sectionNames }}</span> <span class="name">{{ item.name }}</span>
<span class="btn" @click="openDialog(item,index)" <span class="section_name">{{ item.sectionNames }}</span>
@mouseover="isShowNum = index" <span class="btn" @click="openDialog(item,index)"
@mouseleave="isShowNum = -1"> @mouseover="isShowNum = index"
<img v-if="isShowNum==index" src="/static/images/registration/3-active.png" style="width: 15px;height: 14px;margin-right: 8px" alt=""> @mouseleave="isShowNum = -1">
<img v-else src="/static/images/registration/3.png" alt="" style="width: 15px;height: 14px;margin-right: 8px"> <img v-if="isShowNum==index" src="/static/images/registration/3-active.png"
style="width: 15px;height: 14px;margin-right: 8px" alt="">
<img v-else src="/static/images/registration/3.png" alt=""
style="width: 15px;height: 14px;margin-right: 8px">
挂号 挂号
</span> </span>
</li> </li>
</el-scrollbar>
</ul> </ul>
</div> </div>
</div> </div>
</Panel> </Panel>
</div> </div>
</div> </div>
<div class="right"> <div class="right">
<Panel title="挂号列表"> <Panel title="挂号列表">
@ -151,8 +154,8 @@ const close = () => {
id.value = null id.value = null
getPatientList() getPatientList()
} }
const reset=() =>{ const reset = () => {
keyword.value='' keyword.value = ''
getPatientList() getPatientList()
} }
</script> </script>
@ -183,76 +186,91 @@ const reset=() =>{
flex: 1; flex: 1;
min-height: 0; min-height: 0;
margin-top: 20px; margin-top: 20px;
}
li { .panel-content {
height: 50px;
display: flex;
font-size: 14px;
padding: 0 10px;
border-radius: 5px;
align-items: center;
&:hover {
background: rgba(#4D6DE4, 0.3);
}
.name {
color: #999;
width: 100px;
}
.section_name {
flex: 1;
color: #999;
}
.btn {
cursor: pointer;
padding: 5px;
width: 78px;
height: 32px;
border-radius: 6px;
background: #FFFFFF;
border: 1px solid #4D6DE4;
font-weight: bold;
font-size: 14px;
color: #4D6DE4;
font-style: normal;
display: flex; display: flex;
align-items: center; flex-direction: column;
justify-content: center;
&:hover { .search {
background: #4D6DE4; padding: 0 24px;
color: #FFF; height: 42px;
margin-top: 10px;
}
.content_list {
flex: 1;
min-height: 0;
margin-top: 10px;
.role_list {
height: 100%;
li {
height: 50px;
display: flex;
font-size: 14px;
padding: 0 10px;
border-radius: 5px;
align-items: center;
&:hover {
background: rgba(#4D6DE4, 0.3);
}
.name {
color: #999;
width: 100px;
}
.section_name {
flex: 1;
color: #999;
}
.btn {
cursor: pointer;
padding: 5px;
width: 78px;
height: 32px;
border-radius: 6px;
background: #FFFFFF;
border: 1px solid #4D6DE4;
font-weight: bold;
font-size: 14px;
color: #4D6DE4;
font-style: normal;
display: flex;
align-items: center;
justify-content: center;
&:hover {
background: #4D6DE4;
color: #FFF;
}
}
}
.active {
background: #4D6DE4;
.name {
color: #fff;
}
.section_name {
color: #fff;
}
.btn {
color: #fff;
}
}
}
} }
} }
}
.search {
margin-top: 10px;
}
.content_list {
margin-top: 10px;
}
.active {
background: #4D6DE4;
.name {
color: #fff;
}
.section_name {
color: #fff;
}
.btn {
color: #fff;
}
} }
} }