dev
This commit is contained in:
parent
8b78c320b1
commit
6f8e68fa7a
|
|
@ -141,6 +141,7 @@ const statusList = ref([
|
|||
])
|
||||
const tab = (item: any) => {
|
||||
query.value.status = item.value
|
||||
curItem.value={}
|
||||
emit('getStatus', item.value)
|
||||
init()
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,15 +1,15 @@
|
|||
<template>
|
||||
<Mask :width="800" :height="438" :is-show="show">
|
||||
<!-- <el-card>-->
|
||||
<!-- <template #header>-->
|
||||
<Mask :width="800" :height="438" :is-show="show" @close="show = false" :show-footer="true">
|
||||
<!-- <el-card>-->
|
||||
<template #header>
|
||||
<div class="header">
|
||||
<span>收费</span>
|
||||
<CloseBtn @click="show = false" style="margin-top: 12px"></CloseBtn>
|
||||
</div>
|
||||
<!-- </template>-->
|
||||
</template>
|
||||
<div class="panel">
|
||||
<div class="price">¥{{ retailOrder.totalPrice }}</div>
|
||||
<div class="social" >
|
||||
<div class="social">
|
||||
<CardPay v-model="socialCard"/>
|
||||
</div>
|
||||
<div class="price-type">
|
||||
|
|
@ -22,17 +22,16 @@
|
|||
<div class="image" :style="{'background-color':item.color}">
|
||||
<img style="width: 16px;height: 16px;" :src="item.img" alt=""/>
|
||||
</div>
|
||||
<span>{{item.name}}</span>
|
||||
<span>{{ item.name }}</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- <template #footer>-->
|
||||
<template #footer>
|
||||
<div class="footer">
|
||||
<el-checkbox v-model="printReceipt">同时打印凭证</el-checkbox>
|
||||
<el-button @click="completeSettlement()" type="primary">完成收费</el-button>
|
||||
</div>
|
||||
<!-- </template>-->
|
||||
<!-- </el-card>-->
|
||||
</template>
|
||||
</Mask>
|
||||
<PersonalPayment ref="psnPaymentRef" @orderCompleted="orderCompleted" @orderCancel="orderCanceled"></PersonalPayment>
|
||||
</template>
|
||||
|
|
@ -48,15 +47,16 @@ import {medTypeJson, priceBtnList} from "@/assets/config/constants.ts"
|
|||
import {useWsStore} from "@/stores/wsStore.ts";
|
||||
import PersonalPayment from "@/components/charge/PersonalPayment.vue";
|
||||
import {ElMessage} from "element-plus";
|
||||
|
||||
const wsStore = useWsStore();
|
||||
const socialCard =defineModel<any>();
|
||||
const socialCard = defineModel<any>();
|
||||
|
||||
const show = ref(false)
|
||||
const printReceipt = ref(false);
|
||||
const payType = ref(null);
|
||||
const retailOrder = ref<any>(null);
|
||||
const init = (code: any) => {
|
||||
post ('charge/getByCode',{code:code}).then((res:any)=>{
|
||||
post('charge/getByCode', {code: code}).then((res: any) => {
|
||||
retailOrder.value = res;
|
||||
show.value = true;
|
||||
})
|
||||
|
|
@ -66,21 +66,21 @@ defineExpose({init})
|
|||
const changePriceType = (type: any) => {
|
||||
payType.value = type;
|
||||
}
|
||||
const emit = defineEmits(['orderComplete','orderCanceled'])
|
||||
const completeSettlement = ()=>{
|
||||
if (!retailOrder.value){
|
||||
const emit = defineEmits(['orderComplete', 'orderCanceled'])
|
||||
const completeSettlement = () => {
|
||||
if (!retailOrder.value) {
|
||||
return;
|
||||
}
|
||||
if (payType.value == null){
|
||||
if (payType.value == null) {
|
||||
return
|
||||
}
|
||||
if(payType.value == 1){
|
||||
if (payType.value == 1) {
|
||||
//医保结算
|
||||
console.log('医保结算',socialCard.value)
|
||||
console.log('医保结算', socialCard.value)
|
||||
socialSettlement();
|
||||
}else {
|
||||
} else {
|
||||
//其他结算
|
||||
post('charge/completeOrder',{id:retailOrder.value.id,payType:payType.value}).then((res:any)=>{
|
||||
post('charge/completeOrder', {id: retailOrder.value.id, payType: payType.value}).then((res: any) => {
|
||||
orderCompleted()
|
||||
})
|
||||
}
|
||||
|
|
@ -88,18 +88,18 @@ const completeSettlement = ()=>{
|
|||
}
|
||||
|
||||
|
||||
const orderCompleted = ()=>{
|
||||
const orderCompleted = () => {
|
||||
show.value = false;
|
||||
ElMessage.success("保存成功")
|
||||
emit('orderComplete',printReceipt.value)
|
||||
emit('orderComplete', printReceipt.value)
|
||||
}
|
||||
const orderCanceled = ()=>{
|
||||
const orderCanceled = () => {
|
||||
show.value = false;
|
||||
emit('orderCanceled')
|
||||
}
|
||||
|
||||
const getBalcByInsutype = (type:any) =>{
|
||||
let balc =0;
|
||||
const getBalcByInsutype = (type: any) => {
|
||||
let balc = 0;
|
||||
for (const item of socialCard.value.data.insuinfo) {
|
||||
if (item.insutype == type) {
|
||||
balc = item.balc;
|
||||
|
|
@ -109,27 +109,26 @@ const getBalcByInsutype = (type:any) =>{
|
|||
return balc
|
||||
}
|
||||
|
||||
const socialSettlement = ()=>{
|
||||
const socialSettlement = () => {
|
||||
const params = {
|
||||
mdtrtCertType: socialCard.value.mdtrtCertType,
|
||||
mdtrtCertNo: socialCard.value.mdtrtCertNo,
|
||||
insutype: socialCard.value.payInfo.selfpay_prop_type,
|
||||
changeOrderCode:retailOrder.value.code,
|
||||
changeOrderCode: retailOrder.value.code,
|
||||
}
|
||||
post("charge/uploadCostDetails",{changeOrderCode:retailOrder.value.code}).then((res:any)=>{
|
||||
post("charge/uploadCostDetails", {changeOrderCode: retailOrder.value.code}).then((res: any) => {
|
||||
//预结算
|
||||
post("charge/socialPrePay",{...params}).then((res:any)=>{
|
||||
openPsnPayment(res,params)
|
||||
post("charge/socialPrePay", {...params}).then((res: any) => {
|
||||
openPsnPayment(res, params)
|
||||
})
|
||||
})
|
||||
|
||||
|
||||
|
||||
}
|
||||
const psnPaymentRef = ref();
|
||||
const openPsnPayment = (payInfo:any,orderInfo:any)=>{
|
||||
nextTick(()=>{
|
||||
psnPaymentRef.value?.open(payInfo,orderInfo);
|
||||
const openPsnPayment = (payInfo: any, orderInfo: any) => {
|
||||
nextTick(() => {
|
||||
psnPaymentRef.value?.open(payInfo, orderInfo);
|
||||
})
|
||||
|
||||
}
|
||||
|
|
@ -137,22 +136,23 @@ const openPsnPayment = (payInfo:any,orderInfo:any)=>{
|
|||
</script>
|
||||
|
||||
|
||||
|
||||
<style scoped lang="scss">
|
||||
.panel {
|
||||
.price{
|
||||
.price {
|
||||
height: 50px;
|
||||
text-align: center;
|
||||
font-size: 25px;
|
||||
font-weight: 600;
|
||||
color: rgba(237, 120, 23, 0.8);
|
||||
}
|
||||
|
||||
.price-type {
|
||||
display: flex;
|
||||
margin-top: 20px;
|
||||
justify-content: space-between;
|
||||
flex-wrap: wrap;
|
||||
align-items: center;
|
||||
|
||||
.btn {
|
||||
height: 45px;
|
||||
width: 95px;
|
||||
|
|
@ -165,7 +165,8 @@ const openPsnPayment = (payInfo:any,orderInfo:any)=>{
|
|||
align-items: center;
|
||||
padding: 10px;
|
||||
cursor: pointer;
|
||||
.image{
|
||||
|
||||
.image {
|
||||
width: 16px;
|
||||
height: 16px;
|
||||
margin-right: 3px;
|
||||
|
|
@ -190,7 +191,8 @@ const openPsnPayment = (payInfo:any,orderInfo:any)=>{
|
|||
|
||||
}
|
||||
}
|
||||
.footer{
|
||||
|
||||
.footer {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -19,7 +19,7 @@ const editItem= () => {
|
|||
<Panel :showTools="false" :showHeader="false">
|
||||
<div class="footer">
|
||||
<div>总金额:<span class="text icon">¥</span><span class="text">{{ totalAmount || '0' }}</span></div>
|
||||
<div class="btn-group" v-if="status == 0">
|
||||
<div class="btn-group" v-if="status">
|
||||
<el-button type="primary" disabled>追溯码</el-button>
|
||||
<el-button type="primary" @click="editItem">收费</el-button>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -30,7 +30,7 @@
|
|||
@change="handleChange"
|
||||
clearable
|
||||
style="width: 100%"
|
||||
:disabled="statusDisabled == 1"
|
||||
:disabled="formData.status == 1"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in doctorList"
|
||||
|
|
@ -46,15 +46,15 @@
|
|||
</Panel>
|
||||
</div>
|
||||
<div style="margin-top: 24px">
|
||||
<ServiceDetail v-model="formData.itemDetail" :status="statusDisabled == 0"
|
||||
<ServiceDetail v-model="formData.itemDetail" :status="formData.status == 0"
|
||||
@totalPriceChange="getOrderTotalPrice"></ServiceDetail>
|
||||
</div>
|
||||
<div style="margin-top: 24px">
|
||||
<GoodsDetail v-model="formData.goodsDetail" :status="statusDisabled == 0"
|
||||
<GoodsDetail v-model="formData.goodsDetail" :status="formData.status == 0"
|
||||
@totalPriceChange="getOrderTotalPrice"></GoodsDetail>
|
||||
</div>
|
||||
<div class="bottom">
|
||||
<TotalPrice v-model="formData.totalPrice" @edit="saveAndCharge" :status="statusDisabled==1"></TotalPrice>
|
||||
<TotalPrice v-model="formData.totalPrice" @edit="saveAndCharge" :status="!(statusDisabled)&&formData.status==0"></TotalPrice>
|
||||
</div>
|
||||
</el-scrollbar>
|
||||
</div>
|
||||
|
|
@ -207,7 +207,14 @@ const list = () => {
|
|||
})
|
||||
}
|
||||
const getStatus=(status:any)=>{
|
||||
statusDisabled.value = status
|
||||
console.log(111)
|
||||
formData.value = {
|
||||
patientInfo: {},
|
||||
diagnosisMedicalRecord: {},
|
||||
goodsDetail: [],
|
||||
itemDetail: [],
|
||||
patientRegistration: {}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue