Merge branch 'dev'

This commit is contained in:
zoujiandong 2023-11-09 17:26:17 +08:00
commit 5dc42ab6b6
37 changed files with 3995 additions and 179 deletions

49
src/api/doctor/ca.js Normal file
View File

@ -0,0 +1,49 @@
import request from '../../utils/request'
export function updateCA(id){//更新证书
return request({
url:'/admin/ca/cert/user/renew/'+id,
method: 'put',
})
}
export function removeCA(id){//注销证书
return request({
url:'/admin/ca/cert/user/remove/'+id,
method: 'put',
})
}
export function applyCA(id){//申请证书
return request({
url:'/admin/ca/cert/user/'+id,
method: 'post',
})
}
export function updateSign(id){//更新签章
return request({
url:'/admin/ca/cert/user/renew/'+id,
method: 'put',
})
}
export function applySign(data){//申请签章
return request({
url:'/admin/ca/sign',
method: 'post',
data
})
}
export function getCA(){//获取云证书数据
return request({
url:'/admin/ca/cert/hospital',
method: 'get'
})
}
export function updateHospitalCA(){//更新证书
return request({
url:'/admin/ca/cert/hospital/renew',
method: 'put',
})
}

View File

@ -0,0 +1,21 @@
import request from '../../utils/request'
export function getAccountList(params){
return request({
url:'/admin/doctor/account',
method: 'get',
params
})
}
export function getAccountDetail(id){
return request({
url:'/admin/doctor/account/'+id,
method: 'get'
})
}
export function getAccountOrder(params){//关联订单列表
return request({
url:'/admin/doctor/account/order',
method: 'get',
params
})
}

9
src/api/finance/bank.js Normal file
View File

@ -0,0 +1,9 @@
import request from '../../utils/request'
export function getBankList(params){
return request({
url:'/admin/doctor/bank',
method: 'get',
params
})
}

49
src/api/finance/record.js Normal file
View File

@ -0,0 +1,49 @@
import request from '../../utils/request'
const url = '/admin/finance/withdrawal';
export function getWithdrawalList(params){
return request({
url:'/admin/finance/withdrawal',
method: 'get',
params
})
}
export function getWithdrawalDetail(id){
return request({
url:'/admin/finance/withdrawal/'+id,
method: 'get'
})
}
export function getOrder(params){
return request({
url:'/admin/finance/withdrawal/order',
method: 'get',
params
})
}
export function editIncome(id,data){
return request({
url:'/admin/finance/withdrawal/income/'+id,
method: 'put',
data
})
}
export function withdrawalStatus(id,data){//提现-修改提现审核状态
return request({
url:'/admin/finance/withdrawal/examine/'+id,
method: 'put',
data
})
}
export function confirmPay(id){//提现-确认打款
return request({
url:'/admin/finance/withdrawal/payment/'+id,
method: 'put'
})
}

View File

@ -14,7 +14,7 @@ export function getInquiryconfigList(params){
export function addInquiryconfig(data){//添加配置
return request({
url:'/admin/inquiry/config/doctor',
method: 'put',
method: 'post',
data
})
}
@ -30,4 +30,20 @@ export function getInquiryconfigDetail(id){
url:'/admin/inquiry/config/doctor/'+id,
method: 'get'
})
}
}
export function getDoctorList(params){//获取医生列表
return request({
url:'/admin/doctor/list',
method: 'get',
params
})
}
export function inquiryPriceAndTime(params){//获取问诊价格和问诊时间
return request({
url:'/admin/inquiry/config/system/detail',
method: 'get',
params
})
}

View File

@ -0,0 +1,41 @@
import request from '../../utils/request'
const url = '/admin/inquiry/config/system';
export function getSysconfigList(params){
return request({
url:'/admin/inquiry/config/system',
method: 'get',
params
})
}
export function addSysconfig(data){//添加配置
return request({
url:'/admin/inquiry/config/system',
method: 'post',
data
})
}
export function editSysconfig(data,id){//添加配置
return request({
url:'/admin/inquiry/config/system/'+id,
method: 'put',
data
})
}
export function getSysconfigDetail(id){
return request({
url:'/admin/inquiry/config/system/'+id,
method: 'get'
})
}
export function getDoctorList(params){//获取医生列表
return request({
url:'/admin/doctor/list',
method: 'get',
params
})
}

View File

@ -0,0 +1,330 @@
<template>
<!-- Modal -->
<a-modal v-model:visible="modalVisible" fullscreen title="医生账户详情" title-align="start" :footer="false"
@cancel="handleClose" >
<a-form :model="modalForm" ref="modalFormRef" :auto-label-width="true">
<div class="titlebox">
<div class="bar"></div>
<div class="name">关联订单</div>
</div>
<a-row style="margin-top: 35px;">
<a-form :model="queryForm" ref="queryFormRef" layout="inline">
<a-form-item field="patient_name" label="患者姓名">
<a-input :style="{ width: '182px' }" v-model="queryForm.patient_name" placeholder="请输入患者姓名" @press-enter="handleQuery" />
</a-form-item>
<a-form-item field="mobile" label="电话号码">
<a-input :style="{ width: '182px' }" v-model="queryForm.mobile" placeholder="请输入患者电话号码" @press-enter="handleQuery" />
</a-form-item>
<a-form-item field="inquiry_status" label="订单状态">
<a-select v-model="queryForm.inquiry_status" placeholder="请订单状态" :style="{ width: '182px' }">
<!-- 1:待支付 2:待分配 3:待接诊 4:已接诊 5:已完成 6:已结束 7:已取消 -->
<a-option :value="1">待支付</a-option>
<a-option :value="2">待分配</a-option>
<a-option :value="3">待接诊</a-option>
<a-option :value="4">已接诊</a-option>
<a-option :value="5">已完成</a-option>
<a-option :value="6">已结束</a-option>
<a-option :value="7">已取消</a-option>
</a-select>
</a-form-item>
<a-row>
<a-form-item field="pay_range_time" label="支付时间范围">
<a-range-picker style="width: 330px;" v-model="queryForm.pay_range_time" />
</a-form-item>
<a-form-item field="complete_range_time" label="完成时间范围">
<a-range-picker style="width: 330px;" v-model="queryForm.complete_range_time" />
</a-form-item>
<a-form-item field="end_range_time" label="结束时间范围">
<a-range-picker style="width: 330px;" v-model="queryForm.end_range_time" />
</a-form-item>
<a-form-item field="cancel_range_time" label="取消时间范围">
<a-range-picker
style="width: 330px"
v-model="queryForm.cancel_range_time"
/>
</a-form-item>
<a-form-item field="reception_range_time" label="接诊时间范围">
<a-range-picker
style="width: 330px"
v-model="queryForm.reception_range_time"
/>
</a-form-item>
<a-form-item field="create_range_time" label="创建时间范围">
<a-range-picker
style="width: 330px"
v-model="queryForm.create_range_time"
/>
</a-form-item>
<a-form-item>
<a-space>
<a-button type="primary" @click="handleQuery"><icon-search /> 搜索</a-button>
<a-button @click="handleResetQuery"><icon-loop /> 重置</a-button>
</a-space>
</a-form-item>
</a-row>
</a-form>
<a-divider />
</a-row>
<a-row :gutter="24" >
<a-col :span="24">
<a-form-item field="idCard" hide-label="true" >
<div class="tablebox" style="width:100%">
<!-- table -->
<a-table :columns="columns" :data="tableData"
:scroll="{ x:1700 }"
:row-selection="{ type: 'checkbox', showCheckedAll: true }"
:pagination="{ 'show-total': true, 'show-jumper': true, 'show-page-size': true, total: pager.total, current: currentPage }"
row-key="order_inquiry_id" @selection-change="(selection) => {console.log(selection)}"
@page-change="handlePageChange" @page-size-change="handlepage_sizeChange">
<template #doctor_id="{record,rowIndex}">
<div>{{(rowIndex+1)+(pager.page-1)*pager.page_size}}</div>
</template>
<template #inquiry_pay_channel="{record}">
<div v-if="record.inquiry_pay_channel==1">小程序支付</div>
<div v-else-if="record.inquiry_pay_channel==2">微信扫码</div>
<div v-else-if="record.inquiry_pay_channel==3">模拟支付</div>
</template>
<!-- 1:待支付 2:待分配 3:待接诊 4:已接诊 5:已完成 6:已结束 7:已取消 -->
<template #inquiry_status="{record}">
<div v-if="record.inquiry_status==1">待支付</div>
<div v-else-if="record.inquiry_status==2">待分配</div>
<div v-else-if="record.inquiry_status==3">待接诊</div>
<div v-else-if="record.inquiry_status==4">已接诊</div>
<div v-else-if="record.inquiry_status==5">已完成</div>
<div v-else-if="record.inquiry_status==6">已结束</div>
<div v-else-if="record.inquiry_status==7">已取消</div>
</template>
<template #payment_amount_total="{ record }">
{{record.payment_amount_total}}
</template>
<template #doctor_amount="{ record }">
{{record.doctor_amount}}
</template>
<template #amount_total="{ record }">
{{record.amount_total}}
</template>
<template #coupon_amount_total="{ record }">
{{record.coupon_amount_total}}
</template>
<template #patient_name_mask="{ record }">
<div class="ta-patient" :title="record.patient_name_mask">{{record.patient_name_mask}}({{record.patient_sex==1?'男,':'女,'}}{{record.patient_age}})</div>
</template>
<template #reception_time="{ record }">
{{ parseTime(record.reception_time) }}
</template>
<template #inquiry_type="{ record }">
{{ formatInquiryType(record.inquiry_type) }}
</template>
<template #cancel_reason="{ record }">
{{ formatOrderCancelReason(record.cancel_reason) }}
</template>
<template #entry_status="{ record }">
{{ formatEnteyStatus(record.entry_status) }}
</template>
<!-- <template #action="{ record }">
<a-space>
<a-button v-has="'admin:sysOrderList:detail'" type="text"
@click="handleDetail(record)"><icon-book />详情</a-button>
</a-space>
</template> -->
</a-table>
</div>
</a-form-item>
</a-col>
</a-row>
</a-form>
</a-modal>
</template>
<script setup>
import {ref,toRefs,watch,reactive,getCurrentInstance} from 'vue';
import {getAccountOrder} from "@/api/finance/account"
import { parseTime } from '@/utils/parseTime';
import {formatInquiryType,formatOrderCancelReason,formatEnteyStatus} from "@/utils/format"
import { Message } from '@arco-design/web-vue';
const props = defineProps({
//
modalVisible: {
type: Boolean,
default: false,
},
modalForm: {
type: Object,
},
});
const { proxy } = getCurrentInstance();
const doctor_id=ref('');
const currentPage = ref(1);
const pager = {
total: 1,
page: 1,
page_size: 10,
};
// form
const queryForm = reactive({});
const emits = defineEmits(['familyVisibleChange']);
const {modalVisible,modalForm} = toRefs(props);
//
const showEye = ref(false);
const id_card_num = ref('');
watch(()=>props.modalForm.doctor_id,()=>{
if(props.modalForm.doctor_id){
doctor_id.value=props.modalForm.doctor_id;
handleGetOrder({...pager,doctor_id:props.modalForm.doctor_id})
}else{
doctor_id.value='';
}
})
watch(()=>queryForm.end_range_time,(value)=>{
if(value){
let[startTime,endTime]=value
queryForm.finish_time=startTime+"&"+endTime;
}else{
queryForm.finish_time=''
};
console.log(queryForm.finish_time)
})
watch(()=>queryForm.pay_range_time,(value)=>{
if(value){
let[startTime,endTime]=value
queryForm.pay_time=startTime+"&"+endTime;
}else{
queryForm.pay_time=''
};
})
watch(()=>queryForm.complete_range_time,(value)=>{
if(value){
let[startTime,endTime]=value
queryForm.complete_time=startTime+"&"+endTime;
}else{
queryForm.complete_time=''
};
})
watch(()=>queryForm.cancel_range_time,(value)=>{
if(value){
let[startTime,endTime]=value
queryForm.cancel_time=startTime+"&"+endTime;
}else{
queryForm.cancel_time=''
};
})
watch(()=>queryForm.reception_range_time,(value)=>{
if(value){
let[startTime,endTime]=value
queryForm.reception_time=startTime+"&"+endTime;
}else{
queryForm.reception_time=''
};
})
watch(()=>queryForm.create_range_time,(value)=>{
if(value){
let[startTime,endTime]=value
queryForm.created_at=startTime+"&"+endTime;
}else{
queryForm.created_at=''
};
})
// Table Columns
const columns = [
{ title: '编号', dataIndex: 'doctor_id', slotName: 'doctor_id', width: '90' },
{ title: '订单编号', dataIndex: 'inquiry_no',width:200 },
{ title: '医生姓名', dataIndex: 'doctor_name',width:100 },
{ title: '就诊人', dataIndex: 'patient_name_mask',slotName:'patient_name_mask',width:200},
{ title: '实付金额', dataIndex: 'payment_amount_total',slotName:'payment_amount_total',width:100 },
{ title: '订单金额', dataIndex: 'amount_total',slotName:'amount_total',width:100 },
{ title: '优惠券金额', dataIndex: 'coupon_amount_total',slotName:'coupon_amount_total',width:100 },
{ title: '医生收益', dataIndex: 'doctor_amount',slotName:'doctor_amount',width:100 },
{ title: '支付方式', dataIndex: 'inquiry_pay_channel',slotName: 'inquiry_pay_channel'},
{ title: '订单状态', dataIndex: 'inquiry_status', slotName:'inquiry_status' },
{ title: '入账状态', dataIndex: 'entry_status', slotName:'entry_status' },
{ title: '理由', dataIndex: 'cancel_reason', slotName: 'cancel_reason' },
{ title: '接诊时间', dataIndex: 'reception_time', slotName: 'reception_time',width:200 },
// { title: '', slotName: 'action',fixed: "right", width: 100 },
]
// Akiraka 20230210
const handleClose = () => {
emits('familyVisibleChange', false);
};
const tableData=ref([]);
const handleGetOrder=(params={})=>{
getAccountOrder(params).then(res=>{
if(res.code==200){
let data=res.data;
tableData.value=data.data;
Object.assign(pager, { total: data.total, page: data.page, page_size: data.page_size });
}
})
}
/**
* 分页改变
* @param {Number} [page]
*/
const handlePageChange = (page) => {
pager.page = page;
//
currentPage.value = page;
handleGetOrder({ ...pager,doctor_id:doctor_id.value});
};
//
const handlepage_sizeChange = (page_size) => {
pager.page_size = page_size;
handleGetOrder({ ...pager,doctor_id:doctor_id.value});
};
const handleQuery = async () => {
pager.page = 1;
const params = {
page: pager.page,
page_size: pager.page_size,
...queryForm,
doctor_id:doctor_id.value
};
handleGetOrder(params);
};
//
const handleResetQuery = () => {
proxy.$refs.queryFormRef.resetFields();
handleGetOrder(doctor_id.value,queryForm);
}
</script>
<style scoped>
.cardNum {
width: 150px;
}
.arco-form-item-layout-horizontal:first-child,
.arco-form-item-layout-horizontal:nth-child(2) {
align-items: center;
}
.cellbox{
margin-top: 35px;
}
.cellbox .cell{
width:50%;
border-bottom:1px dashed #efefef;
margin-bottom: 20px;
}
.cellbox .cell:first-child{
border: none;
}
.box {
display: flex;
align-items: center;
}
.cert .arco-form-item-label-col {
flex: 0 0 8px !important;
}
</style>

View File

@ -3,39 +3,25 @@
<a-modal
v-model:visible="modalVisible"
fullscreen
title="添加问诊配置"
:title="title"
title-align="start"
:footer="false"
@cancel="handleClose"
>
<div class="titlebox">
<div class="bar"></div>
<div class="name">添加医生</div>
</div>
<a-form :model="modalForm" ref="modalFormRef" :auto-label-width="true">
<a-row :gutter="24" style="margin-top: 35px">
<a-col :span="12">
<a-form-item field="avatar" :hide-label="true">
<a-input
:style="{width:'320px'}"
v-model="modalForm.card_num"
placeholder="请输入医生名字并选择想要添加的医生"
/>
</a-form-item>
</a-col>
</a-row>
<a-divider />
<a-form :model="modalForm" ref="modalFormRefConfig" :auto-label-width="true" :rules="rules">
<div class="titlebox">
<div class="bar"></div>
<div class="name">问诊类型</div>
</div>
<a-row :gutter="24" style="margin-top: 35px">
<a-col :span="12">
<a-form-item field="avatar" :hide-label="true">
<a-form-item field="inquiry_type" :hide-label="true">
<a-select
:disabled="inquiry_config_id?true:false"
v-model="modalForm.inquiry_type"
placeholder="请选择服务类型"
placeholder="请选择问诊类型"
@change="changeType"
:style="{ width: '320px' }"
>
<!-- 1:专家问诊 2:快速问诊 3:公益问诊 4:问诊购药 -->
@ -48,49 +34,48 @@
</a-col>
</a-row>
<a-divider />
<div class="typebox">
<div class="titlebox">
<div class="bar"></div>
<div class="name">问诊价格</div>
</div>
<a-row :gutter="24" style="margin-top: 35px;">
<a-col :span="12">
<a-input
:style="{width:'320px'}"
v-model="modalForm.card_num"
placeholder="请选择问诊价格"
/>
</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="" label="" no-style>
<a-space direction="vertical" size="large">
<a-input-number v-model="value" :style="{width:'320px'}" placeholder="Please Enter" class="input-demo" :min="10" :max="100"/>
</a-space>
<div class="titlebox">
<div class="bar"></div>
<div class="name">添加医生</div>
</div>
<a-row :gutter="24" style="margin-top: 35px">
<a-col :span="12">
<a-form-item field="doctor_id" :hide-label="true">
<a-space direction="vertical" size="large">
<a-select :style="{width:'420px'}" allow-search placeholder="请输入医生姓名" :disabled="(inquiry_config_id || !modalForm.inquiry_type)?true:false" v-model="modalForm.doctor_id" allow-clear
:loading="loading" @change="changeDoctor" @search="handleDoctorList" @click="isHasType">
<a-option size="large" style="max-width:500px" v-for="item in doctorData" :key="item.hospital_id"
:value="item.doctor_id" :label="item.user_name">
<span v-if="item.doctor_title || item.hospital_name || item.department_custom_name" :title="item.user_name+'('+formatDoctorTitle(item.doctor_title)+'—'+item.hospital_name+'—'+item.department_custom_name+')'"> {{item.user_name+'('+formatDoctorTitle(item.doctor_title)+''+item.hospital_name+''+item.department_custom_name+')'}}</span>
<span v-else :title="item.user_name"> {{item.user_name}}</span>
</a-option>
</a-select>
</a-space>
</a-form-item>
</a-col>
</a-row>
</div>
<div class="typebox">
<div class="titlebox">
</a-row>
<a-divider />
<!-- <div class="typebox" v-if="toggleType">
</div> -->
<div class="typebox" v-if="!toggleType ">
<div class="titlebox" v-if="is_platform_deep_cooperation==1">
<div class="bar"></div>
<div class="name">问诊日期</div>
</div>
<a-form>
<div class="timecon">
<div class="timecon" v-if="is_platform_deep_cooperation==1">
<div class="left">
<a-row :gutter="24" style="margin-top: 35px;">
<a-col :span="24">
<el-config-provider :locale="locale">
<a-form-item field="" label="问诊日期:" >
<el-date-picker
v-model="modalForm.value1"
value-format="YYYY-MM-DD"
:disabled-date="disabledDate"
:style="{ width: '320px' }"
v-model="inquiry_date"
type="dates"
placeholder="选择问诊日期(可多选)"
/>
@ -100,29 +85,29 @@
</a-row>
<a-row :gutter="24" >
<a-col :span="24">
<el-config-provider :locale="locale">
<a-form-item field="" label="问诊时间:" >
<el-date-picker
v-model="modalForm.value1"
type="dates"
placeholder="选择问诊日期(可多选)"
/>
<a-select
v-model="inquiry_time"
placeholder="请选择问诊时间"
multiple
:style="{ width: '320px' }"
@change="changeTime"
>
<a-option :value="item.inquiry_time_id" v-for="item in system_inquiry_time">{{ item.start_time }}{{item.end_time}}</a-option>
</a-select>
</a-form-item>
</el-config-provider>
</a-col>
</a-row>
<a-row :gutter="24" >
<a-col :span="24">
<a-form-item field="" label="" >
<a-space>
<a-button type="primary"
><icon-check-circle /> 确定</a-button
@click="addTime"><icon-check-circle /> 添加</a-button
>
<a-button @click="reset"><icon-loop /> 重置</a-button>
</a-space>
</a-form-item>
</a-col>
@ -131,17 +116,22 @@
</div>
<div class="line"></div>
<div class="right">
<a-form-item field="" label="" >
<a-form-item field="doctor_inquiry_time" :hide-label="true" :rules="[{ required: true, message: '请选择问诊价格' }]">
<div class="surebox">
<div class="titlebox">
<div class="title">已选问诊时间</div>
<a-button style="margin-left: 20px;" @click="clearTime" type="primary">清空</a-button>
</div>
<div class="timebox">
<a-tag color="green" closable>111</a-tag>
<a-space wrap>
<a-tag color="green" class="tag" closable v-for="(item,index) in slect_all_date" :key="item" @close="closeTag(index)">{{item}}</a-tag>
</a-space>
</div>
</div>
</a-form-item>
</div>
</div>
</a-form>
<a-divider />
<div class="titlebox" >
<div class="bar"></div>
@ -151,13 +141,72 @@
<a-col :span="24">
<a-form-item field="" label="" no-style>
<a-space direction="vertical" size="large">
<a-switch />
<div v-if="is_platform_deep_cooperation==1"></div>
<div v-else></div>
</a-space>
</a-form-item>
</a-col>
</a-row>
<a-divider />
</div>
<div class="titlebox">
<div class="bar"></div>
<div class="name">问诊价格()</div>
</div>
<a-row :gutter="24" style="margin-top: 35px;">
<a-col :span="12">
<a-form-item field="inquiry_price" :hide-label="true" v-if="modalForm.inquiry_type!=3" :rules="[{ required: true, message: '请输入问诊价格' }]">
<a-input-number
:min="min"
:max="max"
:style="{width:'180px'}"
v-model="modalForm.inquiry_price"
placeholder="输入问诊价格"
:disabled="modalForm.inquiry_type==2 || modalForm.inquiry_type==4"
mode="button"
/>
</a-form-item>
<a-form-item field="inquiry_price" :hide-label="true" :rules="[{ required:true, message: '请选择问诊价格' }]" v-if="modalForm.inquiry_type==3">
<a-select
v-model="modalForm.inquiry_price"
placeholder="请选择问诊价格"
:style="{ width: '320px' }"
>
<a-option :value="item" v-for="item in inquiry_price_list" :key="item">{{ item }}</a-option>
</a-select>
</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="work_num_day" :hide-label="true">
<a-space direction="vertical" size="large">
<a-input-number mode="button" v-model="modalForm.work_num_day" :style="{width:'180px'}" placeholder="每日最大接诊量" class="input-demo" :min="0" :max="max_patient"/>
</a-space>
</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="" :hide-label="true" :rules="[{required:true,message:'请设置问诊状态'}]">
<a-space direction="vertical" size="large">
<a-switch v-model="modalForm.is_enable" :checked-value="1" :unchecked-value="0" />
</a-space>
</a-form-item>
</a-col>
</a-row>
<a-divider />
</a-form>
<div class="titlebox" >
<div class="bar"></div>
@ -167,8 +216,7 @@
<a-col :span="24">
<a-form-item field="" label="" no-style>
<a-space >
<a-button type="primary" @click="">开启</a-button>
<a-button type="primary" status="danger" @click="">关闭</a-button>
<a-button type="primary" @click="handleSubmit" v-has="'admin:sysDoctorconfigList:save'">保存</a-button>
</a-space>
</a-form-item>
</a-col>
@ -176,37 +224,290 @@
</a-modal>
</template>
<script setup>
import { ref, toRefs } from 'vue';
import { addInquiryconfig } from '@/api/inquiry/config';
import { formatRelation } from '@/utils/format';
import { ref,toRef, toRefs,onMounted,watch,getCurrentInstance,reactive } from 'vue';
import { addInquiryconfig,getDoctorList,inquiryPriceAndTime,getInquiryconfigDetail,editInquiryconfig} from '@/api/inquiry/config';
import { formatDoctorTitle } from '@/utils/format';
import { parseTime } from '@/utils/parseTime';
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
import { reactive } from 'vue';
const { proxy } = getCurrentInstance();
let multi_point_status='';
const props = defineProps({
//
modalVisible: {
type: Boolean,
default: false,
},
inquiry_config_id:{
type:String,
default:''
}
});
const modalForm=reactive({
})
const {modalVisible}=toRefs(props);
const emits = defineEmits(['familyVisibleChange']);
const is_platform_deep_cooperation=ref(null);
const loading = ref(false);
const title=ref('添加问诊配置');
const modalForm=reactive({
inquiry_mode:1,
inquiry_price:null,
doctor_inquiry_time:[],
is_enable:1
});
const disabledDate=(time)=>{
return time.getTime() < Date.now() - 8.64e7;
}
const locale=ref('');
const toggleType=ref(true);
const slect_all_date=ref([]);
const {modalVisible,inquiry_config_id}=toRefs(props);
const emits = defineEmits(['familyVisibleChange','freshList']);
// Rules
const doctorData=ref([]);
const handleDetail=(id)=>{
getInquiryconfigDetail(id).then(data=>{
if(data.code==200){
let result=data.data;
Object.assign(modalForm,result);
if (result.inquiry_type == 1 || result.inquiry_type == 3) {
toggleType.value = true;
} else {
toggleType.value = false;
}
if(result.doctor_inquiry_time){
slect_all_date.value=result.doctor_inquiry_time.map(item=>{
return parseTime(item.inquiry_date,'{y}-{m}-{d}')+" "+item.start_time+"—"+item.end_time
})
};
handleInquiryPriceAndTime();
is_platform_deep_cooperation.value=result.user_doctor.is_platform_deep_cooperation;
handleDoctorList(result.user_doctor.user_name);
}
})
};
const handleDoctorList=(value)=>{
loading.value=true;
let formData=null;
if(modalForm.inquiry_type==4){
formData={
user_name:value,
idcard_status:1,
iden_auth_status:1,
is_bind_bank:1,
multi_point_status: 1
}
}else{
formData= {
user_name:value,
idcard_status:1,
iden_auth_status:1,
is_bind_bank:1,
}
}
getDoctorList(formData).then(data=>{
if(data.code=200){
doctorData.value=data.data;
if(!value){
modalForm.doctor_id='';
}
}
loading.value=false;
})
};
watch(()=>props.inquiry_config_id,(newVal,oldValval)=>{
if(newVal){
title.value='修改医生问诊配置'
handleDetail(newVal)
}else{
//handleDoctorList();
title.value='添加医生问诊配置';
toggleType.value=true;
modalForm.inquiry_price=null
}
},{immediate:true})
let rules = reactive({
doctor_id: [{ required: true, message: '请输入医生姓名' }],
inquiry_type: [{ required: true, message: '请选择问诊类型' }],
work_num_day: [{ required: true, message: '请输入每日接诊数量' }],
inquiry_price: [{ required: true, message: '请输入问诊价格' }]
})
const changeDoctor=(value)=>{
let cur=doctorData.value.filter((item)=> item.doctor_id==value);
if(cur && cur.length==1){
is_platform_deep_cooperation.value=cur[0].is_platform_deep_cooperation
}else{
is_platform_deep_cooperation.value=0
}
};
const reset=()=>{
inquiry_date.value=[];
inquiry_time.value=[];
};
let temp_date=[];
const addTime=()=>{
let temp=[];
if(inquiry_date.value.length==0){
proxy.$message.warning('请选择问诊日期!');
return false;
}
if(inquiry_time.value.length==0){
proxy.$message.warning('请选择问诊时间!');
return false;
}
let arr1=inquiry_date.value
let arr2=select_time.value;
for (let i = 0; i < arr1.length; i++) {
for (let j = 0; j < arr2.length; j++) {
temp.push(arr1[i]+" "+arr2[j]);
}
}
temp_date=temp_date.concat(temp);
slect_all_date.value=[...new Set(temp_date)];
reset();
}
const clearTime=()=>{
temp_date=[];
slect_all_date.value=[];
}
watch(slect_all_date,(newVal,oldVal)=>{
if(newVal.length>0){
console.log(newVal.length)
modalForm.doctor_inquiry_time=newVal.map((item)=>{
const [inquiry_date,time]=item.split(' ');
const [start_time,end_time]=time.split("—");
return {inquiry_date,start_time,end_time}
})
}else{
modalForm.doctor_inquiry_time=[]
}
},{deep:true})
//tag
const closeTag=(index)=>{
slect_all_date.value.splice(index,1);
}
locale.value=zhCn;
//
const min=ref(0);
const max=ref(1000000);
const max_patient=ref(1000000);
const system_inquiry_time=ref([]);
//
const inquiry_date=ref([]);
//
const inquiry_time=ref([]);
const select_time=ref([]);
const changeTime=(value)=>{
select_time.value=[];
let arr=system_inquiry_time.value;
for (let i = 0; i < arr.length; i++) {
for (let j = 0; j < value.length; j++) {
if(arr[j].inquiry_time_id === value[i]){
select_time.value.push(arr[j].start_time+"—"+arr[j].end_time);
}
}
};
};
const changeType=(value)=>{
if(value==1 || value==3){
toggleType.value=true
}else{
toggleType.value=false
};
doctorData.value=[];
modalForm.doctor_id='';
modalForm.doctor_inquiry_time=[];
modalForm.inquiry_price=null;
slect_all_date.value=[];
//
proxy.$refs.modalFormRefConfig.clearValidate();
handleInquiryPriceAndTime()
}
const inquiry_price_list=ref([]);
const handleInquiryPriceAndTime=()=>{
inquiryPriceAndTime({
inquiry_type:modalForm.inquiry_type,
inquiry_mode:modalForm.inquiry_mode
}).then(data=>{
if(data.code=200){
const result=data.data;
if(modalForm.inquiry_type==1){
min.value=Number(result.min_inquiry_price);
max.value=Number(result.max_inquiry_price);
}else if(modalForm.inquiry_type==3){
inquiry_price_list.value=result.inquiry_price.split(",").map((item)=>{
return Number(item)
}).sort((a, b)=>{return a-b})
}else{
system_inquiry_time.value=result.system_inquiry_time;
modalForm.inquiry_price=Number(result.inquiry_price);
};
//modalForm.work_num_day=result.max_work_num_day;
max_patient.value=result.max_work_num_day;
// rules = reactive(rules_obj);
}
})
}
//
const handleAddInquiryconfig = async () => {
const { data, code, message } = await AddInquiryconfig(modalForm);
}
};
// Akiraka 20230210
const handleClose = () => {
proxy.$refs.modalFormRefConfig.resetFields();
reset();
emits('familyVisibleChange', false);
};
const reset=()=>{
alert("重置")
}
const isHasType=()=>{
if(!modalForm.inquiry_type){
proxy.$message.error('请先选择问诊类型');
}
};
const handleSubmit=()=>{
proxy.$refs.modalFormRefConfig.validate(async (valid) => {
let data=null;
if (!valid) {
if(props.inquiry_config_id){
data= await editInquiryconfig(modalForm,props.inquiry_config_id)
}else{
data= await addInquiryconfig(modalForm);
}
if(data.code==200){
props.inquiry_config_id?proxy.$message.success('修改成功'):proxy.$message.success('添加成功');
emits('freshList', '');
}
handleClose();
}else {
console.log(valid)
proxy.$message.error('表单校验失败');
//done(false);
}
});
};
// onMounted(()=>{
// handleDoctorList()
// })
</script>
<style scoped>
.tag{
margin-bottom: 10px;
}
.tag:last-child{
margin-bottom: 0;
}
.cardNum {
width: 150px;
}
@ -214,6 +515,9 @@ const reset=()=>{
.arco-form-item-layout-horizontal:nth-child(2) {
align-items: center;
}
.surebox{
width:100%;
}
.cellbox {
margin-top: 35px;
}
@ -236,7 +540,7 @@ const reset=()=>{
}
.timebox{
min-height:200px;
width:300px;
width:100%;
margin-top: 20px;
padding: 20px;
border:1px solid var(--color-neutral-3);
@ -244,7 +548,8 @@ const reset=()=>{
}
.timecon{
display: flex;
width: 1000px;
width:100%;
justify-content: space-between;
align-items: center;
}
.left{
@ -252,12 +557,13 @@ const reset=()=>{
}
.right{
width:600px;
flex:1;
}
.line{
height: 240px;
width:2px;
margin:0 100px;
background: var(--color-neutral-3);
}
</style>

View File

@ -0,0 +1,480 @@
<template>
<!-- Modal -->
<a-modal
v-model:visible="modalVisible"
fullscreen
:title="title"
title-align="start"
:footer="false"
@cancel="handleClose"
>
<a-form
:model="modalForm"
ref="modalFormRefConfig"
:auto-label-width="true"
:rules="rules"
>
<div class="titlebox">
<div class="bar"></div>
<div class="name">问诊类型</div>
</div>
<a-row :gutter="24" style="margin-top: 35px">
<a-col :span="12">
<a-form-item field="inquiry_type" :hide-label="true">
<a-select
:disabled="inquiry_config_id ? true : false"
v-model="modalForm.inquiry_type"
placeholder="请选择问诊类型"
@change="changeType"
:style="{ width: '320px' }"
>
<!-- 1:专家问诊 2:快速问诊 3:公益问诊 4:问诊购药 -->
<a-option :value="1">专家问诊</a-option>
<a-option :value="2">快速问诊</a-option>
<a-option :value="3">公益问诊</a-option>
<a-option :value="4">问诊购药</a-option>
</a-select>
</a-form-item>
</a-col>
</a-row>
<a-divider />
<!-- <div class="typebox" v-if="toggleType">
</div> -->
<div class="typebox" v-if="!toggleType">
<div class="titlebox" >
<div class="bar"></div>
<div class="name">问诊时间段</div>
</div>
<div class="timecon" >
<div class="left">
<a-row :gutter="24" style="margin-top: 35px">
<a-col :span="24">
<a-button type="primary" @click="addTime" style="margin-bottom: 10px;">添加</a-button>
<div class="timebox">
<div class="timecell">
<a-form-item v-for="(item,index) in modalForm.system_inquiry_time" :key="item.id" :field="`system_inquiry_time[${index}].start_time`" :rules="timerules" >
<div class="timecell">
<div class="timetitle" :hide-label="true"> 时间范围{{index+1}}</div>
<a-time-picker
type="time-range"
format="HH:mm"
:default-value="[item.start_time, item.end_time]"
@change="(valueString, value) =>changeTime(valueString,value,index)"
style="width: 252px;" />
<icon-minus-circle-fill style="color:red;font-size: 25px;margin-left: 5px;" @click="delTime(index)" v-if="modalForm.system_inquiry_time.length>1"/>
</div>
</a-form-item>
</div>
</div>
</a-col>
</a-row>
</div>
</div>
<a-divider />
</div>
<div class="titlebox">
<div class="bar"></div>
<div class="name">问诊价格()</div>
</div>
<a-row :gutter="24" style="margin-top: 35px">
<a-col :span="12">
<div class="priceRange" v-if="modalForm.inquiry_type == 1" style="width:460px">
<div style="white-space:nowrap;margin-right: 10px;" class="pricestyle">价格范围:</div>
<a-form-item
field="min_inquiry_price"
:hide-label="true"
:rules="[{ required: true, message: '请输入最低问诊价格' }]"
>
<a-input-number
:min="0"
:style="{ width: '180px' }"
v-model="modalForm.min_inquiry_price"
placeholder="输入最低问诊价格"
mode="button"
/>
</a-form-item>
<span class="pricestyle">&nbsp;&nbsp;~&nbsp;&nbsp; </span>
<a-form-item field="max_inquiry_price"
:hide-label="true" style="width:auto"
:rules="[{ required: true, message: '请输入最高问诊价格' },{type:'number',min:modalForm.min_inquiry_price,message:'最高问诊价格不能小于最低价格'}]">
<a-input-number
:min="0"
:style="{ width: '180px' }"
v-model="modalForm.max_inquiry_price"
placeholder="输入最高问诊价格"
mode="button"
/>
</a-form-item>
</div>
<a-form-item
field="inquiry_price"
:hide-label="true"
v-if="modalForm.inquiry_type == 2 || modalForm.inquiry_type == 4"
:rules="[{ required: true, message: '请输入问诊价格' }]"
>
<a-input-number
:min="min"
:style="{ width: '180px' }"
v-model="modalForm.inquiry_price"
placeholder="输入问诊价格"
mode="button"
/>
</a-form-item>
<a-form-item
field="temp_free_price"
:hide-label="true"
:rules="[
{ type: 'array', minLength: 1, message: '请选择问诊价格' },
]"
v-if="modalForm.inquiry_type == 3"
>
<a-select
v-model="modalForm.temp_free_price"
placeholder="请选择问诊价格(多选)"
multiple
:style="{ width: '320px' }"
>
<a-option :value="item" v-for="item in inquiry_price_list">{{
item
}}</a-option>
</a-select>
</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="max_work_num_day" :hide-label="true">
<a-space direction="vertical" size="large">
<a-input-number
mode="button"
v-model="modalForm.max_work_num_day"
:style="{ width: '180px' }"
placeholder="每日最大接诊量"
class="input-demo"
:min="0"
/>
</a-space>
</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="duration" :hide-label="true">
<a-space direction="vertical" size="large">
<a-input-number
mode="button"
v-model="modalForm.duration"
:style="{ width: '180px' }"
placeholder="请输入沟通时长"
class="input-demo"
:min="0"
/>
</a-space>
</a-form-item>
<div class="tip">备注0代表不限时长</div>
</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="times_number" :hide-label="true">
<a-space direction="vertical" size="large">
<a-input-number
mode="button"
v-model="modalForm.times_number"
:style="{ width: '200px' }"
placeholder="请输入沟通次数"
class="input-demo"
:min="0"
/>
</a-space>
</a-form-item>
<div class="tip">备注0代表不限次数</div>
</a-col>
</a-row>
<a-divider />
</a-form>
<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="" label="" no-style>
<a-space>
<a-button type="primary" @click="handleSubmit" v-has="'admin:sysconfigList:save'">保存</a-button>
</a-space>
</a-form-item>
</a-col>
</a-row>
</a-modal>
</template>
<script setup>
import {
ref,
toRefs,
watch,
getCurrentInstance,
reactive,
} from 'vue';
import {
getSysconfigDetail,
editSysconfig,
} from '@/api/inquiry/sysconfig';
import { formatDoctorTitle } from '@/utils/format';
const { proxy } = getCurrentInstance();
const props = defineProps({
//
modalVisible: {
type: Boolean,
default: false,
},
inquiry_config_id: {
type: String,
default: '',
},
});
const is_platform_deep_cooperation = ref(null);
const timerules=[{
validator: (value, cb) => {
return new Promise(resolve => {
window.setTimeout(() => {
if (!value) {
cb('请填写时间')
}
resolve()
},300)
})
}
}];
const loading = ref(false);
const title = ref('添加问诊配置');
const modalForm = reactive({
inquiry_mode: 1,
inquiry_price:0,
doctor_inquiry_time: [],
is_enable: 1,
temp_free_price:[],
max_work_num_day:null,
system_inquiry_time:[{
start_time:'',
end_time:'',
id:new Date().getTime()
}]
});
const handleDetail = (id) => {
getSysconfigDetail(id).then((data) => {
if (data.code == 200) {
let result = data.data;
Object.assign(modalForm, result);
if (result.inquiry_type == 1 || result.inquiry_type == 3) {
toggleType.value = true;
} else {
toggleType.value = false;
}
if(result.inquiry_type == 3){
modalForm.temp_free_price=result.inquiry_price.split(",").map((item)=>{
return Number(item)
})
for (let i = 0; i < 51; i++) {
inquiry_price_list.value.push(i)
}
}
if (result.inquiry_type == 2 || result.inquiry_type == 4 ) {
modalForm.inquiry_price = Number(result.inquiry_price);
}
}
});
};
watch(
() => props.inquiry_config_id,
(newVal, oldValval) => {
if (newVal) {
title.value = '修改系统问诊配置';
handleDetail(newVal);
}
},
{ immediate: true }
);
const locale = ref('');
const toggleType = ref(true);
const { modalVisible, inquiry_config_id } = toRefs(props);
const emits = defineEmits(['familyVisibleChange', 'freshList']);
// Rules
let rules = reactive({
inquiry_type: [{ required: true, message: '请选择问诊类型' }],
work_num_day: [{ required: true, message: '请输入每日接诊数量' }],
duration: [{ required: true, message: '请输入沟通时长' }],
times_number: [{ required: true, message: '请输入沟通次数' }],
});
const changeDoctor = (value) => {
let cur = doctorData.value.filter((item) => item.doctor_id == value);
if (cur && cur.lenght == 1) {
is_platform_deep_cooperation.value = cur[0].is_platform_deep_cooperation;
}
};
const slect_all_date = ref([]);
const addTime = () => {
modalForm.inquiry_price_listsystem_inquiry_time.push({
start_time:'',
id:new Date().getTime(),
end_time:''})
};
const delTime=(index)=>{
modalForm.system_inquiry_time.splice(index,1)
}
//
const min = ref(0);
const changeTime = (timeString,time,index) => {
if(timeString){
modalForm.system_inquiry_time[index].start_time=timeString[0];
modalForm.system_inquiry_time[index].end_time=timeString[1];
}else{
modalForm.system_inquiry_time[index].start_time='';
modalForm.system_inquiry_time[index].end_time=='';
}
};
const changeType = (value) => {
if (value == 1 || value == 3) {
toggleType.value = true;
} else {
toggleType.value = false;
}
modalForm.inquiry_price = null;
//
proxy.$refs.modalFormRefConfig.clearValidate();
};
const inquiry_price_list = ref([]);
// Akiraka 20230210
const handleClose = () => {
proxy.$refs.modalFormRefConfig.resetFields();
emits('familyVisibleChange', false);
};
const handleSubmit = () => {
proxy.$refs.modalFormRefConfig.validate(async (valid) => {
if (!valid) {
if(modalForm.inquiry_type==3){
modalForm.inquiry_price=modalForm.temp_free_price.join(',')
}else if(modalForm.inquiry_type==2 || modalForm.inquiry_type==4){
modalForm.inquiry_price=String(modalForm.inquiry_price)
}
const {data,code}=await editSysconfig(modalForm, props.inquiry_config_id);
if (code == 200) {
proxy.$message.success('修改成功')
emits('freshList', '');
}
handleClose();
} else {
console.log(valid);
proxy.$message.error('表单校验失败');
//done(false);
}
});
};
</script>
<style scoped>
.tip{
font-size: 12px;
color:#666;
}
.tag {
margin-bottom: 10px;
}
.tag:last-child {
margin-bottom: 0;
}
.priceRange{
display: flex;
height: 32px;
vertical-align: middle;
align-items: center;
}
.pricestyle{
margin-bottom: 20px;
height: 32px;
align-items: center;
display: flex;
}
.arco-form-item-layout-horizontal:first-child,
.arco-form-item-layout-horizontal:nth-child(2) {
align-items: center;
}
.cellbox {
margin-top: 35px;
}
.cellbox .cell {
width: 50%;
border-bottom: 1px dashed #efefef;
margin-bottom: 20px;
}
.cellbox .cell:first-child {
border: none;
}
.box {
display: flex;
align-items: center;
}
.cert .arco-form-item-label-col {
flex: 0 0 8px !important;
}
.timecon {
display: flex;
width: 1000px;
justify-content: space-between;
align-items: center;
}
.timecell{
display: flex;
align-items: center;
margin-right: 15px;
flex-wrap: wrap;
}
.timebox{
display: flex;
}
</style>

View File

@ -245,12 +245,12 @@
</a-col>
</a-row>
<a-divider />
<div class="titlebox">
<div class="titlebox" v-if="Object.keys(modalForm.user_doctor_info).length != 0">
<div class="bar"></div>
<div class="name">医师证件</div>
</div>
<a-row :gutter="24" style="margin-top: 35px;"
v-if="(modalForm.user_doctor_info.license_cert && modalForm.user_doctor_info.license_cert.length>0) || modalSatus!='detail'">
v-if="(modalForm.user_doctor_info.license_cert && modalForm.user_doctor_info.license_cert.length>0) || modalSatus!='detail'">
<a-col :span="24">
<div class="titletip"><span
@ -372,8 +372,31 @@
</a-form-item>
</a-col>
</a-row>
<a-divider v-show="modalSatus!='detail'" />
<a-divider v-if="Object.keys(modalForm.user_doctor_info).length != 0" />
<div class="titlebox" v-if="modalForm.department_custom_name && modalForm.iden_auth_status==1 && modalForm.user_doctor_info.sign_image && modalForm.multi_point_status==1">
<div class="bar"></div>
<div class="name">CA证书配置</div>
</div>
<a-row :gutter="24" style="margin-top: 35px;" v-if="modalForm.department_custom_name && modalForm.iden_auth_status==1 && modalForm.user_doctor_info.sign_image && modalForm.multi_point_status==1">
<a-col :span="24">
<a-form-item field="" label="" no-style>
<div v-if="modalForm.user_ca_cert">证书有效期:{{parseTime(modalForm.user_ca_cert.cert_application_time,'{y}-{m}-{d}')}}-{{parseTime(modalForm.user_ca_cert.cert_expire_time,'{y}-{m}-{d}')}}</div>
<a-space style="margin-top: 15px;">
<a-button type="primary" @click="()=>{okVisible=true;okStatus=6;}" v-has="'admin:sysDoctorList:applyCA'">证书申请</a-button>
<a-button type="primary" status="success" @click="()=>{okVisible=true;okStatus=2;}" v-has="'admin:sysDoctorList:updateCA'">证书续期</a-button>
<a-button type="primary" status="danger" @click="()=>{okVisible=true;okStatus=3;}" v-has="'admin:sysDoctorList:removeCA'">证书注销</a-button>
</a-space>
<a-divider />
<div class="title">签章配置</div>
<a-space style="margin-top: 15px;">
<a-button type="primary" status="success" @click="()=>{okVisible=true;okStatus=4;}" v-has="'admin:sysDoctorList:applySign'">签章申请</a-button>
<!-- <a-button type="primary" status="danger" @click="()=>{okVisible=true;okStatus=5;}">签章更新</a-button> -->
</a-space>
</a-form-item>
</a-col>
</a-row>
</a-form>
<a-divider v-show="modalSatus!='detail' " v-if="modalForm.department_custom_name && modalForm.iden_auth_status==1 && modalForm.user_doctor_info.sign_image && modalForm.multi_point_status==1"/>
<div class="titlebox" v-if="modalSatus!='detail'">
<div class="bar"></div>
<div class="name">操作</div>
@ -399,6 +422,7 @@ import { reactive, ref, getCurrentInstance,watch,toRefs,onMounted } from 'vue';
import { getDoctorDetail, departmentList, decryptCard, hospitalList, expertiseList, areaList, bankList, decryptBank } from '@/api/doctor/list';
import { ossSign, ossUpload } from '@/api/oss';
import dayjs from 'dayjs'
import { parseTime } from '@/utils/parseTime';
const { proxy } = getCurrentInstance();
const props = defineProps({
//
@ -421,6 +445,8 @@ watch(()=>props.doctorVisible,(value)=>{
doctorVisible.value=value
}
})
const okVisible=ref(false)
const okStatus=ref(1); //1 2 3// //4 //5
watch(()=>props.doctor_id,(value)=>{
if(doctor_id){
doctor_id.value=value
@ -894,7 +920,7 @@ const modalForm = reactive({
//oss
const getOssSign = async (scene, File) => {
const { data, code, message } = await ossSign({
user_type: 4,
user_type: 2,
scene,
});
if (code == 200) {

View File

@ -0,0 +1,308 @@
<template>
<!-- Modal -->
<a-modal
v-model:visible="modalVisible"
fullscreen
:title="'问诊订单详情'"
title-align="start"
:auto-label-width="true"
:footer="false"
@cancel="handleClose"
>
<div class="titlebox">
<div class="bar"></div>
<div class="name">订单信息</div>
</div>
<a-form :model="modalForm" 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>
</a-form-item>
</a-col>
<a-col :span="12">
<a-form-item field="order_product_status" label="订单状态:">
<span>{{ formatInquiryStatus(modalForm.inquiry_status) }}</span>
</a-form-item>
</a-col>
</a-row>
<a-row :gutter="24" >
<a-col :span="12">
<a-form-item field="user.created_at" label="下单时间:">
<span >{{modalForm.created_at}}</span>
</a-form-item>
</a-col>
<a-col :span="12">
<a-form-item field="pay_time" label="支付时间:">
<span v-if="parseTime(modalForm.pay_time)">{{parseTime(modalForm.pay_time)}}</span>
<span v-else>-</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>
</a-form-item>
</a-col>
<a-col :span="12">
<a-form-item field="coupon_amount_total" label="优惠卷:">
<span v-if="modalForm.coupon_amount_total>0">{{modalForm.coupon_amount_total}}</span>
<span v-else></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>
</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>
</a-col>
</a-row>
<a-row :gutter="24" v-if="modalForm.cancel_reason">
<a-col :span="24">
<a-form-item field="department_custom_name" label="备 注 ">
<span>{{ formatOrderCancelReason(modalForm.cancel_reason)}}</span>
</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="12">
<a-form-item field="" label="平台与医生分成比例:">
<span>2.5/7.5</span>
</a-form-item>
</a-col>
<a-col :span="12">
<a-form-item field="" label="平台收益:">
<span v-if="modalForm.amount_total*0.25==0">0元</span>
<span v-else>{{ Math.floor(modalForm.amount_total*0.25*100)/100}}</span>
</a-form-item>
</a-col>
</a-row>
<a-row :gutter="24" >
<a-col :span="12">
<a-form-item field="" label="医生收益:">
<span v-if="modalForm.amount_total*0.75==0">0元</span>
<span v-else>{{Math.floor(modalForm.amount_total*0.75*100)/100}}</span>
</a-form-item>
</a-col>
</a-row>
<a-divider />
<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>
<a-image
width="80"
height="80"
class="headImg"
src="https://img.applets.igandanyiyuan.com/basic/file/doctor_avatar.png"
v-else
>
</a-image>
</a-space>
<div class="infobox">
<div class="name">
{{ modalForm.user_doctor.user_name }}&nbsp;&nbsp;{{
formatDoctorTitle(modalForm.user_doctor.doctor_title)
}}
</div>
<div class="hospital">
{{
modalForm.user_doctor.hospital.hospital_name
}}&nbsp;&nbsp;{{
modalForm.user_doctor.department_custom_name
}}
</div>
</div>
</div>
<div class="doctorInfo" v-else>暂未分配到医生</div>
</a-form-item>
</a-col>
</a-row>
<a-divider 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-button type="primary" status="warning" @click="openPatient"
>查看就诊人完整信息</a-button
>
</a-space>
</div>
<a-row
:gutter="24"
style="margin-top: 35px"
v-if="modalForm.order_inquiry_case"
>
<a-col :span="24">
<a-form-item label="就诊人姓名:">
<span
>{{ modalForm.order_inquiry_case.name }}&nbsp;&nbsp;{{
modalForm.order_inquiry_case.sex == 1 ? '男' : '女'
}}&nbsp;&nbsp;{{ modalForm.order_inquiry_case.age }}</span
>
</a-form-item>
</a-col>
</a-row>
<a-row :gutter="24" v-if="modalForm.order_inquiry_case">
<a-col :span="24">
<a-form-item field="inquiry_no" label="病情描述:">
<span>{{ modalForm.order_inquiry_case.disease_desc }}</span>
</a-form-item>
</a-col>
</a-row>
<a-row :gutter="24" v-if="modalForm.order_inquiry_case">
<a-col :span="24">
<a-form-item field="inquiry_no" label="确诊疾病:">
<span
>{{
modalForm.order_inquiry_case.disease_class_name
}}&nbsp;&nbsp;{{
modalForm.user_doctor.department_custom_name
}}</span
>
</a-form-item>
</a-col>
</a-row>
<a-divider />
</a-form>
</a-modal>
<!-- 医生详情弹框 -->
<doctorModal
:doctorVisible="doctorVisible"
:doctor_id="doctor_id"
@doctorVisibleChange="
() => {
doctorVisible = false;
doctor_id = '';
}
"
></doctorModal>
<!-- 患者详情弹窗 -->
<patientModal
:patientVisible="patientVisible"
:data="patientData"
@patientVisibleChange="
() => {
patientVisible = false;
}
"
></patientModal>
</template>
<script setup>
import { ref, toRefs, reactive, watch} from 'vue';
import { formatDoctorTitle } from '@/utils/format';
import { parseTime } from '@/utils/parseTime';
import { inquiryCase} from '@/api/order/list';
import { formatInquiryType, formatInquiryStatus,formatOrderCancelReason } from '@/utils/format';
const emits = defineEmits(['inquiryVisibleChange']);
const props = defineProps({
//
modalVisible: {
type: Boolean,
default: false,
},
modalForm: {
type: Object,
default:{
order_inquiry_case:{
inquiry_case_id:''
}
}
},
});
const doctorVisible = ref(false);
const doctor_id = ref('');
const patientVisible = ref(false);
const patientData = reactive({});
const { modalVisible, modalForm } = toRefs(props);
const openPatient = () => {
patientVisible.value = true;
};
const order_inquiry_id=ref('');
watch(() => props.modalForm,() => {
if (
props.modalForm.order_inquiry_case &&
props.modalForm.order_inquiry_case.inquiry_case_id
) {
let id = props.modalForm.order_inquiry_case.inquiry_case_id;
inquiryCase(id).then((data) => {
Object.assign(patientData, data.data);
});
}
// 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;
};
const handleClose = () => {
emits('inquiryVisibleChange', (modalVisible.value = false));
};
</script>
<style scoped>
.headImg {
margin-right: 20px;
border-radius: 50%;
width: 80px;
height: 80px;
}
.doctorInfo {
display: flex;
align-items: center;
}
.infobox {
display: flex;
flex-direction: column;
justify-content: space-between;
}
</style>

View File

@ -0,0 +1,79 @@
<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="income_tax" label="个人所得税:" >
<a-input-number :min="0" :style="{width:'200px'}" v-model="form.income_tax" placeholder="请输入个人所得税" mode="button" class="input-demo" />
</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({
income_tax:null
});
const props = defineProps({
//
okVisible: {
type: Boolean,
default: false,
},
max:{
type: Number,
default: 0,
},
id:{
type: String,
default:'',
},
api: {
type: Function,
},
});
const emits = defineEmits(['closeChange']);
const {okVisible,id,api,max} = toRefs(props);
// Akiraka 20230210
const handleClose = () => {
emits('closeChange',false);
proxy.$refs.modalFormRef.resetFields();
// alert(flag)
}
// Akiraka 20230210
const rules = {
income_tax: [
{ required: true, message: '请输入个人所得税' },
{
validator: (value, cb) => {
if (value>props.max) {
cb('修改金额不可超出提现金额');
}
}
}
]
};
// Akiraka 20230210 =>
const handleConfirm = () => {
proxy.$refs.modalFormRef.validate(async(valid) => {
if (!valid) {
const {code,message}= await api.value(id.value,form);
if(code==200){
Message.success("修改成功");
proxy.$refs.modalFormRef.resetFields();
}
emits('closeChange',true);
}
})
}
</script>

View File

@ -63,7 +63,7 @@
const getOssSign = async (scene, File) => {
proxy.$loading.show();
const { data, code, message } = await ossSign({
user_type: 4,
user_type: 2,
scene,
});
if (code == 200) {

View File

@ -0,0 +1,455 @@
<template>
<!-- Modal -->
<a-modal v-model:visible="modalVisible" fullscreen title="提现详情" title-align="start" :footer="false"
@cancel="handleClose">
<div class="titlebox">
<div class="bar"></div>
<div class="name">医生信息</div>
</div>
<a-form :model="modalForm" ref="modalFormRef" :auto-label-width="true">
<a-row :gutter="24" style="margin-top: 35px;">
<a-col :span="12">
<a-form-item field="avatar" label="医生姓名:">
<span>{{modalForm.doctor_name}} </span>
</a-form-item>
</a-col>
<a-col :span="12">
<a-form-item field="idCard" label="身份证号:" >
<div class="box" v-show="!showEye">
<div class="cardNum">{{modalForm.doctor_card_num_mask}}</div>
<icon-eye-invisible class="eye" @click="handelDecryptCard(modalForm.doctor_user_id,'')" />
</div>
<div class="box" v-show="showEye">
<div class="cardNum">{{id_card_num}}</div>
<icon-eye class="eye" @click="()=>{showEye=false}" />
</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="12">
<a-form-item field="avatar" label="银行卡号:">
<span>{{modalForm.bank_card_code}}</span>
</a-form-item>
</a-col>
<a-col :span="12">
<a-form-item field="idCard" label="提现状态:" >
<div v-if="modalForm.examine_status==1 && modalForm.payment_status==0">待结算</div>
<div v-else-if="modalForm.examine_status==2 && modalForm.payment_status==0">结算中</div>
<div v-else-if="modalForm.examine_status==2 && modalForm.payment_status==1">结算成功</div>
<div v-else-if="modalForm.examine_status==3 ">结算失败</div>
</a-form-item>
</a-col>
</a-row>
<a-row :gutter="24">
<a-col :span="12">
<a-form-item field="idCard" label="所在城市:" >
<span v-if="modalForm.doctor_withdrawal_bank">{{modalForm.doctor_withdrawal_bank.province}}{{modalForm.doctor_withdrawal_bank.city}}{{modalForm.doctor_withdrawal_bank.county}}</span>
<span v-else>-</span>
</a-form-item>
</a-col>
<a-col :span="12">
<a-form-item field="idCard" label="开户行:" >
<span v-if="modalForm.doctor_withdrawal_bank">{{modalForm.doctor_withdrawal_bank.basic_bank.bank_name
}}</span>
<span v-else>-</span>
</a-form-item>
</a-col>
</a-row>
<a-row :gutter="24" v-if="modalForm.examine_fail_reason">
<a-col :span="12">
<a-form-item field="idCard" label="拒绝理由:" >
<span >{{modalForm.doctor_withdrawal_bank.province}}{{modalForm.doctor_withdrawal_bank.city}}{{modalForm.doctor_withdrawal_bank.county}}</span>
</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="12">
<a-form-item field="idCard" label="申请时间:" >
<div>{{modalForm.created_at}}</div>
</a-form-item>
</a-col>
<a-col :span="12">
<a-form-item field="idCard" label="确认账单时间:" >
<div v-if="parseTime(modalForm.examine_time)">{{parseTime(modalForm.examine_time)}}</div>
<div v-else>-</div>
</a-form-item>
</a-col>
</a-row>
<a-row :gutter="24" >
<a-col :span="12">
<a-form-item field="idCard" label="应提现金额:" >
<div>{{modalForm.applied_withdrawal_amount}}</div>
</a-form-item>
</a-col>
<a-col :span="12">
<a-form-item field="idCard" label="实际提现金额:" >
<div>{{modalForm.actual_withdrawal_amount}}</div>
</a-form-item>
</a-col>
</a-row>
<a-row :gutter="24" >
<a-col :span="12">
<a-form-item field="idCard" label="分成比例:" >
<div>平台2.5/医生7.5</div>
</a-form-item>
</a-col>
<a-col :span="12">
<a-form-item field="idCard" label="个人所得税:" >
<div>{{modalForm.income_tax}}</div>
<a-button type="primary" @click="()=>okVisible=true" style="margin-left:20px;" v-has="'admin:sysFinancialRecord:tax'" :disabled="!(modalForm.examine_status==1 && modalForm.payment_status==0)">纠正个人所得税</a-button>
</a-form-item>
</a-col>
</a-row>
<a-row :gutter="24" v-if="parseTime(modalForm.payment_time)">
<a-col :span="12">
<a-form-item field="idCard" label="打款时间:" >
<div>{{parseTime(modalForm.payment_time)}}</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="idCard" :hide-label="true" >
<!-- table -->
<a-table :columns="columns" :data="tableData"
:scroll="{ x:1500 }"
style="width:100%"
:row-selection="{ type: 'checkbox', showCheckedAll: true }"
:pagination="{ 'show-total': true, 'show-jumper': true, 'show-page-size': true, total: pager.total, current: currentPage }"
row-key="doctor_id" @selection-change="(selection) => {deleteData = selection;console.log(selection)}"
@page-change="handlePageChange" @page-size-change="handlepage_sizeChange">
<template #doctor_id="{record,rowIndex}">
<div>{{(rowIndex+1)+(pager.page-1)*pager.page_size}}</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>
<!-- 1:待支付 2:待分配 3:待接诊 4:已接诊 5:已完成 6:已结束 7:已取消 -->
<template #inquiry_status="{record}">
<div v-if="record.inquiry_status==1">待支付</div>
<div v-else-if="record.inquiry_status==2">待分配</div>
<div v-else-if="record.inquiry_status==3">待接诊</div>
<div v-else-if="record.inquiry_status==4">已接诊</div>
<div v-else-if="record.inquiry_status==5">已完成</div>
<div v-else-if="record.inquiry_status==6">已结束</div>
<div v-else-if="record.inquiry_status==7">已取消</div>
</template>
<template #doctor_amount="{ record }">
{{(record.doctor_amount) }}
</template>
<template #patient_name_mask="{ record }">
<div class="ta-patient" :title="record.patient_name_mask">{{record.patient_name_mask}}({{record.patient_sex==1?'男,':'女,'}}{{record.patient_age}})</div>
</template>
<template #inquiry_type="{ record }">
{{ formatInquiryType(record.inquiry_type) }}
</template>
<template #pay_time="{ record }">
{{ parseTime(record.pay_time) }}
</template>
<template #action="{ record }">
<a-space>
<a-button v-has="'admin:sysOrderList:detail'" type="text"
@click="handleDetail(record)"><icon-book />详情</a-button>
<!-- <a-button v-has="'admin:sysFamilyList:edit'" type="text" @click="handleUpdate(record)"><icon-edit />
修改</a-button> -->
<!-- <a-button v-has="'admin:sysFamilyList:remove'" type="text"
@click="() => { deleteVisible = true; deleteData = [record.doctor_id]; }"><icon-delete /> 删除</a-button> -->
</a-space>
</template>
</a-table>
</a-form-item>
</a-col>
</a-row>
<a-divider />
</a-form>
<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="" label="" no-style>
<a-space >
<a-button type="primary" @click="()=>{confirmVisible=true;okStatus=1}" v-if="modalForm.examine_status==1" v-has="'admin:sysFinancialRecord:pass'">确认账单</a-button>
<a-button type="primary" @click="()=>{confirmVisible=true;okStatus=2}" v-if="modalForm.examine_status==2 && modalForm.payment_status==0" v-has="'admin:sysFinancialRecord:pay'">确认打款</a-button>
<a-button type="primary" status="danger" @click="()=>{rejectVisible=true;}" v-if="modalForm.examine_status==1" v-has="'admin:sysFinancialRecord:reject'">拒绝提现</a-button>
</a-space>
</a-form-item>
</a-col>
</a-row>
</a-modal>
<inquiryDetailMoneyModal :modalVisible="recordVisible" :modalForm="modalFormData" @inquiryVisibleChange="()=>{recordVisible=false}"></inquiryDetailMoneyModal>
<numberModal
:okVisible="okVisible"
:api="editIncome"
:id="withdrawal_order_id"
:max="modalForm.actual_withdrawal_amount"
@closeChange="closeChange"
></numberModal>
<a-modal v-model:visible="rejectVisible" :modal-style="{width:'420px'}" @ok="handleConfirmReject"
@cancel="closeReject" >
<template #title>
提示
</template>
<a-form :model="rejectform" :rules="rules" ref="rejectFormRef" size="medium" label-align="left" auto-label-width>
<a-form-item field="examine_fail_reason" label="拒绝原因:" >
<a-textarea v-model.trim="rejectform.examine_fail_reason" allow-clear placeholder="请输入拒绝原因"></a-textarea>
</a-form-item>
</a-form>
<template #footer>
<a-button @click="closeReject"><template #icon><icon-close /></template>取消</a-button>
<a-button type="primary" @click="handleConfirmReject"><template #icon><icon-check /></template>确认</a-button>
</template>
</a-modal>
<!-- 二次确认弹框 -->
<a-modal v-model:visible="confirmVisible" :modal-style="{width:'320px'}" body-class="okmodal" @ok="handleSubmitConfirm"
@cancel="()=>confirmVisible=false">
<template #title>
提示
</template>
<div v-if="okStatus==1">确定账单审核通过</div>
<div v-else-if="okStatus==2">确定打款</div>
</a-modal>
</template>
<script setup>
import {ref,toRefs,watch,reactive,getCurrentInstance} from 'vue';
import {decryptCard} from '@/api/doctor/list';
import {getOrder,editIncome,withdrawalStatus,confirmPay} from "@/api/finance/record"
import { parseTime } from '@/utils/parseTime';
import {formatInquiryType} from "@/utils/format"
import {getOrderDetail,inquiryCase} from '@/api/order/list';
import { Message } from '@arco-design/web-vue';
const props = defineProps({
//
modalVisible: {
type: Boolean,
default: false,
},
modalForm: {
type: Object,
},
});
const { proxy } = getCurrentInstance();
const confirmVisible=ref(false);
const okVisible=ref(false);
const withdrawal_order_id=ref('');
const currentPage = ref(1);
const pager = {
total: 1,
page: 1,
page_size: 10,
};
const emits = defineEmits(['familyVisibleChange','freshDetail']);
const {modalVisible,modalForm} = toRefs(props);
//
const showEye = ref(false);
const id_card_num = ref('');
watch(()=>props.modalForm.withdrawal_id,()=>{
if(props.modalForm.withdrawal_id){
withdrawal_order_id.value=props.modalForm.withdrawal_id;
handleGetOrder({
...pager,
withdrawal_id:props.modalForm.withdrawal_id
})
}else{
withdrawal_order_id.value='';
}
})
//
const handelDecryptCard = async (user_id,family_id) => {
showEye.value = true;
const { data, code, message } = await decryptCard({
user_id,
family_id
});
if (code == 200) {
id_card_num.value = data;
}
};
// Table Columns
const columns = [
{ title: '编号', dataIndex: 'doctor_id', slotName: 'doctor_id', width: '90' },
{ title: '订单编号', dataIndex: 'inquiry_no',width:200 },
{ title: '医生姓名', dataIndex: 'doctor_name',width:100 },
{ title: '就诊人', dataIndex: 'patient_name_mask',slotName:'patient_name_mask',width:200},
{ title: '联系电话', dataIndex: 'patient_mobile_mask',width: 130 },
{ title: '医生收益', dataIndex: 'doctor_amount',slotName:'doctor_amount',width:100 },
{ title: '支付方式', dataIndex: 'pay_channel',slotName: 'pay_channel'},
{ title: '订单状态', dataIndex: 'inquiry_status', slotName:'inquiry_status' },
{ title: '支付时间', dataIndex: 'pay_time', slotName: 'pay_time',width:200 },
{ title: '操作', slotName: 'action',fixed: "right", width: 100 },
]
// Akiraka 20230210
const handleClose = () => {
emits('familyVisibleChange', false);
};
const tableData=ref([]);
const handleGetOrder=(params={})=>{
getOrder(params).then(res=>{
if(res.code==200){
let data=res.data;
console.log(data.data)
tableData.value=data.data;
Object.assign(pager, { total: data.total, page: data.page, page_size: data.page_size });
}
})
}
/**
* 分页改变
* @param {Number} [page]
*/
const handlePageChange = (page) => {
pager.page = page;
//
currentPage.value = page;
handleGetOrder({ ...pager, withdrawal_id:withdrawal_order_id.value});
};
//
const handlepage_sizeChange = (page_size) => {
pager.page_size = page_size;
handleGetOrder({ ...pager, withdrawal_id:withdrawal_order_id.value});
};
const patientData=reactive({});
const modalFormData=reactive({});
const recordVisible=ref(false);
//
const handleDetail = async (record) => {
recordVisible.value = true;
Object.assign(patientData,{});
const { code, data} = await getOrderDetail(record.order_inquiry_id
);
if (code == 200) {
Object.assign(modalFormData, data);
if(data.order_inquiry_case && data.order_inquiry_case.inquiry_case_id){
const caseInfo= await inquiryCase(data.order_inquiry_case.inquiry_case_id);
Object.assign(patientData,caseInfo.data);
}
}
};
//
const closeChange = () => {
okVisible.value = false;
emits('freshDetail');
};
const rejectVisible=ref(false);
const rules = {
examine_fail_reason: [{ required: true, message: '请输入拒绝理由' }]
};
const rejectform=reactive({
examine_fail_reason:''
})
//
const handleWithdrawalStatus= async(examine_status)=>{
let obj=null;
if(examine_status==2){
obj={
examine_status
}
}else{
obj={
examine_status,
examine_fail_reason:rejectform.examine_fail_reason
}
}
const {data,code}=await withdrawalStatus(withdrawal_order_id.value,obj);
if(code==200){
examine_status==2?Message.success("已通过审核"):Message.success("已拒绝成功")
emits('freshDetail');
}
if(examine_status==3){
closeReject()
}
}
const okStatus=ref(1);
const handleConfirmReject=()=>{
proxy.$refs.rejectFormRef.validate(async(valid) => {
if (!valid) {
handleWithdrawalStatus(3);
}
})
};
const closeReject=()=>{
rejectVisible.value=false;
proxy.$refs.rejectFormRef.resetFields();
}
const handleConfirmPay=async()=>{
const {data,code}=await confirmPay(withdrawal_order_id.value);
if(code==200){
Message.success("打款成功");
}
emits('freshDetail');
};
const handleSubmitConfirm=()=>{
if(okStatus.value==1){
handleWithdrawalStatus(2);
}else{
handleConfirmPay();
}
}
</script>
<style scoped>
.cardNum {
width: 150px;
}
.arco-form-item-layout-horizontal:first-child,
.arco-form-item-layout-horizontal:nth-child(2) {
align-items: center;
}
.cellbox{
margin-top: 35px;
}
.cellbox .cell{
width:50%;
border-bottom:1px dashed #efefef;
margin-bottom: 20px;
}
.cellbox .cell:first-child{
border: none;
}
.box {
display: flex;
align-items: center;
}
.cert .arco-form-item-label-col {
flex: 0 0 8px !important;
}
.arco-btn-disabled{
cursor: not-allowed!important;
}
</style>

View File

@ -1,7 +1,7 @@
<template>
<template v-for="menu in props.menuList" :key="menu.menu_id">
<a-sub-menu
v-if="menu.parent_id==0"
v-if="menu.menu_type== 1 && menu.children"
:key="menu.path"
>
<template #icon>
@ -11,7 +11,7 @@
<sub-menu :menuList="menu.children" />
</a-sub-menu>
<a-menu-item
v-if="menu.parent_id!=0 && isRouteParams(menu.path)"
v-if="menu.menu_type== 2 && isRouteParams(menu.path)"
:key="menu.path"
>{{ menu.menu_title }}</a-menu-item>
</template>

View File

@ -6,7 +6,6 @@ import { Message, Modal, Notification } from '@arco-design/web-vue';
import '@arco-design/web-vue/dist/arco.css';
import router from './router/';
import { parseTime } from '@/utils/parseTime';
import piniaPluginPersistedstate from 'pinia-plugin-persistedstate'
// Directive
import permission from '@/directive/permission/permission';

View File

@ -105,23 +105,25 @@ router.beforeEach(async(to, from, next) => {
// afterEach Router
router.afterEach((to) => {
const store = useUserStore();
// 修改网页标题
if (to.name !== 'login') {
document.title = `${to.meta.title} - ${store.sysConfig.sys_app_name}`;
} else {
document.title = store.sysConfig.sys_app_name;
}
// Vincent 2023004 修复加载水印的bug
if (store.userInfo != undefined){
if ( store.userInfo.name != undefined ) {
Watermark.set(store.userInfo.name)
// Vincent 2023004 修复加载水印的bug
if (store.userInfo != undefined){
if ( store.userInfo.nick_name != undefined ) {
Watermark.set(store.userInfo.nick_name)
} else {
Watermark.out() // 清除水印
}
} else{
Watermark.out() // 清除水印
}
// 修改网页标题
if (to.name !== 'login') {
document.title = `${to.meta.title} - ${store.sysConfig.sys_app_name}`;
} else {
document.title = store.sysConfig.sys_app_name;
Watermark.out()
}
});
export default router;

View File

@ -2,8 +2,8 @@ import { defineStore } from 'pinia';
import { setLocalStorage, getLocalStorage } from '@/utils/storage';
import {logout} from '@/api/admin/login'
import { usePermissionStore } from '@/store/permission';
import { getInfo } from '@/api/admin/sys-user';
import { getAppConfig } from '@/api/admin/login';
// import { getInfo } from '@/api/admin/sys-user';
// import { getAppConfig } from '@/api/admin/login';
export const useUserStore = defineStore('user', {
state: () => {
@ -47,7 +47,7 @@ export const useUserStore = defineStore('user', {
if(code==200){
this.clearInfo();
window.location.href="/login"
window.location.href="/login";
}
}

View File

@ -97,4 +97,24 @@ export const formatRelation=(val)=>{
}else{
return ''
}
};
};
export const formatMode=(val)=>{
//1:图文 2:视频 3:语音 4:电话 5:会员
let data={1:'图文',2:'视频', 3:'语音', 4:'电话',5:'会员'}
if(val){
return data[val]
}else{
return ''
}
};
export const formatEnteyStatus=(val)=>{
//入账状态0:未入账 1:已入账 2:入账中 3:入账失败 4:入账取消)
let data={0:'未入账',1:'已入账', 2:'入账中', 3:'入账失败',4:'入账取消'}
if(val || val==0){
return data[val]
}else{
return ''
}
};

View File

@ -35,7 +35,7 @@
@page-size-change="handlepage_sizeChange"
>
<template #post_id="{record,rowIndex}">
<div>{{(rowIndex+1)+(pager.page-1)*10}}</div>
<div>{{(rowIndex+1)+(pager.page-1)*pager.page_size}}</div>
</template>
<template #createdAt="{ record }">
{{ parseTime(record.createdAt) }}

View File

@ -42,7 +42,7 @@
@selection-change="(selection) => {deleteData = selection;}" @select="handleSelect"
@page-change="handlePageChange" @page-size-change="handlePageSizeChange">
<template #role_id="{record,rowIndex}">
<div>{{(rowIndex+1)+(pager.page-1)*10}}</div>
<div>{{(rowIndex+1)+(pager.page-1)*pager.page_size}}</div>
</template>
<template #status="{ record }">
<a-space direction="vertical" size="large">

View File

@ -84,7 +84,7 @@
@page-size-change="handlePageSizeChange"
>
<template #user_id="{record,rowIndex}">
<div>{{(rowIndex+1)+(pager.page-1)*10}}</div>
<div>{{(rowIndex+1)+(pager.page-1)*pager.page_size}}</div>
</template>
<template #role_name="{ record }">
{{ record.role_name?.role_name}}

View File

@ -0,0 +1,207 @@
<template>
<div class="app-container">
<!-- table -->
<a-table :columns="columns" :data="tableData"
:pagination="{ 'show-total': true, 'show-jumper': true, 'show-page-size': true, total: pager.total, current: currentPage }"
row-key="doctor_id" @selection-change="(selection) => {deleteData = selection;console.log(selection)}"
@page-change="handlePageChange" @page-size-change="handlepage_sizeChange">
<template #doctor_id="{record,rowIndex}">
<div>{{(rowIndex+1)+(pager.page-1)*pager.page_size}}</div>
</template>
<template #cert_application_time="{ record }">
<div><span >{{ parseTime(record.cert_application_time,'{y}-{m}-{d}')}}</span>-<span>{{parseTime(record.cert_expire_time,'{y}-{m}-{d}')}}</span></div>
</template>
<template #cert_name="{ record }">
<div>肝胆相照互联网医院签章</div>
</template>
<template #action="{ record }">
<a-space>
<a-button v-has="'admin:sysDicitonary:updateCA'" type="text"
@click="handleUpdateCA(record)"><icon-book />证书续期</a-button>
<!-- <a-button v-has="'admin:sysFamilyList:edit'" type="text" @click="handleUpdate(record)"><icon-edit />
修改</a-button> -->
<!-- <a-button v-has="'admin:sysFamilyList:remove'" type="text"
@click="() => { deleteVisible = true; deleteData = [record.doctor_id]; }"><icon-delete /> 删除</a-button> -->
</a-space>
</template>
</a-table>
<a-modal v-model:visible="okVisible" :modal-style="{width:'320px'}" body-class="okmodal"
@cancel="()=>okVisible=false">
<template #title>
提示
</template>
<div>确定保存当前信息</div>
</a-modal>
</div>
</template>
<script setup>
import { reactive, ref, getCurrentInstance, onMounted, nextTick, watch, computed } from 'vue';
import { getCA,updateHospitalCA} from '@/api/doctor/ca';
import { parseTime } from '@/utils/parseTime';
import { Message } from '@arco-design/web-vue';
const okVisible = ref(false);
const file = ref();
const { proxy } = getCurrentInstance();
const currentPage = ref(1);
const queryForm = reactive({
});
const modalForm = reactive({
});
const pager = {
total: 1,
page: 1,
page_size: 10,
};
// Modal
const modalVisible = ref(false);
const modalTitle = ref('默认标题');
// Table Columns
const columns = [
{ title: '编号', dataIndex: 'doctor_id', slotName: 'doctor_id', width: '90' },
{ title: '名称', dataIndex: 'cert_name',slotName:'cert_name'},
{ title: '有效期', dataIndex: 'cert_application_time',slotName:'cert_application_time'},
{ title: '操作', slotName: 'action', fixed: "right", width: 180 },
];
// Table Data
const tableData = ref([]);
const handleUpdateCA=(record)=>{
updateHospitalCA().then(data=>{
if(data.code==200){
Message.success('证书更新成功');
}
})
}
/**
* 分页改变
* @param {Number} [page]
*/
const handlePageChange = (page) => {
pager.page = page;
//
currentPage.value = page;
getCAInfo({ ...pager, ...queryForm });
};
//
const handlepage_sizeChange = (page_size) => {
pager.page_size = page_size;
getCAInfo({ ...pager, ...queryForm });
};
//
const getCAInfo = async (params = {}) => {
const { data, code, message } = await getCA(params);
if (code == 200) {
tableData.value =[data];
}
};
//
const handleQuery = async () => {
pager.page = 1;
const params = {
page: pager.page,
page_size: pager.page_size,
...queryForm,
};
getCAInfo(params);
};
//
const handleResetQuery = () => {
proxy.$refs.queryFormRef.resetFields();
getCAInfo(queryForm);
}
onMounted(() => {
getCAInfo(pager);
});
</script>
<style lang="scss" scoped>
.action {
margin-bottom: 12px;
}
.okmodal div {
text-align: center;
}
.hospital_name {
width: 140px;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
.headImg {
margin-right: 20px;
border-radius: 50%;
width: 80px;
height: 80px;
}
.arco-form-item-layout-horizontal:first-child,
.arco-form-item-layout-horizontal:nth-child(2) {
align-items: center;
}
.cellbox{
margin-top: 35px;
}
.cellbox .cell{
width:50%;
border-bottom:1px dashed #efefef;
margin-bottom: 20px;
}
.cellbox .cell:first-child{
border: none;
}
.cell{
.arco-form-item{
margin-bottom: 10px;
}
}
.box {
display: flex;
align-items: center;
}
.cert .arco-form-item-label-col {
flex: 0 0 8px !important;
}
.red {
display: inline-block;
margin-right: 5px;
font-size: 14px;
color: red;
margin-top: 5px;
}
.cardNum {
width: 148px;
}
.codbox{
display: flex;
align-items: center;
}
.reason{
width:250px;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
</style>

View File

@ -34,7 +34,7 @@
@selection-change="(selection) => {deleteData = selection;}" @page-change="handlePageChange"
@page-size-change="handlepage_sizeChange">
<template #doctor_id="{record,rowIndex}">
<div>{{(rowIndex+1)+(pager.page-1)*10}}</div>
<div>{{(rowIndex+1)+(pager.page-1)*pager.page_size}}</div>
</template>
<template #doctor_title="{ record }">
<!-- 医生职称1:主任医师 2:主任中医师 3:副主任医师 4:副主任中医师 5:主治医师 6:住院医师 -->

View File

@ -106,7 +106,7 @@
row-key="doctor_id" @selection-change="(selection) => {deleteData = selection;console.log(selection)}"
@page-change="handlePageChange" @page-size-change="handlepage_sizeChange">
<template #doctor_id="{record,rowIndex}">
<div>{{(rowIndex+1)+(pager.page-1)*10}}</div>
<div>{{(rowIndex+1)+(pager.page-1)*pager.page_size}}</div>
</template>
<template #doctor_title="{ record }">
<!-- 医生职称1:主任医师 2:主任中医师 3:副主任医师 4:副主任中医师 5:主治医师 6:住院医师 -->
@ -368,11 +368,11 @@
</a-col>
</a-row>
<a-divider />
<div class="titlebox">
<div class="titlebox" v-if="modalForm.doctor_bank_card">
<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;" v-if="modalForm.doctor_bank_card">
<a-col :span="12">
<a-form-item field="doctor_bank_card.province_id" label="开户银行所在地:">
<a-space size="large" style="margin-right: 12px;">
@ -409,15 +409,15 @@
</a-form-item>
</a-col>
</a-row>
<a-row :gutter="24">
<a-row :gutter="24" v-if="modalForm.doctor_bank_card">
<a-col :span="12">
<a-form-item field="bank_card_code" label="银行卡号:">
<a-input v-model="modalForm.bank_card_code" placeholder="请输入银行卡号" />
</a-form-item>
</a-col>
</a-row>
<a-divider />
<div class="titlebox">
<a-divider v-if="modalForm.doctor_bank_card"/>
<div class="titlebox" v-if="Object.keys(modalForm.user_doctor_info).length != 0">
<div class="bar"></div>
<div class="name">医师证件</div>
</div>
@ -557,8 +557,32 @@
</a-form-item>
</a-col>
</a-row>
<a-divider v-show="modalSatus!='detail'" />
<a-divider v-if="Object.keys(modalForm.user_doctor_info).length != 0"/>
<div class="titlebox" v-if="modalForm.department_custom_name && modalForm.iden_auth_status==1 && modalForm.user_doctor_info.sign_image && modalForm.multi_point_status==1">
<div class="bar"></div>
<div class="name">CA证书配置</div>
</div>
<a-row :gutter="24" style="margin-top: 35px;" v-if="modalForm.department_custom_name && modalForm.iden_auth_status==1 && modalForm.user_doctor_info.sign_image && modalForm.multi_point_status==1">
<a-col :span="24">
<a-form-item field="" label="" no-style>
<div v-if="modalForm.user_ca_cert">证书有效期:{{parseTime(modalForm.user_ca_cert.cert_application_time,'{y}-{m}-{d}')}}-{{parseTime(modalForm.user_ca_cert.cert_expire_time,'{y}-{m}-{d}')}}</div>
<a-space style="margin-top: 15px;">
<a-button type="primary" @click="()=>{okVisible=true;okStatus=6;}" v-has="'admin:sysDoctorList:applyCA'">证书申请</a-button>
<a-button type="primary" status="success" @click="()=>{okVisible=true;okStatus=2;}" v-has="'admin:sysDoctorList:updateCA'">证书续期</a-button>
<a-button type="primary" status="danger" @click="()=>{okVisible=true;okStatus=3;}" v-has="'admin:sysDoctorList:removeCA'">证书注销</a-button>
</a-space>
<a-divider />
<div class="title">签章配置</div>
<a-space style="margin-top: 15px;">
<a-button type="primary" status="success" @click="()=>{okVisible=true;okStatus=4;}" v-has="'admin:sysDoctorList:applySign'">签章申请</a-button>
<!-- <a-button type="primary" status="danger" @click="()=>{okVisible=true;okStatus=5;}">签章更新</a-button> -->
</a-space>
</a-form-item>
</a-col>
</a-row>
</a-form>
<a-divider v-show="modalSatus!='detail' " v-if="modalForm.department_custom_name && modalForm.iden_auth_status==1 && modalForm.user_doctor_info.sign_image && modalForm.multi_point_status==1"/>
<div class="titlebox" v-if="modalSatus!='detail'">
<div class="bar"></div>
<div class="name">操作</div>
@ -567,7 +591,7 @@
<a-col :span="24">
<a-form-item field="" label="" no-style>
<a-space v-if="modalSatus!='detail'" style="margin-right: 8px;">
<a-button type="primary" @click="()=>okVisible=true">保存</a-button>
<a-button type="primary" @click="()=>{okVisible=true,okStatus=1}" v-has="'admin:sysDoctorList:save'">保存</a-button>
</a-space>
<!-- <a-space v-if="modalSatus=='edit'">
<a-button type="primary" status="warning">拉黑</a-button>
@ -587,15 +611,23 @@
<template #title>
提示
</template>
<div>确定保存当前信息</div>
<div v-if="okStatus==1">确定保存当前信息</div>
<div v-else-if="okStatus==2">确定重新续期CA证书</div>
<div v-else-if="okStatus==3">确定注销CA证书</div>
<div v-else-if="okStatus==4">确定申请签章</div>
<div v-else-if="okStatus==5">确定更新签章</div>
<div v-else-if="okStatus==6">确定申请CA证书</div>
</a-modal>
</div>
</template>
<script setup>
import { reactive, ref, getCurrentInstance, onMounted, nextTick, watch, computed } from 'vue';
import { reactive, ref, getCurrentInstance, onMounted, watch } from 'vue';
import { getDoctorList, addDoctor, removeDoctor, updateDoctor, getDoctorDetail, departmentList, decryptCard, hospitalList, expertiseList, areaList, bankList, decryptBank } from '@/api/doctor/list';
import { applyCA,updateCA,removeCA,updateSign,applySign } from '@/api/doctor/ca';
import { ossSign, ossUpload } from '@/api/oss';
import { parseTime } from '@/utils/parseTime';
import { Message } from '@arco-design/web-vue';
import dayjs from 'dayjs'
// Akiraka 20230210
const deleteData = ref([])
@ -603,7 +635,7 @@
const deleteVisible = ref(false)
// Akiraka 20230210
const okVisible = ref(false);
const okStatus=ref(1); //1 2 3// //4 //5
watch(() => deleteVisible.value, (value) => {
if (value == false) {
getDoctorInfo(pager);
@ -634,6 +666,9 @@
},
user_doctor_info: {
card_num_mask:''
},
user_ca_cert:{
},
doctor_bank_card: {
province_id:'',
@ -1100,7 +1135,7 @@
oldBackImg.value = id_card_back;
oldSignImg.value = sign_image;
if (modalForm.iden_auth_status == 2) {
proxy.$message.warning('正在审核中,暂时不能修改');
Message.warning('正在审核中,暂时不能修改');
}
if (data.doctor_expertise && data.doctor_expertise.length > 0) {
let arr = [];
@ -1113,6 +1148,50 @@
//await nextTick();
};
//
const handleApplyCA=()=>{
applyCA(modalForm.user_doctor_info.user_id).then(data=>{
if(data.code==200){
Message.success('证书申请成功');
handleUpdate({doctor_id:modalForm.doctor_id})
}
})
}
const handleUpdateCA=()=>{
updateCA(modalForm.user_doctor_info.user_id).then(data=>{
if(data.code==200){
Message.success('证书更新成功');
handleUpdate({doctor_id:modalForm.doctor_id})
}
})
}
const handleRemoveCA=()=>{
removeCA(modalForm.user_doctor_info.user_id).then(data=>{
if(data.code==200){
Message.success('证书注销成功');
handleUpdate({doctor_id:modalForm.doctor_id})
}
})
}
const handleApplySign=()=>{
applySign({
type:2,
user_id:modalForm.user_doctor_info.user_id
}).then(data=>{
if(data.code==200){
Message.success('签章申请成功');
}
})
}
const handleUpdateSign=()=>{
updateSign(modalForm.user_doctor_info.user_id).then(data=>{
if(data.code==200){
Message.success('签章更新成功');
}
})
}
//
// const filterService = (record) => {
// let arr = [];
@ -1141,7 +1220,8 @@
// Modal ok
// Modal done()
const handleSubmit = (done) => {
proxy.$refs.modalFormRef.validate(async (valid) => {
if(okStatus.value==1){
proxy.$refs.modalFormRef.validate(async (valid) => {
if (!valid) {
let res;
let modalData = {
@ -1258,10 +1338,27 @@
} else {
console.log(valid)
proxy.$message.error('表单校验失败');
Message.error('表单校验失败');
//done(false);
}
});
}else if(okStatus.value==2){
//
handleUpdateCA();
}else if(okStatus.value==3){
//
handleRemoveCA();
}else if(okStatus.value==4){
//
handleApplySign();
}else if(okStatus.value==5){
//
handleUpdateSign();
}else if(okStatus.value==6){
handleApplyCA();
}
};
//
@ -1273,15 +1370,15 @@
hideCancel: false,
onOk: async () => {
const res = await removeDoctor({ ids: batchList });
proxy.$message.success(res.message);
Message.success(res.message);
getDoctorInfo(pager);
},
onCancel: () => {
proxy.$message.info('已取消批量删除数据');
Message.info('已取消批量删除数据');
},
});
} else {
proxy.$message.error('请勾选需要删除的数据!');
Message.error('请勾选需要删除的数据!');
}
};
@ -1481,6 +1578,7 @@
getOssSign(1, fileList[0].file);
}
//ca
onMounted(() => {
getDoctorInfo(pager);
handleHospitalList();

View File

@ -34,7 +34,7 @@
@selection-change="(selection) => {deleteData = selection;}" @page-change="handlePageChange"
@page-size-change="handlepage_sizeChange">
<template #doctor_id="{record,rowIndex}">
<div>{{(rowIndex+1)+(pager.page-1)*10}}</div>
<div>{{(rowIndex+1)+(pager.page-1)*pager.page_size}}</div>
</template>
<template #doctor_title="{ record }">
<!-- 医生职称1:主任医师 2:主任中医师 3:副主任医师 4:副主任中医师 5:主治医师 6:住院医师 -->

View File

@ -0,0 +1,307 @@
<template>
<div class="app-container">
<a-form :model="queryForm" ref="queryFormRef" layout="inline">
<a-form-item field="user_name" label="医生姓名">
<a-input :style="{ width: '182px' }" v-model="queryForm.user_name" placeholder="请输入医生姓名" @press-enter="handleQuery" />
</a-form-item>
<a-form-item field="mobile" label="电话号码">
<a-input :style="{ width: '182px' }" v-model="queryForm.mobile" placeholder="请输入电话号码" @press-enter="handleQuery" />
</a-form-item>
<a-form-item field="bank_card_code" label="银行卡号">
<a-input :style="{ width: '182px' }" v-model="queryForm.bank_card_code" placeholder="请输入银行卡号" @press-enter="handleQuery" />
</a-form-item>
<a-form-item field="bank_name" label="开户行">
<a-select v-model="queryForm.bank_name" placeholder="请选择开户行" :style="{ width: '182px' }">
<a-option v-for="item in bankData" :key="item.bank_id" :value="item.bank_name"
:label="item.bank_name"></a-option>
</a-select>
</a-form-item>
<a-form-item>
<a-space>
<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:sysFamilyList:add'" type="primary" @click="handleAdd"><icon-export /> 导出 </a-button>
</a-space>
</div>
<!-- table -->
<a-table :columns="columns" :data="tableData"
:scroll="{ x: 1400 }"
:row-selection="{ type: 'checkbox', showCheckedAll: true }"
:pagination="{ 'show-total': true, 'show-jumper': true, 'show-page-size': true, total: pager.total, current: currentPage }"
row-key="doctor_id" @selection-change="(selection) => {deleteData = selection;console.log(selection)}"
@page-change="handlePageChange" @page-size-change="handlepage_sizeChange">
<template #doctor_id="{record,rowIndex}">
<div>{{(rowIndex+1)+(pager.page-1)*pager.page_size}}</div>
</template>
<template #province="{ record }">
<div>{{record.province}}{{record.city}}{{record.county}}</div>
</template>
<template #action="{ record }">
<a-space>
<a-button v-has="'admin:sysconfigList:edit'" type="text"
@click="handleDetail(record)"><icon-edit />修改</a-button>
<!-- <a-button v-has="'admin:sysFamilyList:edit'" type="text" @click="handleUpdate(record)"><icon-edit />
修改</a-button> -->
<!-- <a-button v-has="'admin:sysFamilyList:remove'" type="text"
@click="() => { deleteVisible = true; deleteData = [record.doctor_id]; }"><icon-delete /> 删除</a-button> -->
</a-space>
</template>
</a-table>
<!-- Akiraka 20230223 删除与批量删除 开始 -->
<!-- <DeleteModal :data="deleteData" :visible="deleteVisible" :apiDelete="removeFamily"
@deleteVisibleChange="() => deleteVisible = false" /> -->
<!-- Akiraka 20230223 删除与批量删除 结束 -->
<a-modal v-model:visible="okVisible" :modal-style="{width:'320px'}" body-class="okmodal"
@cancel="()=>okVisible=false">
<template #title>
提示
</template>
<div>确定保存当前信息</div>
</a-modal>
</div>
</template>
<script setup>
import { reactive, ref, getCurrentInstance, onMounted, nextTick, watch, computed } from 'vue';
import { getBankList} from '@/api/finance/bank';
import { bankList} from '@/api/doctor/list';
// Akiraka 20230210
const deleteData = ref([])
// Akiraka 20230210
const deleteVisible = ref(false)
// Akiraka 20230210
const okVisible = ref(false);
const inquiry_config_id=ref("");
watch(() => deleteVisible.value, (value) => {
if (value == false) {
getBankInfo(pager);
}
});
const file = ref();
const { proxy } = getCurrentInstance();
const currentPage = ref(1);
// Pager
const pager = {
total: 0,
page: 1,
page_size: 10,
};
// form
const queryForm = reactive({
});
const modalForm = reactive({
user:{},
avatar: 'https://img.applets.igandanyiyuan.com/basic/file/patient_avatar.png',
});
// Modal
const modalVisible = ref(false);
const modalTitle = ref('默认标题');
// Batch Del List
let batchList = [];
// Table Columns
const columns = [
{ title: '编号', dataIndex: 'doctor_id', slotName: 'doctor_id', width: '90' },
{
title: '银行卡号',
dataIndex: 'bank_card_code_mask',
slotName:'bank_card_code_mask'
},
{
title: '医生姓名',
dataIndex: 'doctor_name',
slotName:'doctor_name'
},{
title: '医生电话',
dataIndex: 'doctor_mobile_mask',
slotName:'doctor_mobile_mask'
},
{
title: '开户行所在地',
dataIndex: 'province',
slotName:'province'
},
{
title: '开户行',
dataIndex: 'bank_name',
slotName:'bank_name'
},
{
title: '添加时间',
dataIndex: 'created_at',
slotName:'created_at'
},
//{ title: '', slotName: 'action', fixed: "right", width: 150 }
]
// Table Data
const tableData = ref([]);
//
const modalSatus = ref('add');
// Satus
const handleAdd = () => {
alert('导出')
};
//
const handleDetail = async (record) => {
inquiry_config_id.value=record.system_inquiry_config_id;
modalVisible.value = true;
};
/**
* 分页改变
* @param {Number} [page]
*/
const handlePageChange = (page) => {
pager.page = page;
//
currentPage.value = page;
getBankInfogetBankInfo({ ...pager, ...queryForm });
};
//
const handlepage_sizeChange = (page_size) => {
pager.page_size = page_size;
getBankInfo({ ...pager, ...queryForm });
};
//
const getBankInfo = async (params = {}) => {
const { data, code, message } = await getBankList(params);
if (code == 200) {
tableData.value = data.data;
Object.assign(pager, { total: data.total, page: data.page, page_size: data.page_size });
}
};
//
const handleQuery = async () => {
pager.page = 1;
const params = {
page: pager.page,
page_size: pager.page_size,
...queryForm,
};
getBankInfo(params);
};
//
const handleResetQuery = () => {
proxy.$refs.queryFormRef.resetFields();
getBankInfo(queryForm);
}
const bankData = ref([])
const handleBankList = () => {
bankList().then((res) => {
const { data, code, message } = res;
if (code == 200) {
bankData.value = data;
}
})
}
onMounted(() => {
getBankInfo(pager);
handleBankList();
});
</script>
<style lang="scss" scoped>
.action {
margin-bottom: 12px;
}
.okmodal div {
text-align: center;
}
.hospital_name {
width: 140px;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
.headImg {
margin-right: 20px;
border-radius: 50%;
width: 80px;
height: 80px;
}
.arco-form-item-layout-horizontal:first-child,
.arco-form-item-layout-horizontal:nth-child(2) {
align-items: center;
}
.cellbox{
margin-top: 35px;
}
.cellbox .cell{
width:50%;
border-bottom:1px dashed #efefef;
margin-bottom: 20px;
}
.cellbox .cell:first-child{
border: none;
}
.cell{
.arco-form-item{
margin-bottom: 10px;
}
}
.box {
display: flex;
align-items: center;
}
.cert .arco-form-item-label-col {
flex: 0 0 8px !important;
}
.red {
display: inline-block;
margin-right: 5px;
font-size: 14px;
color: red;
margin-top: 5px;
}
.cardNum {
width: 148px;
}
.codbox{
display: flex;
align-items: center;
}
.reason{
width:250px;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
</style>

View File

@ -0,0 +1,300 @@
<template>
<div class="app-container">
<a-form :model="queryForm" ref="queryFormRef" layout="inline">
<a-form-item field="user_name" label="医生姓名">
<a-input :style="{ width: '182px' }" v-model="queryForm.user_name" placeholder="请输入医生姓名" @press-enter="handleQuery" />
</a-form-item>
<a-form-item field="mobile" label="电话号码">
<a-input :style="{ width: '182px' }" v-model="queryForm.mobile" placeholder="请输入电话号码" @press-enter="handleQuery" />
</a-form-item>
<a-form-item>
<a-space>
<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:sysDoctorAccount:export'" type="primary" @click="handleExport"><icon-export />导出 </a-button>
</a-space>
</div>
<!-- table -->
<a-table :columns="columns" :data="tableData"
:row-selection="{ type: 'checkbox', showCheckedAll: true }"
:pagination="{ 'show-total': true, 'show-jumper': true, 'show-page-size': true, total: pager.total, current: currentPage }"
row-key="doctor_id" @selection-change="(selection) => {deleteData = selection;console.log(selection)}"
@page-change="handlePageChange" @page-size-change="handlepage_sizeChange">
<template #doctor_id="{record,rowIndex}">
<div>{{(rowIndex+1)+(pager.page-1)*pager.page_size}}</div>
</template>
<template #province="{ record }">
<div>{{record.province}}{{record.city}}{{record.county}}</div>
</template>
<template #action="{ record }">
<a-space>
<a-button v-has="'admin:sysDoctorAccount:detail'" type="text"
@click="handleDetail(record)"><icon-book />详情</a-button>
</a-space>
</template>
</a-table>
<accountModal :modalVisible="modalVisible" :modalForm="modalForm" @familyVisibleChange="()=>{modalVisible=false,modalForm.doctor_id=''}" ></accountModal>
<!-- Akiraka 20230223 删除与批量删除 开始 -->
<!-- <DeleteModal :data="deleteData" :visible="deleteVisible" :apiDelete="removeFamily"
@deleteVisibleChange="() => deleteVisible = false" /> -->
<!-- Akiraka 20230223 删除与批量删除 结束 -->
<a-modal v-model:visible="okVisible" :modal-style="{width:'320px'}" body-class="okmodal"
@cancel="()=>okVisible=false">
<template #title>
提示
</template>
<div>确定保存当前信息</div>
</a-modal>
</div>
</template>
<script setup>
import { reactive, ref, getCurrentInstance, onMounted, nextTick, watch, computed } from 'vue';
import { getAccountList,getAccountDetail} from '@/api/finance/account';
// Akiraka 20230210
const deleteData = ref([])
// Akiraka 20230210
const deleteVisible = ref(false)
// Akiraka 20230210
const okVisible = ref(false);
const inquiry_config_id=ref("");
watch(() => deleteVisible.value, (value) => {
if (value == false) {
getAccountInfo(pager);
}
});
const file = ref();
const { proxy } = getCurrentInstance();
const currentPage = ref(1);
const family_data=ref([]);
const family_columns=ref([{
title: '编号',
dataIndex: 'code',
slotName:'code'
},{
title: '就诊人姓名',
dataIndex: 'card_name_mask',
},{
title: '身份证号',
dataIndex: 'id_number_mask',
},{
title: '与账号关系',
dataIndex: 'relation',
slotName:'relation'
},{
title: '添加时间',
dataIndex: 'created_at',
slotName:'created_at'
}, { title: '操作', slotName: 'action'}])
// Pager
const pager = {
total: 0,
page: 1,
page_size: 10,
};
// form
const queryForm = reactive({
});
const modalForm = reactive({
user:{},
avatar: 'https://img.applets.igandanyiyuan.com/basic/file/patient_avatar.png',
});
// Modal
const modalVisible = ref(false);
const modalTitle = ref('默认标题');
// Batch Del List
let batchList = [];
// Table Columns
const columns = [
{ title: '编号', dataIndex: 'doctor_id', slotName: 'doctor_id', width: '90' },
{
title: '医生姓名',
dataIndex: 'doctor_name',
slotName:'doctor_name'
},{
title: '医生电话',
dataIndex: 'doctor_mobile_mask',
slotName:'doctor_mobile_mask',
width:120
},
{
title: '账户金额(元)',
dataIndex: 'balance_account',
slotName:'balance_account'
},
{
title: '已完成待入账金额(元)',
dataIndex: 'completed_wait_entry_amount',
slotName:'completed_wait_entry_amount'
},
{
title: '今日接诊收入(元)',
dataIndex: 'estimate_income',
slotName:'estimate_income'
},
{ title: '操作', slotName: 'action', fixed: "right", width: 150 }
]
// Table Data
const tableData = ref([]);
const handleExport=()=>{
alert('导出')
}
//
const handleDetail = async (record) => {
const { code, data, message } = await getAccountDetail(record.doctor_id);
if (code == 200) {
Object.assign(modalForm, data);
modalVisible.value = true;
}
};
/**
* 分页改变
* @param {Number} [page]
*/
const handlePageChange = (page) => {
pager.page = page;
//
currentPage.value = page;
getAccountInfogetAccountInfo({ ...pager, ...queryForm });
};
//
const handlepage_sizeChange = (page_size) => {
pager.page_size = page_size;
getAccountInfo({ ...pager, ...queryForm });
};
//
const getAccountInfo = async (params = {}) => {
const { data, code, message } = await getAccountList(params);
if (code == 200) {
tableData.value = data.data;
Object.assign(pager, { total: data.total, page: data.page, page_size: data.page_size });
}
};
//
const handleQuery = async () => {
pager.page = 1;
const params = {
page: pager.page,
page_size: pager.page_size,
...queryForm,
};
getAccountInfo(params);
};
//
const handleResetQuery = () => {
proxy.$refs.queryFormRef.resetFields();
getAccountInfo(queryForm);
}
onMounted(() => {
getAccountInfo(pager);
});
</script>
<style lang="scss" scoped>
.action {
margin-bottom: 12px;
}
.okmodal div {
text-align: center;
}
.hospital_name {
width: 140px;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
.headImg {
margin-right: 20px;
border-radius: 50%;
width: 80px;
height: 80px;
}
.arco-form-item-layout-horizontal:first-child,
.arco-form-item-layout-horizontal:nth-child(2) {
align-items: center;
}
.cellbox{
margin-top: 35px;
}
.cellbox .cell{
width:50%;
border-bottom:1px dashed #efefef;
margin-bottom: 20px;
}
.cellbox .cell:first-child{
border: none;
}
.cell{
.arco-form-item{
margin-bottom: 10px;
}
}
.box {
display: flex;
align-items: center;
}
.cert .arco-form-item-label-col {
flex: 0 0 8px !important;
}
.red {
display: inline-block;
margin-right: 5px;
font-size: 14px;
color: red;
margin-top: 5px;
}
.cardNum {
width: 148px;
}
.codbox{
display: flex;
align-items: center;
}
.reason{
width:250px;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
</style>

View File

@ -0,0 +1,389 @@
<template>
<div class="app-container">
<a-form :model="queryForm" ref="queryFormRef" layout="inline">
<a-form-item field="user_name" label="医生姓名">
<a-input :style="{ width: '182px' }" v-model="queryForm.user_name" placeholder="请输入医生姓名" @press-enter="handleQuery" />
</a-form-item>
<a-form-item field="mobile" label="电话号码">
<a-input :style="{ width: '182px' }" v-model="queryForm.mobile" placeholder="请输入电话号码" @press-enter="handleQuery" />
</a-form-item>
<a-form-item field="settle_status" label="结算状态">
<a-select @change="changeSettle" v-model="queryForm.settle_status" placeholder="请选择结算状态" :style="{ width: '182px' }">
<a-option :value="1">待结算</a-option>
<a-option :value="2">结算中</a-option>
<a-option :value="3">结算成功</a-option>
<a-option :value="4">结算失败</a-option>
</a-select>
</a-form-item>
<!-- <a-form-item field="examine_status" label="审核状态">
<a-select v-model="queryForm.examine_status" placeholder="请选择审核状态" :style="{ width: '182px' }">
<a-option :value="1">审核中</a-option>
<a-option :value="2">审核通过</a-option>
<a-option :value="3">审核未通过</a-option>
</a-select>
</a-form-item>
<a-form-item field="payment_status" label="打款状态">
<a-select v-model="queryForm.payment_status" placeholder="请选择打款状态" :style="{ width: '182px' }">
<a-option :value="0"></a-option>
<a-option :value="1"></a-option>
</a-select>
</a-form-item> -->
<a-form-item field="examine_range_time" label="审核时间范围">
<a-range-picker
style="width: 260px"
v-model="queryForm.examine_range_time"
/>
</a-form-item>
<a-form-item field="payment_range_time" label="打款时间范围">
<a-range-picker
style="width: 260px"
v-model="queryForm.payment_range_time"
/>
</a-form-item>
<a-form-item>
<a-space>
<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:sysFamilyList:add'" type="primary" @click="handleAdd"><icon-plus /> 新增 </a-button>
<a-button v-has="'admin:sysFamilyList:remove'" type="primary" status="danger"><icon-delete /> 批量删除 </a-button>
</a-space>
</div> -->
<!-- table -->
<a-table :columns="columns" :data="tableData"
:scroll="{ x:2000 }"
:row-selection="{ type: 'checkbox', showCheckedAll: true }"
:pagination="{ 'show-total': true, 'show-jumper': true, 'show-page-size': true, total: pager.total, current: currentPage }"
row-key="doctor_id" @selection-change="(selection) => {deleteData = selection;console.log(selection)}"
@page-change="handlePageChange" @page-size-change="handlepage_sizeChange">
<template #doctor_id="{record,rowIndex}">
<div>{{(rowIndex+1)+(pager.page-1)*pager.page_size}}</div>
</template>
<template #payment_status="{ record }">
<!-- 状态0:禁用 1:正常 2:删除 -->
<div v-if="record.examine_status==1 && record.payment_status==0">待结算</div>
<div v-else-if="record.examine_status==2 && record.payment_status==0">结算中</div>
<div v-else-if="record.examine_status==2 && record.payment_status==1">结算成功</div>
<div v-else-if="record.examine_status==3 ">结算失败</div>
<!--
<a-tag v-if="record.payment_status == 1" color="green">正常</a-tag>
<a-tag v-else color="red">失败</a-tag> -->
</template>
<template #created_at="{record}">
<div>{{parseTime(record.created_at)}}</div>
</template>
<template #payment_time="{record}">
<div>{{parseTime(record.payment_time)}}</div>
</template>
<template #action="{ record }">
<a-space>
<a-button v-has="'admin:sysFinancialRecord:detail'" type="text"
@click="handleDetail(record)"><icon-book />详情</a-button>
<!-- <a-button v-has="'admin:sysFamilyList:edit'" type="text" @click="handleUpdate(record)"><icon-edit />
修改</a-button> -->
<!-- <a-button v-has="'admin:sysFamilyList:remove'" type="text"
@click="() => { deleteVisible = true; deleteData = [record.doctor_id]; }"><icon-delete /> 删除</a-button> -->
</a-space>
</template>
</a-table>
<withdrawalModal :modalVisible="modalVisible" :modalForm="modalForm" @familyVisibleChange="()=>{modalVisible=false,modalForm.withdrawal_id=''}" @freshDetail="freshDetail"></withdrawalModal>
<!-- Akiraka 20230223 删除与批量删除 开始 -->
<!-- <DeleteModal :data="deleteData" :visible="deleteVisible" :apiDelete="removeFamily"
@deleteVisibleChange="() => deleteVisible = false" /> -->
<!-- Akiraka 20230223 删除与批量删除 结束 -->
<!-- <a-modal v-model:visible="okVisible" :modal-style="{width:'320px'}" body-class="okmodal"
@cancel="()=>okVisible=false">
<template #title>
提示
</template>
<div>确定保存当前信息</div>
</a-modal> -->
</div>
</template>
<script setup>
import { reactive, ref, getCurrentInstance, onMounted, nextTick, watch, computed, withDirectives } from 'vue';
import { getWithdrawalList,getWithdrawalDetail} from '@/api/finance/record';
import { parseTime } from '@/utils/parseTime';
// Akiraka 20230210
const deleteData = ref([])
// Akiraka 20230210
const deleteVisible = ref(false)
// Akiraka 20230210
const okVisible = ref(false);
watch(() => deleteVisible.value, (value) => {
if (value == false) {
getWithdrawalInfo(pager);
}
});
const file = ref();
const { proxy } = getCurrentInstance();
const currentPage = ref(1);
// Pager
const pager = {
total: 0,
page: 1,
page_size: 10,
};
// form
const queryForm = reactive({
});
const modalForm = reactive({
user:{},
avatar: 'https://img.applets.igandanyiyuan.com/basic/file/patient_avatar.png',
});
watch(() => queryForm.examine_range_time,
(value) => {
if (value) {
let [startTime, endTime] = value;
queryForm.examine_time = startTime + '&' + endTime;
} else {
queryForm.examine_time = '';
}
}
);
watch(() => queryForm.payment_range_time,
(value) => {
if (value) {
let [startTime, endTime] = value;
queryForm.payment_time = startTime + '&' + endTime;
} else {
queryForm.payment_time = '';
}
}
);
// Modal
const modalVisible = ref(false);
const modalTitle = ref('默认标题');
// Batch Del List
let batchList = [];
// Table Columns
const columns = [
{ title: '编号', dataIndex: 'doctor_id', slotName: 'doctor_id', width: '90' },
{ title: '医生姓名', dataIndex: 'doctor_name',width:200 },
{ title: '应提现金额(元)', dataIndex: 'applied_withdrawal_amount',slotName: 'applied_withdrawal_amount', width:180 },
{ title: '实际提现金额(元)', dataIndex: 'actual_withdrawal_amount',slotName: 'actual_withdrawal_amount',width:180 },
{ title: '个人所得税(元)', dataIndex: 'income_tax', slotName: 'income_tax',width: 150 },
{ title: '开户行', dataIndex: 'bank_name', slotName: 'bank_name',width: 150 },
{ title: '开户城市', dataIndex: 'bank_city', slotName: 'bank_city',width: 150 },
{ title: '状态', dataIndex: 'payment_status', slotName: 'payment_status' },
{ title: '提现时间', dataIndex: 'created_at', slotName: 'created_at' },
{ title: '打款时间', dataIndex: 'payment_time', slotName: 'payment_time' },
{ title: '操作人', dataIndex: 'examine_by', slotName: 'examine_by',width: 80 },
{ title: '操作', slotName: 'action', fixed: "right", width: 180 },
];
// Table Data
const tableData = ref([]);
//
const modalSatus = ref('add');
// Satus
const handleAdd = () => {
modalVisible.value = true;
modalTitle.value = '新增患者';
modalSatus.value = 'add';
modalForm.patient_id = null;
};
//
const handleDetail = async (record) => {
const { code, data, message } = await getWithdrawalDetail(record.withdrawal_id);
if (code == 200) {
Object.assign(modalForm, data);
modalVisible.value = true;
}
};
const freshDetail=()=>{
handleDetail({
withdrawal_id:modalForm.withdrawal_id
})
}
//
const handleBatchDelete = () => {
if (batchList.length !== 0) {
proxy.$modal.warning({
title: '提示',
content: '是否批量删除以下选中的数据?',
hideCancel: false,
onOk: async () => {
const res = await removeFamily({ ids: batchList });
proxy.$message.success(res.message);
getWithdrawalInfo(pager);
},
onCancel: () => {
proxy.$message.info('已取消批量删除数据');
},
});
} else {
proxy.$message.error('请勾选需要删除的数据!');
}
};
const changeSettle=(value)=>{
// <div v-if="record.examine_status!=3 && record.payment_status==0"></div>
// <div v-else-if="record.examine_status==2 && record.payment_status==0"></div>
// <div v-else-if="record.examine_status==2 && record.payment_status==1"></div>
// <div v-else-if="record.examine_status==3 "></div>
if(value==1){
queryForm.examine_status=1;
queryForm.payment_status=0;
}else if(value==2){
queryForm.examine_status=2;
queryForm.payment_status=0;
}else if(value==3){
queryForm.examine_status=2;
queryForm.payment_status=1;
}else if(value==4){
queryForm.examine_status=3;
delete queryForm.payment_status;
}else{
delete queryForm.examine_status;
delete queryForm.payment_status;
}
}
/**
* 分页改变
* @param {Number} [page]
*/
const handlePageChange = (page) => {
pager.page = page;
//
currentPage.value = page;
getWithdrawalInfo({ ...pager, ...queryForm });
};
//
const handlepage_sizeChange = (page_size) => {
pager.page_size = page_size;
getWithdrawalInfo({ ...pager, ...queryForm });
};
//
const getWithdrawalInfo = async (params = {}) => {
const { data, code, message } = await getWithdrawalList(params);
if (code == 200) {
tableData.value = data.data;
Object.assign(pager, { total: data.total, page: data.page, page_size: data.page_size });
}
};
//
const handleQuery = async () => {
pager.page = 1;
const params = {
page: pager.page,
page_size: pager.page_size,
...queryForm,
};
getWithdrawalInfo(params);
};
//
const handleResetQuery = () => {
delete queryForm.examine_status;
delete queryForm.payment_status;
proxy.$refs.queryFormRef.resetFields();
handleQuery();
}
onMounted(() => {
getWithdrawalInfo(pager);
});
</script>
<style lang="scss" scoped>
.action {
margin-bottom: 12px;
}
.okmodal div {
text-align: center;
}
.hospital_name {
width: 140px;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
.headImg {
margin-right: 20px;
border-radius: 50%;
width: 80px;
height: 80px;
}
.arco-form-item-layout-horizontal:first-child,
.arco-form-item-layout-horizontal:nth-child(2) {
align-items: center;
}
.cellbox{
margin-top: 35px;
}
.cellbox .cell{
width:50%;
border-bottom:1px dashed #efefef;
margin-bottom: 20px;
}
.cellbox .cell:first-child{
border: none;
}
.cell{
.arco-form-item{
margin-bottom: 10px;
}
}
.box {
display: flex;
align-items: center;
}
.cert .arco-form-item-label-col {
flex: 0 0 8px !important;
}
.red {
display: inline-block;
margin-right: 5px;
font-size: 14px;
color: red;
margin-top: 5px;
}
.cardNum {
width: 148px;
}
.codbox{
display: flex;
align-items: center;
}
.reason{
width:250px;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
</style>

View File

@ -3,7 +3,7 @@
<a-form :model="queryForm" ref="queryFormRef" layout="inline">
<a-form-item field="doctor_name" label="医生姓名">
<a-input :style="{ width: '182px' }" v-model="queryForm.user_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="mobile" label="电话号码">
<a-input :style="{ width: '182px' }" v-model="queryForm.mobile" placeholder="请输入电话号码" @press-enter="handleQuery" />
@ -20,8 +20,8 @@
</a-form-item>
<a-form-item field="is_enable" label="启用状态">
<a-select v-model="queryForm.is_enable" placeholder="请选择启用状态" :style="{ width: '182px' }">
<a-option :value="0"></a-option>
<a-option :value="1"></a-option>
<a-option :value="0">关闭</a-option>
<a-option :value="1">开启</a-option>
</a-select>
</a-form-item>
@ -39,7 +39,7 @@
<!-- action -->
<div class="action">
<a-space>
<a-button v-has="'admin:sysFamilyList:add'" type="primary" @click="handleAdd"><icon-plus /> 新增 </a-button>
<a-button v-has="'admin:sysDoctorconfigList:add'" type="primary" @click="handleAdd"><icon-plus /> 新增 </a-button>
<!-- <a-button v-has="'admin:sysFamilyList:remove'" type="primary" status="danger"><icon-delete /> 批量删除 </a-button> -->
</a-space>
</div>
@ -52,7 +52,7 @@
row-key="doctor_id" @selection-change="(selection) => {deleteData = selection;console.log(selection)}"
@page-change="handlePageChange" @page-size-change="handlepage_sizeChange">
<template #doctor_id="{record,rowIndex}">
<div>{{(rowIndex+1)+(pager.page-1)*10}}</div>
<div>{{(rowIndex+1)+(pager.page-1)*pager.page_size}}</div>
</template>
<template #doctor_title="{ record }">
<div>{{ formatDoctorTitle(record.doctor_title) }}</div>
@ -68,13 +68,19 @@
<div class="reason" v-if="record.last_enable_method==1" >自己</div>
<div v-else>后台</div>
</template>
<template #is_enable="{record}">
<a-tag v-if="record.is_enable == 0" color="red">关闭</a-tag>
<a-tag v-else-if="record.is_enable== 1" color="green">开启</a-tag>
</template>
<template #relation="{record}">
<div>{{formatRelation(record.relation)}}</div>
</template>
<template #action="{ record }">
<a-space>
<a-button v-has="'admin:sysFamilyList:detail'" type="text"
<a-button v-has="'admin:sysDoctorconfigList:edit'" type="text"
@click="handleDetail(record)"><icon-edit />修改</a-button>
<!-- <a-button v-has="'admin:sysFamilyList:edit'" type="text" @click="handleUpdate(record)"><icon-edit />
修改</a-button> -->
@ -84,7 +90,7 @@
</template>
</a-table>
<addInquiryConfigModal :modalVisible="modalVisible" :modalForm="modalForm" @familyVisibleChange="()=>{modalVisible=false}"></addInquiryConfigModal>
<addInquiryConfigModal :modalVisible="modalVisible" :inquiry_config_id="inquiry_config_id" :modalForm="modalForm" @freshList="getInquiryInfo(pager);" @familyVisibleChange="()=>{modalVisible=false;inquiry_config_id='';}"></addInquiryConfigModal>
<!-- Akiraka 20230223 删除与批量删除 开始 -->
<!-- <DeleteModal :data="deleteData" :visible="deleteVisible" :apiDelete="removeFamily"
@deleteVisibleChange="() => deleteVisible = false" /> -->
@ -101,7 +107,7 @@
<script setup>
import { reactive, ref, getCurrentInstance, onMounted, nextTick, watch, computed } from 'vue';
import { getInquiryconfigList,getInquiryconfigDetail} from '@/api/inquiry/config';
import { getInquiryconfigList} from '@/api/inquiry/config';
import {formatDoctorTitle,formatInquiryType,formatMultipoint} from "@/utils/format"
// Akiraka 20230210
@ -110,7 +116,7 @@
const deleteVisible = ref(false)
// Akiraka 20230210
const okVisible = ref(false);
const inquiry_config_id=ref("");
watch(() => deleteVisible.value, (value) => {
if (value == false) {
getInquiryInfo(pager);
@ -172,6 +178,7 @@
{ title: '接诊数量', dataIndex: 'work_num_day' },
{ title: '多点执业', dataIndex: 'multi_point_status',slotName:'multi_point_status' },
{ title: '问诊类型', dataIndex: 'inquiry_type',slotName:'inquiry_type' },
{ title: '启用状态', dataIndex: 'is_enable',slotName:'is_enable' },
{ title: '申请人', dataIndex: 'last_enable_method',slotName:'last_enable_method' },
{ title: '操作', slotName: 'action', fixed: "right", width: 180 },
];
@ -184,39 +191,13 @@
// Satus
const handleAdd = () => {
modalVisible.value = true;
modalTitle.value = '新增患者';
modalSatus.value = 'add';
modalForm.patient_id = null;
inquiry_config_id.value='';
};
//
const handleDetail = async (record) => {
const { code, data, message } = await getInquiryconfigDetail(record.family_id);
if (code == 200) {
Object.assign(modalForm, data);
modalVisible.value = true;
}
};
//
const handleBatchDelete = () => {
if (batchList.length !== 0) {
proxy.$modal.warning({
title: '提示',
content: '是否批量删除以下选中的数据?',
hideCancel: false,
onOk: async () => {
const res = await removeFamily({ ids: batchList });
proxy.$message.success(res.message);
getInquiryInfo(pager);
},
onCancel: () => {
proxy.$message.info('已取消批量删除数据');
},
});
} else {
proxy.$message.error('请勾选需要删除的数据!');
}
inquiry_config_id.value=record.inquiry_config_id;
modalVisible.value = true;
};
/**

View File

@ -0,0 +1,344 @@
<template>
<div class="app-container">
<a-form :model="queryForm" ref="queryFormRef" layout="inline">
<a-form-item field="inquiry_type" label="问诊类型">
<a-select v-model="queryForm.inquiry_type" placeholder="请选择服务类型" :style="{ width: '182px' }">
<!-- 1:专家问诊 2:快速问诊 3:公益问诊 4:问诊购药 -->
<a-option :value="1">专家问诊</a-option>
<a-option :value="2">快速问诊</a-option>
<a-option :value="3">公益问诊</a-option>
<a-option :value="4">问诊购药</a-option>
<a-option :value="5">糖组检测</a-option>
</a-select>
</a-form-item>
<a-form-item field="inquiry_mode" label="接诊方式">
<a-select v-model="queryForm.inquiry_mode" placeholder="请选择接诊方式" :style="{ width: '182px' }">
<a-option :value="1">图文</a-option>
<a-option :value="2">视频</a-option>
<a-option :value="3">语音</a-option>
<a-option :value="4">电话</a-option>
<a-option :value="5">会员</a-option>
</a-select>
</a-form-item>
<a-form-item>
<a-space>
<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:sysFamilyList:add'" type="primary" @click="handleAdd"><icon-plus /> 新增 </a-button>
<a-button v-has="'admin:sysFamilyList:remove'" type="primary" status="danger"><icon-delete /> 批量删除 </a-button>
</a-space>
</div> -->
<!-- table -->
<a-table :columns="columns" :data="tableData"
:scroll="{ x: 1400 }"
:row-selection="{ type: 'checkbox', showCheckedAll: true }"
:pagination="{ 'show-total': true, 'show-jumper': true, 'show-page-size': true, total: pager.total, current: currentPage }"
row-key="doctor_id" @selection-change="(selection) => {deleteData = selection;console.log(selection)}"
@page-change="handlePageChange" @page-size-change="handlepage_sizeChange">
<template #doctor_id="{record,rowIndex}">
<div>{{(rowIndex+1)+(pager.page-1)*pager.page_size}}</div>
</template>
<template #inquiry_mode="{ record }">
<div>{{ formatMode(record.inquiry_mode) }}</div>
</template>
<template #inquiry_price="{ record }">
<div v-if="record.inquiry_price">{{ record.inquiry_price}}</div>
</template>
<template #inquiry_type="{record}">
<div>{{ formatInquiryType(record.inquiry_type) }}</div>
</template>
<template #times_number="{record}">
<div v-if="record.times_number==0" >不限次数</div>
<div v-else>{{record.times_number}}</div>
</template>
<template #duration="{record}">
<div v-if="record.duration==0" >不限时长</div>
<div v-else-if="record.duration>0 && record.duration<60">{{record.duration}}分钟</div>
<div v-else-if="record.duration>=60">{{record.duration/60}}小时</div>
</template>
<template #action="{ record }">
<a-space>
<a-button v-has="'admin:sysconfigList:edit'" type="text"
@click="handleDetail(record)"><icon-edit />修改</a-button>
<!-- <a-button v-has="'admin:sysFamilyList:edit'" type="text" @click="handleUpdate(record)"><icon-edit />
修改</a-button> -->
<!-- <a-button v-has="'admin:sysFamilyList:remove'" type="text"
@click="() => { deleteVisible = true; deleteData = [record.doctor_id]; }"><icon-delete /> 删除</a-button> -->
</a-space>
</template>
</a-table>
<addSysconfigModal :modalVisible="modalVisible" :inquiry_config_id="inquiry_config_id" :modalForm="modalForm" @freshList="getInquiryInfo(pager);" @familyVisibleChange="()=>{modalVisible=false;inquiry_config_id='';}"></addSysconfigModal>
<!-- Akiraka 20230223 删除与批量删除 开始 -->
<!-- <DeleteModal :data="deleteData" :visible="deleteVisible" :apiDelete="removeFamily"
@deleteVisibleChange="() => deleteVisible = false" /> -->
<!-- Akiraka 20230223 删除与批量删除 结束 -->
<a-modal v-model:visible="okVisible" :modal-style="{width:'320px'}" body-class="okmodal"
@cancel="()=>okVisible=false">
<template #title>
提示
</template>
<div>确定保存当前信息</div>
</a-modal>
</div>
</template>
<script setup>
import { reactive, ref, getCurrentInstance, onMounted, nextTick, watch, computed } from 'vue';
import { getSysconfigList} from '@/api/inquiry/sysconfig';
import {formatMode,formatInquiryType} from "@/utils/format"
// Akiraka 20230210
const deleteData = ref([])
// Akiraka 20230210
const deleteVisible = ref(false)
// Akiraka 20230210
const okVisible = ref(false);
const inquiry_config_id=ref("");
watch(() => deleteVisible.value, (value) => {
if (value == false) {
getInquiryInfo(pager);
}
});
const file = ref();
const { proxy } = getCurrentInstance();
const currentPage = ref(1);
const family_data=ref([]);
const family_columns=ref([{
title: '编号',
dataIndex: 'code',
slotName:'code'
},{
title: '就诊人姓名',
dataIndex: 'card_name_mask',
},{
title: '身份证号',
dataIndex: 'id_number_mask',
},{
title: '与账号关系',
dataIndex: 'relation',
slotName:'relation'
},{
title: '添加时间',
dataIndex: 'created_at',
slotName:'created_at'
}, { title: '操作', slotName: 'action'}])
// Pager
const pager = {
total: 0,
page: 1,
page_size: 10,
};
// form
const queryForm = reactive({
});
const modalForm = reactive({
user:{},
avatar: 'https://img.applets.igandanyiyuan.com/basic/file/patient_avatar.png',
});
// Modal
const modalVisible = ref(false);
const modalTitle = ref('默认标题');
// Batch Del List
let batchList = [];
// Table Columns
const columns = [
{ title: '编号', dataIndex: 'doctor_id', slotName: 'doctor_id', width: '90' },
{
title: '问诊类型',
dataIndex: 'inquiry_type',
slotName:'inquiry_type'
},{
title: '接诊方式',
dataIndex: 'inquiry_mode',
slotName:'inquiry_mode'
},{
title: '接诊价格',
dataIndex: 'inquiry_price',
slotName:'inquiry_price'
},
{
title: '最高接诊价格',
dataIndex: 'max_inquiry_price',
slotName:'max_inquiry_price'
},
{
title: '最低接诊价格',
dataIndex: 'min_inquiry_price',
slotName:'min_inquiry_price'
},
{
title: '沟通次数',
dataIndex: 'times_number',
slotName:'times_number'
},
{
title: '沟通时长',
dataIndex: 'duration',
slotName:'duration'
},
{ title: '操作', slotName: 'action', fixed: "right", width: 150 }]
// Table Data
const tableData = ref([]);
//
const modalSatus = ref('add');
// Satus
const handleAdd = () => {
modalVisible.value = true;
inquiry_config_id.value='';
};
//
const handleDetail = async (record) => {
inquiry_config_id.value=record.system_inquiry_config_id;
modalVisible.value = true;
};
/**
* 分页改变
* @param {Number} [page]
*/
const handlePageChange = (page) => {
pager.page = page;
//
currentPage.value = page;
getInquiryInfo({ ...pager, ...queryForm });
};
//
const handlepage_sizeChange = (page_size) => {
pager.page_size = page_size;
getInquiryInfo({ ...pager, ...queryForm });
};
//
const getInquiryInfo = async (params = {}) => {
const { data, code, message } = await getSysconfigList(params);
if (code == 200) {
tableData.value = data.data;
Object.assign(pager, { total: data.total, page: data.page, page_size: data.page_size });
}
};
//
const handleQuery = async () => {
pager.page = 1;
const params = {
page: pager.page,
page_size: pager.page_size,
...queryForm,
};
getInquiryInfo(params);
};
//
const handleResetQuery = () => {
proxy.$refs.queryFormRef.resetFields();
getInquiryInfo(queryForm);
}
onMounted(() => {
getInquiryInfo(pager);
});
</script>
<style lang="scss" scoped>
.action {
margin-bottom: 12px;
}
.okmodal div {
text-align: center;
}
.hospital_name {
width: 140px;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
.headImg {
margin-right: 20px;
border-radius: 50%;
width: 80px;
height: 80px;
}
.arco-form-item-layout-horizontal:first-child,
.arco-form-item-layout-horizontal:nth-child(2) {
align-items: center;
}
.cellbox{
margin-top: 35px;
}
.cellbox .cell{
width:50%;
border-bottom:1px dashed #efefef;
margin-bottom: 20px;
}
.cellbox .cell:first-child{
border: none;
}
.cell{
.arco-form-item{
margin-bottom: 10px;
}
}
.box {
display: flex;
align-items: center;
}
.cert .arco-form-item-label-col {
flex: 0 0 8px !important;
}
.red {
display: inline-block;
margin-right: 5px;
font-size: 14px;
color: red;
margin-top: 5px;
}
.cardNum {
width: 148px;
}
.codbox{
display: flex;
align-items: center;
}
.reason{
width:250px;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
</style>

View File

@ -13,7 +13,7 @@
<div class="login-form-container">
<div class="account-top">
<div class="account-top-logo">
<img :src="store.sysConfig.sys_app_logo" />
<img src="../../icons/logo.png" />
<span class="project-title">用户登录</span>
</div>
<div class="account-top-desc">肝胆相照 健康中国</div>

View File

@ -69,7 +69,7 @@
row-key="doctor_id" @selection-change="(selection) => {deleteData = selection;console.log(selection)}"
@page-change="handlePageChange" @page-size-change="handlepage_sizeChange">
<template #doctor_id="{record,rowIndex}">
<div>{{(rowIndex+1)+(pager.page-1)*10}}</div>
<div>{{(rowIndex+1)+(pager.page-1)*pager.page_size}}</div>
</template>
<template #inquiry_type="{record}">
<div>{{formatInquiryType(record.inquiry_type)}}</div>

View File

@ -96,7 +96,7 @@
@page-size-change="handlepage_sizeChange"
>
<template #post_id="{record,rowIndex}">
<div>{{(rowIndex+1)+(pager.page-1)*10}}</div>
<div>{{(rowIndex+1)+(pager.page-1)*pager.page_size}}</div>
</template>
<template #inquiry_pay_channel="{record}">
<div v-if="record.inquiry_pay_channel==1">小程序支付</div>

View File

@ -46,7 +46,7 @@
row-key="doctor_id" @selection-change="(selection) => {deleteData = selection;console.log(selection)}"
@page-change="handlePageChange" @page-size-change="handlepage_sizeChange">
<template #doctor_id="{record,rowIndex}">
<div>{{(rowIndex+1)+(pager.page-1)*10}}</div>
<div>{{(rowIndex+1)+(pager.page-1)*pager.page_size}}</div>
</template>
<template #status="{ record }">
<!-- 状态0:禁用 1:正常 2:删除 -->

View File

@ -47,7 +47,7 @@
row-key="doctor_id" @selection-change="(selection) => {deleteData = selection;console.log(selection)}"
@page-change="handlePageChange" @page-size-change="handlepage_sizeChange">
<template #doctor_id="{record,rowIndex}">
<div>{{(rowIndex+1)+(pager.page-1)*10}}</div>
<div>{{(rowIndex+1)+(pager.page-1)*pager.page_size}}</div>
</template>
<template #status="{ record }">
<!-- 状态0:禁用 1:正常 2:删除 -->

View File

@ -92,7 +92,7 @@
row-key="doctor_id" @selection-change="(selection) => {deleteData = selection;console.log(selection)}"
@page-change="handlePageChange" @page-size-change="handlepage_sizeChange">
<template #doctor_id="{record,rowIndex}">
<div>{{(rowIndex+1)+(pager.page-1)*10}}</div>
<div>{{(rowIndex+1)+(pager.page-1)*pager.page_size}}</div>
</template>
<template #prescription_status="{ record }">
<span>{{formatPrescriptionStatus(record.prescription_status)}}</span>