dev
This commit is contained in:
parent
cc18ac3f52
commit
1386dbaf3d
|
|
@ -28,7 +28,8 @@
|
||||||
<el-table-column
|
<el-table-column
|
||||||
v-for="item in showConfig"
|
v-for="item in showConfig"
|
||||||
:prop="item.prop"
|
:prop="item.prop"
|
||||||
:label="item.label"
|
:label="item.label||'-'"
|
||||||
|
show-overflow-tooltip
|
||||||
></el-table-column>
|
></el-table-column>
|
||||||
</el-table>
|
</el-table>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
||||||
|
|
@ -119,13 +119,33 @@ const goodsShowConfig = [
|
||||||
prop: "name",
|
prop: "name",
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: "项目类型",
|
label: "规格",
|
||||||
prop: "type",
|
prop: "specifications",
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: "售价",
|
label: "库存",
|
||||||
|
prop: "inventory",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "价格",
|
||||||
prop: "unitPrice",
|
prop: "unitPrice",
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
label: "厂家",
|
||||||
|
prop: "producer",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "效期",
|
||||||
|
prop: "lifespan",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "收费项目等级",
|
||||||
|
prop: "category",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "限制条件",
|
||||||
|
prop: "limit",
|
||||||
|
}
|
||||||
]
|
]
|
||||||
const goodsSelect = (row: any) => {
|
const goodsSelect = (row: any) => {
|
||||||
row.selectedNum = 1
|
row.selectedNum = 1
|
||||||
|
|
@ -133,6 +153,10 @@ const goodsSelect = (row: any) => {
|
||||||
row.selectedPrice = row.unitPrice
|
row.selectedPrice = row.unitPrice
|
||||||
if (goodsDetail.value.find((i: any) => i.id == row.id)) {
|
if (goodsDetail.value.find((i: any) => i.id == row.id)) {
|
||||||
ElMessage.warning("数据已存在,只能加数量")
|
ElMessage.warning("数据已存在,只能加数量")
|
||||||
|
goodsDetail.value.find((i: any) => i.id == row.id).selectedNum += 1
|
||||||
|
goodsDetail.value.find((i: any) => i.id == row.id).selectedUnit = row.packagingUnit
|
||||||
|
goodsDetail.value.find((i: any) => i.id == row.id).selectedPrice = row.unitPrice
|
||||||
|
emit('totalPriceChange')
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
goodsDetail.value.push(row)
|
goodsDetail.value.push(row)
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,7 @@
|
||||||
<template>
|
<template>
|
||||||
<Panel title="服务项目">
|
<Panel title="服务项目">
|
||||||
<el-table v-if="itemDetail.length>0" :data="itemDetail" max-height="150">
|
<el-table v-if="itemDetail.length>0" :data="itemDetail" max-height="150">
|
||||||
<el-table-column prop="itemName" label="项目名称">
|
<el-table-column prop="itemName" label="项目名称" show-overflow-tooltip width="200">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<el-popover
|
<el-popover
|
||||||
width="485"
|
width="485"
|
||||||
|
|
@ -32,7 +32,7 @@
|
||||||
¥{{ scope.row.selectedPrice }}
|
¥{{ scope.row.selectedPrice }}
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="数量">
|
<el-table-column label="数量" width="180">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<el-input-number v-if="props.status" v-model="scope.row.selectedNum" :min="0"
|
<el-input-number v-if="props.status" v-model="scope.row.selectedNum" :min="0"
|
||||||
@change="handleNumChange" size="small"></el-input-number>
|
@change="handleNumChange" size="small"></el-input-number>
|
||||||
|
|
@ -90,13 +90,22 @@ const serviceShowConfig = [
|
||||||
prop: "itemName",
|
prop: "itemName",
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: "服务医保码",
|
label: "单位",
|
||||||
prop: "itemSocialCode",
|
prop: "unit",
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: "售价",
|
label: "售价",
|
||||||
prop: "unitPrice",
|
prop: "unitPrice",
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
label: "收费项目等级",
|
||||||
|
prop: "chrgitmLv",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "限制条件",
|
||||||
|
prop: "limit",
|
||||||
|
},
|
||||||
|
|
||||||
]
|
]
|
||||||
const emit = defineEmits(['totalPriceChange', 'focus'])
|
const emit = defineEmits(['totalPriceChange', 'focus'])
|
||||||
const serviceSelect = (row: any) => {
|
const serviceSelect = (row: any) => {
|
||||||
|
|
@ -105,6 +114,10 @@ const serviceSelect = (row: any) => {
|
||||||
row.selectedPrice = row.unitPrice
|
row.selectedPrice = row.unitPrice
|
||||||
if (itemDetail.value.find((i: any) => i.id == row.id)) {
|
if (itemDetail.value.find((i: any) => i.id == row.id)) {
|
||||||
ElMessage.warning("数据已存在,只能加数量")
|
ElMessage.warning("数据已存在,只能加数量")
|
||||||
|
itemDetail.value.find((i: any) => i.id == row.id).selectedNum += 1
|
||||||
|
itemDetail.value.find((i: any) => i.id == row.id).selectedUnit = row.packagingUnit
|
||||||
|
itemDetail.value.find((i: any) => i.id == row.id).selectedPrice = row.unitPrice
|
||||||
|
emit('totalPriceChange')
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
itemDetail.value.push(row)
|
itemDetail.value.push(row)
|
||||||
|
|
@ -146,6 +159,7 @@ const hide = () => {
|
||||||
text-align: right;
|
text-align: right;
|
||||||
border-top: 1px solid #EAEAEC;
|
border-top: 1px solid #EAEAEC;
|
||||||
display: flex;
|
display: flex;
|
||||||
|
|
||||||
.search {
|
.search {
|
||||||
flex: 1;
|
flex: 1;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,5 @@
|
||||||
<template>
|
<template>
|
||||||
|
|
||||||
|
|
||||||
<el-popover placement="bottom-start" :visible="isVisible" :width="props.width" ref="popoverRef"
|
<el-popover placement="bottom-start" :visible="isVisible" :width="props.width" ref="popoverRef"
|
||||||
@before-enter="beforeShow" @hide="afterShow">
|
@before-enter="beforeShow" @hide="afterShow">
|
||||||
<template #reference>
|
<template #reference>
|
||||||
|
|
|
||||||
|
|
@ -10,12 +10,11 @@
|
||||||
<template #default>
|
<template #default>
|
||||||
<div class="diagnosis-content">
|
<div class="diagnosis-content">
|
||||||
<div class="diagnosis">
|
<div class="diagnosis">
|
||||||
诊断:
|
<div style="width: 62px">诊断:</div>
|
||||||
<DiagnosisSearchInput
|
<DiagnosisSearchInput
|
||||||
v-model="diagnosisKeyword"
|
v-model="diagnosisKeyword"
|
||||||
:request-api="diagnosisSearchApi"
|
:request-api="diagnosisSearchApi"
|
||||||
:show-config="diagnosisShowConfig"
|
:show-config="diagnosisShowConfig"
|
||||||
:width="600"
|
|
||||||
@selectedCallBack="diagnosisSelect"
|
@selectedCallBack="diagnosisSelect"
|
||||||
ref="diagnosisSearchRef"
|
ref="diagnosisSearchRef"
|
||||||
:show-header="false"
|
:show-header="false"
|
||||||
|
|
@ -25,12 +24,13 @@
|
||||||
</DiagnosisSearchInput>
|
</DiagnosisSearchInput>
|
||||||
</div>
|
</div>
|
||||||
<div class="doctor">
|
<div class="doctor">
|
||||||
医生:
|
<div>医生:</div>
|
||||||
<el-select
|
<el-select
|
||||||
v-model="formData.doctorId"
|
v-model="formData.doctorId"
|
||||||
@change="handleChange"
|
@change="handleChange"
|
||||||
clearable
|
clearable
|
||||||
size="large">
|
style="width: 100%"
|
||||||
|
>
|
||||||
<el-option
|
<el-option
|
||||||
v-for="item in doctorList"
|
v-for="item in doctorList"
|
||||||
:key="item.id"
|
:key="item.id"
|
||||||
|
|
@ -40,17 +40,17 @@
|
||||||
</el-option>
|
</el-option>
|
||||||
</el-select>
|
</el-select>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
</Panel>
|
</Panel>
|
||||||
</div>
|
</div>
|
||||||
<div style="margin-top: 24px">
|
<div style="margin-top: 24px">
|
||||||
<ServiceDetail v-model="formData.itemDetail" :status="formData.status == 0" @totalPriceChange="getOrderTotalPrice"></ServiceDetail>
|
<ServiceDetail v-model="formData.itemDetail" :status="formData.status == 0"
|
||||||
|
@totalPriceChange="getOrderTotalPrice"></ServiceDetail>
|
||||||
</div>
|
</div>
|
||||||
<div style="margin-top: 24px">
|
<div style="margin-top: 24px">
|
||||||
<GoodsDetail v-model="formData.goodsDetail" :status="formData.status == 0" @totalPriceChange="getOrderTotalPrice"></GoodsDetail>
|
<GoodsDetail v-model="formData.goodsDetail" :status="formData.status == 0"
|
||||||
|
@totalPriceChange="getOrderTotalPrice"></GoodsDetail>
|
||||||
</div>
|
</div>
|
||||||
<div class="bottom">
|
<div class="bottom">
|
||||||
<TotalPrice v-model="formData.totalPrice" @edit="saveAndCharge" :status="formData.status"></TotalPrice>
|
<TotalPrice v-model="formData.totalPrice" @edit="saveAndCharge" :status="formData.status"></TotalPrice>
|
||||||
|
|
@ -174,7 +174,6 @@ onMounted(() => {
|
||||||
list()
|
list()
|
||||||
})
|
})
|
||||||
const getOrderTotalPrice = () => {
|
const getOrderTotalPrice = () => {
|
||||||
debugger
|
|
||||||
let totalPrice = 0
|
let totalPrice = 0
|
||||||
formData.value.itemDetail?.forEach((item: any) => {
|
formData.value.itemDetail?.forEach((item: any) => {
|
||||||
totalPrice += item.selectedPrice * item.selectedNum
|
totalPrice += item.selectedPrice * item.selectedNum
|
||||||
|
|
@ -224,11 +223,11 @@ const list = () => {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
|
|
||||||
.diagnosis-content {
|
.diagnosis-content {
|
||||||
height: 64px;
|
height: 64px;
|
||||||
padding: 0 24px 24px;
|
padding: 0 24px 24px;
|
||||||
display: flex;
|
display: flex;
|
||||||
justify-content: left;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.case {
|
.case {
|
||||||
|
|
@ -285,6 +284,7 @@ const list = () => {
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.bottom {
|
.bottom {
|
||||||
margin-top: 24px;
|
margin-top: 24px;
|
||||||
height: 86px;
|
height: 86px;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue