优化
This commit is contained in:
@@ -1,3 +1,5 @@
|
||||
import { API } from "../../utils/network/api";
|
||||
const api = new API()
|
||||
// commpents/wenzhen_data/index.js
|
||||
Component({
|
||||
/**
|
||||
@@ -87,6 +89,8 @@ Component({
|
||||
this.setData({
|
||||
show: false
|
||||
})
|
||||
|
||||
console.log("开始订阅消息");
|
||||
wx.requestSubscribeMessage({
|
||||
tmplIds: ['jhYUf91ULCTX_f69hazqAYwImdFf8ELasRAwB6X-MTM'],
|
||||
success (res) {
|
||||
@@ -100,6 +104,24 @@ Component({
|
||||
}
|
||||
})
|
||||
},
|
||||
postDoctorInquiry(e){
|
||||
this.setData({
|
||||
show: false
|
||||
})
|
||||
console.log("order_inquiry_id: ", e.currentTarget.dataset.order_inquiry_id);
|
||||
let params = {};
|
||||
params.order_inquiry_id = e.currentTarget.dataset.order_inquiry_id;
|
||||
console.log("params: ",params)
|
||||
api.postDoctorInquiry(params).then(response => {
|
||||
console.log("开始接诊");
|
||||
console.log(response);
|
||||
}).then(() => {
|
||||
this.goChat(e);
|
||||
}).catch(errors => {
|
||||
console.error(errors);
|
||||
})
|
||||
|
||||
},
|
||||
tabShow(){
|
||||
this.setData({
|
||||
show: true
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
<van-button type="default" bindtap="tabShow" custom-style="width:200rpx; border-radius: 10rpx;margin-left:20rpx;" color="#3CC7C0">去接诊</van-button>
|
||||
</view>
|
||||
<view class="btn" wx:if="{{ status >= 4 }}">
|
||||
<van-button bind:click="goChat" data-from_account="{{from_account}}" data-url="/Pages/yishi/chat/index" plain custom-style="width:200rpx; border-radius: 10rpx;" color="#3CC7C0">问诊详情</van-button>
|
||||
<van-button bind:click="goChat" data-from_account="{{from_account}}" data-inquiry_type="{{inquiry_type}}" data-order_inquiry_id="{{order_inquiry_id}}" data-url="/Pages/yishi/chat/index" plain custom-style="width:200rpx; border-radius: 10rpx;" color="#3CC7C0">问诊详情</van-button>
|
||||
<!-- <van-button bind:click="go" data-url="/Pages/yishi/chat_session/index" plain custom-style="width:200rpx; border-radius: 10rpx;" color="#3CC7C0">会话列表</van-button> -->
|
||||
</view>
|
||||
</view>
|
||||
@@ -27,7 +27,7 @@
|
||||
<view class="pop_note">为保障服务质量,请您查看患者病历信息在选择是否接诊。</view>
|
||||
<view class="pop_btn">
|
||||
<view class="pop_btn_left" bindtap="go" data-from_account="{{from_account}}" data-url="/Pages/yishi/case/index?order_inquiry_id={{order_inquiry_id}}" >去查看</view>
|
||||
<view class="pop_btn_right" bindtap="goChat" data-from_account="{{from_account}}" data-inquiry_type="{{inquiry_type}}" data-order_inquiry_id="{{order_inquiry_id}}" data-url="/Pages/yishi/chat/index" >去接诊</view>
|
||||
<view class="pop_btn_right" bindtap="postDoctorInquiry" data-from_account="{{from_account}}" data-inquiry_type="{{inquiry_type}}" data-order_inquiry_id="{{order_inquiry_id}}" data-url="/Pages/yishi/chat/index" >去接诊</view>
|
||||
</view>
|
||||
</view>
|
||||
</van-popup>
|
||||
Reference in New Issue
Block a user