@ -18,23 +18,17 @@
< div class = "qqCode-wrap right" >
< div class = "qqCode-wrap right" >
< div class = "avator-wrapper flex" >
< div class = "avator-wrapper flex" >
< img v-if ="doctorAvatorUrl" :src="doctorAvatorUrl" alt="" class="uploadImg" >
< img v-if ="doctorAvatorUrl" :src="doctorAvatorUrl" alt="" class="uploadImg" >
< hover -button :button-text ="doctorAvatorUrl?'重新上传':'开始上传'" :default-icon ="require('../assets/upLoad_grey.svg')"
< hover -button : button -text = " doctorAvatorUrl ? ' 重新上传 ' : ' 开始上传 ' "
: hover - icon = "require('../assets/upLoad_active.svg')"
: default - icon = "require('../assets/upLoad_grey.svg')"
default - text - color = "#23242B" hover - text - color = "#006AFF" >
: hover - icon = "require('../assets/upLoad_active.svg')"
default - text - color = "#23242B" hover - text - color = "#006AFF" >
< / h o v e r - b u t t o n >
< / h o v e r - b u t t o n >
< div class = "info-upload-wrapper" @click ="clearDocotorAvatorFiles" >
< div class = "info-upload-wrapper" @click ="clearDocotorAvatorFiles" >
< el -upload
< el -upload :on-change ="handleAvatarChange" action = "#" list -type = " picture -card "
: on - change = "handleAvatarChange"
: multiple = "false" : http - request = "setDoctorBaseInfoUpload" : limit = "Number(1)"
action = "#"
ref = "avatorUpload" : auto - upload = "false" >
list - type = "picture-card"
< i slot = "default" class = "el-icon-plus" > < / i >
: multiple = "false"
: http - request = "setDoctorBaseInfoUpload"
: limit = "Number(1)"
ref = "avatorUpload"
: auto - upload = "false"
>
< i slot = "default" class = "el-icon-plus" > < / i >
< / e l - u p l o a d >
< / e l - u p l o a d >
< / div >
< / div >
< / div >
< / div >
@ -46,8 +40,8 @@
< / e l - f o r m - i t e m >
< / e l - f o r m - i t e m >
< GuipInput ref = "GuipInput" column = "column" :required ="true" label = "医生姓名"
< GuipInput ref = "GuipInput" column = "column" :required ="true" label = "医生姓名" v -model = " siteForm.name "
v - model = "siteForm.name" prop = "name" placeholder = "请输入" / >
prop = "name" placeholder = "请输入" / >
< / div >
< / div >
< div class = "flex-line" > < / div >
< div class = "flex-line" > < / div >
< div class = "flex-right" >
< div class = "flex-right" >
@ -62,6 +56,27 @@
< / div >
< / div >
< div class = "siteMessage flex-common" id = "siteMessage2" >
< div class = "siteMessage flex-common" id = "siteMessage2" >
< p class = "littleTitle mb32" > 出诊设置 < / p >
< el -form :model ="siteForm" :rules ="siteFormrules3" ref = "siteForm3" >
< div class = "flex-wrap" >
< div class = "flex-left" >
< p class = "coincideTip mb12" > 您有多个出诊医院时 , 允许不同医院排班时段重合吗 ? < / p >
< div class = "flex" >
< div class = "coincideWrap" >
< el -radio v-model ="siteForm.is_allow_coincide" :label ="1" > 允许时段重合 < / el -radio >
< p > 适用于 : 可由助理代为坐诊 < / p >
< / div >
< div class = "coincideWrap" >
< el -radio v-model ="siteForm.is_allow_coincide" :label ="0" > 禁止时段重合 < / el -radio >
< p > 适用于 : 可由助理代为坐诊 < / p >
< / div >
< / div >
< / div >
< / div >
< / e l - f o r m >
< 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" >
< el -form :model ="siteForm" :rules ="siteFormrules2" ref = "siteForm2" >
< div class = "flex-wrap" >
< div class = "flex-wrap" >
@ -69,7 +84,7 @@
< GuipRadio v -model = " siteForm.first_visit_audit " class = "mb12" column = "column"
< 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" / >
@ change = "radioChange" / >
< GuipInput ref = "GuipInput" column = "column" label = "审批人电话" desc = "审批人电话、微信,至少填写一项"
< GuipInput ref = "GuipInput" column = "column" label = "审批人电话" desc = "审批人电话、微信,至少填写一项"
v - model = "siteForm.approver_phone" prop = "approver_phone" placeholder = "请输入" / >
v - model = "siteForm.approver_phone" prop = "approver_phone" placeholder = "请输入" / >
< / div >
< / div >
< div class = "flex-line" > < / div >
< div class = "flex-line" > < / div >
@ -80,27 +95,24 @@
< div class = "avator-wrapper" >
< div class = "avator-wrapper" >
< div class = "flex" style = "position: relative;" >
< div class = "flex" style = "position: relative;" >
< img v-if ="approverWechatUrl" :src="approverWechatUrl" class="uploadImg" >
< img v-if ="approverWechatUrl" :src="approverWechatUrl" class="uploadImg" >
< hover -button : button -text = " ( approverWechatUrl ? ' 重新上传 ' : ' 微信二维码 ' ) " :default-icon ="require('../assets/upLoad_grey.svg')"
< hover -button : button -text = " ( approverWechatUrl ? ' 重新上传 ' : ' 微信二维码 ' ) "
: hover - icon = "require('../assets/upLoad_active.svg')"
: default - icon = "require('../assets/upLoad_grey.svg')"
default - text - color = "#23242B" hover - text - color = "#006AFF" / >
: hover - icon = "require('../assets/upLoad_active.svg')"
default - text - color = "#23242B" hover - text - color = "#006AFF" / >
< div class = "info-upload-wrapper" @click ="clearApproverWechatFiles" style = "width: 177px;left: 0;display: flex;justify-content: flex-start;overflow: hidden;" >
< el -upload
< div class = "info-upload-wrapper" @click ="clearApproverWechatFiles"
: on - change = "handleApproverWechatChange"
style = "width: 177px;left: 0;display: flex;justify-content: flex-start;overflow: hidden;" >
action = "#"
< el -upload :on-change ="handleApproverWechatChange" action = "#"
list - type = "picture-card"
list - type = "picture-card" : multiple = "false"
: multiple = "false"
: http - request = "setApproverWechatUpload" : limit = "Number(1)"
: http - request = "setApproverWechatUpload"
ref = "approverWechatUpload" : auto - upload = "false" >
: limit = "Number(1)"
ref = "approverWechatUpload"
: auto - upload = "false"
>
< i slot = "default" class = "el-icon-plus" > < / i >
< i slot = "default" class = "el-icon-plus" > < / i >
< / e l - u p l o a d >
< / e l - u p l o a d >
< / div >
< / div >
< / div >
< / div >
< div slot = "tip" class = "el-upload__tip desc" style = "margin-top:8px;" > 批人微信二维码 , 大小2M以内 < / div >
< div slot = "tip" class = "el-upload__tip desc" style = "margin-top:8px;" > 批人微信二维码 , 大小2M以内
< / div >
< / div >
< / div >
< / div >
< / div >
< / GuipFormItem >
< / GuipFormItem >
@ -121,8 +133,8 @@
< / div >
< / div >
< div class = "flex-line" > < / div >
< div class = "flex-line" > < / div >
< div class = "flex-right" >
< div class = "flex-right" >
< GuipInput ref = "GuipInput" column = "column" label = "个人标签"
< GuipInput ref = "GuipInput" column = "column" label = "个人标签" v -model = " siteForm.label " prop = "name"
v - model = "siteForm.label" prop = "name" placeholder = "请输入" / >
placeholder = "请输入" / >
< / div >
< / div >
< / div >
< / div >
< / e l - f o r m >
< / e l - f o r m >
@ -156,11 +168,11 @@ export default {
fileList : [
fileList : [
/ / { n a m e : ' i m a g e . j p e g ' , u r l : ' h t t p : / / j a s o n y i z h e r e n x i n . c h e c k c o p y . c o m / u s e r _ a v a t a r / 1 . p n g ? v = 9 3 9 4 0 d f 0 b 5 9 6 9 6 1 c 4 2 d e 2 3 e f 1 f 2 d 3 2 5 7 ' }
/ / { n a m e : ' i m a g e . j p e g ' , u r l : ' h t t p : / / j a s o n y i z h e r e n x i n . c h e c k c o p y . c o m / u s e r _ a v a t a r / 1 . p n g ? v = 9 3 9 4 0 d f 0 b 5 9 6 9 6 1 c 4 2 d e 2 3 e f 1 f 2 d 3 2 5 7 ' }
] ,
] ,
fileList1 : [ ] ,
fileList1 : [ ] ,
doctorAvatoFile : [ ] ,
doctorAvatoFile : [ ] ,
doctorAvatorUrl : '' ,
doctorAvatorUrl : '' ,
approverWechatUrl : '' ,
approverWechatUrl : '' ,
approverWechatFile : [ ] ,
approverWechatFile : [ ] ,
options_payword : [ ] ,
options_payword : [ ] ,
groupOptions : [
groupOptions : [
{ label : '需审批' , value : '1' } ,
{ label : '需审批' , value : '1' } ,
@ -168,7 +180,7 @@ export default {
] ,
] ,
formData : null ,
formData : null ,
siteForm : {
siteForm : {
did : 0 ,
did : 0 ,
name : '' ,
name : '' ,
idcard : ' ' ,
idcard : ' ' ,
phone : '' ,
phone : '' ,
@ -176,9 +188,10 @@ export default {
doctor_desc : '' ,
doctor_desc : '' ,
doctor_detail : '' ,
doctor_detail : '' ,
label : '' ,
label : '' ,
approver_phone : '' ,
approver_phone : '' ,
approver_wechat : '' ,
approver_wechat : '' ,
first_visit_audit : '' ,
first_visit_audit : '' ,
is_allow_coincide : '' / / 是 否 允 许 重 合
} ,
} ,
oldForm : { } ,
oldForm : { } ,
siteFormrules2 : {
siteFormrules2 : {
@ -186,6 +199,11 @@ export default {
{ required : true , message : '请选择初诊审批设置' , trigger : 'change' }
{ required : true , message : '请选择初诊审批设置' , trigger : 'change' }
]
]
} ,
} ,
siteFormrules3 : {
coincide : [
{ required : true , message : '请选择出诊设置' , trigger : 'change' }
]
} ,
siteFormrules : {
siteFormrules : {
name : [
name : [
{ required : true , message : '请输入姓名' , trigger : 'blur' }
{ required : true , message : '请输入姓名' , trigger : 'blur' }
@ -231,7 +249,7 @@ export default {
} ,
} ,
methods : {
methods : {
setDoctorDesc ( ) {
setDoctorDesc ( ) {
if ( ! this . doctorId ) {
if ( ! this . doctorId ) {
this . $message . error ( '请先设置医生基础信息' )
this . $message . error ( '请先设置医生基础信息' )
return ;
return ;
}
}
@ -253,7 +271,7 @@ export default {
} )
} )
} ,
} ,
getDoctorData ( doctor_id ) {
getDoctorData ( doctor_id ) {
this . $http ( 'POST' , '/api/admin/get_doctor_baseinfo' , { did : doctor_id } ) . then ( response => {
this . $http ( 'POST' , '/api/admin/get_doctor_baseinfo' , { did : doctor_id } ) . then ( response => {
if ( response . code != 0 ) {
if ( response . code != 0 ) {
this . $message . error ( response . msg )
this . $message . error ( response . msg )
return ;
return ;
@ -277,9 +295,9 @@ export default {
this . $message . success ( response . msg )
this . $message . success ( response . msg )
var data = response . data
var data = response . data
if ( this . doctorId ) return ;
if ( this . doctorId ) return ;
setTimeout ( ( ) => {
setTimeout ( ( ) => {
location . href = location . href + '?doctor_id=' + data . doctor_id
location . href = location . href + '?doctor_id=' + data . doctor_id
} , 800 ) ;
} , 800 ) ;
} ) . catch ( error => {
} ) . catch ( error => {
console . error ( error , 'error' )
console . error ( error , 'error' )
@ -299,8 +317,8 @@ export default {
this . setDoctorInfo ( fd )
this . setDoctorInfo ( fd )
} ,
} ,
submitDoctorBaseInfo ( ) {
submitDoctorBaseInfo ( ) {
if ( this . doctorAvatoFile . length == 0 ) {
if ( this . doctorAvatoFile . length == 0 ) {
if ( this . doctorId ) {
if ( this . doctorId ) {
this . setDoctorInfo ( this . siteForm )
this . setDoctorInfo ( this . siteForm )
return ;
return ;
}
}
@ -310,12 +328,12 @@ export default {
this . $refs . avatorUpload . submit ( ) ;
this . $refs . avatorUpload . submit ( ) ;
} ,
} ,
clearDocotorAvatorFiles ( ) {
clearDocotorAvatorFiles ( ) {
this . doctorAvatorUrl = '' ;
this . doctorAvatorUrl = '' ;
this . doctorAvatoFile = [ ]
this . doctorAvatoFile = [ ]
this . $refs . avatorUpload . clearFiles ( ) ;
this . $refs . avatorUpload . clearFiles ( ) ;
} ,
} ,
clearApproverWechatFiles ( ) {
clearApproverWechatFiles ( ) {
this . approverWechatUrl = '' ;
this . approverWechatUrl = '' ;
this . approverWechatFile = [ ]
this . approverWechatFile = [ ]
this . $refs . approverWechatUpload . clearFiles ( ) ;
this . $refs . approverWechatUpload . clearFiles ( ) ;
@ -340,9 +358,9 @@ export default {
this . $message . success ( response . msg )
this . $message . success ( response . msg )
var data = response . data
var data = response . data
if ( this . doctorId ) return ;
if ( this . doctorId ) return ;
setTimeout ( ( ) => {
setTimeout ( ( ) => {
location . href = location . href + '?doctor_id=' + data . doctor_id
location . href = location . href + '?doctor_id=' + data . doctor_id
} , 800 ) ;
} , 800 ) ;
} ) . catch ( error => {
} ) . catch ( error => {
console . error ( error , 'error' )
console . error ( error , 'error' )
@ -350,18 +368,42 @@ export default {
} )
} )
} ,
} ,
submitApproverWechat ( ) {
submitApproverWechat ( ) {
if ( ! this . doctorId ) {
if ( ! this . doctorId ) {
this . $message . error ( '请先设置医生基础信息' )
this . $message . error ( '请先设置医生基础信息' )
return ;
return ;
}
}
if ( this . approverWechatFile . length == 0 ) {
if ( this . approverWechatFile . length == 0 ) {
this . setApproverWechat ( this . siteForm )
this . setApproverWechat ( this . siteForm )
return ;
return ;
}
}
this . $refs . approverWechatUpload . submit ( ) ;
this . $refs . approverWechatUpload . submit ( ) ;
} ,
} ,
/ / 出 诊 设 置
submitCoincideSet ( ) {
if ( ! this . doctorId ) {
this . $message . error ( '请先设置医生基础信息' )
return ;
}
/ / 接 口 待 定
/ / t h i s . $ h t t p ( ' P O S T ' , ' / a p i / a d m i n / s e t _ d o c t o r _ a p p r o v e r ' , {
/ / i s _ a l l o w _ c o i n c i d e : t h i s . s i t e F o r m . i s _ a l l o w _ c o i n c i d e
/ / } ) . t h e n ( r e s p o n s e = > {
/ / i f ( r e s p o n s e . c o d e ! = 0 ) {
/ / t h i s . $ m e s s a g e . e r r o r ( r e s p o n s e . m s g )
/ / r e t u r n ;
/ / }
/ / t h i s . $ m e s s a g e . s u c c e s s ( r e s p o n s e . m s g )
/ / i f ( t h i s . d o c t o r I d ) r e t u r n ;
/ / } ) . c a t c h ( e r r o r = > {
/ / c o n s o l e . e r r o r ( e r r o r , ' e r r o r ' )
/ / t h i s . $ m e s s a g e . e r r o r ( ' 设 置 失 败 ' )
/ / } )
} ,
handleApproverWechatChange ( file , fileList ) {
handleApproverWechatChange ( file , fileList ) {
console . log ( file , fileList )
console . log ( file , fileList )
this . approverWechatFile = file
this . approverWechatFile = file
@ -382,8 +424,30 @@ export default {
}
}
< / script >
< / script >
< style lang = "scss" scoped >
< style lang = "scss" scoped >
. coincideWrap {
. info - upload - wrapper : : v - deep . el - upload - list . el - upload - list -- picture - card {
margin - right : 24 px ;
text - align : left ;
p {
font - family : Microsoft YaHei UI ;
font - size : 12 px ;
font - weight : normal ;
line - height : 24 px ;
letter - spacing : 0.08 em ;
color : # 8 A9099 ;
padding - left : 22 px ;
}
}
. coincideTip {
font - family : Microsoft YaHei UI ;
font - size : 14 px ;
font - weight : normal ;
line - height : normal ;
letter - spacing : 0.08 em ;
color : # 1 E2226 ;
text - align : left ;
}
. info - upload - wrapper : : v - deep . el - upload - list . el - upload - list -- picture - card {
display : none ;
display : none ;
}
}
@ -393,11 +457,12 @@ export default {
border : 1 px solid transparent ;
border : 1 px solid transparent ;
}
}
. uploadImg {
. uploadImg {
width : 150 px ;
width : 150 px ;
margin - right : 20 px ;
margin - right : 20 px ;
}
}
. special - form - item : : v - deep . el - form - item__label {
. special - form - item : : v - deep . el - form - item__label {
margin - bottom : 12 px ;
margin - bottom : 12 px ;
}
}
@ -421,9 +486,11 @@ export default {
display : flex ;
display : flex ;
width : 100 % ;
width : 100 % ;
justify - content : flex - start ;
justify - content : flex - start ;
. avator - wrapper {
. avator - wrapper {
position : relative ;
position : relative ;
. info - upload - wrapper {
. info - upload - wrapper {
position : absolute ;
position : absolute ;
display : flex ;
display : flex ;
justify - content : flex - end ;
justify - content : flex - end ;