优化
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
<view class="container">
|
||||
<view class="tui-navigatorbar">
|
||||
<image wx:if="{{ navbarData.showCapsule==1 }}" class="tui-navigatorbar-back" bindtap="_navback" src="/TUIKit/static/assets/ic_back_white.svg" />
|
||||
<image wx:if="{{ navbarData.showCapsule==1 }}" class="tui-navigatorbar-back" bindtap="_navback" src="/TUIKit/static/assets/ic_back_black.svg" />
|
||||
<view class="conversation-title">{{ navbarData.title }}</view>
|
||||
</view>
|
||||
<view class="box">
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
top: 0;
|
||||
width: 750rpx;
|
||||
height: 170rpx;
|
||||
background-color: #e94d4d;
|
||||
background-color: #ffffff;
|
||||
z-index: 99;
|
||||
}
|
||||
.tui-navigatorbar-back{
|
||||
|
||||
@@ -20,7 +20,7 @@ Component({
|
||||
showCapsule: 1, //是否显示左上角图标 1表示显示 0表示不显示
|
||||
title: '医师身份认证', //导航栏 中间的标题
|
||||
},
|
||||
height: app.globalData.height,
|
||||
height: app.globalData.height,
|
||||
//选项卡
|
||||
stickyProps: {
|
||||
zIndex: 2,
|
||||
@@ -96,7 +96,8 @@ Component({
|
||||
license_cert_reason: "",
|
||||
qualification_cert_reason: "",
|
||||
work_cert_reason: "",
|
||||
department_custom_name_reason: ''
|
||||
department_custom_name_reason: '',
|
||||
zhuanchang_note: '请选择专长',
|
||||
},
|
||||
|
||||
options: {
|
||||
@@ -108,15 +109,11 @@ Component({
|
||||
|
||||
console.log("myprofile attached")
|
||||
let _this = this;
|
||||
console.log(_this.data.zhicheng_columns);
|
||||
console.log(_this.data.zhicheng_columns);
|
||||
|
||||
|
||||
//获得医师身份认证
|
||||
api.getDoctorAuthIden({source: this.data.indentity?1:2}).then(response => {
|
||||
console.log("getDoctorAuthIden: ",response);
|
||||
this.setData({
|
||||
|
||||
doctorauthiden_data_ready: true,
|
||||
textarea_jianjie: response.data.brief_introduction,
|
||||
textarea_shanchang: response.data.be_good_at,
|
||||
@@ -217,6 +214,15 @@ Component({
|
||||
_this.setData({
|
||||
zhuanchang_columns: response.data
|
||||
})
|
||||
}).then(()=>{
|
||||
let index = this.data.zhuanchang_columns.findIndex(item => {
|
||||
return item.is_selected == 1
|
||||
})
|
||||
if(index) {
|
||||
this.setData({
|
||||
zhuanchang_note: ""
|
||||
})
|
||||
}
|
||||
}).catch(errors => {console.error(errors); })
|
||||
|
||||
let keshi_huixian = false;
|
||||
@@ -235,10 +241,13 @@ Component({
|
||||
console.log("select_keshi_id: ", _this.data.select_keshi_id);
|
||||
return item.value == _this.data.select_keshi_id
|
||||
})
|
||||
if(index){
|
||||
console.log("科室:", index)
|
||||
let keshi_note = _this.data.keshi_columns[index].text;
|
||||
console.log("科室 keshi_note:", keshi_note);
|
||||
if(index != undefined){
|
||||
_this.setData({
|
||||
select_keshi_index: index,
|
||||
keshi_note: _this.data.keshi_columns[index].text
|
||||
keshi_note: keshi_note
|
||||
})
|
||||
}
|
||||
keshi_huixian = true;
|
||||
@@ -479,7 +488,7 @@ Component({
|
||||
this.setData({ yiyuan_show: true });
|
||||
}else{
|
||||
wx.showToast({
|
||||
title: '请先选择省市',
|
||||
title: '请先选择城市',
|
||||
icon: "error"
|
||||
})
|
||||
}
|
||||
@@ -650,6 +659,7 @@ Component({
|
||||
}
|
||||
})
|
||||
|
||||
console.log("countcountcountcount: ",count)
|
||||
if(count >= 10 && e.currentTarget.dataset.is_selected==0){
|
||||
wx.showToast({
|
||||
title: '最多10个专长',
|
||||
@@ -661,6 +671,27 @@ Component({
|
||||
let data = "zhuanchang_columns["+index+"].is_selected";
|
||||
this.setData({[data]: is_selected==1?0:1})
|
||||
}
|
||||
|
||||
this.checkZhuanchangNote()
|
||||
},
|
||||
checkZhuanchangNote(){
|
||||
let count = 0
|
||||
this.data.zhuanchang_columns.forEach(item => {
|
||||
if(item.is_selected == 1){
|
||||
count = count + 1;
|
||||
}
|
||||
})
|
||||
|
||||
if(count > 0){
|
||||
this.setData({
|
||||
zhuanchang_note: ""
|
||||
})
|
||||
}
|
||||
if(count == 0){
|
||||
this.setData({
|
||||
zhuanchang_note: "请选择专长"
|
||||
})
|
||||
}
|
||||
},
|
||||
zhuanchangConfirm(e){
|
||||
this.setData({ zhuanchang_show: false });
|
||||
@@ -881,5 +912,8 @@ Component({
|
||||
[file_name]: img_list
|
||||
})
|
||||
},
|
||||
moveZhuanChang(){
|
||||
|
||||
}
|
||||
}
|
||||
})
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<view class="photo" style="border-bottom: {{avatar_reason==''?'1px solid var(--td-cell-border-color, var(--td-gray-color-3, #e7e7e7));':'unset'}}">
|
||||
<view class="title">头像 <text class="required"> *</text></view>
|
||||
<van-uploader bind:after-read="doUploadPhoto" data-scene="1" data-field_name="avatar" data-file_multiple="false">
|
||||
<van-uploader disabled="{{ indentity && iden_auth_disabled }}" bind:after-read="doUploadPhoto" data-scene="1" data-field_name="avatar" data-file_multiple="false">
|
||||
<view class="right">
|
||||
<view class="note">真人正脸</view>
|
||||
<t-avatar image="{{ avatar }}" />
|
||||
@@ -19,7 +19,7 @@
|
||||
</view>
|
||||
|
||||
<!-- <t-cell title="头像" hover required arrow note="真人正脸" /> -->
|
||||
<t-cell title="城市" hover required arrow note="{{ city_note }}" bindtap="onCityShow"/>
|
||||
<t-cell title="城市" hover required arrow note="{{ city_note }}" bindtap="{{(indentity && iden_auth_disabled)?'':'onCityShow'}}"/>
|
||||
|
||||
<t-cascader
|
||||
visible="{{ city_show }}"
|
||||
@@ -31,7 +31,7 @@
|
||||
bind:change="onChangeCity"
|
||||
></t-cascader>
|
||||
|
||||
<t-cell title="医院" hover required arrow note="{{ yiyuan_note }}" bindtap="onYiYuanShow"/>
|
||||
<t-cell title="医院" hover required arrow note="{{ yiyuan_note }}" bindtap="{{(indentity && iden_auth_disabled)?'':'onYiYuanShow'}}"/>
|
||||
<van-popup
|
||||
show="{{ yiyuan_show }}"
|
||||
position="bottom"
|
||||
@@ -57,10 +57,14 @@
|
||||
bind:search="hospitalSearch"
|
||||
/>
|
||||
</van-popup>
|
||||
<t-cell title="科室" hover required arrow note="{{keshi_note}}" bindtap="onKeshiShow" bordered="{{ select_keshi_id == '' }}"/>
|
||||
<t-cell title="科室" hover required arrow note="{{keshi_note}}"
|
||||
bindtap="{{(indentity && iden_auth_disabled)?'':'onKeshiShow'}}" bordered="{{ select_keshi_id == '' }}"/>
|
||||
|
||||
<view class="custom_keshi" wx:if="{{ select_keshi_id != ''}}">
|
||||
<van-field bind:change="onCustomKeshiChange" model:value="{{custom_keshi}}" label="" placeholder="请输入科室" border="{{department_custom_name_reason == ''}}" />
|
||||
<van-field bind:change="onCustomKeshiChange"
|
||||
disabled="{{(indentity && iden_auth_disabled)}}"
|
||||
type="text" model:value="{{custom_keshi}}" label=""
|
||||
placeholder="请输入科室" border="{{department_custom_name_reason == ''}}" />
|
||||
</view>
|
||||
|
||||
<view class="has_error" wx:if="{{ department_custom_name_reason != '' }}" >
|
||||
@@ -142,8 +146,10 @@
|
||||
</view>
|
||||
</van-popup>
|
||||
|
||||
<t-popup visible="{{zhuanchang_show}}" bind:visible-change="onZhuanChangVisibleChange" placement="bottom">
|
||||
<view class="zhuanchang_block">
|
||||
<t-popup visible="{{zhuanchang_show}}"
|
||||
prevent-scroll-through
|
||||
bind:visible-change="onZhuanChangVisibleChange" placement="bottom">
|
||||
<view class="zhuanchang_block" catchtouchmove="moveZhuanChang">
|
||||
<view class="zhuanchang_header">
|
||||
<view class="zhuanchang_btn zhuanchang_btn--cancel" aria-role="button" bindtap="zhuanchangConcle">取消</view>
|
||||
<view class="zhuanchang_title">选择专长</view>
|
||||
@@ -169,7 +175,8 @@
|
||||
</view>
|
||||
</t-popup>
|
||||
|
||||
<t-cell title="职称" hover required arrow note="{{zhicheng_note}}" bindtap="onZhiChengShow" />
|
||||
<t-cell title="职称" hover required arrow note="{{zhicheng_note}}"
|
||||
bindtap="{{(indentity && iden_auth_disabled)?'':'onZhiChengShow'}}" />
|
||||
<!-- <t-input
|
||||
label="科室电话"
|
||||
placeholder="请输入科室电话"
|
||||
@@ -185,7 +192,9 @@
|
||||
placeholder="请输入科室电话"
|
||||
placeholder-style="font-size:25rpx;letter-spacing: 2rpx;color:rgba(0, 0, 0, 0.4);"
|
||||
input-align="right"
|
||||
type="number"
|
||||
clearable
|
||||
disabled="{{(indentity && iden_auth_disabled)}}"
|
||||
border="{{ department_custom_mobile_reason == '' }}"
|
||||
custom-style="font-size:30rpx;"
|
||||
>
|
||||
@@ -199,7 +208,7 @@
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<view class="zhuanchang" bindtap="onZhuanChangShow">
|
||||
<view class="zhuanchang" bindtap="{{(indentity && iden_auth_disabled)?'':'onZhuanChangShow'}}">
|
||||
<view class="title">专长 <text class="required"> *</text></view>
|
||||
<view class="content">
|
||||
<view class="content_item" wx:key="expertise_name" wx:if="{{data.is_selected == 1}}" wx:for="{{ zhuanchang_columns }}" wx:for-item="data">
|
||||
@@ -208,7 +217,7 @@
|
||||
</view>
|
||||
|
||||
<view class="right">
|
||||
<view class="note">请选择专长</view>
|
||||
<view class="note">{{zhuanchang_note}}</view>
|
||||
<view class="icon">
|
||||
<t-icon name="chevron-right" size="48rpx" data-name="chevron-right" />
|
||||
</view>
|
||||
@@ -221,6 +230,7 @@
|
||||
bind:showNote="onshowJianJieNote"
|
||||
textarea_cell_content_placeholder="您的从业经历,职称,所获荣誉等信息(10~1000字)"
|
||||
textarea_val="{{textarea_jianjie}}"
|
||||
disabled="{{(indentity && iden_auth_disabled)}}"
|
||||
has_error_content="{{ brief_introduction_reason }}"
|
||||
data-textarea_name="textarea_jianjie" bindTextAreaBlur="getTextAreaVal" />
|
||||
|
||||
@@ -228,6 +238,7 @@
|
||||
textarea_cell_name="擅长领域"
|
||||
t_icon_name="view-module"
|
||||
bind:showNote="onshowShanChangNote"
|
||||
disabled="{{(indentity && iden_auth_disabled)}}"
|
||||
textarea_val="{{textarea_shanchang}}"
|
||||
has_error_content="{{ be_good_at_reason }}"
|
||||
textarea_cell_content_placeholder="您的专业领域、擅长疾病、研究方法等信息(10~1000字)"
|
||||
@@ -248,6 +259,7 @@
|
||||
upload_cell_note="查看示例"
|
||||
has_error_content="{{ license_cert_reason }}"
|
||||
wx:if="{{indentity}}"
|
||||
disabled="{{(indentity && iden_auth_disabled)}}"
|
||||
is_multiple="true"
|
||||
/>
|
||||
|
||||
@@ -266,6 +278,7 @@
|
||||
upload_cell_note="查看示例"
|
||||
has_error_content="{{ qualification_cert_reason }}"
|
||||
wx:if="{{indentity}}"
|
||||
disabled="{{(indentity && iden_auth_disabled)}}"
|
||||
is_multiple="true"
|
||||
/>
|
||||
|
||||
@@ -284,6 +297,7 @@
|
||||
upload_cell_note="查看示例"
|
||||
has_error_content="{{ work_cert_reason }}"
|
||||
wx:if="{{indentity}}"
|
||||
disabled="{{(indentity && iden_auth_disabled)}}"
|
||||
is_multiple="true"
|
||||
/>
|
||||
|
||||
|
||||
@@ -219,4 +219,4 @@
|
||||
}
|
||||
.custom_keshi_error{
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -24,9 +24,18 @@
|
||||
<t-navbar class="block" title="{{navbarData.title}}" left-arrow bind:go-back="onBack" />
|
||||
</view>
|
||||
<!-- 仅显示home -->
|
||||
<view class="block" wx:if="{{navbarData.showCapsule == 3}}">
|
||||
<t-navbar class="block" title="{{navbarData.title}}" home bind:go-back="onGoHome" />
|
||||
</view>
|
||||
<t-navbar title="{{navbarData.title}}" wx:if="{{navbarData.showCapsule == 3}}">
|
||||
<view slot="left" class="custom-capsule-home">
|
||||
<t-icon
|
||||
size="20"
|
||||
bind:tap="onGoHome"
|
||||
aria-role="button"
|
||||
aria-label="首页"
|
||||
name="home"
|
||||
class="custom-capsule__icon"
|
||||
/>
|
||||
</view>
|
||||
</t-navbar>
|
||||
<!-- 都不显示 -->
|
||||
<view class="block" wx:if="{{navbarData.showCapsule == 0}}">
|
||||
<t-navbar class="block" title="{{navbarData.title}}" />
|
||||
|
||||
@@ -20,4 +20,7 @@
|
||||
width: 1px;
|
||||
height: 36rpx;
|
||||
background: #e7e7e7;
|
||||
}
|
||||
.custom-capsule-home{
|
||||
margin-left: 36rpx;
|
||||
}
|
||||
@@ -12,6 +12,10 @@ Component({
|
||||
type: Boolean,
|
||||
value: true,
|
||||
},
|
||||
disabled: {
|
||||
type: Boolean,
|
||||
value: false,
|
||||
},
|
||||
textarea_cell_note: {
|
||||
type: String,
|
||||
value: '示例备注',
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
</view>
|
||||
</view>
|
||||
<view class="textarea-cell-content">
|
||||
<textarea bindblur="bindTextAreaBlur" maxlength="1000" style="margin: 32rpx 32rpx 0 32rpx; width: 100%; height: 90%; background-color: #FAFAFA;" name="" id="" placeholder="{{ textarea_cell_content_placeholder }}" value="{{textarea_val}}"></textarea>
|
||||
<textarea disabled="{{disabled}}" bindblur="bindTextAreaBlur" maxlength="1000" style="margin: 32rpx 32rpx 0 32rpx; width: 100%; height: 90%; background-color: #FAFAFA;" name="" id="" placeholder="{{ textarea_cell_content_placeholder }}" value="{{textarea_val}}"></textarea>
|
||||
</view>
|
||||
<view class="error_box" wx:if="{{ has_error_content != '' }}" >
|
||||
<t-icon color="red" name="close-circle-filled" size="48rpx" data-name="close-circle-filled" />
|
||||
|
||||
Reference in New Issue
Block a user