头像上传裁剪
This commit is contained in:
+11
-10
@@ -13,18 +13,11 @@ Page({
|
||||
imglist: []
|
||||
},
|
||||
onLoad(options){
|
||||
console.log("onLoad", options)
|
||||
this.setData({
|
||||
order_inquiry_id: options.order_inquiry_id
|
||||
})
|
||||
//获取患者问诊病例
|
||||
api.getDoctorInquiryCase({order_inquiry_id: this.data.order_inquiry_id}).then(response => {
|
||||
console.log(response);
|
||||
this.setData({
|
||||
case_detail: response.data
|
||||
})
|
||||
}).then(res => {
|
||||
this.formatImgList();
|
||||
}).catch(errors => {console.error(errors);})
|
||||
|
||||
},
|
||||
formatImgList(){
|
||||
let diagnose_images = this.data.case_detail.diagnose_images;
|
||||
@@ -40,7 +33,15 @@ Page({
|
||||
})
|
||||
},
|
||||
onShow(){
|
||||
|
||||
//获取患者问诊病例
|
||||
api.getDoctorInquiryCase({order_inquiry_id: this.data.order_inquiry_id}).then(response => {
|
||||
console.log(response);
|
||||
this.setData({
|
||||
case_detail: response.data
|
||||
})
|
||||
}).then(res => {
|
||||
this.formatImgList();
|
||||
}).catch(errors => {console.error(errors);})
|
||||
},
|
||||
|
||||
})
|
||||
@@ -8,7 +8,7 @@
|
||||
<view class="sex">{{case_detail.sex==1?'男':case_detail.sex==2?'女':'未知'}}|{{case_detail.age}}岁 </view>
|
||||
</view>
|
||||
<view class="info">
|
||||
<view class="height info_item"><text class="info_title">身高:</text><text class="info_val">{{case_detail.height==null?'未知':case_detail.height}}cm</text></view>
|
||||
<view class="height info_item"><text class="info_title">身高:</text><text class="info_val">{{case_detail.height==null?'未知':case_detail.height}}CM</text></view>
|
||||
<view class="weight info_item"><text class="info_title">体重:</text><text class="info_val">{{case_detail.weight==null?'未知':case_detail.weight}}KG</text></view>
|
||||
<view class="minzu info_item"><text class="info_title">民族:</text><text class="info_val">{{case_detail.nation_name==''?'未知':case_detail.nation_name}}</text></view>
|
||||
<view class="zhiye info_item"><text class="info_title">职业:</text><text class="info_val">{{case_detail.job_name==''?'未知':case_detail.job_name}}</text></view>
|
||||
@@ -58,8 +58,9 @@
|
||||
|
||||
</view>
|
||||
</view>
|
||||
<view class="main_title" wx:if="{{case_detail.is_allergy_history != null && case_detail.is_family_history != null && case_detail.is_pregnant != null && case_detail.drink_wine_status != null && case_detail.smoke_status != null && case_detail.is_operation != null && case_detail.chemical_compound_status != null && case_detail.chemical_compound_status != null}}">其他信息</view>
|
||||
<view class="data_box orther" wx:if="{{case_detail.is_allergy_history != null && case_detail.is_family_history != null && case_detail.is_pregnant != null && case_detail.drink_wine_status != null && case_detail.smoke_status != null && case_detail.is_operation != null && case_detail.chemical_compound_status != null && case_detail.chemical_compound_status != null}}">
|
||||
|
||||
<view class="main_title" wx:if="{{!(case_detail.is_allergy_history == null && case_detail.is_family_history == null && case_detail.is_pregnant == null && case_detail.drink_wine_status == null && case_detail.smoke_status == null && case_detail.is_operation == null && case_detail.chemical_compound_status == null && case_detail.chemical_compound_status == null)}}">其他信息</view>
|
||||
<view class="data_box orther" wx:if="{{!(case_detail.is_allergy_history == null && case_detail.is_family_history == null && case_detail.is_pregnant == null && case_detail.drink_wine_status == null && case_detail.smoke_status == null && case_detail.is_operation == null && case_detail.chemical_compound_status == null && case_detail.chemical_compound_status == null)}}">
|
||||
<view class="disease_box">
|
||||
<view class="disease_box_item" wx:if="{{case_detail.is_allergy_history != null}}">
|
||||
<view class="title">过敏史:</view>
|
||||
@@ -89,7 +90,7 @@
|
||||
<view class="title">接触化学物:</view>
|
||||
<view class="conent">{{case_detail.chemical_compound_status==1?'从不':case_detail.chemical_compound_status==2?'偶尔':case_detail.chemical_compound_status==3?'经常':case_detail.chemical_compound_status==4?'每天':'其他'}}</view>
|
||||
</view>
|
||||
<view class="disease_info" wx:if="{{case_detail.chemical_compound_describe != null}}">
|
||||
<view class="disease_info" wx:if="{{case_detail.chemical_compound_describe != '' && case_detail.chemical_compound_describe != null}}">
|
||||
详细描述:{{case_detail.chemical_compound_describe}}
|
||||
</view>
|
||||
</view>
|
||||
|
||||
@@ -66,6 +66,9 @@ Page({
|
||||
console.log("onChange: ", detail);
|
||||
if(detail){
|
||||
this.setData({ note: this.data.open_note });
|
||||
wx.vibrateShort({
|
||||
"type": "heavy"
|
||||
})
|
||||
}else{
|
||||
this.setData({ note: this.data.close_note });
|
||||
}
|
||||
|
||||
@@ -61,6 +61,9 @@ Page({
|
||||
let check = this.checkPrice(inquiry_price);
|
||||
if(!check) return;
|
||||
this.setData({ note: this.data.open_note });
|
||||
wx.vibrateShort({
|
||||
"type": "heavy"
|
||||
})
|
||||
}else{
|
||||
this.setData({ note: this.data.close_note });
|
||||
}
|
||||
|
||||
@@ -47,6 +47,9 @@ Page({
|
||||
},
|
||||
onStepperChange(event) {
|
||||
console.log(event.detail);
|
||||
wx.vibrateShort({
|
||||
"type": "heavy"
|
||||
})
|
||||
this.setData({
|
||||
"info.work_num_day": event.detail
|
||||
});
|
||||
|
||||
@@ -12,7 +12,6 @@ Page({
|
||||
license_cert: [],
|
||||
qualification_cert: [],
|
||||
work_cert: [],
|
||||
license_cert_visible: false
|
||||
},
|
||||
onLoad(){
|
||||
api.getDoctorCret().then(response => {
|
||||
@@ -24,20 +23,13 @@ Page({
|
||||
})
|
||||
}).catch(errors => {console.error(errors);})
|
||||
},
|
||||
show_license_cert(){
|
||||
console.log("show_license_cert")
|
||||
this.setData({
|
||||
license_cert_visible: true
|
||||
previewImage(e){
|
||||
let name = e.currentTarget.dataset.name;
|
||||
let name_date = this.data[name]
|
||||
|
||||
wx.previewImage({
|
||||
current: name_date[0], // 当前显示图片的http链接
|
||||
urls: name_date // 需要预览的图片http链接列表
|
||||
})
|
||||
},
|
||||
close_license_cert(e) {
|
||||
const {
|
||||
detail: { trigger },
|
||||
} = e;
|
||||
console.log("trigger: ", trigger);
|
||||
console.log("close_license_cert")
|
||||
this.setData({
|
||||
license_cert_visible: false,
|
||||
});
|
||||
},
|
||||
}
|
||||
})
|
||||
@@ -2,7 +2,6 @@
|
||||
"component": true,
|
||||
"usingComponents": {
|
||||
"te-nav-bar": "/commpents/te_navbar",
|
||||
"t-image": "tdesign-miniprogram/image/image",
|
||||
"t-image-viewer": "tdesign-miniprogram/image-viewer/image-viewer"
|
||||
"t-image": "tdesign-miniprogram/image/image"
|
||||
}
|
||||
}
|
||||
@@ -12,7 +12,8 @@
|
||||
style="margin: 0 50rpx 0 20rpx;"
|
||||
width="220rpx" height="220rpx"
|
||||
aria-label="img" wx:for="{{license_cert}}"
|
||||
bindtap="show_license_cert" />
|
||||
data-name="license_cert"
|
||||
bindtap="previewImage" />
|
||||
</view>
|
||||
</view>
|
||||
<view class="imgbox_item">
|
||||
@@ -25,7 +26,9 @@
|
||||
mode="heightFix"
|
||||
style="margin: 0 50rpx 0 20rpx;"
|
||||
width="220rpx" height="220rpx"
|
||||
aria-label="img" wx:for="{{qualification_cert}}" />
|
||||
aria-label="img" wx:for="{{qualification_cert}}"
|
||||
data-name="qualification_cert"
|
||||
bindtap="previewImage"/>
|
||||
</view>
|
||||
</view>
|
||||
<view class="imgbox_item">
|
||||
@@ -37,18 +40,10 @@
|
||||
mode="heightFix"
|
||||
style="margin: 0 50rpx 20rpx 20rpx;"
|
||||
width="220rpx" height="220rpx"
|
||||
aria-label="img" wx:for="{{work_cert}}" />
|
||||
aria-label="img" wx:for="{{work_cert}}"
|
||||
data-name="work_cert"
|
||||
bindtap="previewImage"/>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<!-- <t-image-viewer
|
||||
deleteBtn="{{false}}"
|
||||
close-btn="{{true}}"
|
||||
show-index="{{true}}"
|
||||
visible="{{license_cert_visible}}"
|
||||
images="{{license_cert}}"
|
||||
bind:close="close_license_cert"
|
||||
></t-image-viewer> -->
|
||||
|
||||
</view>
|
||||
@@ -88,7 +88,11 @@ Page({
|
||||
onChange({ detail }) {
|
||||
console.log("onChange: ", detail);
|
||||
|
||||
|
||||
if(detail){
|
||||
wx.vibrateShort({
|
||||
"type": "heavy"
|
||||
})
|
||||
}
|
||||
//修改开关
|
||||
let params = {};
|
||||
params.inquiry_type = this.data.inquiry_type;//接诊类型(1:专家问诊 2:快速问诊 3:公益问诊 4:问诊购药)
|
||||
@@ -98,7 +102,6 @@ Page({
|
||||
console.log(response);
|
||||
}).then(()=>{
|
||||
if(detail){
|
||||
|
||||
let tmplIds = ['G1RIs0RYqsTQ2CuPQWalIMyb6_deuEEbJfajfhGvNzc']
|
||||
let sub_promise = requestSubscribeMessage(tmplIds)
|
||||
sub_promise.then(res => {
|
||||
|
||||
@@ -150,6 +150,9 @@ Page({
|
||||
},
|
||||
onStepperChange(event) {
|
||||
console.log(event.detail);
|
||||
wx.vibrateShort({
|
||||
"type": "heavy"
|
||||
})
|
||||
this.setData({
|
||||
"info.work_num_day": event.detail
|
||||
});
|
||||
@@ -160,6 +163,9 @@ Page({
|
||||
},
|
||||
|
||||
onColumnChange(e) {
|
||||
wx.vibrateShort({
|
||||
"type": "heavy"
|
||||
})
|
||||
console.log('picker pick:', e);
|
||||
},
|
||||
|
||||
|
||||
Reference in New Issue
Block a user