This commit is contained in:
ChenQiuYu 2025-05-13 11:31:07 +08:00
parent 78e9cef909
commit e899aaa2d3
8 changed files with 122 additions and 30 deletions

View File

@ -93,5 +93,5 @@ body {
.el-popper.is-light.type-popper, .el-popper.is-light>.el-popper__arrow:before{
background:#F5FAFF !important;
padding: 0 !important;
border: 1px solid #4D6DE4 !important;
//border: 1px solid #4D6DE4 !important;
}

View File

@ -0,0 +1,70 @@
<script setup lang="ts">
import { ref, defineProps, defineEmits } from 'vue';
const props = defineProps({
modelValue: {
type: Number,
default: 0
},
minValue: {
type: Number,
default: 0
},
maxValue: {
type: Number,
default: 100
}
});
const emit = defineEmits(['update:modelValue']);
const currentValue = ref(props.modelValue);
//
const increment = () => {
if (currentValue.value < props.maxValue) {
currentValue.value++;
emit('update:modelValue', currentValue.value);
}
};
//
const decrement = () => {
if (currentValue.value > props.minValue) {
currentValue.value--;
emit('update:modelValue', currentValue.value);
}
};
const change = () => {
emit('update:modelValue', currentValue.value);
};
</script>
<template>
<div class="number-input">
<button @click="decrement" :disabled="currentValue <= minValue">-</button>
<el-input style="width: 100px" v-model.number="currentValue" :min="minValue" :max="maxValue" @input="change"/>
<button @click="increment" :disabled="currentValue >= maxValue">+</button>
</div>
</template>
<style scoped lang="scss">
.number-input {
display: flex;
align-items: center;
}
button {
width: 30px;
height: 30px;
font-size: 18px;
cursor: pointer;
}
input {
width: 60px;
text-align: center;
margin: 0 5px;
}
</style>

View File

@ -1,7 +1,8 @@
<template>
<panel title="药品耗材">
<el-table v-if="goodsDetail.length>0" :data="goodsDetail" max-height="150" style="width: 100%">
<el-table-column prop="name" label="名称">
<el-table v-if="goodsDetail.length>0" :data="goodsDetail" max-height="300" style="width: 100%"
:header-cell-style="{ backgroundColor: '#F5FAFF' }">
<el-table-column prop="name" label="名称" width="400">
<template #default="scope">
<el-popover
placement="top-start"
@ -39,20 +40,20 @@
</el-popover>
</template>
</el-table-column>
<el-table-column prop="selectedPrice" label="单价">
<el-table-column prop="selectedPrice" label="单价" width="200">
<template #default="scope">
{{ scope.row.selectedPrice }}
</template>
</el-table-column>
<el-table-column prop="number" label="数量">
<el-table-column prop="number" label="数量" width="250">
<template #default="scope">
<div v-if="props.status">
<el-input-number v-model="scope.row.selectedNum" :min="0" @change="handleNumChange(scope.row)"
size="small"></el-input-number>
<el-dropdown>
<span style="line-height: 30px;margin-left: 10px">{{ scope.row.selectedUnit }}</span>
style="margin-right: 5px"></el-input-number>
<el-dropdown v-if="scope.row.trdnFlag == 1">
<span style="line-height: 30px;margin-left: 10px;cursor: pointer">{{ scope.row.selectedUnit }}</span>
<template #dropdown>
<el-dropdown-menu v-if="scope.row.trdnFlag == 1">
<el-dropdown-menu>
<el-dropdown-item @click="selectUnit(scope.row,scope.row.packagingUnit)">{{ scope.row.packagingUnit }}
</el-dropdown-item>
<el-dropdown-item @click="selectUnit(scope.row,scope.row.minPackagingUnit)">
@ -61,6 +62,7 @@
</el-dropdown-menu>
</template>
</el-dropdown>
<span v-else style="line-height: 30px;margin-left: 10px">{{ scope.row.selectedUnit }}</span>
</div>
<div v-else>
<div>{{ scope.row.selectedNum }} {{ scope.row.selectedUnit }}</div>
@ -91,7 +93,7 @@
:width="1000"
></SearchInput>
</div>
<span v-if="status">合计{{ getTotalPrice() }}</span>
<span v-if="status" style="padding: 10px">合计{{ getTotalPrice() }}</span>
</div>
</panel>
</template>
@ -163,7 +165,6 @@ const goodsSelect = (row: any) => {
if (goodsDetail.value.find((i: any) => i.id == row.id)) {
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
@ -220,8 +221,11 @@ const colosInfo = () => {
}
</script>
<style scoped lang="scss">
:deep(.el-table__cell) {
padding: 0 4px;
:deep(.el-table tr) {
font-size: 16px;
font-weight: 500;
color: #333333;
height: 60px;
}
.bottom {

View File

@ -1,7 +1,7 @@
<template>
<Panel title="服务项目">
<el-table v-if="itemDetail.length>0" :data="itemDetail">
<el-table-column prop="itemName" label="项目名称" show-overflow-tooltip width="200">
<el-table v-if="itemDetail.length>0" :data="itemDetail" max-height="300" :header-cell-style="{ backgroundColor: '#F5FAFF' }">
<el-table-column prop="itemName" label="项目名称" show-overflow-tooltip width="400">
<template #default="scope">
<el-popover
width="485"
@ -27,15 +27,15 @@
</el-popover>
</template>
</el-table-column>
<el-table-column label="单价">
<el-table-column label="单价" width="200">
<template #default="scope">
{{ scope.row.selectedPrice }}
</template>
</el-table-column>
<el-table-column label="数量" width="180">
<el-table-column label="数量" width="250">
<template #default="scope">
<el-input-number v-if="props.status" v-model="scope.row.selectedNum" :min="0"
@change="handleNumChange" size="small"></el-input-number>
@change="handleNumChange" style="margin-right: 5px"></el-input-number>
<span v-else>{{ scope.row.selectedNum }}</span>
{{ scope.row.selectedUnit }}
</template>
@ -61,7 +61,7 @@
:show-config="serviceShowConfig"
@selectedCallBack="serviceSelect" :disabled="!props.status"></SearchInput>
</div>
<span v-if="status">合计{{ getTotalPrice() || 0 }}</span>
<span v-if="status" style="padding: 10px">合计{{ getTotalPrice() || 0 }}</span>
</div>
</Panel>
</template>
@ -121,7 +121,6 @@ const serviceSelect = (row: any) => {
if (itemDetail.value.find((i: any) => i.id == row.id)) {
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
@ -157,8 +156,11 @@ const hide = () => {
}
</script>
<style scoped lang="scss">
:deep(.el-table__cell) {
padding: 0 4px;
:deep(.el-table tr) {
font-size: 16px;
font-weight: 500;
color: #333333;
height: 60px;
}
.bottom {

View File

@ -20,8 +20,8 @@ const editItem= () => {
<div class="footer">
<div>总金额<span class="text icon"></span><span class="text">{{ totalAmount || '0' }}</span></div>
<div class="btn-group">
<el-button v-if="status" @click="deleteItem">取消接诊</el-button>
<el-button v-if="status" type="primary" @click="save">完成接诊</el-button>
<span v-if="status" @click="deleteItem">取消接诊</span>
<span v-if="status" @click="save">完成接诊</span>
<!-- <el-button v-if="status == 3" type="primary" @click="editItem">修改</el-button>-->
</div>
</div>
@ -45,5 +45,22 @@ const editItem= () => {
.text {
color: #FF282E
}
.btn-group{
display: flex;
span{
width: 119px;
height: 48px;
text-align: center;
line-height: 48px;
border-radius: 8px;
border: 1px solid #D8D8D8;
margin-left: 24px;
cursor: pointer;
&:hover{
background: #4D6DE4 ;
color: #fff;
}
}
}
}
</style>

View File

@ -82,7 +82,6 @@ const getInfoFor1101 = (params: any) => {
duration: 1000,
});
emit('socialCardUpdate', socialCard.value)
}).catch(() => {
isReading.value = false;
emit('changeLoading', false)

View File

@ -2,7 +2,6 @@
<Mask :is-show="isShow" width="800" :height="height" title="挂号" @close="close"
:show-footer="true">
<template #default>
<div style="padding:0 24px">
<el-form
v-loading="loading"
@ -360,6 +359,7 @@ const deleteCard = () => {
nextTick(() => {
cardDefaultRef.value?.close()
height.value = 470
console.log(socialCard.value,'socialCard')
})
}
},

View File

@ -93,6 +93,7 @@ const isShowNum = ref(-1)
const roleList = ref<any>([])
onMounted(() => {
selectedDate.value = [getToday().start, getToday().end]
initDoctor()
getPatientList()
})
@ -119,7 +120,6 @@ const handleDateChange = (date: any[]) => {
const getPatientList = () => {
isShowNum.value = -1
id.value = null
selectedDate.value = [getToday().start, getToday().end]
post('registration/list', {
page: page.value,
size: size.value,