9.12 feature 问诊订单,药品订单,取消订单
This commit is contained in:
parent
c53cd6763f
commit
d3aa9d7f45
@ -1,2 +1,3 @@
|
||||
BASE_URL= "https://vue3.go-admin.dev"
|
||||
VITE_BASE_URL= "http://dev.hospital.admin.api.igandanyiyuan.com"
|
||||
VITE_IMG_URL="https://img.applets.igandanyiyuan.com"
|
||||
@ -1,2 +1,3 @@
|
||||
BASE_URL= "https://vue3.go-admin.dev"
|
||||
VITE_BASE_URL= "//prod.hospital.admin.api.igandanyiyuan.com"
|
||||
VITE_BASE_URL= "//prod.hospital.admin.api.igandanyiyuan.com"
|
||||
VITE_IMG_URL="https://oss.prod.applets.igandanyiyuan.com"
|
||||
@ -1,2 +1,3 @@
|
||||
BASE_URL= "https://vue3.go-admin.dev"
|
||||
VITE_BASE_URL= "http://dev.hospital.admin.api.igandanyiyuan.com"
|
||||
VITE_IMG_URL="https://img.applets.igandanyiyuan.com"
|
||||
@ -27,3 +27,23 @@ export function productList(params){ //药品列表
|
||||
params
|
||||
})
|
||||
}
|
||||
export function getProductDetail(id){//药品列表
|
||||
return request({
|
||||
url:`/admin/order/product/${id}`,
|
||||
method: 'get'
|
||||
})
|
||||
}
|
||||
export function cancelInquiry(id,data){//取消问诊
|
||||
return request({
|
||||
url:`/admin/order/inquiry/cancel/${id}`,
|
||||
method: 'put',
|
||||
data
|
||||
})
|
||||
}
|
||||
export function cancelProduct(id,data){//取消药品
|
||||
return request({
|
||||
url:`/admin/order/product/cancel/${id}`,
|
||||
method: 'put',
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
BIN
src/assets/hasuse.png
Normal file
BIN
src/assets/hasuse.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 21 KiB |
BIN
src/assets/nowork.png
Normal file
BIN
src/assets/nowork.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 21 KiB |
BIN
src/assets/unuse.png
Normal file
BIN
src/assets/unuse.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 22 KiB |
75
src/components/confirmModal.vue
Normal file
75
src/components/confirmModal.vue
Normal file
@ -0,0 +1,75 @@
|
||||
<template>
|
||||
<a-modal v-model:visible="okVisible" :modal-style="{width:'420px'}" body-class="okmodal" @ok="handleConfirm"
|
||||
@cancel="handleClose" >
|
||||
<template #title>
|
||||
提示
|
||||
</template>
|
||||
<a-form :model="form" :rules="rules" ref="modalFormRef" size="medium" label-align="left" auto-label-width>
|
||||
<a-form-item field="cancel_remarks" label="理由" >
|
||||
<a-textarea v-model.trim="form.cancel_remarks" allow-clear placeholder="请输入取消订单理由"></a-textarea>
|
||||
</a-form-item>
|
||||
</a-form>
|
||||
<template #footer>
|
||||
<a-button @click="handleClose"><template #icon><icon-close /></template>取消</a-button>
|
||||
<a-button type="primary" @click="handleConfirm"><template #icon><icon-check /></template>确认</a-button>
|
||||
</template>
|
||||
|
||||
</a-modal>
|
||||
</template>
|
||||
<script setup>
|
||||
import { reactive, toRefs, getCurrentInstance } from 'vue';
|
||||
import { Message } from '@arco-design/web-vue';
|
||||
const { proxy } = getCurrentInstance();
|
||||
const form = reactive({
|
||||
cancel_remarks: ''
|
||||
});
|
||||
const props = defineProps({
|
||||
// 是否显示
|
||||
okVisible: {
|
||||
type: Boolean,
|
||||
default: false,
|
||||
},
|
||||
id:{
|
||||
type: String,
|
||||
default:'',
|
||||
},
|
||||
dealType:{
|
||||
type: String,
|
||||
default:'',
|
||||
},
|
||||
title:{
|
||||
type: String,
|
||||
default:'',
|
||||
},
|
||||
api: {
|
||||
type: Function,
|
||||
},
|
||||
});
|
||||
const emits = defineEmits(['closeChange']);
|
||||
const {okVisible,title,id,api} = toRefs(props);
|
||||
|
||||
// Akiraka 20230210 关闭弹窗
|
||||
const handleClose = () => {
|
||||
emits('closeChange', false);
|
||||
}
|
||||
// Akiraka 20230210 删除数据校验
|
||||
const rules = reactive({
|
||||
cancel_remarks: [{ required: true, message: '请输入取消订单理由' }]
|
||||
});
|
||||
// Akiraka 20230210 确认按钮 => 开始数据检查
|
||||
const handleConfirm = () => {
|
||||
proxy.$refs.modalFormRef.validate((valid) => {
|
||||
if (!valid) {
|
||||
api.value(id.value,form).then(response => {
|
||||
// Akiraka 20230210 关闭弹窗
|
||||
if(response.code==200){
|
||||
Message.success("取消成功");
|
||||
}else{
|
||||
proxy.$notification.error(response.message);
|
||||
}
|
||||
handleClose();
|
||||
})
|
||||
}
|
||||
})
|
||||
}
|
||||
</script>
|
||||
@ -413,7 +413,6 @@ import { getDoctorDetail, departmentList, decryptCard, hospitalList, expertiseLi
|
||||
import { ossSign, ossUpload } from '@/api/oss';
|
||||
import dayjs from 'dayjs'
|
||||
const { proxy } = getCurrentInstance();
|
||||
|
||||
const props = defineProps({
|
||||
// 是否显示
|
||||
doctorVisible: {
|
||||
|
||||
224
src/components/prescription.vue
Normal file
224
src/components/prescription.vue
Normal file
@ -0,0 +1,224 @@
|
||||
<template>
|
||||
<div class="container">
|
||||
<img src="../assets/hasuse.png" alt="" srcset="" class="status">
|
||||
<div class="header">
|
||||
<div class="chufang">普通处方</div>
|
||||
<div class="title">
|
||||
成都金牛欣欣相照互联网医院
|
||||
</div>
|
||||
<div class="title titlename">电子处方签</div>
|
||||
<div class="sicknum">处方号:<span>{{data.prescription_code}}</span></div>
|
||||
</div>
|
||||
<div class="table">
|
||||
<div class="row">
|
||||
<div class="left">
|
||||
<div class="name">日期:</div>
|
||||
<div class="desc">{{data.doctor_created_time}}</div>
|
||||
</div>
|
||||
<div class="right">
|
||||
<div class="name">科室:</div>
|
||||
<div class="desc">内科</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="left">
|
||||
<div class="name">姓名:</div>
|
||||
<div class="desc">陈晓丽</div>
|
||||
</div>
|
||||
<div class="right">
|
||||
<div class="name">性别:</div>
|
||||
<div class="desc">女</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="left">
|
||||
<div class="name">过敏史:</div>
|
||||
<div class="desc">无</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="left">
|
||||
<div class="name">初步判断:</div>
|
||||
<div class="desc">急性扁桃体炎</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="left">
|
||||
<div class="name">医生建议:</div>
|
||||
<div class="desc">急性扁桃体炎急性扁桃体炎急性扁桃体炎急性扁桃体炎急性扁桃体炎急性扁桃体炎急性扁桃体炎急性扁桃体炎急性扁桃体炎急性扁桃体炎急</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="rp">
|
||||
<div class="text">Rp</div>
|
||||
<div class="line"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="yaofang">
|
||||
<div class="row">
|
||||
<div class="name">我是电动车颗粒(50mg*11袋)</div>
|
||||
<div class="num">x1盒</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="name">用量:一次100mg 一日两次</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="name">用法:口服</div>
|
||||
</div>
|
||||
<div class="squre">
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<div class="signbox">
|
||||
<div class="row">
|
||||
<div class="left">
|
||||
<div class="name">医生签名:</div>
|
||||
<div class="desc">xxx</div>
|
||||
</div>
|
||||
<div class="right">
|
||||
<div class="name">药师签名:</div>
|
||||
<div class="desc">xxx</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="left">
|
||||
<div class="name">配药人员:</div>
|
||||
<div class="desc">xxx</div>
|
||||
</div>
|
||||
<div class="right">
|
||||
<div class="name">复核人员:</div>
|
||||
<div class="desc">xxx</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="tips">注意:处方有效期为3天,经本院审方中心审核通过后具有效力。</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
<script setup>
|
||||
import { toRefs} from 'vue';
|
||||
const props = defineProps({
|
||||
// 数组名称
|
||||
data: {
|
||||
type: Object,
|
||||
}
|
||||
|
||||
});
|
||||
const {data} = toRefs(props);
|
||||
</script>
|
||||
<style scoped>
|
||||
.container{
|
||||
box-shadow: 0 0 10px 0 #ccc;
|
||||
overflow: hidden;
|
||||
width:600px;
|
||||
height:auto;
|
||||
position: relative;
|
||||
border-radius:5px;
|
||||
padding:15px;
|
||||
background-color: #fff;;
|
||||
margin: 10px 0;
|
||||
}
|
||||
.header{
|
||||
position: relative;
|
||||
margin:48px 10px 0;
|
||||
font-size: 18px;
|
||||
text-align: center;
|
||||
border-bottom: 1px dashed #000;
|
||||
padding-bottom: 10px;
|
||||
}
|
||||
.status{
|
||||
position: absolute;
|
||||
width:140px;
|
||||
height:140px;
|
||||
z-index:9;
|
||||
top:20px;
|
||||
left:20px;
|
||||
}
|
||||
.titlename{
|
||||
margin-top: 15px;
|
||||
}
|
||||
.chufang{
|
||||
left:10px;
|
||||
position: absolute;
|
||||
top:-30px;
|
||||
width: 40px;
|
||||
font-size:20px;
|
||||
}
|
||||
.sicknum{
|
||||
text-align: right;
|
||||
font-size: 14px;
|
||||
margin:0 10px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: flex-end;
|
||||
}
|
||||
.sicknum span{
|
||||
font-size: 13px;
|
||||
font-weight: bold;
|
||||
}
|
||||
.table{
|
||||
margin:0 10px;
|
||||
}
|
||||
.table .row{
|
||||
margin: 8px 0;
|
||||
display: flex;
|
||||
font-size: 14px;
|
||||
}
|
||||
.row .left,.row .right{
|
||||
flex:1;
|
||||
display: flex;
|
||||
}
|
||||
.row .left .name,.row .right .name{
|
||||
white-space:nowrap;
|
||||
}
|
||||
.desc{
|
||||
flex:1;
|
||||
font-weight: bold;
|
||||
margin-left: 12px;
|
||||
}
|
||||
.rp{
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
.text{
|
||||
margin-right: 8px;
|
||||
}
|
||||
.line{
|
||||
flex:1;
|
||||
height:1px;
|
||||
background:#000;
|
||||
}
|
||||
.yaofang{
|
||||
margin:15px 10px 0;
|
||||
}
|
||||
.yaofang .row{
|
||||
font-size: 14px;
|
||||
display: flex;
|
||||
margin:5px 0px;
|
||||
justify-content: space-between;
|
||||
}
|
||||
.squre{
|
||||
margin-top: -20px;
|
||||
position: relative;
|
||||
width: 100%;
|
||||
height:0;
|
||||
padding-bottom: 50%;
|
||||
background:red;
|
||||
border-bottom:1px solid #000;
|
||||
background:linear-gradient(to bottom right,rgba(0,0,0,0) 0%,rgba(0,0,0,0)calc(50% - 1px),rgba(0,0,0,1)50%,rgba(0,0,0,0)calc(50% + 1px),rgba(0,0,0,0)100%)
|
||||
}
|
||||
.signbox{
|
||||
margin-top: 10px;
|
||||
}
|
||||
.signbox .row{
|
||||
font-size: 14px;
|
||||
margin:5px 10px;
|
||||
display: flex;
|
||||
}
|
||||
.tips{
|
||||
margin:15px 10px;
|
||||
text-align: center;
|
||||
font-size: 12px;
|
||||
}
|
||||
.yaofang .row{
|
||||
line-height: 22px;
|
||||
}
|
||||
</style>
|
||||
25
src/components/tableUnit.vue
Normal file
25
src/components/tableUnit.vue
Normal file
@ -0,0 +1,25 @@
|
||||
<template>
|
||||
|
||||
<a-table :columns="columns" :data="data" :pagination="pagination">
|
||||
<template #url="{ record }" wx:if="record.url">
|
||||
<a :href="record.url" target="_blank">查看处方</a>
|
||||
</template>
|
||||
</a-table>
|
||||
</template>
|
||||
<script setup>
|
||||
import {toRefs} from 'vue';
|
||||
const props = defineProps({
|
||||
// 数组名称
|
||||
data: {
|
||||
type: Array,
|
||||
},
|
||||
pagination:{
|
||||
type: Boolean,
|
||||
default:true
|
||||
},
|
||||
columns:{
|
||||
type: Array
|
||||
}
|
||||
});
|
||||
const { data, columns,pagination} = toRefs(props);
|
||||
</script>
|
||||
27
src/utils/format.js
Normal file
27
src/utils/format.js
Normal file
@ -0,0 +1,27 @@
|
||||
export const formatDoctorTitle=(val)=>{
|
||||
//医生职称(1:主任医师 2:主任中医师 3:副主任医师 4:副主任中医师 5:主治医师 6:住院医师)
|
||||
let data={1:'主任医师', 2:'主任中医师', 3:'副主任医师', 4:'副主任中医师', 5:'主治医师',6:'住院医师'}
|
||||
if(val){
|
||||
return data[val]
|
||||
}else{
|
||||
return ''
|
||||
}
|
||||
}
|
||||
export const formatPrescriptionStatus=(val)=>{
|
||||
//处方状态(1:待审核 2:待使用 3:已失效 4:已使用)
|
||||
let data={1:'待审核', 2:'待使用', 3:'已失效', 4:'已使用'}
|
||||
if(val){
|
||||
return data[val]
|
||||
}else{
|
||||
return ''
|
||||
}
|
||||
}
|
||||
export const formatPharmacistStatus=(val)=>{
|
||||
//pharmacist_audit_status药师审核状态(0:审核中 1:审核成功 2:审核驳回)
|
||||
let data={1:'审核中', 2:'审核成功', 3:'审核驳回'}
|
||||
if(val || val==0){
|
||||
return data[val]
|
||||
}else{
|
||||
return ''
|
||||
}
|
||||
}
|
||||
@ -1,24 +1,47 @@
|
||||
<template>
|
||||
<div class="app-container">
|
||||
<a-form :model="queryForm" ref="queryFormRef" layout="inline">
|
||||
|
||||
<a-form-item field="order_product_no" label="订单编号">
|
||||
<a-input :style="{ width: '182px' }" v-model="queryForm.order_product_no" placeholder="请输入订单编号" @press-enter="handleQuery" />
|
||||
<a-input
|
||||
:style="{ width: '182px' }"
|
||||
v-model="queryForm.order_product_no"
|
||||
placeholder="请输入订单编号"
|
||||
@press-enter="handleQuery"
|
||||
/>
|
||||
</a-form-item>
|
||||
<a-form-item field="mobile" label="医生姓名">
|
||||
<a-input :style="{ width: '182px' }" v-model="queryForm.doctor_name" placeholder="请输入医生姓名" @press-enter="handleQuery" />
|
||||
<a-input
|
||||
:style="{ width: '182px' }"
|
||||
v-model="queryForm.doctor_name"
|
||||
placeholder="请输入医生姓名"
|
||||
@press-enter="handleQuery"
|
||||
/>
|
||||
</a-form-item>
|
||||
<a-form-item field="hospital_name" label="就诊人姓名">
|
||||
<a-input :style="{ width: '182px' }" v-model="queryForm.patient_name" placeholder="请输入就诊人姓名" @press-enter="handleQuery" />
|
||||
<a-input
|
||||
:style="{ width: '182px' }"
|
||||
v-model="queryForm.patient_name"
|
||||
placeholder="请输入就诊人姓名"
|
||||
@press-enter="handleQuery"
|
||||
/>
|
||||
</a-form-item>
|
||||
<!-- <a-form-item field="department_custom_name" label="科室名称">
|
||||
<a-input v-model="queryForm.department_custom_name" placeholder="请输入科室名称" @press-enter="handleQuery" />
|
||||
</a-form-item> -->
|
||||
<a-form-item field="doctor_title" label="电话号码">
|
||||
<a-input :style="{ width: '182px' }" v-model="queryForm.mobile" placeholder="请输入医生电话号码" @press-enter="handleQuery" />
|
||||
</a-form-item>
|
||||
<a-form-item field="doctor_title" label="电话号码">
|
||||
<a-input
|
||||
:style="{ width: '182px' }"
|
||||
v-model="queryForm.mobile"
|
||||
placeholder="请输入医生或者患者电话号码"
|
||||
@press-enter="handleQuery"
|
||||
/>
|
||||
</a-form-item>
|
||||
<a-form-item field="order_product_status" label="订单状态">
|
||||
<a-select v-model="queryForm.order_product_status" placeholder="请选择订单状态" :style="{ width: '182px' }">
|
||||
<a-select
|
||||
v-model="queryForm.order_product_status"
|
||||
placeholder="请选择订单状态"
|
||||
:style="{ width: '182px' }"
|
||||
>
|
||||
<!-- 1:待支付 2:待发货 3:已发货 4:已签收 5:已取消 -->
|
||||
<a-option value="1">待支付</a-option>
|
||||
<a-option value="2">待发货</a-option>
|
||||
@ -29,185 +52,330 @@
|
||||
</a-form-item>
|
||||
<a-form-item>
|
||||
<a-space>
|
||||
<a-button type="primary" @click="handleQuery"><icon-search /> 搜索</a-button>
|
||||
<a-button type="primary" @click="handleQuery"
|
||||
><icon-search /> 搜索</a-button
|
||||
>
|
||||
<a-button @click="handleResetQuery"><icon-loop /> 重置</a-button>
|
||||
</a-space>
|
||||
</a-form-item>
|
||||
</a-form>
|
||||
|
||||
<a-divider />
|
||||
|
||||
<!-- action -->
|
||||
<div class="action">
|
||||
<a-space>
|
||||
<a-button v-has="'admin:sysDoctorList:add'" type="primary" @click="handleAdd"><icon-plus /> 新增 </a-button>
|
||||
<!-- <a-button v-has="'admin:sysDoctorList:remove'" type="primary" status="danger"><icon-delete /> 批量删除 </a-button> -->
|
||||
</a-space>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- table -->
|
||||
<a-table
|
||||
:columns="columns"
|
||||
:data="tableData"
|
||||
:pagination="{ 'show-total': true, 'show-jumper': true, 'show-page-size': true, total: pager.total, current: currentPage }"
|
||||
:pagination="{
|
||||
'show-total': true,
|
||||
'show-jumper': true,
|
||||
'show-page-size': true,
|
||||
total: pager.total,
|
||||
current: currentPage,
|
||||
}"
|
||||
:row-selection="{ type: 'checkbox', showCheckedAll: true }"
|
||||
row-key="post_id"
|
||||
@selection-change="(selection) => {deleteData = selection;}"
|
||||
@selection-change="
|
||||
(selection) => {
|
||||
deleteData = selection;
|
||||
}
|
||||
"
|
||||
@page-change="handlePageChange"
|
||||
@page-size-change="handlepage_sizeChange"
|
||||
>
|
||||
<template #post_id="{record,rowIndex}">
|
||||
<div>{{(rowIndex+1)+(pager.page-1)*10}}</div>
|
||||
<template #post_id="{ record, rowIndex }">
|
||||
<div>{{ rowIndex + 1 + (pager.page - 1) * 10 }}</div>
|
||||
</template>
|
||||
<template #pay_channel="{record}">
|
||||
<div v-if="record.pay_channel==1">小程序支付</div>
|
||||
<div v-else-if="record.pay_channel==2">微信扫码支付</div>
|
||||
<div v-else-if="record.pay_channel==3">模拟支付</div>
|
||||
<template #pay_channel="{ record }">
|
||||
<div v-if="record.pay_channel == 1">小程序支付</div>
|
||||
<div v-else-if="record.pay_channel == 2">微信扫码支付</div>
|
||||
<div v-else-if="record.pay_channel == 3">模拟支付</div>
|
||||
</template>
|
||||
<!-- 1:待支付 2:待分配 3:待接诊 4:已接诊 5:已完成 6:已结束 7:已取消) -->
|
||||
<template #order_product_status="{record}">
|
||||
<div>{{formatProductStatus(record.order_product_status)}}</div>
|
||||
<!-- <div v-if="==1">待支付</div>
|
||||
<div v-else-if="record.order_product_status==2">待分配</div>
|
||||
<div v-else-if="record.order_product_status==3">待接诊</div>
|
||||
<div v-else-if="record.order_product_status==4">已接诊</div>
|
||||
<div v-else-if="record.order_product_status==5">已完成</div>
|
||||
<div v-else-if="record.order_product_status==6">已结束</div>
|
||||
<div v-else-if="record.order_product_status==7">已取消</div> -->
|
||||
<template #order_product_status="{ record }">
|
||||
<div>{{ formatProductStatus(record.order_product_status) }}</div>
|
||||
</template>
|
||||
<template #amount_total="{ record }">
|
||||
{{(record.amount_total) }}元
|
||||
</template>
|
||||
<template #payment_amount_total="{ record }">
|
||||
{{(record.payment_amount_total) }}元
|
||||
</template>
|
||||
<template #pay_time="{ record }">
|
||||
{{ parseTime(record.pay_time) }}
|
||||
</template>
|
||||
|
||||
<template #patient_name_mask="{ record }">
|
||||
{{record.patient_name_mask}}({{record.patient_sex==1?'男,':'女,'}}{{record.patient_age}}岁)
|
||||
</template>
|
||||
<template #action="{ record }">
|
||||
<a-space>
|
||||
<a-button v-has="'admin:sysDoctorList:detail'" type="text"
|
||||
@click="handleDetail(record)"><icon-book />详情</a-button>
|
||||
<a-button
|
||||
v-has="'admin:sysProductList:detail'"
|
||||
type="text"
|
||||
@click="handleDetail(record)"
|
||||
><icon-book />详情</a-button
|
||||
>
|
||||
<!-- <a-button v-has="'admin:sysPost:remove'" type="text" @click="() => { deleteVisible = true; deleteData = [record.post_id]; }"><icon-delete /> 删除</a-button> -->
|
||||
</a-space>
|
||||
</template>
|
||||
</a-table>
|
||||
<!-- Modal -->
|
||||
<a-modal v-model:visible="modalVisible" fullscreen :title="modalTitle" title-align="start" :footer="false"
|
||||
@before-ok="handleSubmit" @close="() => {$refs.modalFormRef.resetFields(); modalForm.doctor_id = null;}">
|
||||
<!-- Modal -->
|
||||
<a-modal
|
||||
v-model:visible="modalVisible"
|
||||
fullscreen
|
||||
:title="modalTitle"
|
||||
title-align="start"
|
||||
:footer="false"
|
||||
@before-ok="handleSubmit"
|
||||
@close="
|
||||
() => {
|
||||
$refs.modalFormRef.resetFields();
|
||||
modalForm.doctor_id = null;
|
||||
}
|
||||
"
|
||||
>
|
||||
<div class="titlebox">
|
||||
<div class="bar"></div>
|
||||
<div class="name">订单信息</div>
|
||||
</div>
|
||||
<a-form :model="modalForm" :disabled="true" :rules="rules" ref="modalFormRef" :auto-label-width="true">
|
||||
<a-row :gutter="24" style="margin-top: 35px;">
|
||||
<a-form
|
||||
:model="modalForm"
|
||||
:rules="rules"
|
||||
ref="modalFormRef"
|
||||
:auto-label-width="true"
|
||||
>
|
||||
<a-row :gutter="24" style="margin-top: 35px">
|
||||
<a-col :span="12">
|
||||
<a-form-item field="inquiry_no" label="订单编号:">
|
||||
<span>{{ modalForm.inquiry_no }}</span>
|
||||
<span>{{ modalForm.order_product_no }}</span>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<a-form-item field="order_product_status" label="订单状态:" >
|
||||
<span>{{ formatRefundStatus(modalForm.order_product_status) }}</span>
|
||||
<a-form-item field="order_product_status" label="处方编号:">
|
||||
<span v-if="modalForm.order_prescription">{{
|
||||
modalForm.order_prescription.order_prescription_id
|
||||
}}</span>
|
||||
<span v-else>暂无</span>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-row :gutter="24" >
|
||||
<a-row :gutter="24">
|
||||
<a-col :span="12">
|
||||
<a-form-item field="user.created_at" label="下单时间:">
|
||||
<span >{{modalForm.created_at}}</span>
|
||||
<span>{{ modalForm.created_at }}</span>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<a-form-item field="pay_time" label="支付时间:">
|
||||
<span >{{modalForm.pay_time}}</span>
|
||||
<span>{{ modalForm.pay_time }}</span>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-row :gutter="24">
|
||||
<a-col :span="12">
|
||||
<a-form-item field="amount_total" label="订单金额:">
|
||||
<span>{{modalForm.amount_total}}</span>
|
||||
<span>{{ modalForm.amount_total }}</span>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<a-form-item field="coupon_amount_total" label="优惠卷:">
|
||||
<span>{{modalForm.coupon_amount_total}}</span>
|
||||
<a-form-item field="logistics_fee" label="邮费:">
|
||||
<span>{{ modalForm.logistics_fee }}</span>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-row :gutter="24">
|
||||
<a-col :span="12">
|
||||
<a-form-item field="payment_amount_total" label="实付金额:">
|
||||
<span>{{modalForm.payment_amount_total}}</span>
|
||||
<span>{{ modalForm.payment_amount_total }}</span>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<a-form-item field="inquiry_type" label="问诊类型:">
|
||||
<span>{{formatInquiryType(modalForm.inquiry_type)}}</span>
|
||||
<a-form-item field="order_product_status" label="订单状态:">
|
||||
<span>{{
|
||||
formatRefundStatus(modalForm.order_product_status)
|
||||
}}</span>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-row :gutter="24" v-if="modalForm.cancel_remarks">
|
||||
<a-col :span="24">
|
||||
<a-form-item field="department_custom_name" label="备 注 :">
|
||||
<span>{{ modalForm.cancel_remarks}}</span>
|
||||
</a-form-item>
|
||||
<span>{{ modalForm.cancel_remarks }}</span>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-divider />
|
||||
<div class="titlebox" v-if="modalForm.order_inquiry_refund">
|
||||
<div class="titlebox" v-if="modalForm.order_product_refund">
|
||||
<div class="bar"></div>
|
||||
<div class="name">退款信息</div>
|
||||
</div>
|
||||
<a-row :gutter="24" style="margin-top: 35px;" v-if="modalForm.order_inquiry_refund">
|
||||
<a-row
|
||||
:gutter="24"
|
||||
style="margin-top: 35px"
|
||||
v-if="modalForm.order_product_refund"
|
||||
>
|
||||
<a-col :span="12">
|
||||
<a-form-item field="inquiry_refund_no" label="退款编号:">
|
||||
<span>{{modalForm.order_inquiry_refund.inquiry_refund_no}}</span>
|
||||
<span>{{
|
||||
modalForm.order_product_refund.product_refund_no
|
||||
}}</span>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<a-form-item field="escrow_trade_no" label=" 第三方订单编号:">
|
||||
<span>{{modalForm.escrow_trade_no}}</span>
|
||||
|
||||
</a-form-item>
|
||||
<span>{{ modalForm.order_product_refund.refund_id }}</span>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-row :gutter="24" v-if="modalForm.order_inquiry_refund">
|
||||
<a-row :gutter="24" v-if="modalForm.order_product_refund">
|
||||
<a-col :span="12">
|
||||
<a-form-item field="inquiry_refund_no" label="退款金额:">
|
||||
<span>{{modalForm.order_inquiry_refund.refund_total}}</span>
|
||||
<span>{{ modalForm.order_product_refund.refund_total }}</span>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<a-form-item field="escrow_trade_no" label="退款状态:">
|
||||
<span>{{formatRefundStatus(modalForm.order_inquiry_refund.inquiry_refund_status)}}</span>
|
||||
|
||||
</a-form-item>
|
||||
<span>{{
|
||||
formatRefundStatus(
|
||||
modalForm.order_product_refund.product_refund_status
|
||||
)
|
||||
}}</span>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-row :gutter="24" v-if="modalForm.order_inquiry_refund">
|
||||
<a-row :gutter="24" v-if="modalForm.order_product_refund">
|
||||
<a-col :span="24">
|
||||
<a-form-item field="inquiry_refund_no" label="退款时间:">
|
||||
<span>{{modalForm.order_inquiry_refund.success_time}}</span>
|
||||
<span>{{ modalForm.order_product_refund.success_time }}</span>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-row :gutter="24" v-if="modalForm.order_inquiry_refund">
|
||||
<a-row :gutter="24" v-if="modalForm.order_product_refund">
|
||||
<a-col :span="24">
|
||||
<a-form-item field="inquiry_refund_no" label="退款原因:">
|
||||
<span>{{modalForm.order_inquiry_refund.refund_reason}}</span>
|
||||
<span>{{ modalForm.order_product_refund.refund_reason }}</span>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-divider v-if="modalForm.order_inquiry_refund"/>
|
||||
<div class="titlebox" v-if="modalForm.user_doctor">
|
||||
<a-divider v-if="modalForm.order_product_refund" />
|
||||
<div class="titlebox" v-if="modalForm.order_product_item.length > 0">
|
||||
<div class="bar"></div>
|
||||
<div class="name">医生信息</div>
|
||||
<a-space style="margin-right: 8px;flex:1;display: flex;justify-content: flex-end;">
|
||||
<a-button type="primary" @click="openDcotor">查看医生完整信息1</a-button>
|
||||
</a-space>
|
||||
<div class="name">药品信息</div>
|
||||
</div>
|
||||
<a-row :gutter="24" style="margin-top: 35px;" v-if="modalForm.user_doctor">
|
||||
<a-row
|
||||
:gutter="24"
|
||||
style="margin-top: 35px"
|
||||
v-if="modalForm.order_product_item.length > 0"
|
||||
>
|
||||
<a-col :span="24">
|
||||
<a-form-item field="license_cert" :hide-label="true">
|
||||
<a-list>
|
||||
<a-list-item
|
||||
v-for="item in modalForm.order_product_item"
|
||||
:key="item.product_item_id"
|
||||
>
|
||||
<a-list-item-meta
|
||||
:title="item.product_name + item.product_spec"
|
||||
:description="item.manufacturer + '*' + item.amount"
|
||||
>
|
||||
<template #avatar>
|
||||
<a-avatar shape="square">
|
||||
<img
|
||||
alt="avatar"
|
||||
src="https://p1-arco.byteimg.com/tos-cn-i-uwbnlip3yd/3ee5f13fb09879ecb5185e440cef6eb9.png~tplv-uwbnlip3yd-webp.webp"
|
||||
/>
|
||||
</a-avatar>
|
||||
</template>
|
||||
</a-list-item-meta>
|
||||
</a-list-item>
|
||||
</a-list>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-divider v-if="modalForm.order_product_item.length > 0" />
|
||||
<div class="titlebox">
|
||||
<div class="bar"></div>
|
||||
<div class="name">地址信息</div>
|
||||
</div>
|
||||
<a-row :gutter="24" style="margin-top: 35px">
|
||||
<a-col :span="24">
|
||||
<a-form-item field="license_cert" :hide-label="true">
|
||||
<div class="doctorInfo">
|
||||
<div class="infobox">
|
||||
<div class="row">
|
||||
<div class="row">
|
||||
<div class="nameDesc">收货人姓名:</div>
|
||||
<div class="desc">
|
||||
{{ modalForm.consignee_name_mask }}
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="nameDesc">收货人电话:</div>
|
||||
<div class="desc">
|
||||
{{ modalForm.consignee_tel_mask }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="nameDesc">收货人地址:</div>
|
||||
<div class="desc">
|
||||
{{ modalForm.address_mask }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-divider />
|
||||
<div class="titlebox" >
|
||||
<div class="bar"></div>
|
||||
<div class="name">物流信息</div>
|
||||
</div>
|
||||
<a-row
|
||||
:gutter="24"
|
||||
style="margin-top: 35px"
|
||||
|
||||
>
|
||||
<a-col :span="24">
|
||||
<a-form-item field="license_cert" :hide-label="true">
|
||||
<div class="timeline" v-if="modalForm.order_product_logistics">
|
||||
<a-timeline >
|
||||
<a-timeline-item :label="item.time" :dotColor="formatColor(item.status)" v-for="item in cur_express">
|
||||
{{item.context}}
|
||||
</a-timeline-item>
|
||||
</a-timeline>
|
||||
<a-button @click="toggleExpand" class="expand">{{isExpand?"收起":"展开"}}</a-button>
|
||||
</div>
|
||||
<div v-else>暂无物流信息</div>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
</a-row>
|
||||
</a-form>
|
||||
<a-divider />
|
||||
<div class="titlebox" v-if="modalForm.order_prescription">
|
||||
<div class="bar"></div>
|
||||
<div class="name">处方信息</div>
|
||||
</div>
|
||||
<a-row :gutter="24" style="margin-top: 35px;" v-if="modalForm.order_prescription">
|
||||
<a-col :span="24">
|
||||
<a-form-item field="license_cert" :hide-label="true" >
|
||||
<div class="doctorInfo">
|
||||
<tableUnit :pagination="false" :columns="chufang_columns" :data="chufang_data"></tableUnit>
|
||||
<!-- <prescription :data="modalForm.order_prescription"></prescription> -->
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-divider v-if="modalForm.order_prescription"/>
|
||||
<div class="titlebox" v-if="modalForm.user_doctor">
|
||||
<div class="bar"></div>
|
||||
<div class="name">医生信息</div>
|
||||
<a-space style="margin-right: 8px;flex:1;display: flex;justify-content: flex-end;" >
|
||||
<a-button type="primary" @click="openDcotor">查看医生完整信息</a-button>
|
||||
</a-space>
|
||||
</div>
|
||||
<a-row :gutter="24" style="margin-top: 35px;" >
|
||||
<a-col :span="24">
|
||||
<a-form-item field="license_cert" :hide-label="true" >
|
||||
<div class="doctorInfo" v-if="modalForm.user_doctor">
|
||||
<a-space size="large">
|
||||
<a-image width="80" height="80" class="headImg" :src="modalForm.user_doctor.avatar" v-if="modalForm.user_doctor.avatar">
|
||||
</a-image>
|
||||
@ -215,10 +383,11 @@
|
||||
</a-image>
|
||||
</a-space>
|
||||
<div class="infobox">
|
||||
<div class="name">{{modalForm.user_doctor.user_name}} {{modalForm.user_doctor.doctor_title}}</div>
|
||||
<div class="name">{{modalForm.user_doctor.user_name}} {{formatDoctorTitle(modalForm.user_doctor.doctor_title)}}</div>
|
||||
<div class="hospital">{{modalForm.user_doctor.hospital.hospital_name}} {{modalForm.user_doctor.department_custom_name}}</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="doctorInfo" v-else>暂未分配到医生</div>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
</a-row>
|
||||
@ -227,7 +396,7 @@
|
||||
<div class="bar"></div>
|
||||
<div class="name">就诊人信息</div>
|
||||
<a-space style="margin-right: 8px;flex:1;display: flex;justify-content: flex-end;">
|
||||
<a-button type="primary" status="warning" @click="()=>okVisible=true">查看就诊人完整信息</a-button>
|
||||
<a-button type="primary" status="warning" @click="openPatient">查看就诊人完整信息</a-button>
|
||||
</a-space>
|
||||
</div>
|
||||
<a-row :gutter="24" style="margin-top: 35px;" v-if="modalForm.user_doctor">
|
||||
@ -237,7 +406,7 @@
|
||||
<div class="infobox">
|
||||
<div class="row">
|
||||
<div class="nameDesc">就诊人姓名:</div>
|
||||
<div class="desc">{{modalForm.patient_name_mask}} ({{modalForm.patient_sex=1?'男':'女'}} {{modalForm.patient_age}}岁)</div>
|
||||
<div class="desc">{{modalForm.order_inquiry_case.name}} ({{modalForm.order_inquiry_case.sex=1?'男':'女'}} {{modalForm.order_inquiry_case.age}}岁)</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="nameDesc">确诊疾病:</div>
|
||||
@ -252,79 +421,99 @@
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
</a-row>
|
||||
</a-form>
|
||||
<a-divider v-if="modalForm.user_doctor"/>
|
||||
<div class="titlebox" v-if="modalForm.order_evaluation">
|
||||
<div class="bar"></div>
|
||||
<div class="name">评价信息</div>
|
||||
</div>
|
||||
<a-row :gutter="24" style="margin-top: 35px;" v-if="modalForm.order_evaluation">
|
||||
<a-col :span="24">
|
||||
<a-form-item field="" label="" no-style>
|
||||
<div class="infobox commentbox">
|
||||
<div class="row">
|
||||
<div class="nameDesc">回复质量:</div>
|
||||
<div class="desc"><a-rate :default-value="modalForm.order_evaluation.reply_quality" readonly /></div>
|
||||
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="nameDesc">服务态度:</div>
|
||||
<div class="desc"><a-rate :default-value="modalForm.order_evaluation.service_attitude" readonly /></div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="nameDesc">回复速度:</div>
|
||||
<div class="desc"><a-rate :default-value="modalForm.order_evaluation.reply_progress" readonly /></div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="nameDesc">评价内容:</div>
|
||||
<div class="desc">{{ modalForm.order_evaluation.content }}</div>
|
||||
</div>
|
||||
</div>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-divider v-if="modalForm.order_evaluation"/>
|
||||
<div class="titlebox" >
|
||||
<a-divider />
|
||||
<div class="titlebox">
|
||||
<div class="bar"></div>
|
||||
<div class="name">操作</div>
|
||||
</div>
|
||||
<a-row :gutter="24" style="margin-top: 35px;" >
|
||||
<a-row :gutter="24" style="margin-top: 35px">
|
||||
<a-col :span="24">
|
||||
<a-form-item field="" label="" no-style>
|
||||
<a-space style="margin-right: 8px;">
|
||||
<a-button type="primary" @click="()=>okVisible=true">问诊记录</a-button>
|
||||
<a-space style="margin-right: 8px">
|
||||
<a-button type="primary" @click="() => (alert('开发中'))"
|
||||
>上报处方平台</a-button
|
||||
>
|
||||
</a-space>
|
||||
<a-space style="margin-right: 8px;">
|
||||
<a-button type="primary" status="danger" @click="()=>okVisible=true">删除订单</a-button>
|
||||
<a-space style="margin-right: 8px" v-if="modalForm.order_product_status==2">
|
||||
<a-button
|
||||
type="primary"
|
||||
v-has="'admin:sysProductList:cancel'"
|
||||
status="danger"
|
||||
@click="()=>{okVisible=true;cur_product_id=modalForm.order_inquiry_id;}"
|
||||
>取消药品订单</a-button
|
||||
>
|
||||
</a-space>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
</a-row>
|
||||
</a-modal>
|
||||
|
||||
<!-- 医生详情弹框 -->
|
||||
<doctorModal :visable="doctorVisible" @doctorVisibleChange="() => {doctorVisible = false;doctor_id='';}"></doctorModal>
|
||||
<!-- 医生详情弹框 -->
|
||||
<doctorModal :doctorVisible="doctorVisible" :doctor_id="doctor_id" @doctorVisibleChange="() => {doctorVisible = false;doctor_id='';}"></doctorModal>
|
||||
<confirmModal :okVisible="okVisible" :api="cancelProduct" :title="'确定取消此订单吗?'" :dealType="'order_inquiry_id'" :id="cur_product_id" @closeChange="closeChange"></confirmModal>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import { reactive, ref, getCurrentInstance, onMounted, nextTick, watch } from 'vue';
|
||||
import {productList} from '@/api/order/list';
|
||||
import {
|
||||
reactive,
|
||||
ref,
|
||||
getCurrentInstance,
|
||||
onMounted,
|
||||
nextTick,
|
||||
watch,
|
||||
} from 'vue';
|
||||
import { productList, getProductDetail,cancelProduct} from '@/api/order/list';
|
||||
import { parseTime } from '@/utils/parseTime';
|
||||
|
||||
import {formatDoctorTitle,formatPrescriptionStatus,formatPharmacistStatus} from "@/utils/format"
|
||||
const IMG_URL=import.meta.env.VITE_IMG_URL;
|
||||
// Akiraka 20230210 删除数据
|
||||
const deleteData = ref([])
|
||||
const deleteData = ref([]);
|
||||
// Akiraka 20230210 删除对话框
|
||||
const deleteVisible = ref(false)
|
||||
const deleteVisible = ref(false);
|
||||
// Akiraka 20230210 监听删除事件
|
||||
|
||||
const doctorVisible=ref(false);
|
||||
const doctor_id=ref('');
|
||||
watch(() => deleteVisible.value ,(value) => {
|
||||
if ( value == false ) {
|
||||
getProductInfo(pager);
|
||||
const okVisible=ref(false);
|
||||
const cur_product_id=ref('');
|
||||
const doctorVisible = ref(false);
|
||||
const doctor_id = ref('');
|
||||
let express=[];//物流信息;
|
||||
const cur_express=ref([]);
|
||||
const isExpand=ref(false)
|
||||
const chufang_columns=reactive([
|
||||
{
|
||||
title: '处方编号',
|
||||
dataIndex: 'prescription_code',
|
||||
},
|
||||
{
|
||||
title: '处方状态',
|
||||
dataIndex: 'prescription_status',
|
||||
},
|
||||
{
|
||||
title: '药师审核状态',
|
||||
dataIndex: 'pharmacist_audit_status',
|
||||
},
|
||||
{
|
||||
title: '医嘱',
|
||||
dataIndex: 'doctor_advice',
|
||||
},
|
||||
{
|
||||
title: '药师驳回原因',
|
||||
dataIndex: 'pharmacist_fail_reason',
|
||||
},
|
||||
{
|
||||
title: '处方链接',
|
||||
dataIndex: 'url',
|
||||
slotName:"url"
|
||||
}
|
||||
]);
|
||||
let chufang_data=reactive([])
|
||||
watch(
|
||||
() => deleteVisible.value,
|
||||
(value) => {
|
||||
if (value == false) {
|
||||
getProductInfo(pager);
|
||||
}
|
||||
}
|
||||
})
|
||||
);
|
||||
|
||||
const { proxy } = getCurrentInstance();
|
||||
|
||||
@ -338,16 +527,16 @@ const pager = {
|
||||
// form
|
||||
const queryForm = reactive({});
|
||||
const modalForm = reactive({
|
||||
sort: 0,
|
||||
status: 1,
|
||||
order_inquiry_refund:{},
|
||||
order_evaluation:null
|
||||
|
||||
order_product_refund: {},
|
||||
order_product_item: [],
|
||||
order_product_logistics: null,
|
||||
user_doctor: null,
|
||||
order_prescription: null,
|
||||
});
|
||||
|
||||
// Rules
|
||||
const rules = {
|
||||
post_name: [{ required: true, message: '请输入岗位名称' }]
|
||||
post_name: [{ required: true, message: '请输入岗位名称' }],
|
||||
};
|
||||
|
||||
// Modal
|
||||
@ -359,16 +548,20 @@ let batchList = [];
|
||||
|
||||
// Table Columns
|
||||
const columns = [
|
||||
{ title: '排序', dataIndex: 'post_id',slotName: 'post_id' },
|
||||
{ title: '排序', dataIndex: 'post_id', slotName: 'post_id' },
|
||||
{ title: '订单编号', dataIndex: 'order_product_no' },
|
||||
{ title: '处方编号', dataIndex: 'order_prescription_id' },
|
||||
{ title: '医生姓名', dataIndex: 'doctor_name' },
|
||||
{ title: '就诊人姓名', dataIndex: 'patient_name_mask' },
|
||||
// { title: '医生联系电话', dataIndex: 'patient_name' },
|
||||
{ title: '订单金额', dataIndex: 'amount_total' },
|
||||
{ title: '实付金额', dataIndex: 'payment_amount_total' },
|
||||
{ title: '支付方式', dataIndex: 'pay_channel',slotName: 'pay_channel'},
|
||||
{ title: '订单状态', dataIndex: 'order_product_status', slotName:'order_product_status' },
|
||||
{ title: '就诊人', dataIndex: 'patient_name_mask',slotName:'patient_name_mask' },
|
||||
{ title: '就诊人联系电话', dataIndex: 'patient_mobile' },
|
||||
{ title: '订单金额', dataIndex: 'amount_total',slotName:'amount_total' },
|
||||
{ title: '实付金额', dataIndex: 'payment_amount_total',slotName:'payment_amount_total' },
|
||||
{ title: '支付方式', dataIndex: 'pay_channel', slotName: 'pay_channel' },
|
||||
{
|
||||
title: '订单状态',
|
||||
dataIndex: 'order_product_status',
|
||||
slotName: 'order_product_status',
|
||||
},
|
||||
{ title: '支付时间', dataIndex: 'pay_time', slotName: 'pay_time' },
|
||||
{ title: '操作', slotName: 'action' },
|
||||
];
|
||||
@ -399,16 +592,19 @@ const handleSubmit = (done) => {
|
||||
let res;
|
||||
if (!modalForm.post_id) {
|
||||
const { code, message } = await addPost(modalForm);
|
||||
if (code == 200 ) {
|
||||
if (code == 200) {
|
||||
proxy.$notification.success('新增成功');
|
||||
} else {
|
||||
proxy.$notification.error(message);
|
||||
}
|
||||
} else {
|
||||
console.log("post_id:"+modalForm.post_id)
|
||||
console.log('post_id:' + modalForm.post_id);
|
||||
|
||||
const { code, message } = await updatePost(modalForm, modalForm.post_id);
|
||||
if (code == 200 ) {
|
||||
const { code, message } = await updatePost(
|
||||
modalForm,
|
||||
modalForm.post_id
|
||||
);
|
||||
if (code == 200) {
|
||||
proxy.$notification.success('更新成功');
|
||||
} else {
|
||||
proxy.$notification.error(message);
|
||||
@ -423,13 +619,11 @@ const handleSubmit = (done) => {
|
||||
});
|
||||
};
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 分页改变
|
||||
* @param {Number} [page]
|
||||
*/
|
||||
const handlePageChange = (page) => {
|
||||
const handlePageChange = (page) => {
|
||||
pager.page = page;
|
||||
|
||||
// 修改当前页码
|
||||
@ -446,9 +640,13 @@ const handlepage_sizeChange = (page_size) => {
|
||||
// 获取岗位信息
|
||||
const getProductInfo = async (params = {}) => {
|
||||
const { data, code, message } = await productList(params);
|
||||
if ( code == 200 ) {
|
||||
if (code == 200) {
|
||||
tableData.value = data.data;
|
||||
Object.assign(pager, { total: data.total, page: data.page, page_size: data.page_size });
|
||||
Object.assign(pager, {
|
||||
total: data.total,
|
||||
page: data.page,
|
||||
page_size: data.page_size,
|
||||
});
|
||||
} else {
|
||||
proxy.$notification.error(message);
|
||||
}
|
||||
@ -456,7 +654,7 @@ const getProductInfo = async (params = {}) => {
|
||||
|
||||
// 查询岗位信息
|
||||
const handleQuery = async () => {
|
||||
pager.page=1;
|
||||
pager.page = 1;
|
||||
const params = {
|
||||
page: pager.page,
|
||||
page_size: pager.page_size,
|
||||
@ -466,53 +664,104 @@ const handleQuery = async () => {
|
||||
getProductInfo(params);
|
||||
};
|
||||
//获取订单详情
|
||||
const handleDetail = async (record) => {
|
||||
alert("开发中");return;
|
||||
modalVisible.value = true;
|
||||
modalTitle.value = '订单详情';
|
||||
const { code, data, message } = await getOrderDetail(record.order_inquiry_id);
|
||||
if (code == 200) {
|
||||
Object.assign(modalForm, data);
|
||||
}
|
||||
const handleDetail = async (record) => {
|
||||
modalVisible.value = true;
|
||||
modalTitle.value = '药品订单详情';
|
||||
const { code, data, message } = await getProductDetail(
|
||||
record.order_product_id
|
||||
);
|
||||
if (code == 200) {
|
||||
Object.assign(modalForm, data);
|
||||
let result=data.order_prescription;
|
||||
express=data.order_product_logistics && JSON.parse(data.order_product_logistics.logistics_content);
|
||||
cur_express.value=express.slice(0,1);
|
||||
let data_arr=[{}];
|
||||
if(result){
|
||||
chufang_columns.forEach((item)=>{
|
||||
if(item.dataIndex=="prescription_status"){
|
||||
data_arr[0][item.dataIndex]=formatPrescriptionStatus(result[item.dataIndex])
|
||||
}else if(item.dataIndex=="pharmacist_audit_status"){
|
||||
data_arr[0][item.dataIndex]=formatPharmacistStatus(result[item.dataIndex])
|
||||
}else if(item.dataIndex=="url"){
|
||||
data_arr[0][item.dataIndex]=IMG_URL+'/applet/prescription/'+result.order_prescription_id+'.pdf'
|
||||
}else if(item.dataIndex=="pharmacist_fail_reason"){
|
||||
data_arr[0][item.dataIndex]=result[item.dataIndex]?result[item.dataIndex]:'暂无'
|
||||
}else{
|
||||
data_arr[0][item.dataIndex]=result[item.dataIndex]
|
||||
}
|
||||
});
|
||||
console.log(data_arr)
|
||||
chufang_data=data_arr;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
};
|
||||
const formatProductStatus = (val) => {
|
||||
//订单状态(<!-- 1:待支付 2:待发货 3:已发货 4:已签收 5:已取消 -->
|
||||
let data = {
|
||||
1: '待支付',
|
||||
2: '待发货',
|
||||
3: '已发货',
|
||||
4: '已签收',
|
||||
5: '已取消',
|
||||
};
|
||||
const formatProductStatus=(val)=>{
|
||||
//订单状态(<!-- 1:待支付 2:待发货 3:已发货 4:已签收 5:已取消 -->
|
||||
let data={1:'待支付', 2:'待发货', 3:'已发货', 4:'已签收', 5:'已取消'}
|
||||
if(val){
|
||||
return data[val]
|
||||
}else{
|
||||
return ''
|
||||
}
|
||||
if (val) {
|
||||
return data[val];
|
||||
} else {
|
||||
return '';
|
||||
}
|
||||
const formatRefundStatus=(val)=>{
|
||||
//问诊订单退款状态(0:无退款 1:申请退款 2:退款中 3:退款成功 4:拒绝退款 5:退款关闭 6:退款异常)
|
||||
let data={0:'无退款', 1:'申请退款', 2:'退款中',3:'退款成功', 4:'拒绝退款', 5:'退款关闭', 6:'退款异常'}
|
||||
if(val || val==0){
|
||||
return data[val]
|
||||
}else{
|
||||
return ''
|
||||
}
|
||||
};
|
||||
const formatRefundStatus = (val) => {
|
||||
//问诊订单退款状态(0:无退款 1:申请退款 2:退款中 3:退款成功 4:拒绝退款 5:退款关闭 6:退款异常)
|
||||
let data = {
|
||||
0: '无退款',
|
||||
1: '申请退款',
|
||||
2: '退款中',
|
||||
3: '退款成功',
|
||||
4: '拒绝退款',
|
||||
5: '退款关闭',
|
||||
6: '退款异常',
|
||||
};
|
||||
if (val || val == 0) {
|
||||
return data[val];
|
||||
} else {
|
||||
return '';
|
||||
}
|
||||
const formatInquiryType=(val)=>{
|
||||
//订单类型(1:专家问诊 2:快速问诊 3:公益问诊 4:问诊购药 5:检测)
|
||||
let data={1:'专家问诊', 2:'快速问诊', 3:'公益问诊', 4:'问诊购药', 5:'糖组检测'}
|
||||
if(val){
|
||||
return data[val]
|
||||
}else{
|
||||
return ''
|
||||
}
|
||||
};
|
||||
const formatColor=(value)=>{
|
||||
if(value=="签收"){
|
||||
return "#00B42A"
|
||||
}else{
|
||||
return "var(--color-fill-4)"
|
||||
}
|
||||
|
||||
};
|
||||
const toggleExpand=()=>{
|
||||
isExpand.value=!isExpand.value;
|
||||
if(isExpand.value){
|
||||
cur_express.value=express.slice(0,-1)
|
||||
}else{
|
||||
cur_express.value=express.slice(0,1)
|
||||
}
|
||||
};
|
||||
//关闭确认框
|
||||
const closeChange=()=>{
|
||||
cur_product_id.value="";
|
||||
okVisible.value=false
|
||||
}
|
||||
// 重置搜索
|
||||
const handleResetQuery = () => {
|
||||
proxy.$refs.queryFormRef.resetFields();
|
||||
|
||||
getProductInfo(queryForm);
|
||||
}
|
||||
};
|
||||
const openDcotor=()=>{
|
||||
alert("11")
|
||||
doctor_id.value=modalForm.doctor_id;
|
||||
doctorVisible.value=true;
|
||||
console.log(doctor_id.value,doctorVisible.value)
|
||||
doctor_id.value=modalForm.doctor_id;
|
||||
doctorVisible.value=true;
|
||||
}
|
||||
const openPatient=()=>{
|
||||
alert('开发中')
|
||||
}
|
||||
onMounted(() => {
|
||||
getProductInfo(pager);
|
||||
@ -523,33 +772,40 @@ onMounted(() => {
|
||||
.action {
|
||||
margin-bottom: 12px;
|
||||
}
|
||||
.doctorInfo{
|
||||
.doctorInfo {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
|
||||
}
|
||||
.row{
|
||||
line-height:32px;
|
||||
.row {
|
||||
line-height: 32px;
|
||||
display: flex;
|
||||
}
|
||||
.row .nameDesc{
|
||||
.row .nameDesc {
|
||||
text-align: right;
|
||||
width:120px;
|
||||
color:#000;
|
||||
width: 120px;
|
||||
color: #000;
|
||||
}
|
||||
.row .desc{
|
||||
color:#666;
|
||||
.row .desc {
|
||||
color: #666;
|
||||
}
|
||||
.infobox{
|
||||
.infobox {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: space-between;
|
||||
}
|
||||
.headImg {
|
||||
margin-right: 20px;
|
||||
border-radius: 50%;
|
||||
width: 80px;
|
||||
height: 80px;
|
||||
}
|
||||
|
||||
margin-right: 20px;
|
||||
border-radius: 50%;
|
||||
width: 80px;
|
||||
height: 80px;
|
||||
}
|
||||
.arco-timeline-item-content-wrapper{
|
||||
width:80%;
|
||||
}
|
||||
.arco-timeline-item-label{
|
||||
margin-left: 10px;
|
||||
}
|
||||
.expand{
|
||||
margin-top: 15px;
|
||||
}
|
||||
</style>
|
||||
|
||||
@ -14,8 +14,13 @@
|
||||
<!-- <a-form-item field="department_custom_name" label="科室名称">
|
||||
<a-input v-model="queryForm.department_custom_name" placeholder="请输入科室名称" @press-enter="handleQuery" />
|
||||
</a-form-item> -->
|
||||
<a-form-item field="doctor_title" label="电话号码">
|
||||
<a-input :style="{ width: '182px' }" v-model="queryForm.mobile" placeholder="请输入医生电话号码" @press-enter="handleQuery" />
|
||||
<a-form-item field="doctor_title" label="电话号码">
|
||||
<a-input
|
||||
:style="{ width: '182px' }"
|
||||
v-model="queryForm.mobile"
|
||||
placeholder="请输入医生或者患者电话号码"
|
||||
@press-enter="handleQuery"
|
||||
/>
|
||||
</a-form-item>
|
||||
<a-form-item field="inquiry_service" label="订单状态">
|
||||
<a-select v-model="queryForm.inquiry_status" placeholder="请选择订单状态" :style="{ width: '182px' }">
|
||||
@ -39,15 +44,6 @@
|
||||
|
||||
<a-divider />
|
||||
|
||||
<!-- action -->
|
||||
<div class="action">
|
||||
<a-space>
|
||||
<a-button v-has="'admin:sysDoctorList:add'" type="primary" @click="handleAdd"><icon-plus /> 新增 </a-button>
|
||||
<!-- <a-button v-has="'admin:sysDoctorList:remove'" type="primary" status="danger"><icon-delete /> 批量删除 </a-button> -->
|
||||
</a-space>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- table -->
|
||||
<a-table
|
||||
:columns="columns"
|
||||
@ -77,13 +73,23 @@
|
||||
<div v-else-if="record.inquiry_status==6">已结束</div>
|
||||
<div v-else-if="record.inquiry_status==7">已取消</div>
|
||||
</template>
|
||||
<template #amount_total="{ record }">
|
||||
{{(record.amount_total) }}元
|
||||
</template>
|
||||
<template #payment_amount_total="{ record }">
|
||||
{{(record.payment_amount_total) }}元
|
||||
</template>
|
||||
<template #patient_name="{ record }">
|
||||
{{record.patient_name}}({{record.patient_sex==1?'男,':'女,'}}{{record.patient_age}}岁)
|
||||
</template>
|
||||
|
||||
<template #pay_time="{ record }">
|
||||
{{ parseTime(record.pay_time) }}
|
||||
</template>
|
||||
|
||||
<template #action="{ record }">
|
||||
<a-space>
|
||||
<a-button v-has="'admin:sysDoctorList:detail'" type="text"
|
||||
<a-button v-has="'admin:sysOrderList:detail'" type="text"
|
||||
@click="handleDetail(record)"><icon-book />详情</a-button>
|
||||
<!-- <a-button v-has="'admin:sysPost:remove'" type="text" @click="() => { deleteVisible = true; deleteData = [record.post_id]; }"><icon-delete /> 删除</a-button> -->
|
||||
</a-space>
|
||||
@ -202,17 +208,17 @@
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-divider v-if="modalForm.order_inquiry_refund"/>
|
||||
<div class="titlebox" v-if="modalForm.user_doctor">
|
||||
<div class="titlebox">
|
||||
<div class="bar"></div>
|
||||
<div class="name">医生信息</div>
|
||||
<a-space style="margin-right: 8px;flex:1;display: flex;justify-content: flex-end;">
|
||||
<a-space style="margin-right: 8px;flex:1;display: flex;justify-content: flex-end;" v-if="modalForm.user_doctor">
|
||||
<a-button type="primary" @click="openDcotor">查看医生完整信息</a-button>
|
||||
</a-space>
|
||||
</div>
|
||||
<a-row :gutter="24" style="margin-top: 35px;" v-if="modalForm.user_doctor">
|
||||
<a-row :gutter="24" style="margin-top: 35px;" >
|
||||
<a-col :span="24">
|
||||
<a-form-item field="license_cert" :hide-label="true" >
|
||||
<div class="doctorInfo">
|
||||
<div class="doctorInfo" v-if="modalForm.user_doctor">
|
||||
<a-space size="large">
|
||||
<a-image width="80" height="80" class="headImg" :src="modalForm.user_doctor.avatar" v-if="modalForm.user_doctor.avatar">
|
||||
</a-image>
|
||||
@ -220,10 +226,11 @@
|
||||
</a-image>
|
||||
</a-space>
|
||||
<div class="infobox">
|
||||
<div class="name">{{modalForm.user_doctor.user_name}} {{modalForm.user_doctor.doctor_title}}</div>
|
||||
<div class="name">{{modalForm.user_doctor.user_name}} {{formatDoctorTitle(modalForm.user_doctor.doctor_title)}}</div>
|
||||
<div class="hospital">{{modalForm.user_doctor.hospital.hospital_name}} {{modalForm.user_doctor.department_custom_name}}</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="doctorInfo" v-else>暂未分配到医生</div>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
</a-row>
|
||||
@ -297,10 +304,10 @@
|
||||
<a-col :span="24">
|
||||
<a-form-item field="" label="" no-style>
|
||||
<a-space style="margin-right: 8px;">
|
||||
<a-button type="primary" @click="()=>okVisible=true">问诊记录</a-button>
|
||||
<a-button type="primary" @click="()=>(alert('开发中'))">问诊记录</a-button>
|
||||
</a-space>
|
||||
<a-space style="margin-right: 8px;">
|
||||
<a-button type="primary" status="danger" @click="()=>okVisible=true">删除订单</a-button>
|
||||
<a-space style="margin-right: 8px;" v-if="modalForm.inquiry_status==4 || modalForm.inquiry_status==5">
|
||||
<a-button type="primary" status="danger" v-has="'admin:sysOrderList:cancel'" @click="()=>{okVisible=true;cur_inruiry_id=modalForm.order_inquiry_id;}">取消问诊</a-button>
|
||||
</a-space>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
@ -309,6 +316,7 @@
|
||||
|
||||
<!-- 医生详情弹框 -->
|
||||
<doctorModal :doctorVisible="doctorVisible" :doctor_id="doctor_id" @doctorVisibleChange="() => {doctorVisible = false;doctor_id='';}"></doctorModal>
|
||||
<confirmModal :okVisible="okVisible" :api="cancelInquiry" :title="'确定取消此订单吗?'" :dealType="'order_inquiry_id'" :id="cur_inruiry_id" @closeChange="closeChange"></confirmModal>
|
||||
</div>
|
||||
|
||||
|
||||
@ -316,8 +324,9 @@
|
||||
|
||||
<script setup>
|
||||
import { reactive, ref, getCurrentInstance, onMounted, nextTick, watch } from 'vue';
|
||||
import { getOrderList,getOrderDetail} from '@/api/order/list';
|
||||
import { getOrderList,getOrderDetail,cancelInquiry} from '@/api/order/list';
|
||||
import { parseTime } from '@/utils/parseTime';
|
||||
import {formatDoctorTitle} from "@/utils/format"
|
||||
|
||||
// Akiraka 20230210 删除数据
|
||||
const deleteData = ref([])
|
||||
@ -325,6 +334,8 @@ const deleteData = ref([])
|
||||
const deleteVisible = ref(false)
|
||||
|
||||
const doctorVisible=ref(false);
|
||||
const okVisible=ref(false);
|
||||
const cur_inruiry_id=ref('');
|
||||
const doctor_id=ref('');
|
||||
// Akiraka 20230210 监听删除事件
|
||||
watch(() => deleteVisible.value ,(value) => {
|
||||
@ -370,10 +381,10 @@ const columns = [
|
||||
{ title: '排序', dataIndex: 'post_id',slotName: 'post_id' },
|
||||
{ title: '订单编号', dataIndex: 'inquiry_no' },
|
||||
{ title: '医生姓名', dataIndex: 'doctor_name' },
|
||||
{ title: '就诊人姓名', dataIndex: 'patient_name' },
|
||||
{ title: '联系电话', dataIndex: 'patient_name' },
|
||||
{ title: '订单金额', dataIndex: 'amount_total' },
|
||||
{ title: '实付金额', dataIndex: 'payment_amount_total' },
|
||||
{ title: '就诊人', dataIndex: 'patient_name',slotName:'patient_name' },
|
||||
{ title: '联系电话', dataIndex: 'patient_mobile' },
|
||||
{ title: '订单金额', dataIndex: 'amount_total',slotName:'amount_total' },
|
||||
{ title: '实付金额', dataIndex: 'payment_amount_total',slotName:'payment_amount_total' },
|
||||
{ title: '支付方式', dataIndex: 'inquiry_pay_channel',slotName: 'inquiry_pay_channel'},
|
||||
{ title: '订单状态', dataIndex: 'inquiry_status', slotName:'inquiry_status' },
|
||||
{ title: '支付时间', dataIndex: 'pay_time', slotName: 'pay_time' },
|
||||
@ -471,10 +482,12 @@ const handleQuery = async () => {
|
||||
|
||||
getOrderInfo(params);
|
||||
};
|
||||
|
||||
|
||||
//获取订单详情
|
||||
const handleDetail = async (record) => {
|
||||
modalVisible.value = true;
|
||||
modalTitle.value = '订单详情';
|
||||
modalTitle.value = '问诊订单详情';
|
||||
const { code, data, message } = await getOrderDetail(record.order_inquiry_id);
|
||||
if (code == 200) {
|
||||
Object.assign(modalForm, data);
|
||||
@ -508,6 +521,8 @@ const handleQuery = async () => {
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
const openDcotor=()=>{
|
||||
|
||||
doctor_id.value=modalForm.doctor_id;
|
||||
@ -516,6 +531,11 @@ const openDcotor=()=>{
|
||||
const openPatient=()=>{
|
||||
alert('开发中')
|
||||
}
|
||||
//关闭确认框
|
||||
const closeChange=()=>{
|
||||
cur_inruiry_id.value="";
|
||||
okVisible.value=false
|
||||
}
|
||||
// 重置搜索
|
||||
const handleResetQuery = () => {
|
||||
proxy.$refs.queryFormRef.resetFields();
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user