Merge branch 'main' of ssh://git.jizhiweb.cn:2222/clinic-v2/web

This commit is contained in:
LiJianZhao 2025-05-19 16:13:40 +08:00
commit 2ed0b0e7ee
20 changed files with 71 additions and 68 deletions

View File

@ -74,10 +74,19 @@ const getInfoFor1101 = (params: any) => {
} }
onMounted(async () => { onMounted(async () => {
wsStore.setMessageCallback(reciceMessage) wsStore.setMessageCallback(reciceMessage)
wsStore.setErrorCallback(errorCallBack)
}); });
onUnmounted(() => { onUnmounted(() => {
wsStore.removeAllMessageCallback() wsStore.removeAllMessageCallback()
wsStore.removeAllErrorCallback()
}) })
const errorCallBack = () => {
ElMessage({
message: '请连接设备',
type: 'warning',
});
isReading.value = false;
}
</script> </script>
<template> <template>

View File

@ -293,7 +293,7 @@ const selected = ref(false)
} }
.item-time { .item-time {
width: 40px; width: 80px;
} }
.item-status{ .item-status{
width: 40px; width: 40px;

View File

@ -118,6 +118,9 @@ defineExpose({init, clear})
min-width: 0; min-width: 0;
height: 20px; height: 20px;
line-height: 20px; line-height: 20px;
white-space: nowrap; /* 防止文本换行 */
overflow: hidden; /* 隐藏溢出的文本 */
text-overflow: ellipsis; /* 显示省略号 */
} }
.avatar-info-num { .avatar-info-num {
margin-left: 28px; margin-left: 28px;

View File

@ -12,7 +12,7 @@
</div> </div>
</template> </template>
<div> <div>
<Detail :detail="item"></Detail> <Detail :detail="item" :key="item.id"></Detail>
</div> </div>
</el-collapse-item> </el-collapse-item>
</el-collapse> </el-collapse>
@ -31,11 +31,10 @@ const list = ref<any>([])
const init = (patientId: any) => { const init = (patientId: any) => {
const query = { const query = {
patientId: patientId, patientId: patientId,
pageSize: 10 pageSize: 20
} }
post('charge/listDetail', {query}).then((res: any) => { post('charge/listDetail', {query}).then((res: any) => {
list.value = res.list list.value = res.list
console.log(list, 'list')
}) })
} }
const clearList = () => { const clearList = () => {

View File

@ -55,7 +55,7 @@
</div> </div>
</template> </template>
<script setup lang="ts"> <script setup lang="ts">
import {ref, defineProps, onMounted} from 'vue' import {ref, defineProps, onMounted, watch} from 'vue'
const {detail} = defineProps(['detail']); const {detail} = defineProps(['detail']);
const detailObj = ref<any>(detail) const detailObj = ref<any>(detail)
@ -70,6 +70,7 @@ onMounted(() => {
}, 0); }, 0);
sumPrice.value = pharmaceuticalTotalAmount + serviceTotalAmount; sumPrice.value = pharmaceuticalTotalAmount + serviceTotalAmount;
}) })
</script> </script>
<style scoped lang="scss"> <style scoped lang="scss">
.disease-detail { .disease-detail {
@ -130,7 +131,8 @@ onMounted(() => {
display: flex; display: flex;
justify-content: space-between; justify-content: space-between;
margin-bottom: 8px; margin-bottom: 8px;
.name{
.name {
white-space: nowrap; /* 防止文本换行 */ white-space: nowrap; /* 防止文本换行 */
overflow: hidden; /* 隐藏溢出的文本 */ overflow: hidden; /* 隐藏溢出的文本 */
text-overflow: ellipsis; /* 显示省略号 */ text-overflow: ellipsis; /* 显示省略号 */
@ -143,7 +145,8 @@ onMounted(() => {
.price-left { .price-left {
margin-right: 38px; margin-right: 38px;
} }
.sumPrice{
.sumPrice {
font-weight: bold; font-weight: bold;
font-size: 16px; font-size: 16px;
color: #FF0000; color: #FF0000;

View File

@ -71,7 +71,7 @@ const socialCard = ref<any>({
}); });
const loading = ref(false); const loading = ref(false);
const show = ref(false) const show = ref(false)
const printReceipt = ref(true); const printReceipt = ref(false);
const payType = ref(null); const payType = ref(null);
const retailOrder = ref<any>(null); const retailOrder = ref<any>(null);
const close = () => { const close = () => {

View File

@ -46,15 +46,19 @@ const imageUrl = ref<any>()
height: 208px; height: 208px;
.info-content { .info-content {
width: 100%;
display: flex; display: flex;
padding-left: 24px;
.image { .image {
width: 88px; width: 88px;
height: 88px; height: 88px;
margin: 0 24px; margin-right:24px;
} }
.app_info-content-text { .app_info-content-text {
flex: 1;
min-width: 0;
font-weight: 500; font-weight: 500;
font-size: 16px; font-size: 16px;
color: #333333; color: #333333;

View File

@ -10,7 +10,7 @@ const proxyMessage = defineModel<any>()
<div class="service-content"> <div class="service-content">
<img class="image" src="/static/images/home/qr-code.png" alt=""> <img class="image" src="/static/images/home/qr-code.png" alt="">
<div class="service-text"> <div class="service-text">
<div style="margin-bottom: 20px">服务名称{{ proxyMessage.name }}</div> <div class="message-name" style="margin-bottom: 20px">服务名称{{ proxyMessage.name }}</div>
<div>服务热线{{ proxyMessage.phone }}</div> <div>服务热线{{ proxyMessage.phone }}</div>
</div> </div>
</div> </div>
@ -19,20 +19,22 @@ const proxyMessage = defineModel<any>()
<style scoped lang="scss"> <style scoped lang="scss">
.service { .service {
width: 100%;
height: 170px; height: 170px;
margin: 24px 0; margin: 24px 0;
padding-bottom: 24px;
.service-content { .service-content {
padding: 0 24px 24px;
display: flex; display: flex;
.image { .image {
width: 88px; width: 88px;
height: 88px; height: 88px;
margin: 0 24px; margin-right:24px;
} }
.service-text { .service-text {
flex: 1;
min-width: 0;
font-weight: 500; font-weight: 500;
font-size: 16px; font-size: 16px;
color: #333333; color: #333333;
@ -40,6 +42,11 @@ const proxyMessage = defineModel<any>()
display: flex; display: flex;
flex-direction: column; flex-direction: column;
justify-content: center; justify-content: center;
.message-name{
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
} }
} }
} }

View File

@ -36,7 +36,7 @@
:current-page="pageNum" :current-page="pageNum"
:page-size="pageSize" :page-size="pageSize"
:total="total" :total="total"
@change="changePage" @current-change="changePage"
/> />
</div> </div>
</template> </template>
@ -64,9 +64,8 @@ const close = () => {
const pageNum = ref(1); const pageNum = ref(1);
const pageSize = ref(20); const pageSize = ref(20);
const total = ref(0); const total = ref(0);
const changePage = (pageNum: any) => { const changePage = (value: any) => {
pageNum.value = pageNum pageNum.value = value
console.log(pageNum.value)
init() init()
} }
</script> </script>

View File

@ -40,7 +40,7 @@
:current-page="pageNum" :current-page="pageNum"
:page-size="pageSize" :page-size="pageSize"
:total="total" :total="total"
@change="changePage" @current-change="changePage"
/> />
</div> </div>
</template> </template>
@ -67,10 +67,10 @@ const close = () => {
tableData.value = [] tableData.value = []
}; };
const pageNum = ref(1); const pageNum = ref(1);
const pageSize = ref(1); const pageSize = ref(20);
const total = ref(0); const total = ref(0);
const changePage = (pageNum: any) => { const changePage = (value: any) => {
pageNum.value = pageNum pageNum.value = value
init() init()
} }
</script> </script>

View File

@ -38,7 +38,6 @@ const isZeroInventory = (item: any) => {
<div class="image"/> <div class="image"/>
<div class="item-content"> <div class="item-content">
<div class="item-name">{{ item.name }}</div> <div class="item-name">{{ item.name }}</div>
<div class="item-name-font">剩余库存值</div>
</div> </div>
<div class="item-right"> <div class="item-right">
<div class="wholeNumber">{{ item.inventoryWholeNumber }} <div class="wholeNumber">{{ item.inventoryWholeNumber }}

View File

@ -61,8 +61,13 @@ const systemMessage = defineModel<SystemMessage[]>({ default: () => [] });
justify-content: space-between; justify-content: space-between;
&-title { &-title {
flex: 1;
min-width: 0;
font-size: 18px; font-size: 18px;
color: #333333; color: #333333;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
} }
} }

View File

@ -18,7 +18,7 @@ const expireDateWarningListSrc = ref<any>([]);
const expireDateWarningList = ref<any>([]); const expireDateWarningList = ref<any>([]);
const getExpiryDateWarning = () => { const getExpiryDateWarning = () => {
post("statistics/expiryDateWarning",{pageNum: 1, pageSize: 20}).then((res: any) => { post("statistics/expiryDateWarning", {pageNum: 1, pageSize: 20}).then((res: any) => {
expireDateWarningList.value = res.list.slice(0, 4) expireDateWarningList.value = res.list.slice(0, 4)
}) })
} }
@ -38,13 +38,7 @@ const isExpire = (item: any) => {
:class="isExpire(item) ? 'item__danger' : 'item__warn'"> :class="isExpire(item) ? 'item__danger' : 'item__warn'">
<div class="image"/> <div class="image"/>
<div class="item-content"> <div class="item-content">
<el-tooltip <div class="item-name">{{ item.name }}</div>
effect="dark"
:content="item.name"
placement="bottom-start"
>
<div class="item-name">{{ item.name }}</div>
</el-tooltip>
<div class="item-name-font"> <div class="item-name-font">
<span>{{ item.whole_number }}{{ item.packaging_unit }}</span> <span>{{ item.whole_number }}{{ item.packaging_unit }}</span>
<span v-if="item.fragment_number>0">{{ <span v-if="item.fragment_number>0">{{
@ -146,6 +140,7 @@ const isExpire = (item: any) => {
.item-right { .item-right {
width: 120px; width: 120px;
display: flex; display: flex;
.item-right-num { .item-right-num {
font-size: 28px; font-size: 28px;
font-weight: bold; font-weight: bold;

View File

@ -12,7 +12,7 @@
</div> </div>
</template> </template>
<div> <div>
<DiseaseDetails :detail="item" @copy="copy" @copyItem="copyItem" @copyGoods="copyGoods"></DiseaseDetails> <DiseaseDetails :detail="item" :key="item.id" @copy="copy" @copyItem="copyItem" @copyGoods="copyGoods"></DiseaseDetails>
</div> </div>
</el-collapse-item> </el-collapse-item>
</el-collapse> </el-collapse>

View File

@ -309,7 +309,7 @@ watch(() => selectedDate.value, (newValue, oldValue) => {
} }
.item-time { .item-time {
width: 40px; width: 80px;
} }
.item-type { .item-type {

View File

@ -15,8 +15,8 @@
</div> </div>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="phone" label="手机号" width="180"></el-table-column> <el-table-column prop="phone" label="手机号" width="180" show-overflow-tooltip></el-table-column>
<el-table-column prop="status" label="状态" width="180"> <el-table-column prop="status" label="状态" width="180" show-overflow-tooltip>
<template #default="scope"> <template #default="scope">
<el-tag <el-tag
:type="scope.row.status === 1 ? 'warning' : scope.row.status === 2 ? 'success' : scope.row.status === 3 ? 'info' : 'danger'" :type="scope.row.status === 1 ? 'warning' : scope.row.status === 2 ? 'success' : scope.row.status === 3 ? 'info' : 'danger'"
@ -27,27 +27,27 @@
</el-tag> </el-tag>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="organizationSectionId" label="科室"> <el-table-column prop="organizationSectionId" label="科室" show-overflow-tooltip>
<template #default="scope"> <template #default="scope">
{{ sectionList.find((item:any)=>item.id===scope.row.organizationSectionId)?.name || '-' }} {{ sectionList.find((item:any)=>item.id===scope.row.organizationSectionId)?.name || '-' }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="organizationDoctorId" label="医生"> <el-table-column prop="organizationDoctorId" label="医生" show-overflow-tooltip>
<template #default="scope"> <template #default="scope">
{{ roleList.find((item: any) => item.id === scope.row.organizationDoctorId)?.name || '-' }} {{ roleList.find((item: any) => item.id === scope.row.organizationDoctorId)?.name || '-' }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="visitType" label="初/复诊"> <el-table-column prop="visitType" label="初/复诊" show-overflow-tooltip>
<template #default="scope"> <template #default="scope">
{{ visitType[scope.row.visitType] || '-' }} {{ visitType[scope.row.visitType] || '-' }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="createDatetime" label="挂号日期" width="180"> <el-table-column prop="createDatetime" label="挂号日期" width="180" show-overflow-tooltip>
<template #default="scope"> <template #default="scope">
{{ formatDate(scope.row.createDatetime) || '-' }} {{ formatDate(scope.row.createDatetime) || '-' }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="memo" label="备注"></el-table-column> <el-table-column prop="memo" label="备注" show-overflow-tooltip></el-table-column>
</el-table> </el-table>
</div> </div>
</template> </template>

View File

@ -1,15 +1 @@
import { ref } from 'vue'
import { defineStore } from 'pinia'
export const useLogoStore = defineStore('logo', () => {
const logoUrl = ref<string>("")
function setLogoUrl(url: string) {
logoUrl.value = url
}
function getLogoUrl() {
return logoUrl.value
}
// 返回需要暴露的方法和变量
return { logoUrl, setLogoUrl, getLogoUrl }
})

View File

@ -246,10 +246,8 @@ const orderCompleted = (printReceipt: any) => {
type MedTypeKey = keyof typeof medTypeJson; type MedTypeKey = keyof typeof medTypeJson;
const wsStore = useWsStore() const wsStore = useWsStore()
const printReceiptDo = async () => { const printReceiptDo = async () => {
let chargeOrder:any = await post("charge/getOrderByDiagnosisCode", { let chargeOrder:any = await post("charge/getOrderByDiagnosisCode", {
diagnosisCode: formData.value.code, diagnosisCode: formData.value.code,
status: formData.value.status
}) })
if (!chargeOrder) { if (!chargeOrder) {
ElMessage.error("该订单不存在") ElMessage.error("该订单不存在")
@ -269,7 +267,6 @@ const printReceiptDo = async () => {
if (res.chargeSocialPayLog) { if (res.chargeSocialPayLog) {
res.chargeSocialPayLog.medTypeStr = medTypeJson[res.chargeSocialPayLog.medType as MedTypeKey]; res.chargeSocialPayLog.medTypeStr = medTypeJson[res.chargeSocialPayLog.medType as MedTypeKey];
} }
console.log(res)
wsStore.sendMessage({ wsStore.sendMessage({
type: "PrintReceipt", type: "PrintReceipt",
config: null, config: null,
@ -317,8 +314,6 @@ const getOrderTotalPrice = () => {
}) })
formData.value.preTotalPrice = Math.round(totalPrice * 100) / 100 formData.value.preTotalPrice = Math.round(totalPrice * 100) / 100
formData.value.totalPrice = Math.round(totalPrice * 100) / 100 formData.value.totalPrice = Math.round(totalPrice * 100) / 100
} }
@ -357,7 +352,6 @@ const refund = async () => {
} }
let chargeOrder:any = await post("charge/getOrderByDiagnosisCode", { let chargeOrder:any = await post("charge/getOrderByDiagnosisCode", {
diagnosisCode: formData.value.code, diagnosisCode: formData.value.code,
status: formData.value.status
}) })
if (!chargeOrder) { if (!chargeOrder) {
ElMessage.error("该订单不存在") ElMessage.error("该订单不存在")

View File

@ -100,8 +100,6 @@ const save = () => {
post('medical/record/save', {data: data}).then((res: any) => { post('medical/record/save', {data: data}).then((res: any) => {
ElMessage.success("保存成功") ElMessage.success("保存成功")
medicalQueueRef.value?.changeCurItemOrStatus(null, 2); medicalQueueRef.value?.changeCurItemOrStatus(null, 2);
}) })
} }
const totalAmount = ref(0) const totalAmount = ref(0)
@ -109,6 +107,7 @@ const medicalHistoryRef = ref()
const patientCardRef = ref() const patientCardRef = ref()
const patientRegistration = ref<any>({})// const patientRegistration = ref<any>({})//
const clickItem = (item: any) => { const clickItem = (item: any) => {
initFormData()
if (!item) return if (!item) return
curRegister.value = item curRegister.value = item
registerId.value = item.id registerId.value = item.id
@ -126,6 +125,7 @@ const clickItem = (item: any) => {
formData.value.itemDetail = res.itemDetail formData.value.itemDetail = res.itemDetail
formData.value.diagType = Number(formData.value.diagType) formData.value.diagType = Number(formData.value.diagType)
patientRegistration.value = res.patientRegistration patientRegistration.value = res.patientRegistration
getOrderTotalPrice()
}) })
} }
@ -162,18 +162,16 @@ const getOrderTotalPrice = () => {
formData.value.itemDetail?.forEach((item: any) => { formData.value.itemDetail?.forEach((item: any) => {
totalPrice += item.selectedPrice * item.selectedNum totalPrice += item.selectedPrice * item.selectedNum
}) })
console.log(totalPrice, 'totalPrice')
formData.value.goodsDetail?.forEach((item: any) => { formData.value.goodsDetail?.forEach((item: any) => {
totalPrice += item.selectedPrice * item.selectedNum totalPrice += item.selectedPrice * item.selectedNum
}) })
console.log(totalPrice, 'totalPrice')
formData.value.preTotalPrice = Math.round((totalPrice * 100) / 100) formData.value.preTotalPrice = Math.round((totalPrice * 100) / 100)
formData.value.totalPrice = totalPrice formData.value.totalPrice = totalPrice
console.log(formData.value.totalPrice, 'formData.value.totalPrice')
} }
const caseRef = ref<any>("") const caseRef = ref<any>("")
const copyForm = (item: any) => { const copyForm = (item: any) => {
formData.value = item.diagnosisMedicalRecord formData.value = item.diagnosisMedicalRecord
formData.value.diagType = Number(item.diagnosisMedicalRecord.diagType)
const diagnosisList = JSON.parse(item.diagnosisMedicalRecord.diagnosisDetail) const diagnosisList = JSON.parse(item.diagnosisMedicalRecord.diagnosisDetail)
const nList = item.diagnosisMedicalRecord.diagnosisSummary.split(',') const nList = item.diagnosisMedicalRecord.diagnosisSummary.split(',')
nextTick(() => { nextTick(() => {
@ -181,10 +179,12 @@ const copyForm = (item: any) => {
}) })
} }
const copyItemList = (item: any) => { const copyItemList = (item: any) => {
itemDetail.value = item.itemDetail formData.value.itemDetail = item.itemDetail
getOrderTotalPrice()
} }
const copyGoodsList = (item: any) => { const copyGoodsList = (item: any) => {
goodsList.value = item.goodsDetail formData.value.goodsDetail = item.goodsDetail
getOrderTotalPrice()
} }
const seeDockerInfo = ref<any>() const seeDockerInfo = ref<any>()

View File

@ -132,8 +132,8 @@ const getPatientList = () => {
const total = ref(0) const total = ref(0)
const size = ref(20) const size = ref(20)
const page = ref(1) const page = ref(1)
const changePage = (page: any) => { const changePage = (value: any) => {
page.value = page page.value = value
getPatientList() getPatientList()
} }
const id = ref<any>('') const id = ref<any>('')