dev
This commit is contained in:
parent
cbcec95d0c
commit
c5cdd9af01
|
|
@ -1,10 +1,6 @@
|
|||
<template>
|
||||
<Mask :top="50" :height="650" :width="900" :is-show="show">
|
||||
<CloseBtn @click="show = false"></CloseBtn>
|
||||
<Mask :top="50" :height="650" :width="900" :is-show="show" title="追溯码采集" @close="show = false" :show-footer="true">
|
||||
<el-card>
|
||||
<template #header>
|
||||
<div class="header">追溯码采集</div>
|
||||
</template>
|
||||
<div class="detail">
|
||||
<el-input placeholder="请输入追溯码" v-model="inputIdCode" clearable @keydown.enter="openAssociationIdCode()">
|
||||
<template #prefix>
|
||||
|
|
@ -44,13 +40,13 @@
|
|||
</div>
|
||||
|
||||
</div>
|
||||
<template #footer>
|
||||
<div class="bottom-btn">
|
||||
<el-button @click="saveRetail()" type="primary">确定</el-button>
|
||||
<el-button @click="show = false">关闭</el-button>
|
||||
</div>
|
||||
</template>
|
||||
</el-card>
|
||||
<template #footer>
|
||||
<div class="bottom-btn">
|
||||
<el-button @click="saveRetail()" type="primary">确定</el-button>
|
||||
<el-button @click="show = false">关闭</el-button>
|
||||
</div>
|
||||
</template>
|
||||
<AssociationIdCode
|
||||
ref="associationIdCodeRef"
|
||||
@addIdCode="cleanInputIdCode"
|
||||
|
|
@ -58,7 +54,7 @@
|
|||
</Mask>
|
||||
</template>
|
||||
<script setup lang="ts">
|
||||
import Mask from "@/components/Mask.vue";
|
||||
import Mask from "@/components/common/Mask.vue";
|
||||
import CloseBtn from "@/components/CloseBtn.vue";
|
||||
import {nextTick, ref} from "vue";
|
||||
import IdCodeListShow from "@/components/charge/IdCodeListShow.vue";
|
||||
|
|
|
|||
|
|
@ -1,44 +1,42 @@
|
|||
<template>
|
||||
<Mask :is-show="show" :width=500 :height="500">
|
||||
<div class="container-wrapper">
|
||||
<CloseBtn @click="show = false"></CloseBtn>
|
||||
<div class="header">
|
||||
个人现金部分
|
||||
</div>
|
||||
<div class="container">
|
||||
<div>
|
||||
总金额:{{socialPayInfo.setlinfo.medfee_sumamt}}<br>
|
||||
基金支付金额:{{socialPayInfo.setlinfo.fund_pay_sumamt}}<br>
|
||||
个人医保支付金额:{{socialPayInfo.setlinfo.acct_pay}}<br>
|
||||
个人现金支付金额:{{socialPayInfo.setlinfo.psn_cash_pay}}<br>
|
||||
</div>
|
||||
<div class="price-type" v-if="socialPayInfo.setlinfo.psn_cash_pay>0">
|
||||
<div
|
||||
class="price-type-item"
|
||||
:class="['btn',payType==item.type?'active':'']"
|
||||
v-for="(item,index) in priceBtnListNoSocial"
|
||||
@click="changePriceType(item.type)"
|
||||
>
|
||||
<div class="image" :style="{'background-color':item.color}">
|
||||
<img style="width: 16px;height: 16px;" :src="item.img" alt=""/>
|
||||
</div>
|
||||
<span>{{item.name}}</span>
|
||||
<Mask :is-show="show" :width=500 :height="500" title="个人现金部分" @close="show=false" :show-footer="true">
|
||||
<div class="container-wrapper">
|
||||
<div class="container">
|
||||
<div>
|
||||
总金额:{{ socialPayInfo.setlinfo.medfee_sumamt }}<br>
|
||||
基金支付金额:{{ socialPayInfo.setlinfo.fund_pay_sumamt }}<br>
|
||||
个人医保支付金额:{{ socialPayInfo.setlinfo.acct_pay }}<br>
|
||||
个人现金支付金额:{{ socialPayInfo.setlinfo.psn_cash_pay }}<br>
|
||||
</div>
|
||||
<el-input v-model="cash" placeholder="请输入收到现金的数量"></el-input>
|
||||
<div class="price-type" v-if="socialPayInfo.setlinfo.psn_cash_pay>0">
|
||||
<div
|
||||
class="price-type-item"
|
||||
:class="['btn',payType==item.type?'active':'']"
|
||||
v-for="(item,index) in priceBtnListNoSocial"
|
||||
@click="changePriceType(item.type)"
|
||||
>
|
||||
<div class="image" :style="{'background-color':item.color}">
|
||||
<img style="width: 16px;height: 16px;" :src="item.img" alt=""/>
|
||||
</div>
|
||||
<span>{{ item.name }}</span>
|
||||
</div>
|
||||
<el-input v-model="cash" placeholder="请输入收到现金的数量"></el-input>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<el-button type="primary" @click="completeSettlement">完成订单</el-button>
|
||||
<el-button @click="cecalOrder">取消订单</el-button>
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
</Mask>
|
||||
<template #footer>
|
||||
<div class="bottom">
|
||||
<el-button type="primary" @click="completeSettlement">完成订单</el-button>
|
||||
<el-button @click="cecalOrder">取消订单</el-button>
|
||||
</div>
|
||||
</template>
|
||||
</Mask>
|
||||
</template>
|
||||
<script setup lang="ts">
|
||||
|
||||
import Mask from "@/components/Mask.vue";
|
||||
import Mask from "@/components/common/Mask.vue";
|
||||
import {nextTick, ref} from "vue";
|
||||
import {priceBtnListNoSocial} from "@/assets/config/constants.ts";
|
||||
import CloseBtn from "@/components/CloseBtn.vue";
|
||||
|
|
@ -53,16 +51,16 @@ const changePriceType = (type: any) => {
|
|||
}
|
||||
const orderInfo = ref<any>(null)
|
||||
const show = ref(false)
|
||||
const open = (payInfo:any,order:any)=>{
|
||||
const open = (payInfo: any, order: any) => {
|
||||
show.value = true
|
||||
socialPayInfo.value = payInfo;
|
||||
orderInfo.value = order;
|
||||
}
|
||||
|
||||
const cash = ref<number>(0)
|
||||
const emit = defineEmits(["orderCompleted","orderCancel"])
|
||||
const completeSettlement = ()=>{
|
||||
if (cash.value != socialPayInfo.value.setlinfo.psn_cash_pay){
|
||||
const emit = defineEmits(["orderCompleted", "orderCancel"])
|
||||
const completeSettlement = () => {
|
||||
if (cash.value != socialPayInfo.value.setlinfo.psn_cash_pay) {
|
||||
ElMessage({
|
||||
message: '现金支付金额与实际收款金额不一致',
|
||||
type: 'warning',
|
||||
|
|
@ -73,19 +71,16 @@ const completeSettlement = ()=>{
|
|||
mdtrtCertType: orderInfo.value.mdtrtCertType,
|
||||
mdtrtCertNo: orderInfo.value.mdtrtCertNo,
|
||||
insutype: orderInfo.value.insutype,
|
||||
changeOrderCode:orderInfo.value.changeOrderCode,
|
||||
changeOrderCode: orderInfo.value.changeOrderCode,
|
||||
}
|
||||
|
||||
post("charge/socialRealPay",{...params}).then((res:any)=>{
|
||||
post("charge/socialRealPay", {...params}).then((res: any) => {
|
||||
show.value = false;
|
||||
emit('orderCompleted')
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
const cecalOrder = ()=>{
|
||||
const cecalOrder = () => {
|
||||
ElMessageBox.confirm(
|
||||
`取消后不能恢复,是否确定取消当前订单?`,
|
||||
'Warning',
|
||||
|
|
@ -95,7 +90,7 @@ const cecalOrder = ()=>{
|
|||
type: 'warning',
|
||||
}
|
||||
).then(() => {
|
||||
post("retail/cancelOrder",{orderId:orderInfo.value.orderId}).then((res:any)=>{
|
||||
post("retail/cancelOrder", {orderId: orderInfo.value.orderId}).then((res: any) => {
|
||||
show.value = false;
|
||||
emit('orderCancel')
|
||||
})
|
||||
|
|
@ -106,16 +101,16 @@ const cecalOrder = ()=>{
|
|||
defineExpose({open})
|
||||
|
||||
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);
|
||||
})
|
||||
|
||||
}
|
||||
const orderCompleted = ()=>{
|
||||
const orderCompleted = () => {
|
||||
show.value = false;
|
||||
}
|
||||
const orderCanceled = ()=>{
|
||||
const orderCanceled = () => {
|
||||
show.value = false;
|
||||
}
|
||||
|
||||
|
|
@ -127,6 +122,7 @@ const orderCanceled = ()=>{
|
|||
justify-content: space-between;
|
||||
flex-wrap: wrap;
|
||||
align-items: center;
|
||||
|
||||
.btn {
|
||||
height: 45px;
|
||||
width: 95px;
|
||||
|
|
@ -139,7 +135,8 @@ const orderCanceled = ()=>{
|
|||
align-items: center;
|
||||
padding: 10px;
|
||||
cursor: pointer;
|
||||
.image{
|
||||
|
||||
.image {
|
||||
width: 16px;
|
||||
height: 16px;
|
||||
margin-right: 3px;
|
||||
|
|
@ -163,4 +160,11 @@ const orderCanceled = ()=>{
|
|||
}
|
||||
|
||||
}
|
||||
.bottom{
|
||||
height: 100%;
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
padding: 0 24px;
|
||||
}
|
||||
</style>
|
||||
|
|
@ -1,5 +1,5 @@
|
|||
<template>
|
||||
<Mask :width="696" :height="409" title="收费" :is-show="show" @close="show = false" :show-footer="true">
|
||||
<Mask :width="696" :height="409" title="收费" :is-show="show" @close="close" :show-footer="true">
|
||||
<template #default>
|
||||
<div class="content">
|
||||
<div class="btns">
|
||||
|
|
@ -66,26 +66,30 @@ const socialCard = ref<any>({
|
|||
data: null,
|
||||
mdtrtCertType: null,
|
||||
mdtrtCertNo: null,
|
||||
payInfo: {
|
||||
}
|
||||
payInfo: {}
|
||||
});
|
||||
|
||||
const show = ref(false)
|
||||
const printReceipt = ref(false);
|
||||
const payType = ref(null);
|
||||
const retailOrder = ref<any>(null);
|
||||
const close = () => {
|
||||
show.value = false;
|
||||
payType.value = null;
|
||||
selectedIndex.value = null
|
||||
}
|
||||
const init = async (code: any, psnNo: any) => {
|
||||
retailOrder.value = await post("charge/getByCode", {code: code});
|
||||
if (psnNo != null){
|
||||
let result:any= await post("social/person/getSocialInfoByPsnNo", {psnNo: psnNo});
|
||||
socialCard.value.data = result;
|
||||
socialCard.value.mdtrtCertType = result.mdtrtCertType;
|
||||
socialCard.value.mdtrtCertNo = result.mdtrtCertNo;
|
||||
socialCard.value.payInfo.selfpay_prop_type = result.insuinfo[0].insutype;
|
||||
if (psnNo != null) {
|
||||
let result: any = await post("social/person/getSocialInfoByPsnNo", {psnNo: psnNo});
|
||||
if (result) {
|
||||
socialCard.value.data = result;
|
||||
socialCard.value.mdtrtCertType = result.mdtrtCertType;
|
||||
socialCard.value.mdtrtCertNo = result.mdtrtCertNo;
|
||||
socialCard.value.payInfo.selfpay_prop_type = result.insuinfo[0].insutype;
|
||||
}
|
||||
}
|
||||
|
||||
show.value = true;
|
||||
|
||||
}
|
||||
defineExpose({init})
|
||||
const changePriceType = (type: any, index: any) => {
|
||||
|
|
@ -98,6 +102,7 @@ const completeSettlement = () => {
|
|||
return;
|
||||
}
|
||||
if (payType.value == null) {
|
||||
ElMessage.warning("请选择支付方式")
|
||||
return
|
||||
}
|
||||
if (payType.value == 1) {
|
||||
|
|
@ -135,6 +140,10 @@ const getBalcByInsutype = (type: any) => {
|
|||
}
|
||||
|
||||
const socialSettlement = () => {
|
||||
if (socialCard.value.data == null) {
|
||||
ElMessage.warning("请刷卡")
|
||||
return;
|
||||
}
|
||||
const params = {
|
||||
mdtrtCertType: socialCard.value.mdtrtCertType,
|
||||
mdtrtCertNo: socialCard.value.mdtrtCertNo,
|
||||
|
|
|
|||
|
|
@ -111,21 +111,20 @@
|
|||
<el-table-column label="生产日期" width="140">
|
||||
<template #default="scope">
|
||||
<el-date-picker
|
||||
:editable="false"
|
||||
v-model="scope.row.productionDate"
|
||||
type="date"
|
||||
value-format="YYYY-MM-DD"
|
||||
placeholder="生产日期"
|
||||
size="small"
|
||||
@change="checkProductionDate(scope.row)"
|
||||
style="width: 100px;"/>
|
||||
style="width: 100px;"
|
||||
@input="inputProductionDate(scope.row)"
|
||||
/>
|
||||
</template>
|
||||
|
||||
</el-table-column>
|
||||
<el-table-column label="有效日期" width="140">
|
||||
<template #default="scope">
|
||||
<el-date-picker
|
||||
:editable="false"
|
||||
v-model="scope.row.expiryDate"
|
||||
type="date"
|
||||
value-format="YYYY-MM-DD"
|
||||
|
|
@ -215,7 +214,12 @@ const checkProductionDate = (row: any) => {
|
|||
}
|
||||
return true;
|
||||
};
|
||||
|
||||
const inputProductionDate= (row: any) => {
|
||||
console.log(row)
|
||||
if (row.productionDate && row.expiryDate) {
|
||||
checkExpiryDate(row);
|
||||
}
|
||||
}
|
||||
const checkExpiryDate = (row: any) => {
|
||||
if (!row.expiryDate) {
|
||||
ElMessage.error('有效期不能为空');
|
||||
|
|
|
|||
|
|
@ -112,7 +112,6 @@ const delDraft = () => {
|
|||
}
|
||||
const settlementRef = ref()
|
||||
const charge = () => {
|
||||
|
||||
if (checkTraceCode(formData.value.goodsDetail)) {
|
||||
//保存订单
|
||||
saveAndCharge()
|
||||
|
|
|
|||
Loading…
Reference in New Issue