机构场景相关 #20

Merged
longchao merged 4 commits from scence_type_2026_01_07 into master 5 days ago
  1. 1
      src/components/GuipSwitch.vue
  2. 18
      src/views/DoctorInformation.vue
  3. 475
      src/views/HosInformation.vue
  4. 6
      src/views/conflictDialog.vue

1
src/components/GuipSwitch.vue

@ -85,7 +85,6 @@ export default {
watch: {
value(newVal) {
this.internalValue = newVal
console.log(this.internalValue, 88888)
},
// modelValue(newVal) {
// this.internalValue = newVal

18
src/views/DoctorInformation.vue

@ -8,7 +8,7 @@
<el-form-item prop="avator" label="" class="special-form-item">
<template #label>
<div class="custom-label flex">
医生照片
个人照片
<img class="labelImg" src="@/assets/require.svg" alt="">
<el-tooltip content="这是提示信息">
<img class="labelImg" src="@/assets/form_qua_ic.svg" alt="">
@ -40,7 +40,7 @@
</el-form-item>
<GuipInput ref="GuipInput" column="column" :required="true" label="医生姓名" v-model="siteForm.name"
<GuipInput ref="GuipInput" column="column" :required="true" label="姓名" v-model="siteForm.name"
prop="name" placeholder="请输入" />
</div>
<div class="flex-line"></div>
@ -77,12 +77,12 @@
<GroupFormBtns @cancel="cancelClick" @confirm="submitCoincideSet" />
</div>
<div class="siteMessage flex-common" id="siteMessage2">
<p class="littleTitle mb32">审批</p>
<p class="littleTitle mb32">次预约审批</p>
<el-form :model="siteForm" :rules="siteFormrules2" ref="siteForm2">
<div class="flex-wrap">
<div class="flex-left">
<GuipRadio v-model="siteForm.first_visit_audit" class="mb12" column="column"
:options="groupOptions" label="初是否审批" required prop="first_visit_audit"
:options="groupOptions" label="初次预约是否审批" required prop="first_visit_audit"
@change="radioChange" />
<GuipInput ref="GuipInput" column="column" label="审批人电话" desc="审批人电话、微信,至少填写一项"
v-model="siteForm.approver_phone" prop="approver_phone" placeholder="请输入" />
@ -236,7 +236,7 @@ export default {
{
validator: (rule, value, callback) => {
if (!this.fileList.length && !this.siteForm.avator) {
callback(new Error('请上传医生照片'));
callback(new Error('请上传个人照片'));
} else {
callback();
}
@ -258,7 +258,7 @@ export default {
methods: {
setDoctorDesc() {
if (!this.doctorId) {
this.$message.error('请先设置医生基础信息')
this.$message.error('请先设置个人基础信息')
return;
}
@ -330,7 +330,7 @@ export default {
this.setDoctorInfo(this.siteForm)
return;
}
this.$message.error('请上传医生照片')
this.$message.error('请上传个人照片')
return;
}
@ -377,7 +377,7 @@ export default {
},
submitApproverWechat() {
if (!this.doctorId) {
this.$message.error('请先设置医生基础信息')
this.$message.error('请先设置个人基础信息')
return;
}
@ -391,7 +391,7 @@ export default {
//
submitCoincideSet() {
if (!this.doctorId) {
this.$message.error('请先设置医生基础信息')
this.$message.error('请先设置个人基础信息')
return;
}
//

475
src/views/HosInformation.vue

@ -6,7 +6,10 @@
<el-form :model="form" :rules="siteFormrules" ref="siteForm">
<div class="flex-wrap">
<div class="flex-left">
<GuipFormItem column="column" class="mb24" label="出诊医院省市" :required="true">
<GuipRadio v-model="sceneType" class="mb12" column="column"
:options="groupOptions" label="机构场景" required @change="sceneTypeChange"/>
<GuipFormItem column="column" class="mb24" :label="pageCurDescText.location" :required="true">
<div class="flex-between" slot="formDom">
<div class="short-width">
<GuipSelect width="100%" v-model="form.province" :options="options_province"
@ -21,14 +24,14 @@
</div>
</div>
</GuipFormItem>
<GuipFormItem column="column" class="mb24" label="出诊医院名称" :required="true"
<GuipFormItem column="column" class="mb24" :label="pageCurDescText.unitName" :required="true"
style="margin-bottom: 0px;">
<GuipInput slot="formDom" ref="GuipInput" column="column" v-model="form.h_realname"
:disabled="true" v-if="depart_id && doctor_id" prop="h_realname"></GuipInput>
</GuipFormItem>
<div class="mb24" style="margin-top:-24px;" v-if="!depart_id && doctor_id">
<el-autocomplete v-model="hospitalSearchState" style="width: 100%"
:fetch-suggestions="queryHospital" placeholder="请输入医院名称或地址" ref="hospitalAutocomplete"
:fetch-suggestions="queryHospital" :placeholder="'请输入'+pageCurDescText.nameKey+'名称或地址'" ref="hospitalAutocomplete"
:popper-class="((hospitalSearchFlag || hospitalRestaurants.length > 0) ? '' : ' el-autocomplete-noloading')"
@select="hospitalHandleSelect">
<template #append>
@ -37,53 +40,133 @@
</template>
</el-autocomplete>
</div>
<GuipFormItem column="column" class="mb24" label="医院简称">
<span slot="formRight" class="desc">方便患者记忆非必填</span>
<GuipFormItem column="column" class="mb24" :label="pageCurDescText.shortName">
<span slot="formRight" class="desc">方便用户记忆非必填</span>
<GuipInput slot="formDom" ref="GuipInput" column="column" v-model="form.h_shortname"
prop="h_shortname" placeholder="请输入" />
</GuipFormItem>
<GuipFormItem column="column" class="mb24" label="所在科室">
<GuipFormItem column="column" class="mb24" label="所在科室" v-if="sceneType == 0">
<GuipInput slot="formDom" ref="GuipInput" column="column" v-model="form.depart_name"
prop="depart_name" :placeholder="(depart_id && doctor_id) ? '无' : '请输入'"
:disabled="(depart_id && doctor_id) ? true : false" />
</GuipFormItem>
<GuipFormItem column="column" class="" :label="pageCurDescText.previewNotice">
<div slot="formRight" class="desc">{{pageCurDescText.previewNoticeTitle}}</div>
<GuipTextarea slot="formDom" v-model="form.notice" prop="notice" width="100%" height="84px"
autosize placeholder="输入" />
</GuipFormItem>
</div>
<div class="flex-line"></div>
<div class="flex-right">
<GuipFormItem column="column" class="mb24" v-if="departIsFixed != -1">
<div slot="formLeft" class="form-top-icon">医保定点</div>
<div class="flex" slot="formDom" style="padding: 9px 0px;">
<GuipSwitch :value="departIsFixed" @change="onSwitchChange" activeText="医保定点"
inactiveText="非医保定点" :active-value="true" :inactive-value="false">
<div slot="formLeft" class="form-top-icon">使用功能</div>
<div class="bidwrap-item bidwrap-item-pd24">
<div class="biditemMast flex-between biditemMast-nopd">
<p>个人名片基础功能不可取消</p>
<div class="flex">
<GuipSwitch :value="true" @change="onSwitchChange" activeText="已开启,不可关闭"
inactiveText="已开启,不可关闭" :active-value="true" :inactive-value="false" :disabled="true">
</GuipSwitch>
</div>
</GuipFormItem>
</div>
<GuipFormItem column="column" class="mb24" label="使用功能">
<div class="biditemMast flex-between biditemMast-nopd mt20">
<div class="flex">
<p>子功能</p>
<el-checkbox-group slot="formDom" v-model="canCheckInList"
class="checkboxGroup checkboxGroup2" :disabled="(previewIsOpen || onLinePay)? true : false">
<div class="flex">
<el-checkbox :label="1">是否允许报到</el-checkbox>
</div>
</el-checkbox-group>
</div>
</div>
</div>
<div class="bidwrap-item bidwrap-item-pd24">
<div class="biditemMast flex-between biditemMast-nopd">
<p>用户预约</p>
<div class="flex">
<GuipSwitch :value="previewIsOpen" @change="onPreviewSwitchChange" activeText="已开启"
inactiveText="已关闭" :active-value="true" :inactive-value="false">
</GuipSwitch>
</div>
</div>
<div class="biditemMast flex-between biditemMast-nopd mt20">
<div class="flex">
<p>子功能</p>
<el-checkbox-group slot="formDom" v-model="previewFunctions"
class="checkboxGroup checkboxGroup2" :disabled="previewIsOpen?false:true">
<div class="flex">
<el-checkbox :label="1">初诊审批</el-checkbox>
<el-checkbox :label="2">挂号收费</el-checkbox>
</div>
</el-checkbox-group>
</div>
</div>
</div>
<div class="bidwrap-item bidwrap-item-pd24">
<div class="biditemMast flex-between biditemMast-nopd">
<p>项目收费</p>
<div class="flex">
<GuipSwitch :value="onLinePay" @change="onLineChange" activeText="已开启"
inactiveText="已关闭" :active-value="true" :inactive-value="false">
</GuipSwitch>
</div>
</div>
<div class="biditemMast flex-between biditemMast-nopd mt20">
<div class="flex">
<p>子功能</p>
<el-checkbox-group slot="formDom" v-model="showProjectPrice"
class="checkboxGroup checkboxGroup2">
<div class="flex">
<el-checkbox :label="1">是否显示项目价格</el-checkbox>
</div>
</el-checkbox-group>
</div>
</div>
</div>
<div class="bidwrap-item bidwrap-item-pd24" v-if="departIsFixed != -1 && sceneType != 1 && departType != 2">
<div class="biditemMast flex-between biditemMast-nopd">
<p>医保定点</p>
<div class="flex">
<GuipSwitch :value="departIsFixed" @change="onSwitchChange" activeText="已开启"
inactiveText="已关闭" :active-value="true" :inactive-value="false">
</GuipSwitch>
</div>
</div>
</div>
<!-- <GuipFormItem column="column" class="mb24" label="使用功能">
<el-checkbox-group slot="formDom" v-model="departType" @change="validateSelection"
class="checkboxGroup">
<div class="flex">
<el-checkbox :label="0">患者预约</el-checkbox>
<el-checkbox :label="0">用户预约</el-checkbox>
<el-checkbox :label="1">仅项目计数</el-checkbox>
</div>
<el-checkbox :label="2">仅医生名片</el-checkbox>
</div>
</el-checkbox-group>
</GuipFormItem>
</GuipFormItem> -->
<GuipFormItem column="column" class="mb24" v-if="departType.length > 0 && departType[0] == 1">
<!-- <GuipFormItem column="column" class="mb24" v-if="departType.length > 0 && departType[0] == 1">
<div slot="formLeft" class="form-top-icon">预约开关</div>
<div class="flex" slot="formDom" style="padding: 9px 0px;">
<GuipSwitch :value="previewIsOpen" @change="onPreviewSwitchChange" activeText="开启预约"
inactiveText="关闭预约" :active-value="true" :inactive-value="false">
</GuipSwitch>
</div>
</GuipFormItem>
</GuipFormItem> -->
<GuipFormItem column="column" class="" label="就诊提醒">
<div slot="formRight" class="desc">就诊前的注意事项非必填</div>
<GuipTextarea slot="formDom" v-model="form.notice" prop="notice" width="100%" height="84px"
autosize placeholder="输入" />
</GuipFormItem>
</div>
</div>
</el-form>
@ -117,31 +200,31 @@
<GroupFormBtns @cancel="cancelClick" @confirm="submitForm('siteForm1')" />
</div>
<div class="siteMessage flex-common mt12" id="siteMessage3">
<p class="littleTitle mb32">放号设置</p>
<p class="littleTitle mb32">{{pageCurDescText.preview.text1}}</p>
<el-form :model="form" :rules="numSettingFormRule" ref="numSettingForm">
<div class="flex-wrap">
<div class="flex-left">
<GuipFormItem column="column" class="mb24" label="号源单位时段" :required="true">
<GuipFormItem column="column" class="mb24" :label="pageCurDescText.preview.text2" :required="true">
<span class="desc" slot="formRight">如30分钟放号时9:00-9:309:30-10:00来划分</span>
<GuipInput slot="formDom" ref="GuipInput" column="column" v-model="form.time_unit"
prop="time_unit" placeholder="请输入" unit="分钟/时段" />
</GuipFormItem>
<GuipFormItem column="column" class="mb24" label="放号量" :required="true">
<span class="desc" slot="formRight">放号量可少于实际数量以便为现场约号患者预留</span>
<GuipFormItem column="column" class="mb24" :label="pageCurDescText.preview.text4" :required="true">
<span class="desc" slot="formRight">放号量可少于实际数量以便为现场约号用户预留</span>
<GuipInput slot="formDom" ref="GuipInput" column="column" v-model="form.time_unit_num"
prop="time_unit_num" placeholder="请输入" unit="个号/时段" />
</GuipFormItem>
</div>
<div class="flex-line"></div>
<div class="flex-right">
<GuipFormItem column="column" class="mb24" label="开放预约" :required="true">
<span class="desc" slot="formRight">患者可提前多久约号</span>
<GuipFormItem column="column" class="mb24" :label="pageCurDescText.preview.text2" :required="true">
<span class="desc" slot="formRight">用户可提前多久约号</span>
<GuipInput slot="formDom" ref="GuipInput" column="column" v-model="form.visit_day"
prop="visit_day" placeholder="请输入" unit="天">
<span slot="prependshow">提前</span>
</GuipInput>
</GuipFormItem>
<GuipFormItem column="column" class="mb24" label="超时未就诊提醒">
<GuipFormItem column="column" class="mb24" :label="pageCurDescText.preview.text5">
<span class="desc" slot="formRight">不输入即无期限</span>
<GuipInput slot="formDom" ref="GuipInput" column="column" v-model="form.treat_expire"
prop="treat_expire" placeholder="请输入" unit="天" />
@ -151,14 +234,14 @@
</el-form>
<GroupFormBtns @cancel="cancelClick" @confirm="submitForm('numSettingForm')" />
</div>
<div class="siteMessage flex-common mt12" id="siteMessage6">
<div class="siteMessage flex-common mt12" id="siteMessage6" v-if="hasVisitFee || onLinePay">
<el-form>
<div class="mb32 flex gap12">
<span class="littleTitle">线上收款</span>
<GuipSwitch :value="onLinePay" ref="hasOnlinePayRef" :active-value="1" :inactive-value="0"
<!-- <GuipSwitch :value="onLinePay" ref="hasOnlinePayRef" :active-value="1" :inactive-value="0"
:disabled="!wxpayList.length" @change="onLineChange"></GuipSwitch>
<span v-if="!onLinePay" class="tipInfo">未绑定微信收款方式无法开启线上收款</span>
<span v-if="!onLinePay == 1"> {{ onLinePay == 1 ? '开启' : '' }}</span>
<span v-if="!onLinePay == 1"> {{ onLinePay == 1 ? '开启' : '' }}</span> -->
</div>
<div class="flex-wrap">
<div class="flex-left">
@ -215,7 +298,7 @@
alt=""><span>支付宝收款</span>
</div>
<div slot="formRight" class="desc">
绑定后患者支付宝扫码付款可享自动退费
绑定后用户支付宝扫码付款可享自动退费
</div>
<CustomDropdown slot="formDom" width="100%" :options="alipayList"
:options_null="!alipayList.length" @change="changeSelectAlipay">
@ -257,13 +340,13 @@
</div>
</el-form>
</div>
<div class="siteMessage flex-common mt12" id="siteMessage7">
<div class="siteMessage flex-common mt12" id="siteMessage7" v-if="hasVisitFee">
<el-form>
<div class="mb32 flex gap12">
<span class="littleTitle">收挂号费</span>
<GuipSwitch :value="hasVisitFee" ref="hasVisitFeeRef" :active-value="1" :inactive-value="0"
@change="onVisitFeeChange"></GuipSwitch>
<span class="desc">患者在小程序预约时{{ hasVisitFee == 1 ? '' : '不' }}需缴纳挂号费</span>
<!-- <GuipSwitch :value="hasVisitFee" ref="hasVisitFeeRef" :active-value="1" :inactive-value="0"
@change="onVisitFeeChange"></GuipSwitch> -->
<span class="desc">用户在小程序预约时{{ hasVisitFee == 1 ? '' : '不' }}需缴纳挂号费</span>
</div>
<div class="bidwrap-item">
<div class="biditemMast mb12 flex-between">
@ -284,12 +367,13 @@
@click="showDialog('register')">立即设置</GuipButton>
</div>
</div>
<div class="biditemMast mb12 flex-between">
<div class="bidwrap-item-top flex">
<div class="top-right column">
<p>免挂号费规则</p>
<p class="desc" v-if="againVisitFreeDays && hasAgainVisitFreeDays">
患者{{ againVisitFreeDays }}天内再次就诊患者有剩余治疗项目免收挂号费</p>
用户{{ againVisitFreeDays }}天内再次就诊用户有剩余治疗项目免收挂号费</p>
</div>
</div>
<div class="flex" v-if="hasFreeRegisterRule">
@ -303,15 +387,58 @@
@click="showDialog('registerRule')">立即设置</GuipButton>
</div>
</div>
<div class="biditemMast flex-between">
<div class="bidwrap-item-top flex">
<div class="top-right column">
<p>赊欠挂号/预约费</p>
<p class="desc">
开启后财务可给用户赊欠挂号/预约费</p>
</div>
</div>
<div class="flex">
<GuipSwitch :value="canCreditVisitFee" @change="onCreditVisitFee" activeText="已开启"
inactiveText="已关闭" :active-value="true" :inactive-value="false">
</GuipSwitch>
</div>
</div>
</div>
</el-form>
</div>
<div class="siteMessage flex-common mt12" id="siteMessage28" v-if="onLinePay">
<el-form>
<div class="mb32 flex gap12">
<span class="littleTitle">收项目费</span>
</div>
<div class="bidwrap-item">
<div class="biditemMast flex-between">
<div class="bidwrap-item-top flex">
<div class="top-right column">
<p>赊欠项目费</p>
<p class="desc">
开启后财务可给用户赊欠项目费</p>
</div>
</div>
<div class="flex">
<GuipSwitch :value="canCreditPreviewFee" @change="onCreditPreviewFee" activeText="已开启"
inactiveText="已关闭" :active-value="true" :inactive-value="false">
</GuipSwitch>
</div>
</div>
</div>
</el-form>
</div>
<div class="siteMessage flex-common mt12" id="siteMessage8">
<div class="littleTitle mb12">出诊设置</div>
<div class="littleTitle mb12">{{pageCurDescText.worktime.text1}}</div>
<el-form :model="houseCallSettingForm">
<GuipFormItem column="column" class="mb24">
<div slot="formLeft" class="form-top-icon">向患者展示</div>
<div slot="formLeft" class="form-top-icon">用户展示</div>
<div class="flex" slot="formDom" style="padding: 9px 0px;">
<el-radio v-model="houseCallSettingForm.display_work_days" class="display_work_days" :label="1">
<div class="flex">自动展示
@ -322,11 +449,11 @@
</div>
</GuipFormItem>
<GuipFormItem column="column" class="mb24">
<div slot="formLeft" class="form-top-icon">每周出诊安排</div>
<div slot="formLeft" class="form-top-icon">{{pageCurDescText.worktime.text2}}</div>
<div class="flex" slot="formDom" style="padding: 9px 0px;">
<el-radio-group v-model="houseCallSettingForm.worktime_no_fixed">
<el-radio :label="0">每周出诊安排固定</el-radio>
<el-radio :label="1">每周出诊安排不固定</el-radio>
<el-radio :label="0">{{pageCurDescText.worktime.text3}}</el-radio>
<el-radio :label="1">{{pageCurDescText.worktime.text4}}</el-radio>
</el-radio-group>
</div>
</GuipFormItem>
@ -346,14 +473,14 @@
</div>
<div class="siteMessage flex-common mt12" id="siteMessage9">
<div class="littleTitle mb12">出诊日历预览</div>
<PromptText text='不同色块代表不同的医院,点击日期,可临时调整当天出诊时间。' :type="1" class="mb24" />
<div class="littleTitle mb12">{{pageCurDescText.calendar.text1}}</div>
<PromptText :text='"不同色块代表不同的"+pageCurDescText.nameKey+",点击日期,可临时调整当天出诊时间。"' :type="1" class="mb24" />
<div class="custom-calendar-header">
<div class="header-left">
<span class="month-text">{{ formatMonth(currentDay) }}</span>
<span v-if="isCurrentMonth(currentDay)" class="current-month-badge">本月</span>
<span class="header-tip" v-if="conflictCount > 0 && !is_allow_coincide">本月有 {{ conflictCount }}
天出诊医院重合请检查</span>
天出诊{{pageCurDescText.nameKey}}重合请检查</span>
</div>
<div class="header-right">
<el-button-group>
@ -696,14 +823,14 @@
<el-form class="freeWrap">
<div class="flex gap8 mb24 mt24">
<el-checkbox v-model="hasAgainVisitFreeDays" :true-label="1" :false-label="0"></el-checkbox>
患者
用户
<GuipInput v-model="againVisitFreeDays" type="number" width="92px" placeholder="请输入">
</GuipInput>
天内再次就诊免挂号费
</div>
<p class="flex gap8">
<el-checkbox v-model="hasRemainVisitFree" :true-label="1" :false-label="0"></el-checkbox>
患者有剩余治疗项目免挂号费
用户有剩余治疗项目免挂号费
</p>
</el-form>
</GuipDialog>
@ -748,6 +875,8 @@ import GuipTable from '@/components/GuipTable.vue';
import GuipDialog from '@/components/GuipDialog.vue';
import CustomDropdown from '@/components/CustomDropdown.vue';
import SetAliPay from '@/components/SetAliPay.vue';
import GuipRadio from '@/components/GuipRadio.vue';
import { mapState } from 'vuex';
import { Object } from 'core-js';
import ConflictDialog from './conflictDialog.vue';
@ -772,7 +901,8 @@ export default {
GroupFormBtns,
SetAliPay,
PromptText,
ConflictDialog
ConflictDialog,
GuipRadio
},
data() {
return {
@ -1019,6 +1149,68 @@ export default {
originalAfternoonSelected: [], //
forceTime: Date.now(),
singleCurrentPlan:null,
sceneType:-1,
groupOptions: [
{ label: '医疗机构:如医院、诊所', value: 0 },
{ label: '养生机构:如养生馆、理疗馆', value: 1 },
],
previewFunctions:[],
firstVisitAudit:0,
canCheckInList:[],
showProjectPrice:[],
pageDescTexts:[
{
location: '出诊医院省市',
unitName:'出诊医院名称',
nameKey:'医院',
shortName:'医院简称',
previewNotice:'就诊提醒',
previewNoticeTitle:'就诊前的注意事项,非必填',
preview:{
text1:'放号设置',
text2:'号源单位时段',
text3:'开放预约',
text4:'放号量',
text5:'超时未就诊提醒',
},
worktime:{
text1:'出诊设置',
text2:'每周出诊安排',
text3:'每周出诊安排固定',
text4:'每周出诊安排不固定',
},
calendar:{
text1:'出诊日历预览',
}
},
{
location: '机构所在省市',
nameKey:'机构',
unitName: '机构名称',
shortName:'机构简称',
previewNotice:'预约提醒',
previewNoticeTitle:'用户预约后的注意事项提醒,非必填',
preview:{
text1:'预约设置',
text2:'预约单位时段',
text3:'可提前预约天数',
text4:'每时段可接待人数',
text5:'服务延期提醒',
},
worktime:{
text1:'排班设置',
text2:'每周排班安排',
text3:'每周排班固定',
text4:'每周排班不固定',
},
calendar:{
text1:'排班日历预览',
}
},
],
pageCurDescText:false,
canCreditVisitFee:false,
canCreditPreviewFee:false
}
},
created() {
@ -1031,6 +1223,11 @@ export default {
const { depart_id, doctor_id } = this.$route.query; // doctorId
if (doctor_id) this.doctor_id = doctor_id;
if(!depart_id) {
this.sceneType = 0
this.sceneTypeChange(this.sceneType)
}
if (doctor_id && depart_id) {
//
this.depart_id = depart_id;
@ -1150,7 +1347,44 @@ export default {
...mapState(['hosMenuData']) // VuexshowSidebar
},
methods: {
async onCreditPreviewFee(e) {
try {
const response = await this.$http('POST', '/api/admin/set_credit_preview_fee', {
doctor_id: this.doctor_id,
depart_id: this.depart_id,
can_credit_preview_fee: e?1:0,
});
if (response.code === 0) {
this.$message.success('设置成功');
} else {
this.$message.error(response.msg || '保存失败');
}
} catch (error) {
this.$message.error('设置失败');
}
},
async onCreditVisitFee(e) {
try {
const response = await this.$http('POST', '/api/admin/set_credit_visit_fee', {
doctor_id: this.doctor_id,
depart_id: this.depart_id,
can_credit_visit_fee: e?1:0,
});
if (response.code === 0) {
this.$message.success('设置成功');
} else {
this.$message.error(response.msg || '保存失败');
}
} catch (error) {
this.$message.error('设置失败');
}
},
sceneTypeChange(e) {
this.pageCurDescText = this.pageDescTexts[e]
},
// -
handleVisitCancel() {
this.handleVisitClose()
@ -1158,7 +1392,6 @@ export default {
// -
handleVisitClose() {
this.visitDialogVisible = false;
},
isMorningCheckboxVisible(hospitalId) {
if (this.is_allow_coincide) return true;
@ -2454,24 +2687,24 @@ export default {
},
async onLineChange(e) {
this.onLinePay = e;
await this.$http('POST', '/api/admin/set_pay_switch', {
doctor_id: this.doctor_id,
depart_id: this.depart_id,
pay_switch: this.onLinePay
}).then(response => {
const { code } = response
const msg = this.onLinePay === 1 ? '已开启' : '已关闭'
const type = code === 0 ? 'success' : 'error';
this.$positionMessage({
type: type,
message: msg + '线上收款',
target: this.$refs['hasOnlinePayRef'],
position: 'top'
})
}).catch(error => {
this.onLinePay = 0;
console.error(error, 'error')
})
// await this.$http('POST', '/api/admin/set_pay_switch', {
// doctor_id: this.doctor_id,
// depart_id: this.depart_id,
// pay_switch: this.onLinePay
// }).then(response => {
// const { code } = response
// const msg = this.onLinePay === 1 ? '' : ''
// const type = code === 0 ? 'success' : 'error';
// this.$positionMessage({
// type: type,
// message: msg + '线',
// target: this.$refs['hasOnlinePayRef'],
// position: 'top'
// })
// }).catch(error => {
// this.onLinePay = 0;
// console.error(error, 'error')
// })
},
async onVisitFeeChange(e) {
this.hasVisitFee = e
@ -2705,15 +2938,37 @@ export default {
this.departType = (response.data.type || response.data.type === 0 || response.data.type === "0") ? [Number(response.data.type)] : []
this.departIsFixed = response.data.is_fixed == "1" ? true : false
this.previewIsOpen = response.data.preview_is_open == "1" ? true : false
this.onLinePay = response.data.pay_switch
this.onLinePay = response.data.pay_switch == "1" ? true : false
this.canCreditVisitFee = response.data.can_credit_visit_fee == "1"? true : false
this.canCreditPreviewFee = response.data.can_credit_preview_fee == "1"? true : false
this.hasVisitFee = response.data.has_visit_fee
this.registerMoney = response.data.visit_price
this.sceneType = response.data.scene_type
this.firstVisitAudit = response.data.first_visit_audit
this.pageCurDescText = this.pageDescTexts[this.sceneType]
this.hasAgainVisitFreeDays = response.data.has_again_visit_free_days
this.againVisitFreeDays = response.data.again_visit_free_days
this.hasRemainVisitFree = response.data.has_remain_visit_free
if ((this.hasAgainVisitFreeDays && this.againVisitFreeDays) || this.hasRemainVisitFree) this.hasFreeRegisterRule = true
this.previewFunctions = [];
if(this.firstVisitAudit) this.previewFunctions.push(1)
if(this.hasVisitFee) this.previewFunctions.push(2)
if(response.data.type == 2) {
this.canCheckInList = []
}else{
this.canCheckInList = [1]
}
if(response.data.show_project_price) {
this.showProjectPrice = [1]
}else{
this.showProjectPrice = []
}
this.getAreaData(this.form.province)
}).catch(error => {
console.error(error, 'error')
@ -2779,6 +3034,19 @@ export default {
this.departType = []
if (val.length > 0) this.departType[0] = val[val.length - 1]
},
setPreviewFunction(val) {
console.log(val)
// var previewFunctions = this.previewFunctions
// var pos = previewFunctions.indexOf(val)
// if(pos > -1){
// previewFunctions.splice(pos, 1)
// }else{
// previewFunctions.push(val)
// }
// this.previewFunctions = previewFunctions
},
selectTag(item) {
if (item == 'all') {
this.projectSearchId = 'all';
@ -2910,6 +3178,7 @@ export default {
onPreviewSwitchChange(data) {
this.form.preview_is_open = data ? 1 : 0
this.previewIsOpen = data
if(!this.previewIsOpen) this.previewFunctions = []
},
onSwitchChange2(row) {
var tmpstatus = row.status == 1 ? 0 : 1
@ -3063,14 +3332,20 @@ export default {
}).then(response => {
if (response.code == 0) {
this.$Message.success('更新成功')
if (this.doctor_id && !this.depart_id) {
var that = this
if (this.doctor_id && !this.depart_id) {
setTimeout(() => {
that.$router.push({
name: '医院信息',
query: { doctor_id: this.doctor_id, depart_id: response.data.depart_id }
})
}, 1000)
}else{
if(url == '/api/admin/set_hospital_depart') {
setTimeout(() => {
location.reload()
}, 1000)
}
}
return;
}
@ -3101,6 +3376,7 @@ export default {
}
}
this.departType[0] = 0;
if (this.departType.length <= 0) {
this.$Message.info('请选择使用功能')
return;
@ -3111,7 +3387,20 @@ export default {
type: this.departType[0],
notice: this.form.notice,
h_shortname: this.form.h_shortname,
preview_is_open: this.previewIsOpen ? 1 : 0
preview_is_open: this.previewIsOpen ? 1 : 0,
scene_type: this.sceneType,
pay_switch: this.onLinePay ? 1 : 0,
}
if(this.previewFunctions.indexOf(1)>-1) props.first_visit_audit = 1
if(this.previewFunctions.indexOf(2)>-1) props.has_visit_fee = 1
props.can_check_in = 0
if(this.canCheckInList.length > 0) props.can_check_in = 1
if(this.showProjectPrice.length > 0) {
props.show_project_price = 1
}else{
props.show_project_price = 0
}
if (this.doctor_id && !this.depart_id) {
@ -3120,7 +3409,26 @@ export default {
return;
}
props = this.form
props = this.form;
props.is_fixed = this.form.is_fixed;
props.type = this.departType[0];
props.notice = this.form.notice;
props.h_shortname = this.form.h_shortname;
props.preview_is_open = this.previewIsOpen ? 1 : 0;
props.scene_type = this.sceneType;
props.pay_switch = this.onLinePay ? 1 : 0;
if(this.previewFunctions.indexOf(1)>-1) props.first_visit_audit = 1
if(this.previewFunctions.indexOf(2)>-1) props.has_visit_fee = 1
props.can_check_in = 0
if(this.canCheckInList.length > 0) props.can_check_in = 1
if(this.showProjectPrice.length > 0) {
props.show_project_price = 1
}else{
props.show_project_price = 0
}
props.type = this.departType[0]
}
rqurl = "/api/admin/set_hospital_depart";
@ -3609,6 +3917,10 @@ export default {
padding: 24px 14px;
box-sizing: border-box;
background: #FAFAFA;
&.bidwrap-item-pd24{
padding: 24px;
margin-top:10px;
}
.biditemMast {
background: #fff;
@ -3616,6 +3928,14 @@ export default {
border-radius: 8px;
background: #FFFFFF;
align-items: flex-start;
&.biditemMast-nopd{
background: #FAFAFA;
padding: 0;
border-radius: 4px;
p{
color: #1E2226;
}
}
.bidwrap-item-top {
.top-right {
@ -3767,6 +4087,11 @@ export default {
gap: 24px;
height: 72px;
padding: 10px 0;
&.checkboxGroup2{
padding: 0;
height: unset;
gap: 10px;
}
}
.addStore {
@ -3826,4 +4151,8 @@ export default {
justify-content: flex-start;
}
}
.mt20{
margin-top: 10px;
}
</style>

6
src/views/conflictDialog.vue

@ -278,10 +278,7 @@ export default {
worktime_no_fixed: worktime_no_fixed,
week_visit_plan: JSON.stringify(this.formatWorktimesArray(worktimes))
}
if (display_work_days == 1 && planDays > 0) {
params.display_work_days = planDays
}
if (display_work_days == 1 && planDays > 0) params.display_work_days = planDays
// vs
const conflictResults = this.checkScheduleConflict(worktimes, worktime_no_fixed);
@ -300,6 +297,7 @@ export default {
}
return;
}
this.saveWorkTimeDirect()
},
async saveWorkTimeDirect() {
const { display_work_days, planDays, worktime_no_fixed, worktimes } = this.houseCallSettingForm;

Loading…
Cancel
Save