From 944b42dbd5b2db5f2e3f52ddc4be63f5dcc420ff Mon Sep 17 00:00:00 2001 From: zoujiandong <10130823232@qq.com> Date: Mon, 16 Oct 2023 16:58:04 +0800 Subject: [PATCH] =?UTF-8?q?=E9=97=AE=E8=AF=8A=E8=AE=B0=E5=BD=95=E6=8C=89?= =?UTF-8?q?=E9=92=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/addInquiryConfigModal.vue | 193 ++++++++++++ src/components/chatRecord.vue | 354 +++++++++++++++++++++++ src/components/inquiryDetailModal.vue | 350 +--------------------- src/components/prescriptionModal.vue | 2 +- src/views/inquiry/inquiry-list/index.vue | 8 +- src/views/order/inquiry-record/index.vue | 2 +- src/views/order/order-list/index.vue | 31 +- 7 files changed, 593 insertions(+), 347 deletions(-) create mode 100644 src/components/addInquiryConfigModal.vue create mode 100644 src/components/chatRecord.vue diff --git a/src/components/addInquiryConfigModal.vue b/src/components/addInquiryConfigModal.vue new file mode 100644 index 0000000..ab18f75 --- /dev/null +++ b/src/components/addInquiryConfigModal.vue @@ -0,0 +1,193 @@ + + + \ No newline at end of file diff --git a/src/components/chatRecord.vue b/src/components/chatRecord.vue new file mode 100644 index 0000000..71f43e4 --- /dev/null +++ b/src/components/chatRecord.vue @@ -0,0 +1,354 @@ + + + \ No newline at end of file diff --git a/src/components/inquiryDetailModal.vue b/src/components/inquiryDetailModal.vue index c029d06..4deb246 100644 --- a/src/components/inquiryDetailModal.vue +++ b/src/components/inquiryDetailModal.vue @@ -168,171 +168,7 @@
聊天记录
-
-
- 点击加载更多 -
---没有更多了---
- -
- - - - - - - - -
-
- {{ JSON.parse(item.message_content).Text }} -
-
- - -
-
-
- {{ JSON.parse(JSON.parse(item.message_content).Data) - .title}} -
-
- 系统推送评价消息 -
-
- 系统推送医生端系统通知 -
-
- 系统推送医生端服务通知 -
-
- 系统推送患者端系统消息 -
-
- 药师审核中 -
-
-
-
处方已开具
-
-
-
RP:
-
{{ JSON.parse(JSON.parse(item.message_content).Data) - .data.product_name }}
-
-
-
开方日期:
-
{{JSON.parse(JSON.parse(item.message_content).Data) - .data.pharmacist_verify_time}}
-
- -
-
-
-
- 系统推送糖组检测报告 -
-
- 系统推送患者病例 -
-
- 系统推送患者信息 -
-
-
{{ parseTime(item.message_send_time) }}
-
-
-
-
+
@@ -417,10 +253,9 @@ import { ref, toRefs, reactive, watch,nextTick } from 'vue'; import { formatDoctorTitle } from '@/utils/format'; import { parseTime } from '@/utils/parseTime'; -import { inquiryCase, getIm } from '@/api/order/list'; +import { inquiryCase} from '@/api/order/list'; import { formatInquiryType, formatInquiryStatus } from '@/utils/format'; const emits = defineEmits(['inquiryVisibleChange']); -const showMore = ref(true); const props = defineProps({ // 是否显示 modalVisible: { @@ -429,9 +264,13 @@ const props = defineProps({ }, modalForm: { type: Object, + default:{ + order_inquiry_case:{ + inquiry_case_id:'' + } + } }, }); -const firstIn=ref(false); const doctorVisible = ref(false); const doctor_id = ref(''); const patientVisible = ref(false); @@ -441,36 +280,8 @@ const { modalVisible, modalForm } = toRefs(props); const openPatient = () => { patientVisible.value = true; }; -const pager = reactive({ - page: 1, - page_size: 10, -}); -const chatlist = ref([]); -const HandleGetIm = async (id, params = {}) => { - const { code, data } = await getIm(id, params); - if (code == 200) { - - if ( data.data.length < 10) { - showMore.value = false; - }else{ - showMore.value = true; - } - chatlist.value = data.data.reverse().concat(chatlist.value); - if(!firstIn.value){ - nextTick(() => { - // 要放在对响应式数据修改之后 - let ele = document.querySelector('.phonecont'); - ele.scrollTop = ele.scrollHeight; - }); - } - - firstIn.value=true - } -}; - -watch( - () => props.modalForm, - () => { +const order_inquiry_id=ref(''); +watch(() => props.modalForm,() => { if ( props.modalForm.order_inquiry_case && props.modalForm.order_inquiry_case.inquiry_case_id @@ -480,15 +291,10 @@ watch( Object.assign(patientData, data.data); }); } - if (props.modalForm.order_inquiry_id) { - let id = props.modalForm.order_inquiry_id; - chatlist.value=[]; - pager.page=1; - HandleGetIm(id, { ...pager }); - } - }, - { immediate: true, deep: true } -); + // if(props.modalForm.order_inquiry_id){ + // order_inquiry_id.value=props.modalForm.order_inquiry_id; + // } + },{ immediate: true, deep: true }) const openDcotor = () => { doctor_id.value = props.modalForm.doctor_id; doctorVisible.value = true; @@ -496,24 +302,10 @@ const openDcotor = () => { const handleClose = () => { emits('inquiryVisibleChange', (modalVisible.value = false)); }; -const loadMore=()=>{ - pager.page= pager.page+1; - let id=props.modalForm.order_inquiry_case.inquiry_case_id - HandleGetIm(id, { ...pager }); - -} + \ No newline at end of file diff --git a/src/components/prescriptionModal.vue b/src/components/prescriptionModal.vue index 9285ff7..421b8e5 100644 --- a/src/components/prescriptionModal.vue +++ b/src/components/prescriptionModal.vue @@ -176,7 +176,7 @@ 查看订单 - 下载 + 下载 diff --git a/src/views/inquiry/inquiry-list/index.vue b/src/views/inquiry/inquiry-list/index.vue index e4f662e..8e45571 100644 --- a/src/views/inquiry/inquiry-list/index.vue +++ b/src/views/inquiry/inquiry-list/index.vue @@ -37,12 +37,12 @@ - -
--> + - + diff --git a/src/views/order/inquiry-record/index.vue b/src/views/order/inquiry-record/index.vue index b4cc2a7..53da55e 100644 --- a/src/views/order/inquiry-record/index.vue +++ b/src/views/order/inquiry-record/index.vue @@ -82,7 +82,7 @@