优化
This commit is contained in:
@@ -20,28 +20,40 @@ Page({
|
||||
message_inquiry_type: 99999,
|
||||
system_notice_unreadnnum: "",
|
||||
service_notice_unreadnnum: "",
|
||||
hasOnShow: false
|
||||
hasOnShow: false,
|
||||
show: false,
|
||||
show_dialog_from_account: "",
|
||||
show_dialog_order_inquiry_id: "",
|
||||
show_dialog_inquiry_type: "",
|
||||
unreadnnum_inter: 0
|
||||
},
|
||||
onLoad() {
|
||||
console.log("wenzhen onload");
|
||||
console.log("wenzhen onloadddd");
|
||||
|
||||
// if(wx.$TUIKit){
|
||||
// wx.$TUIKit.on(wx.$TUIKitTIM.EVENT.MESSAGE_RECEIVED, this.$onMessageReceived, this);
|
||||
// }else{
|
||||
// app.imInit().then(res => {
|
||||
// console.log("wenzhen onload imInit");
|
||||
// wx.$TUIKit.on(wx.$TUIKitTIM.EVENT.MESSAGE_RECEIVED, this.$onMessageReceived, this);
|
||||
// });
|
||||
// }
|
||||
},
|
||||
initInterval(){
|
||||
let usertype = wx.getStorageSync('usertype');
|
||||
let userID = wx.getStorageSync('user_id_'+usertype);
|
||||
if(wx.$TUIKit){
|
||||
wx.$TUIKit.on(wx.$TUIKitTIM.EVENT.MESSAGE_RECEIVED, this.$onMessageReceived, this);
|
||||
}else{
|
||||
app.imInit().then(res => {
|
||||
console.log("wenzhen onload imInit");
|
||||
wx.$TUIKit.on(wx.$TUIKitTIM.EVENT.MESSAGE_RECEIVED, this.$onMessageReceived, this);
|
||||
});
|
||||
}
|
||||
setInterval(() => {
|
||||
let unreadnnum_inter = setInterval(() => {
|
||||
let system_notice_unreadnnum = wx.getStorageSync(userID+"_system_notice_unreadnnum");
|
||||
let service_notice_unreadnnum = wx.getStorageSync(userID+"_service_notice_unreadnnum");
|
||||
this.setData({
|
||||
system_notice_unreadnnum: system_notice_unreadnnum,
|
||||
service_notice_unreadnnum: service_notice_unreadnnum,
|
||||
})
|
||||
}, 500);
|
||||
}, 1000);
|
||||
this.setData({
|
||||
unreadnnum_inter: unreadnnum_inter
|
||||
})
|
||||
console.log("app.globalData.unreadnnum_inter: ", app.globalData.unreadnnum_inter);
|
||||
},
|
||||
onShow: function () {
|
||||
console.log("onShow from wenzhen V2")
|
||||
@@ -54,37 +66,60 @@ Page({
|
||||
})
|
||||
}
|
||||
this.getConversationList();
|
||||
if(this.data.unreadnnum_inter == 0){
|
||||
this.initInterval();
|
||||
}
|
||||
//避免onshow加载多次
|
||||
this.setData({
|
||||
hasOnShow: true
|
||||
})
|
||||
|
||||
if(wx.$TUIKit){
|
||||
wx.$TUIKit.on(wx.$TUIKitTIM.EVENT.MESSAGE_RECEIVED, this.$onMessageReceived, this);
|
||||
}else{
|
||||
app.imInit().then(res => {
|
||||
console.log("wenzhen onload imInit");
|
||||
wx.$TUIKit.on(wx.$TUIKitTIM.EVENT.MESSAGE_RECEIVED, this.$onMessageReceived, this);
|
||||
});
|
||||
}
|
||||
|
||||
},
|
||||
onHide(){
|
||||
console.log("onHideonHide from wenzhen")
|
||||
this.setData({hasOnShow: false})
|
||||
clearInterval(this.data.unreadnnum_inter)
|
||||
this.setData({
|
||||
hasOnShow: false,
|
||||
data_list_1: [],
|
||||
data_list_2: [],
|
||||
data_list_3: [],
|
||||
data_list_4: [],
|
||||
data_list_5: [],
|
||||
message_inquiry_type: 9999,
|
||||
unreadnnum_inter: 0
|
||||
})
|
||||
wx.$TUIKit.off(wx.$TUIKitTIM.EVENT.MESSAGE_RECEIVED, this.$onMessageReceived);
|
||||
},
|
||||
onUnload(){
|
||||
console.log("onUnload from wenzhen")
|
||||
this.setData({hasOnShow: false})
|
||||
// wx.$TUIKit.off(wx.$TUIKitTIM.EVENT.MESSAGE_RECEIVED, this.$onMessageReceived);
|
||||
this.setData({
|
||||
hasOnShow: false,
|
||||
message_inquiry_type: 9999
|
||||
})
|
||||
},
|
||||
getConversationList(){
|
||||
wx.$TUIKit.getConversationList().then((imResponse) => {
|
||||
console.log("imResponse.data.conversationList from wenzhen_v2: ", imResponse.data.conversationList);
|
||||
this.setData({
|
||||
conversationList: imResponse.data.conversationList,
|
||||
});
|
||||
}).then(() => {
|
||||
console.log("开始查询订单状态")
|
||||
this.formatStatus();
|
||||
}).catch(error => {
|
||||
console.log(error)
|
||||
// 补偿登录操作
|
||||
app.imInit().then(res => {
|
||||
this.getConversationList();
|
||||
console.log("getConversationListgetConversationListgetConversationList");
|
||||
app.imInit().then(res => {
|
||||
console.log("wenzhen onload imInit: ", res);
|
||||
wx.$TUIKit.getConversationList().then((imResponse) => {
|
||||
console.log("imResponse.data.conversationList from wenzhen_v2: ", imResponse.data.conversationList);
|
||||
this.setData({
|
||||
conversationList: imResponse.data.conversationList,
|
||||
});
|
||||
}).then(() => {
|
||||
console.log("开始查询订单状态")
|
||||
this.formatStatus();
|
||||
}).catch(error => {
|
||||
console.log(error)
|
||||
this.getConversationList();
|
||||
});
|
||||
});
|
||||
},
|
||||
@@ -190,7 +225,7 @@ Page({
|
||||
},
|
||||
formatStatus(){
|
||||
let order_inquiry_id_list = [];
|
||||
order_inquiry_id_list.push("a");//初始化一个,防止失败
|
||||
order_inquiry_id_list.push("");//初始化一个,防止失败
|
||||
this.data.conversationList.forEach(item => {
|
||||
let conversationID = item.conversationID;
|
||||
if(conversationID == "C2Cadministrator") return;//如果是管理员消息直接跳过
|
||||
@@ -241,14 +276,12 @@ Page({
|
||||
item.patient_age = order.patient_age;
|
||||
item.patient_name = order.patient_name;
|
||||
item.patient_sex = order.patient_sex;
|
||||
|
||||
new_conversationList.push(item);
|
||||
})
|
||||
|
||||
this.setData({
|
||||
conversationList: new_conversationList
|
||||
})
|
||||
|
||||
}
|
||||
}).then(() => {
|
||||
console.log("开始格式化formatConversationList")
|
||||
@@ -300,6 +333,16 @@ Page({
|
||||
let session_item = {};
|
||||
session_item.inquiry_status = item.inquiry_status;//订单状态暂无
|
||||
let txt = {};
|
||||
if(lastMessage.messageForShow == "[自定义消息]"){
|
||||
let text = "自定义消息";
|
||||
let payload = lastMessage.payload;
|
||||
if(payload) {
|
||||
console.log("payload: ",payload.data);
|
||||
let payloadJson = JSON.parse(payload.data);
|
||||
text = payloadJson.title.replace(/-/g, "");
|
||||
}
|
||||
lastMessage.messageForShow = text;
|
||||
}
|
||||
txt.Text= lastMessage.messageForShow;
|
||||
session_item.last_message_content = txt;
|
||||
session_item.message_send_time = getTimeAgo(lastMessage.lastTime);
|
||||
@@ -315,7 +358,12 @@ Page({
|
||||
totalUnreadCount = totalUnreadCount + unreadCount;
|
||||
session_item.message_dot = true;
|
||||
}else{
|
||||
session_item.message_dot = false;
|
||||
if(item.inquiry_status == 3){
|
||||
totalUnreadCount = totalUnreadCount + 1;
|
||||
session_item.message_dot = true;
|
||||
}else{
|
||||
session_item.message_dot = false;
|
||||
}
|
||||
}
|
||||
session_list[inquiry_type - 1].push(session_item);
|
||||
})
|
||||
@@ -336,7 +384,9 @@ Page({
|
||||
this.setData({has_data: false})
|
||||
}else{
|
||||
this.setData({has_data: true})
|
||||
this.selectComponent('#tabs').resize();
|
||||
}
|
||||
|
||||
},
|
||||
checkOrderInquiryId(list, order_inquiry_id){
|
||||
let index = list.findIndex(item => {
|
||||
@@ -346,5 +396,59 @@ Page({
|
||||
},
|
||||
onTabsChange(e){
|
||||
console.log(e);
|
||||
},
|
||||
goChat(e){
|
||||
this.setData({
|
||||
show: false
|
||||
})
|
||||
|
||||
console.log("开始订阅消息");
|
||||
wx.requestSubscribeMessage({
|
||||
tmplIds: ['jhYUf91ULCTX_f69hazqAYwImdFf8ELasRAwB6X-MTM'],
|
||||
success (res) {
|
||||
console.log(res);
|
||||
let from_account = e.currentTarget.dataset.from_account;
|
||||
let order_inquiry_id = e.currentTarget.dataset.order_inquiry_id;
|
||||
let inquiry_type = e.currentTarget.dataset.inquiry_type;
|
||||
let url = e.currentTarget.dataset.url+"?from_account="+from_account+"&order_inquiry_id="+order_inquiry_id+"&inquiry_type="+inquiry_type;
|
||||
app.go(url);
|
||||
}
|
||||
})
|
||||
},
|
||||
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(e){
|
||||
let show_dialog_from_account = e.currentTarget.dataset.show_dialog_from_account;
|
||||
let show_dialog_order_inquiry_id = e.currentTarget.dataset.show_dialog_order_inquiry_id;
|
||||
let show_dialog_inquiry_type = e.currentTarget.dataset.show_dialog_inquiry_type;
|
||||
console.log("tabShowtabShowtabShowtabShow");
|
||||
this.setData({
|
||||
show_dialog_from_account: show_dialog_from_account,
|
||||
show_dialog_order_inquiry_id: show_dialog_order_inquiry_id,
|
||||
show_dialog_inquiry_type: show_dialog_inquiry_type,
|
||||
show: true
|
||||
})
|
||||
},
|
||||
onClose(){
|
||||
console.log("onCloseonCloseonCloseonClose")
|
||||
this.setData({
|
||||
show: false
|
||||
})
|
||||
}
|
||||
})
|
||||
@@ -10,6 +10,7 @@
|
||||
"van-empty": "@vant/weapp/empty/index",
|
||||
"van-image": "@vant/weapp/image/index",
|
||||
"van-tab": "@vant/weapp/tab/index",
|
||||
"van-tabs": "@vant/weapp/tabs/index"
|
||||
"van-tabs": "@vant/weapp/tabs/index",
|
||||
"t-dialog": "tdesign-miniprogram/dialog/dialog"
|
||||
}
|
||||
}
|
||||
@@ -146,9 +146,10 @@
|
||||
color="#3CC7C0"
|
||||
title-active-color="#3CC7C0"
|
||||
border="{{true}}"
|
||||
id="tabs"
|
||||
>
|
||||
<van-tab title="在线问诊" name="1" wx:if="{{data_list_1.length > 0}}">
|
||||
<wenzhen-data
|
||||
<!-- <wenzhen-data
|
||||
name="{{ item.patient_name }}"
|
||||
sex="{{ item.patient_sex==1?'男':'女' }}"
|
||||
age="{{ item.patient_age }}"
|
||||
@@ -162,10 +163,40 @@
|
||||
note="{{ item.inquiry_status==3?'不接诊24小时后自动取消':'' }}"
|
||||
message_dot="{{item.message_dot}}"
|
||||
wx:for="{{ data_list_1 }}"
|
||||
/>
|
||||
/> -->
|
||||
|
||||
<!-- aa -->
|
||||
<view class="content" wx:for="{{ data_list_1 }}">
|
||||
<view class="content_1">
|
||||
<view class="name">
|
||||
<text style="font-size: 34rpx;color: #333;">就诊人:</text>
|
||||
{{item.patient_name}} {{item.patient_sex==1?'男':'女'}}|{{item.patient_age}}<t-badge dot="{{item.message_dot || item.inquiry_status==3}}" offset="{{ [-4, 4] }}" content="岁" />
|
||||
</view>
|
||||
<view class="date"> {{item.message_send_time}}</view>
|
||||
</view>
|
||||
<view class="content_2">{{item.last_message_content.Text}}</view>
|
||||
<view class="content_3">
|
||||
<view class="status">{{ item.inquiry_status==1?'待支付':item.inquiry_status==2?'待分配':item.inquiry_status==3?'待接诊':item.inquiry_status==4?'接诊中':item.inquiry_status==5?'已完成':item.inquiry_status==6?'已结束':item.inquiry_status==7?'已取消':'其他' }}</view>
|
||||
<view class="btn" wx:if="{{ item.inquiry_status == 3 }}">
|
||||
<van-button bind:click="go" data-url="/Pages/yishi/case/index?order_inquiry_id={{item.order_inquiry_id}}" plain custom-style="padding:0 35rpx; height:67rpx; border-radius: 10rpx;" color="#3CC7C0">查看病历</van-button>
|
||||
<van-button type="default"
|
||||
bindtap="tabShow"
|
||||
data-show_dialog_from_account="{{item.from_account}}"
|
||||
data-show_dialog_order_inquiry_id="{{item.order_inquiry_id}}"
|
||||
data-show_dialog_inquiry_type="{{item.inquiry_type}}"
|
||||
custom-style="padding:0 35rpx; height:67rpx; border-radius: 10rpx;margin-left:20rpx;" color="#3CC7C0">去接诊</van-button>
|
||||
</view>
|
||||
<view class="btn" wx:if="{{ item.inquiry_status >= 4 }}">
|
||||
<van-button bind:click="goChat" data-from_account="{{item.from_account}}" data-inquiry_type="{{item.inquiry_type}}" data-order_inquiry_id="{{item.order_inquiry_id}}" data-url="/Pages/yishi/chat/index" plain custom-style="padding:0 35rpx; height:67rpx; 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>
|
||||
<view class="content_4" wx:if="{{ item.inquiry_status == 3 }}">不接诊24小时后自动取消</view>
|
||||
</view>
|
||||
<!-- aa -->
|
||||
</van-tab>
|
||||
<van-tab title="快速问诊" name="2" wx:if="{{data_list_2.length > 0}}">
|
||||
<wenzhen-data
|
||||
<!-- <wenzhen-data
|
||||
name="{{ item.patient_name }}"
|
||||
sex="{{ item.patient_sex==1?'男':'女' }}"
|
||||
age="{{ item.patient_age }}"
|
||||
@@ -179,10 +210,37 @@
|
||||
note="{{ item.inquiry_status==3?'不接诊24小时后自动取消':'' }}"
|
||||
message_dot="{{item.message_dot}}"
|
||||
wx:for="{{ data_list_2 }}"
|
||||
/>
|
||||
/> -->
|
||||
|
||||
<view class="content" wx:for="{{ data_list_2 }}">
|
||||
<view class="content_1">
|
||||
<view class="name">
|
||||
<text style="font-size: 34rpx;color: #333;">就诊人:</text>
|
||||
{{item.patient_name}} {{item.patient_sex==1?'男':'女'}}|{{item.patient_age}}<t-badge dot="{{item.message_dot || item.inquiry_status==3}}" offset="{{ [-4, 4] }}" content="岁" />
|
||||
</view>
|
||||
<view class="date"> {{item.message_send_time}}</view>
|
||||
</view>
|
||||
<view class="content_2">{{item.last_message_content.Text}}</view>
|
||||
<view class="content_3">
|
||||
<view class="status">{{ item.inquiry_status==1?'待支付':item.inquiry_status==2?'待分配':item.inquiry_status==3?'待接诊':item.inquiry_status==4?'接诊中':item.inquiry_status==5?'已完成':item.inquiry_status==6?'已结束':item.inquiry_status==7?'已取消':'其他' }}</view>
|
||||
<view class="btn" wx:if="{{ item.inquiry_status == 3 }}">
|
||||
<van-button bind:click="go" data-url="/Pages/yishi/case/index?order_inquiry_id={{item.order_inquiry_id}}" plain custom-style="padding:0 35rpx; height:67rpx; border-radius: 10rpx;" color="#3CC7C0">查看病历</van-button>
|
||||
<van-button type="default" bindtap="tabShow"
|
||||
data-show_dialog_from_account="{{item.from_account}}"
|
||||
data-show_dialog_order_inquiry_id="{{item.order_inquiry_id}}"
|
||||
data-show_dialog_inquiry_type="{{item.inquiry_type}}"
|
||||
custom-style="padding:0 35rpx; height:67rpx; border-radius: 10rpx;margin-left:20rpx;" color="#3CC7C0">去接诊</van-button>
|
||||
</view>
|
||||
<view class="btn" wx:if="{{ item.inquiry_status >= 4 }}">
|
||||
<van-button bind:click="goChat" data-from_account="{{item.from_account}}" data-inquiry_type="{{item.inquiry_type}}" data-order_inquiry_id="{{item.order_inquiry_id}}" data-url="/Pages/yishi/chat/index" plain custom-style="padding:0 35rpx; height:67rpx; 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>
|
||||
<view class="content_4" wx:if="{{ item.inquiry_status == 3 }}">不接诊24小时后自动取消</view>
|
||||
</view>
|
||||
</van-tab>
|
||||
<van-tab title="公益问诊" name="3" wx:if="{{data_list_3.length > 0}}">
|
||||
<wenzhen-data
|
||||
<!-- <wenzhen-data
|
||||
name="{{ item.patient_name }}"
|
||||
sex="{{ item.patient_sex==1?'男':'女' }}"
|
||||
age="{{ item.patient_age }}"
|
||||
@@ -196,10 +254,37 @@
|
||||
note="{{ item.inquiry_status==3?'不接诊24小时后自动取消':'' }}"
|
||||
message_dot="{{item.message_dot}}"
|
||||
wx:for="{{ data_list_3 }}"
|
||||
/>
|
||||
/> -->
|
||||
|
||||
<view class="content" wx:for="{{ data_list_3 }}">
|
||||
<view class="content_1">
|
||||
<view class="name">
|
||||
<text style="font-size: 34rpx;color: #333;">就诊人:</text>
|
||||
{{item.patient_name}} {{item.patient_sex==1?'男':'女'}}|{{item.patient_age}}<t-badge dot="{{item.message_dot || item.inquiry_status==3}}" offset="{{ [-4, 4] }}" content="岁" />
|
||||
</view>
|
||||
<view class="date"> {{item.message_send_time}}</view>
|
||||
</view>
|
||||
<view class="content_2">{{item.last_message_content.Text}}</view>
|
||||
<view class="content_3">
|
||||
<view class="status">{{ item.inquiry_status==1?'待支付':item.inquiry_status==2?'待分配':item.inquiry_status==3?'待接诊':item.inquiry_status==4?'接诊中':item.inquiry_status==5?'已完成':item.inquiry_status==6?'已结束':item.inquiry_status==7?'已取消':'其他' }}</view>
|
||||
<view class="btn" wx:if="{{ item.inquiry_status == 3 }}">
|
||||
<van-button bind:click="go" data-url="/Pages/yishi/case/index?order_inquiry_id={{item.order_inquiry_id}}" plain custom-style="padding:0 35rpx; height:67rpx; border-radius: 10rpx;" color="#3CC7C0">查看病历</van-button>
|
||||
<van-button type="default" bindtap="tabShow"
|
||||
data-show_dialog_from_account="{{item.from_account}}"
|
||||
data-show_dialog_order_inquiry_id="{{item.order_inquiry_id}}"
|
||||
data-show_dialog_inquiry_type="{{item.inquiry_type}}"
|
||||
custom-style="padding:0 35rpx; height:67rpx; border-radius: 10rpx;margin-left:20rpx;" color="#3CC7C0">去接诊</van-button>
|
||||
</view>
|
||||
<view class="btn" wx:if="{{ item.inquiry_status >= 4 }}">
|
||||
<van-button bind:click="goChat" data-from_account="{{item.from_account}}" data-inquiry_type="{{item.inquiry_type}}" data-order_inquiry_id="{{item.order_inquiry_id}}" data-url="/Pages/yishi/chat/index" plain custom-style="padding:0 35rpx; height:67rpx; 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>
|
||||
<view class="content_4" wx:if="{{ item.inquiry_status == 3 }}">不接诊24小时后自动取消</view>
|
||||
</view>
|
||||
</van-tab>
|
||||
<van-tab title="问诊购药" name="4" wx:if="{{data_list_4.length > 0}}">
|
||||
<wenzhen-data
|
||||
<!-- <wenzhen-data
|
||||
name="{{ item.patient_name }}"
|
||||
sex="{{ item.patient_sex==1?'男':'女' }}"
|
||||
age="{{ item.patient_age }}"
|
||||
@@ -213,12 +298,48 @@
|
||||
note="{{ item.inquiry_status==3?'不接诊24小时后自动取消':'' }}"
|
||||
message_dot="{{item.message_dot}}"
|
||||
wx:for="{{ data_list_4 }}"
|
||||
/>
|
||||
/> -->
|
||||
|
||||
<view class="content" wx:for="{{ data_list_4 }}">
|
||||
<view class="content_1">
|
||||
<view class="name">
|
||||
<text style="font-size: 34rpx;color: #333;">就诊人:</text>
|
||||
{{item.patient_name}} {{item.patient_sex==1?'男':'女'}}|{{item.patient_age}}<t-badge dot="{{item.message_dot || item.inquiry_status==3}}" offset="{{ [-4, 4] }}" content="岁" />
|
||||
</view>
|
||||
<view class="date"> {{item.message_send_time}}</view>
|
||||
</view>
|
||||
<view class="content_2">{{item.last_message_content.Text}}</view>
|
||||
<view class="content_3">
|
||||
<view class="status">{{ item.inquiry_status==1?'待支付':item.inquiry_status==2?'待分配':item.inquiry_status==3?'待接诊':item.inquiry_status==4?'接诊中':item.inquiry_status==5?'已完成':item.inquiry_status==6?'已结束':item.inquiry_status==7?'已取消':'其他' }}</view>
|
||||
<view class="btn" wx:if="{{ item.inquiry_status == 3 }}">
|
||||
<van-button bind:click="go" data-url="/Pages/yishi/case/index?order_inquiry_id={{item.order_inquiry_id}}" plain custom-style="padding:0 35rpx; height:67rpx; border-radius: 10rpx;" color="#3CC7C0">查看病历</van-button>
|
||||
<van-button type="default" bindtap="tabShow"
|
||||
data-show_dialog_from_account="{{item.from_account}}"
|
||||
data-show_dialog_order_inquiry_id="{{item.order_inquiry_id}}"
|
||||
data-show_dialog_inquiry_type="{{item.inquiry_type}}"
|
||||
custom-style="padding:0 35rpx; height:67rpx; border-radius: 10rpx;margin-left:20rpx;" color="#3CC7C0">去接诊</van-button>
|
||||
</view>
|
||||
<view class="btn" wx:if="{{ item.inquiry_status >= 4 }}">
|
||||
<van-button bind:click="goChat" data-from_account="{{item.from_account}}" data-inquiry_type="{{item.inquiry_type}}" data-order_inquiry_id="{{item.order_inquiry_id}}" data-url="/Pages/yishi/chat/index" plain custom-style="padding:0 35rpx; height:67rpx; 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>
|
||||
<view class="content_4" wx:if="{{ item.inquiry_status == 3 }}">不接诊24小时后自动取消</view>
|
||||
</view>
|
||||
</van-tab>
|
||||
</van-tabs>
|
||||
</view>
|
||||
<view style="height: 200rpx;"></view>
|
||||
|
||||
|
||||
|
||||
<t-dialog
|
||||
visible="{{ show }}"
|
||||
title="温馨提示"
|
||||
close-on-overlay-click
|
||||
bind:close="onClose"
|
||||
content="为保障服务质量,请您查看患者病历后再去接诊"
|
||||
>
|
||||
<view slot="cancel-btn" class="dialog dialog_cancel_btn" bindtap="go" data-from_account="{{show_dialog_from_account}}" data-url="/Pages/yishi/case/index?order_inquiry_id={{show_dialog_order_inquiry_id}}" >去查看</view>
|
||||
<view slot="confirm-btn" class="dialog dialog_confirm_btn" bindtap="postDoctorInquiry" data-from_account="{{show_dialog_from_account}}" data-inquiry_type="{{show_dialog_inquiry_type}}" data-order_inquiry_id="{{show_dialog_order_inquiry_id}}" data-url="/Pages/yishi/chat/index" >去接诊</view>
|
||||
</t-dialog>
|
||||
</view>
|
||||
@@ -53,3 +53,88 @@ page{
|
||||
vertical-align: baseline !important;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
.content{
|
||||
background-color: #fff;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
margin-bottom: 20rpx;
|
||||
}
|
||||
.content_1,.content_3,.content_2{
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
margin: 20rpx 30rpx;
|
||||
align-items: center;
|
||||
}
|
||||
.content_1,.content_3{
|
||||
flex: 5;
|
||||
}
|
||||
.name{
|
||||
font-size: 30rpx;
|
||||
color: #666666;
|
||||
height: 50rpx;
|
||||
line-height: 50rpx;
|
||||
}
|
||||
.date{
|
||||
font-size: 30rpx;
|
||||
color: #999;
|
||||
}
|
||||
.content_2{
|
||||
background-color: #FAFAFA;
|
||||
font-size: 26rpx;
|
||||
color: #999999;
|
||||
min-height: 70rpx;
|
||||
padding: 10rpx 20rpx;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
display: block;
|
||||
line-height: 70rpx;
|
||||
}
|
||||
.status{
|
||||
font-size: 26rpx;
|
||||
color: #FA541C;
|
||||
flex: 1;
|
||||
}
|
||||
.status_end{
|
||||
color: #666666;
|
||||
}
|
||||
.btn{
|
||||
flex: 2;
|
||||
display: flex;
|
||||
justify-content: flex-end;
|
||||
}
|
||||
.content_4{
|
||||
flex: 5;
|
||||
font-size: 24rpx;
|
||||
color: #E34D59;
|
||||
justify-self:flex-end;
|
||||
text-align:right;
|
||||
display: flex;
|
||||
justify-content: flex-end;
|
||||
border-top: 1px solid #E3E4E5;
|
||||
align-items: center;
|
||||
margin: 0 30rpx;
|
||||
min-height: 70rpx;
|
||||
}
|
||||
.dialog{
|
||||
width: 50%;
|
||||
text-align: center;
|
||||
height: 100rpx;
|
||||
line-height: 100rpx;
|
||||
}
|
||||
.dialog_cancel_btn{
|
||||
border-top: 1px solid #E9E9E9;
|
||||
border-right: 1px solid #E9E9E9;
|
||||
}
|
||||
.dialog_confirm_btn{
|
||||
border-top: 1px solid #E9E9E9;
|
||||
color: #3CC7C0;
|
||||
}
|
||||
.t-badge__content-text {
|
||||
line-height: 70rpx !important;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user