优化聊天界面
This commit is contained in:
parent
5ba50e4e61
commit
9859b0cbea
@ -47,8 +47,8 @@ Page({
|
||||
api.wechatMobileLogin(params).then(response => {
|
||||
console.log(response);
|
||||
wx.setStorageSync('AUTH_TOKEN_'+usertype, response.data.token);
|
||||
wx.setStorageSync('user_id', response.data.user_id);
|
||||
wx.setStorageSync('client_user_id', response.data.client_user_id);
|
||||
wx.setStorageSync('user_id_'+usertype, response.data.user_id);
|
||||
wx.setStorageSync('client_user_id_'+usertype, response.data.client_user_id);
|
||||
app.globalData.config.userID = response.data.user_id;
|
||||
app.imInit();
|
||||
//跳转页面
|
||||
|
||||
@ -12,7 +12,7 @@ Page({
|
||||
sms: "",
|
||||
btn_msg: "获取验证码",
|
||||
btn_disabled: false,
|
||||
login_disabled: true,
|
||||
login_disabled: false,
|
||||
btn_color: "#ccc"
|
||||
},
|
||||
onChange(event) {
|
||||
@ -115,8 +115,8 @@ Page({
|
||||
api.mobileLogin(params).then(response => {
|
||||
console.log(response);
|
||||
wx.setStorageSync('AUTH_TOKEN_'+usertype, response.data.token);
|
||||
wx.setStorageSync('user_id', response.data.user_id);
|
||||
wx.setStorageSync('client_user_id', response.data.client_user_id);
|
||||
wx.setStorageSync('user_id_'+usertype, response.data.user_id);
|
||||
wx.setStorageSync('client_user_id_'+usertype, response.data.client_user_id);
|
||||
app.globalData.config.userID = response.data.user_id;
|
||||
app.imInit();
|
||||
wx.switchTab({
|
||||
|
||||
@ -36,8 +36,8 @@ Page({
|
||||
if (res.confirm) {
|
||||
console.log('用户点击确定')
|
||||
wx.setStorageSync('AUTH_TOKEN_'+usertype, "");
|
||||
wx.setStorageSync('user_id', "");
|
||||
wx.setStorageSync('client_user_id', "");
|
||||
wx.setStorageSync('user_id_'+usertype, "");
|
||||
wx.setStorageSync('client_user_id_'+usertype, "");
|
||||
app.go("/Pages/index/index");
|
||||
} else if (res.cancel) {
|
||||
console.log('用户点击取消')
|
||||
|
||||
@ -90,11 +90,11 @@ Page({
|
||||
case_text: "请您先多点执业认证"
|
||||
},
|
||||
],
|
||||
skeleton_loading: true,
|
||||
contactKeFu: false,
|
||||
jiesuan_dialog_show: false,
|
||||
jiesuan_dialog_visible: false,
|
||||
aa: 0
|
||||
funbox_height: 100,
|
||||
skeleton_loading: true
|
||||
},
|
||||
// 获取状态栏信息
|
||||
getMenuButtonBound() {
|
||||
@ -316,8 +316,8 @@ Page({
|
||||
let multi_point_status = this.data.info.multi_point_status;
|
||||
//绑定结算银行卡
|
||||
var is_bind_bank = this.data.info.is_bind_bank;
|
||||
|
||||
let userID = wx.getStorageSync('user_id');
|
||||
let usertype = wx.getStorageSync('usertype');
|
||||
let userID = wx.getStorageSync('user_id_'+usertype);
|
||||
wx.setStorageSync(userID+'_idcard_status', idcard_status);
|
||||
wx.setStorageSync(userID+'_iden_auth_status', iden_auth_status);
|
||||
wx.setStorageSync(userID+'_multi_point_status', multi_point_status);
|
||||
|
||||
@ -7,6 +7,7 @@
|
||||
"t-swiper": "tdesign-miniprogram/swiper/swiper",
|
||||
"t-badge": "tdesign-miniprogram/badge/badge",
|
||||
"t-dialog": "tdesign-miniprogram/dialog/dialog",
|
||||
"van-image": "@vant/weapp/image/index"
|
||||
"van-image": "@vant/weapp/image/index",
|
||||
"t-skeleton": "tdesign-miniprogram/skeleton/skeleton"
|
||||
}
|
||||
}
|
||||
@ -1,5 +1,3 @@
|
||||
|
||||
|
||||
<view class="container" id="container">
|
||||
<!-- 顶部背景 -->
|
||||
<view class="top_bk"></view>
|
||||
@ -8,39 +6,57 @@
|
||||
style="top:0;padding-top: {{stateHeight}}px;height: {{navHeight + 10}}px;line-height: {{navHeight}}px;">{{ title }}</view>
|
||||
<!-- 用户信息 -->
|
||||
<view class="info_box" style="margin-top: {{stateHeight+navHeight+10}}px;">
|
||||
|
||||
|
||||
<view class="info">
|
||||
<view class="info_top">
|
||||
<view class="info_photo" bindtap="go" data-url="/Pages/yishi/myinfo/index">
|
||||
<!-- 跳转我的信息 -->
|
||||
<t-avatar alt="头像" class="avatar" size="medium" image="{{info.avatar}}" />
|
||||
<t-avatar alt="头像" class="avatar" size="medium" image="{{info.avatar}}" wx:if="{{!skeleton_loading}}"/>
|
||||
<!-- 骨架屏 -->
|
||||
<t-skeleton theme="avatar" animation="gradient" loading="{{skeleton_loading}}" />
|
||||
</view>
|
||||
<view class="info_content">
|
||||
<view class="info_mobile">{{info.user_name}}</view>
|
||||
<view class="info_mobile" wx:if="{{!skeleton_loading}}">{{info.user_name}}</view>
|
||||
<t-skeleton theme="text" row-col="{{[1]}}" animation="gradient" loading="{{skeleton_loading}}" />
|
||||
</view>
|
||||
<view class="info_shiming" bindtap="go" data-url="{{shiming_status_url}}">
|
||||
<view class="info_shiming_status {{info.info_shiming_status}}">{{info.info_shiming_status_txt}}</view>
|
||||
<view class="info_shiming_status {{info.info_shiming_status}}" wx:if="{{!skeleton_loading}}">{{info.info_shiming_status_txt}}</view>
|
||||
<t-skeleton theme="text" row-col="{{[1]}}" animation="gradient" loading="{{skeleton_loading}}" />
|
||||
</view>
|
||||
</view>
|
||||
<view class="info_wenzhen">
|
||||
<view class="info_wenzhen_new" bindtap="go" data-url="/Pages/yishi/wenzhen_v2/wenzhen" data-moudle="0">新问诊:{{info.not_accepted_inquiry_num}}</view>
|
||||
<view class="info_wenzhen_ing" bindtap="go" data-url="/Pages/yishi/wenzhen_v2/wenzhen" data-moudle="1">接诊中:{{info.accepting_inquiry_num}}</view>
|
||||
<view class="info_wenzhen_new" wx:if="{{skeleton_loading}}">
|
||||
<t-skeleton theme="text" row-col="{{[{ width: '70%' }]}}" animation="gradient" loading="{{skeleton_loading}}" />
|
||||
</view>
|
||||
<view class="info_wenzhen_new" bindtap="go" data-url="/Pages/yishi/wenzhen_v2/wenzhen" data-moudle="0" wx:if="{{!skeleton_loading}}">
|
||||
新问诊:{{info.not_accepted_inquiry_num}}
|
||||
<t-skeleton theme="text" row-col="{{[1]}}" animation="gradient" loading="{{skeleton_loading}}" />
|
||||
</view>
|
||||
<view class="info_wenzhen_ing" bindtap="go" data-url="/Pages/yishi/wenzhen_v2/wenzhen" data-moudle="1" wx:if="{{!skeleton_loading}}">接诊中:{{info.accepting_inquiry_num}}</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="info_note" wx:if="{{info.show_info_note}}">
|
||||
<view class="haoping info_note_item">
|
||||
<view class="haoping info_note_item" wx:if="{{skeleton_loading}}">
|
||||
<t-skeleton theme="text" row-col="{{[{ width: '90%' }]}}" animation="gradient" loading="{{skeleton_loading}}" />
|
||||
</view>
|
||||
<view class="haoping info_note_item" wx:if="{{!skeleton_loading}}">
|
||||
<text class="info_note_txt">好评率</text><text class="info_note_num"> {{info.praise_rate}}%</text>
|
||||
</view>
|
||||
<view class="time info_note_item">
|
||||
<view class="time info_note_item" wx:if="{{!skeleton_loading}}">
|
||||
<text class="info_note_txt">响应时间</text><text class="info_note_num"> {{info.avg_response_time}} </text><text class="info_note_txt">分钟</text>
|
||||
</view>
|
||||
<view class="follow info_note_item">
|
||||
<view class="follow info_note_item" wx:if="{{!skeleton_loading}}">
|
||||
<text class="info_note_txt">关注数</text><text class="info_note_num"> {{info.number_of_fans}}</text>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<!-- 认证信息 -->
|
||||
<view class="renzhen">
|
||||
<view class="renzheng_left" bindtap="go" data-url="/Pages/yishi/identity/index">
|
||||
<view class="renzheng_left" wx:if="{{skeleton_loading}}">
|
||||
<t-skeleton theme="image" row-col="{{[1]}}" animation="gradient" loading="{{skeleton_loading}}" />
|
||||
</view>
|
||||
<view class="renzheng_left" bindtap="go" data-url="/Pages/yishi/identity/index" wx:if="{{!skeleton_loading}}">
|
||||
<view class="renzheng_content_left">
|
||||
<view class="renzheng_content_name">医师身份认证</view>
|
||||
<view class="renzheng_content_status">
|
||||
@ -56,8 +72,10 @@
|
||||
/>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<view class="renzheng_right" bindtap="gozhiye" data-url="/Pages/yishi/zhiye_identity/index">
|
||||
<view class="renzheng_right" wx:if="{{skeleton_loading}}">
|
||||
<t-skeleton theme="image" row-col="{{[1,1,1]}}" animation="gradient" loading="{{skeleton_loading}}" />
|
||||
</view>
|
||||
<view class="renzheng_right" bindtap="gozhiye" data-url="/Pages/yishi/zhiye_identity/index" wx:if="{{!skeleton_loading}}">
|
||||
<view class="renzheng_content_left">
|
||||
<view class="renzheng_content_name">多点执业认证</view>
|
||||
<view class="renzheng_content_status">
|
||||
@ -85,6 +103,7 @@
|
||||
bind:click="onTapAD"
|
||||
bind:change="onChangeAD"
|
||||
data-url="123"
|
||||
wx:if="{{!skeleton_loading}}"
|
||||
>
|
||||
</t-swiper>
|
||||
</view>
|
||||
@ -179,4 +198,6 @@
|
||||
confirm-button-color="#3CC7C0"
|
||||
confirm-button-open-type="contact"
|
||||
/>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
|
||||
|
||||
@ -27,8 +27,8 @@ Page({
|
||||
},
|
||||
});
|
||||
top = wx.getMenuButtonBoundingClientRect().top - stateHeight; // 获取top值
|
||||
console.log('navHeight', navHeight);
|
||||
console.log('top', top);
|
||||
// console.log('navHeight', navHeight);
|
||||
// console.log('top', top);
|
||||
this.setData({
|
||||
// navHeight: navHeight + top * 2, // 导航栏高度
|
||||
navHeight, // 导航栏高度
|
||||
@ -37,7 +37,7 @@ Page({
|
||||
},
|
||||
|
||||
onShow: function () {
|
||||
console.log("onshow ");
|
||||
// console.log("onshow ");
|
||||
if (typeof this.getTabBar === 'function' && this.getTabBar()) {
|
||||
this.getTabBar().setData({
|
||||
active: 2 //数字是当前页面在tabbar的索引,如我的查询页索引是2,因此这边为2,同理首页就为0,审批页面为1
|
||||
@ -46,7 +46,7 @@ Page({
|
||||
this.getMenuButtonBound();
|
||||
},
|
||||
onLoad(){
|
||||
console.log("my onLoad");
|
||||
// console.log("my onLoad");
|
||||
//获取个人中心数据
|
||||
api.getDoctorCenter().then(response => {
|
||||
this.setData({
|
||||
|
||||
@ -35,7 +35,8 @@ Page({
|
||||
}).catch(errors => {console.error(errors);})
|
||||
},
|
||||
onShow(){
|
||||
let user_id = wx.getStorageSync("user_id");
|
||||
let usertype = wx.getStorageSync('usertype');
|
||||
let user_id = wx.getStorageSync("user_id_"+usertype);
|
||||
let is_bind_bank = wx.getStorageSync(user_id+'_is_bind_bank');
|
||||
this.setData({
|
||||
is_bind_bank: is_bind_bank
|
||||
@ -51,8 +52,14 @@ Page({
|
||||
if (res.confirm) {
|
||||
console.log('用户点击确定')
|
||||
wx.setStorageSync('AUTH_TOKEN_'+usertype, "");
|
||||
wx.setStorageSync('user_id', "");
|
||||
wx.setStorageSync('client_user_id', "");
|
||||
wx.setStorageSync('user_id_'+usertype, "");
|
||||
wx.setStorageSync('client_user_id_'+usertype, "");
|
||||
let promise = wx.$TUIKit.logout();
|
||||
promise.then(function(imResponse) {
|
||||
console.log(imResponse.data); // 登出成功
|
||||
}).catch(function(imError) {
|
||||
console.warn('logout error:', imError);
|
||||
});
|
||||
app.go("/Pages/index/index");
|
||||
} else if (res.cancel) {
|
||||
console.log('用户点击取消')
|
||||
|
||||
@ -19,11 +19,14 @@ Page({
|
||||
conversationList: [],
|
||||
message_inquiry_type: 1,
|
||||
system_notice_unreadnnum: "",
|
||||
service_notice_unreadnnum: ""
|
||||
service_notice_unreadnnum: "",
|
||||
hasOnShow: false
|
||||
},
|
||||
onLoad() {
|
||||
console.log("wenzhen onload");
|
||||
let userID = wx.getStorageSync('user_id');
|
||||
let usertype = wx.getStorageSync('usertype');
|
||||
let userID = wx.getStorageSync('user_id_'+usertype);
|
||||
wx.$TUIKit.on(wx.$TUIKitTIM.EVENT.MESSAGE_RECEIVED, this.$onMessageReceived, this);
|
||||
setInterval(() => {
|
||||
let system_notice_unreadnnum = wx.getStorageSync(userID+"_system_notice_unreadnnum");
|
||||
let service_notice_unreadnnum = wx.getStorageSync(userID+"_service_notice_unreadnnum");
|
||||
@ -35,13 +38,28 @@ Page({
|
||||
},
|
||||
onShow: function () {
|
||||
console.log("onShow from wenzhen V2")
|
||||
if(this.data.hasOnShow){
|
||||
return;
|
||||
}
|
||||
if (typeof this.getTabBar === 'function' && this.getTabBar()) {
|
||||
this.getTabBar().setData({
|
||||
active: 1 //数字是当前页面在tabbar的索引,如我的查询页索引是2,因此这边为2,同理首页就为0,审批页面为1
|
||||
})
|
||||
}
|
||||
this.getConversationList();
|
||||
wx.$TUIKit.on(wx.$TUIKitTIM.EVENT.MESSAGE_RECEIVED, this.$onMessageReceived, this);
|
||||
//避免onshow加载多次
|
||||
this.setData({
|
||||
hasOnShow: true
|
||||
})
|
||||
},
|
||||
onHide(){
|
||||
console.log("onHideonHide from wenzhen")
|
||||
this.setData({hasOnShow: false})
|
||||
},
|
||||
onUnload(){
|
||||
console.log("onUnload from wenzhen")
|
||||
this.setData({hasOnShow: false})
|
||||
// wx.$TUIKit.off(wx.$TUIKitTIM.EVENT.MESSAGE_RECEIVED, this.$onMessageReceived);
|
||||
},
|
||||
getConversationList(){
|
||||
wx.$TUIKit.getConversationList().then((imResponse) => {
|
||||
@ -234,6 +252,11 @@ Page({
|
||||
session_list.push(session_data_list_4);
|
||||
session_list.push(session_data_list_5);
|
||||
|
||||
let usertype = wx.getStorageSync('usertype');
|
||||
let userID = wx.getStorageSync('user_id_'+usertype);
|
||||
let wenzhen_info = 0;
|
||||
let message_inquiry_type = this.data.message_inquiry_type;
|
||||
|
||||
this.data.conversationList.forEach(item => {
|
||||
let conversationID = item.conversationID;
|
||||
if(conversationID == "C2Cadministrator") return;//如果是管理员消息直接跳过
|
||||
@ -249,8 +272,11 @@ Page({
|
||||
let inquiry_type = cloudCustomDataJson.inquiry_type;
|
||||
if(!inquiry_type) return;
|
||||
if(inquiry_type > 4) return;
|
||||
if(inquiry_type < message_inquiry_type){
|
||||
message_inquiry_type = inquiry_type;
|
||||
}
|
||||
let patient_family_data = cloudCustomDataJson.patient_family_data;
|
||||
if(!patient_family_data) return;
|
||||
if(patient_family_data == undefined) return;
|
||||
console.log("patient_family_data: ", patient_family_data);
|
||||
let session_item = {};
|
||||
session_item.inquiry_status = item.inquiry_status;//订单状态暂无
|
||||
@ -267,17 +293,23 @@ Page({
|
||||
session_item.from_account = userProfile.userID;
|
||||
let unreadCount = item.unreadCount;
|
||||
if(unreadCount > 0){
|
||||
wenzhen_info = wenzhen_info + unreadCount;
|
||||
session_item.message_dot = true;
|
||||
}else{
|
||||
session_item.message_dot = false;
|
||||
}
|
||||
session_list[inquiry_type - 1].push(session_item);
|
||||
})
|
||||
|
||||
if(wenzhen_info == 0) wenzhen_info = "";
|
||||
wx.setStorageSync(userID+'_wenzhen_info', wenzhen_info);
|
||||
|
||||
this.setData({
|
||||
data_list_1: session_data_list_1,
|
||||
data_list_2: session_data_list_2,
|
||||
data_list_3: session_data_list_3,
|
||||
data_list_4: session_data_list_4,
|
||||
message_inquiry_type: message_inquiry_type
|
||||
})
|
||||
|
||||
if(this.data.data_list_1.length == 0 && this.data.data_list_2.length == 0 && this.data.data_list_3.length == 0 && this.data.data_list_4.length == 0 && this.data.data_list_5.length == 0){
|
||||
|
||||
@ -78,6 +78,7 @@ Component({
|
||||
},
|
||||
parseCustom(message) {
|
||||
const { BUSINESS_ID_TEXT } = constant;
|
||||
const { GDXZ_CUSTOM_MSEEAGE } = constant;
|
||||
// 群消息解析
|
||||
if (message.payload.data === BUSINESS_ID_TEXT.CREATE_GROUP) {
|
||||
const renderDom = [{
|
||||
@ -118,6 +119,36 @@ Component({
|
||||
}];
|
||||
return renderDom;
|
||||
}
|
||||
// 1:消息内页横条
|
||||
if (customMessage.message_type === GDXZ_CUSTOM_MSEEAGE.TRABECULA) {
|
||||
const renderDom = [{
|
||||
type: 'trabecula',
|
||||
title: customMessage.title,
|
||||
desc: customMessage.desc,
|
||||
}];
|
||||
return renderDom;
|
||||
}
|
||||
// 2:订单结束评价弹出
|
||||
if (customMessage.message_type === GDXZ_CUSTOM_MSEEAGE.ORDER_EVALUATION) {
|
||||
let data = customMessage.data;
|
||||
const renderDom = [{
|
||||
type: 'order_evaluation',
|
||||
order_inquiry_id: data.order_inquiry_id
|
||||
}];
|
||||
return renderDom;
|
||||
}
|
||||
// 6:处方开具成功
|
||||
if (customMessage.message_type === GDXZ_CUSTOM_MSEEAGE.PRESCRIBE) {
|
||||
console.log("处方");
|
||||
let data = customMessage.data;
|
||||
const renderDom = [{
|
||||
type: 'prescribe',
|
||||
product_name: data.product_name,
|
||||
order_prescription_id: data.order_prescription_id,
|
||||
pharmacist_verify_time: data.pharmacist_verify_time.substring(0,10),
|
||||
}];
|
||||
return renderDom;
|
||||
}
|
||||
} catch (error) {
|
||||
}
|
||||
// 客服咨询
|
||||
|
||||
@ -1,4 +1,6 @@
|
||||
{
|
||||
"component": true,
|
||||
"usingComponents": {}
|
||||
"usingComponents": {
|
||||
"van-rate": "@vant/weapp/rate/index"
|
||||
}
|
||||
}
|
||||
@ -40,5 +40,33 @@
|
||||
<view wx:if="{{renderDom[0].type ==='notSupport'}}" class="message-body-span text-message" >
|
||||
<view class="message-body-span-text">{{renderDom[0].text}}</view>
|
||||
</view>
|
||||
<!-- 自定义横条样式 -->
|
||||
<view wx:if="{{renderDom[0].type==='trabecula'}}" class="gdxz_custom_trabecula_message">
|
||||
<view class="gdxz_custom_message_title">{{renderDom[0].title}}</view>
|
||||
<view class="gdxz_custom_message_desc">{{renderDom[0].desc}}</view>
|
||||
</view>
|
||||
<!-- 自定义评价样式 -->
|
||||
<view wx:if="{{renderDom[0].type==='order_evaluation'}}" class="gdxz_custom_order_evaluation_message" bindtap="showPop">
|
||||
<view class="evaluation_title">请您对本次问诊服务进行评价</view>
|
||||
<view class="evaluation_ratebox">
|
||||
<van-rate disabled value="{{0}}" size="40rpx" gutter="46rpx" color="#ffd21e" void-icon="star" void-color="#e7e7e7" readonlygutter="20"/>
|
||||
</view>
|
||||
<view class="evaluation_button">点击评价</view>
|
||||
</view>
|
||||
<!-- 自定义开处方样式 -->
|
||||
<view wx:if="{{renderDom[0].type==='prescribe'}}" class="gdxz_custom_order_prescribe_message" bindtap="toBuy">
|
||||
<view class="prescribe_title">
|
||||
处方已开具
|
||||
</view>
|
||||
<view class="prescribe_box">
|
||||
<view class="prescribe_box_top">
|
||||
<view class="prescribe_box_top_product_name"><text style="color: #999;"> RP:</text>{{renderDom[0].product_name}}</view>
|
||||
<view class="prescribe_box_top_pharmacist_verify_time"><text style="color: #999;">开方日期:</text> {{renderDom[0].pharmacist_verify_time}}</view>
|
||||
</view>
|
||||
<view class="prescribe_box_bottom" data-order_prescription_id="{{renderDom[0].order_prescription_id}}">
|
||||
<view class="prescribe_box_buy">去查看</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
|
||||
@ -120,3 +120,116 @@ line-height: 42rpx;
|
||||
letter-spacing: 0;
|
||||
margin-bottom: 12rpx;
|
||||
}
|
||||
|
||||
/* 自定义评价样式 */
|
||||
/* 横条样式 */
|
||||
.gdxz_custom_trabecula_message{
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
width: 100vw;
|
||||
}
|
||||
.gdxz_custom_message_title{
|
||||
flex: 1;
|
||||
display: flex;
|
||||
max-width: 92vw;
|
||||
justify-content: center;
|
||||
background-color: #E1E1E1;
|
||||
padding: 5rpx 40rpx;
|
||||
font-size: 28rpx;
|
||||
border-radius: 5rpx;
|
||||
}
|
||||
.gdxz_custom_message_desc{
|
||||
margin-top: 30rpx;
|
||||
display: flex;
|
||||
max-width: 92vw;
|
||||
letter-spacing: 2rpx;
|
||||
justify-content: center;
|
||||
color: #666666;
|
||||
font-size: 24rpx;
|
||||
}
|
||||
/* 评价样式 */
|
||||
.gdxz_custom_order_evaluation_message{
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
flex-direction: column;
|
||||
width: 80vw;
|
||||
margin-right: 10vw;
|
||||
border-radius: 10px;
|
||||
background-color: #ffffff;
|
||||
height: 250rpx;
|
||||
overflow: hidden;
|
||||
box-shadow: 0 0 10px 10px rgba(143, 142, 142, 0.2);
|
||||
}
|
||||
.evaluation_title{
|
||||
flex: 1;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
font-size: 28rpx;
|
||||
}
|
||||
.evaluation_ratebox{
|
||||
flex: 1;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items:baseline;
|
||||
}
|
||||
.evaluation_button{
|
||||
flex: 1;
|
||||
background-color: rgb(226, 247, 247);
|
||||
color: #3CC7C0;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
font-size: 34rpx;
|
||||
}
|
||||
/* 开具处方样式 */
|
||||
.gdxz_custom_order_prescribe_message{
|
||||
width: 60vw;
|
||||
position: relative;
|
||||
border-radius: 10px 10px 10px 10px;
|
||||
background: rgb(212, 239, 241);
|
||||
border: 1rpx solid #1ACAD3;
|
||||
/* background: rgb(255, 255, 255);
|
||||
border: 1rpx solid #E7E7E7; */
|
||||
}
|
||||
.gdxz_custom_order_prescribe_message::after{
|
||||
content:'';
|
||||
position: absolute;
|
||||
top: 35rpx;
|
||||
right: -19rpx;
|
||||
transform: translate(-50%,-50%) rotate(-135deg);
|
||||
width: 16rpx;
|
||||
height: 16rpx;
|
||||
background: rgb(212, 239, 241);
|
||||
border: 1rpx solid #1ACAD3;
|
||||
/* background: rgb(255, 255, 255);
|
||||
border: 1rpx solid #E7E7E7; */
|
||||
border-style: none none solid solid;
|
||||
}
|
||||
.prescribe_title{
|
||||
font-size: 34rpx;
|
||||
border-bottom: 1px solid #E7E7E7;
|
||||
margin: 0 20rpx;
|
||||
padding: 20rpx 0;
|
||||
}
|
||||
.prescribe_box{
|
||||
margin: 0 20rpx;
|
||||
padding: 20rpx 0;
|
||||
font-size: 28rpx;
|
||||
}
|
||||
.prescribe_box_top_pharmacist_verify_time{
|
||||
margin-top: 20rpx;
|
||||
}
|
||||
.prescribe_box_bottom{
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
}
|
||||
.prescribe_box_buy{
|
||||
margin: 20rpx 20rpx 0 20rpx;
|
||||
background-color: #3CC7C0;
|
||||
color: #fff;
|
||||
padding: 15rpx 30rpx;
|
||||
border-radius: 40rpx;
|
||||
font-size: 30rpx;
|
||||
}
|
||||
@ -250,6 +250,10 @@ Component({
|
||||
this.setData({
|
||||
displayFlag: targetFlag,
|
||||
});
|
||||
var myEventDetail = {} // detail对象,提供给事件监听函数
|
||||
myEventDetail.displayFlag = targetFlag;
|
||||
var myEventOption = {} // 触发事件的选项
|
||||
this.triggerEvent('myhandleExtensions', myEventDetail, myEventOption)
|
||||
},
|
||||
|
||||
error(e) {
|
||||
@ -392,7 +396,8 @@ Component({
|
||||
app.go("/Pages/yishi/case/index?order_inquiry_id="+this.data.order_inquiry_id)
|
||||
break;
|
||||
case '11'://在线开方
|
||||
let userID = wx.getStorageSync('user_id');
|
||||
let usertype = wx.getStorageSync('usertype');
|
||||
let userID = wx.getStorageSync('user_id_'+usertype);
|
||||
let multi_point_status = wx.getStorageSync(userID+'_multi_point_status');
|
||||
if(multi_point_status == 1){
|
||||
app.go("/Pages/yishi/onlinechufang/index?order_inquiry_id="+this.data.order_inquiry_id)
|
||||
|
||||
@ -43,6 +43,7 @@
|
||||
flex: 2;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
}
|
||||
.TUI-message-input-main {
|
||||
min-height: 78rpx;
|
||||
@ -108,6 +109,8 @@
|
||||
justify-content: center;
|
||||
border-radius: 10rpx;
|
||||
color: #fff;
|
||||
max-height: 200rpx;
|
||||
padding: 20rpx 0;
|
||||
}
|
||||
.TUI-sendMessage-btn-input{
|
||||
background-color: #3CC7C0;
|
||||
|
||||
@ -1,8 +1,7 @@
|
||||
import dayjs from '../../../../utils/dayjs';
|
||||
import logger from '../../../../utils/logger';
|
||||
import constant from '../../../../utils/constant';
|
||||
import { API } from './../../../../../utils/network/api'
|
||||
const api = new API()
|
||||
const { GDXZ_CUSTOM_MSEEAGE } = constant;
|
||||
// eslint-disable-next-line no-undef
|
||||
const app = getApp();
|
||||
Component({
|
||||
@ -87,7 +86,6 @@ Component({
|
||||
errorMessage: {},
|
||||
errorMessageID: '',
|
||||
typingMessage: {},
|
||||
dialog_visible: false,
|
||||
|
||||
},
|
||||
|
||||
@ -133,26 +131,7 @@ Component({
|
||||
},
|
||||
|
||||
methods: {
|
||||
//结束问诊
|
||||
putDoctorInquiryFinish() {
|
||||
this.setData({
|
||||
dialog_visible: true
|
||||
})
|
||||
},
|
||||
cancelDialog(){
|
||||
this.setData({
|
||||
dialog_visible: false
|
||||
})
|
||||
},
|
||||
confirmDialog(){
|
||||
api.putDoctorInquiryFinish({order_inquiry_id: this.data.order_inquiry_id}).then(response => {
|
||||
console.log(response);
|
||||
|
||||
}).catch(errors => {console.error(errors);})
|
||||
this.setData({
|
||||
dialog_visible: false
|
||||
})
|
||||
},
|
||||
|
||||
// 刷新消息列表
|
||||
refresh() {
|
||||
if (this.data.isCompleted) {
|
||||
@ -171,6 +150,8 @@ Component({
|
||||
},
|
||||
// 获取消息列表
|
||||
getMessageList(conversation) {
|
||||
|
||||
|
||||
if (!this.data.isCompleted) {
|
||||
wx.$TUIKit.getMessageList({
|
||||
conversationID: conversation.conversationID,
|
||||
@ -183,7 +164,12 @@ Component({
|
||||
let HMM_messageList = HMM_data.messageList;
|
||||
HMM_messageList.forEach(item => {
|
||||
let HMM_type = item.type;
|
||||
if(HMM_type == "TIMCustomElem") return;
|
||||
console.log(item)
|
||||
//去除自定义消息
|
||||
// if(HMM_type == "TIMCustomElem") return;
|
||||
let show_avatar = this.checkShowAvatar(item);
|
||||
item.show_avatar = show_avatar;
|
||||
|
||||
HMM_messageList_del.push(item);
|
||||
})
|
||||
HMM_data.messageList = HMM_messageList_del;
|
||||
@ -200,6 +186,18 @@ Component({
|
||||
});
|
||||
}
|
||||
},
|
||||
checkShowAvatar(message){
|
||||
|
||||
let type = message.type;
|
||||
let show_avatar = true;
|
||||
if(type == "TIMCustomElem"){
|
||||
const customMessage = JSON.parse(message.payload.data);
|
||||
if(customMessage.message_type != GDXZ_CUSTOM_MSEEAGE.PRESCRIBE){
|
||||
show_avatar = false;
|
||||
}
|
||||
}
|
||||
return show_avatar;
|
||||
},
|
||||
// 历史消息渲染
|
||||
$handleMessageRender(messageList, currentMessageList) {
|
||||
this.showHistoryMessageTime(currentMessageList);
|
||||
@ -246,6 +244,7 @@ Component({
|
||||
// 收到的消息
|
||||
$onMessageReceived(value) {
|
||||
const message = value.data[0];
|
||||
message.show_avatar = this.checkShowAvatar(message);
|
||||
wx.$TUIKit.setMessageRead({ conversationID: this.data.conversation.conversationID }).then(() => {
|
||||
logger.log('| MessageList | setMessageRead | ok');
|
||||
});
|
||||
@ -315,6 +314,9 @@ Component({
|
||||
},
|
||||
// 自己的消息上屏
|
||||
updateMessageList(message) {
|
||||
|
||||
//自己的消息有头像
|
||||
message.show_avatar = this.checkShowAvatar(message);
|
||||
if (message.conversationID !== this.data.conversation.conversationID) return;
|
||||
wx.$TUIKit.setMessageRead({ conversationID: this.data.conversation.conversationID }).then(() => {
|
||||
logger.log('| MessageList | setMessageRead | ok');
|
||||
|
||||
@ -12,7 +12,6 @@
|
||||
"FaceMessage": "../MessageElements/FaceMessage/index",
|
||||
"FileMessage": "../MessageElements/FileMessage/index",
|
||||
"MergerMessage": "../MessageElements/MergerMessage/index",
|
||||
"RevokeMessage": "../MessageElements/RevokeMessage/index",
|
||||
"t-dialog": "tdesign-miniprogram/dialog/dialog"
|
||||
"RevokeMessage": "../MessageElements/RevokeMessage/index"
|
||||
}
|
||||
}
|
||||
@ -34,7 +34,7 @@
|
||||
</view>
|
||||
<TipMessage wx:if="{{item.type === 'TIMGroupTipElem'}}" message="{{item}}"/>
|
||||
<view wx:if="{{item.type !== 'TIMGroupTipElem'}}" class="{{item.flow === 'out' ? 't-self-message':'t-recieve-message'}}" >
|
||||
<image class="t-message-avatar" wx:if="{{item.flow === 'in'}}" src="{{item.avatar || 'https://gdxz-hospital.oss-cn-chengdu.aliyuncs.com/applet/doctor/static/images/default_photo.png'}}" data-value="{{item}}" bindtap="getMemberProfile" />
|
||||
<image class="t-message-avatar" wx:if="{{item.flow === 'in' && item.show_avatar }}" src="{{item.avatar || 'https://gdxz-hospital.oss-cn-chengdu.aliyuncs.com/applet/doctor/static/images/default_photo.png'}}" data-value="{{item}}" bindtap="getMemberProfile" />
|
||||
<view class="read-receipts" wx:if="{{conversation.type === 'C2C' && item.flow==='out' }}">
|
||||
<!-- <view wx:if="{{item.isPeerRead}}" >已读</view>
|
||||
<view wx:else>未读</view> -->
|
||||
@ -52,7 +52,7 @@
|
||||
<FileMessage wx:if="{{item.type === 'TIMFileElem'}}" message="{{item}}" isMine="{{item.flow === 'out'}}"/>
|
||||
<MergerMessage wx:if="{{item.type === 'TIMRelayElem'}}" message="{{item}}" isMine="{{item.flow === 'out'}}"/>
|
||||
</view>
|
||||
<image class="t-message-avatar" wx:if="{{item.flow === 'out'}}" src="{{item.avatar || 'https://gdxz-hospital.oss-cn-chengdu.aliyuncs.com/applet/doctor/static/images/default_photo.png'}}" data-value="{{item}}" bindtap="getMemberProfile"/>
|
||||
<image class="t-message-avatar" wx:if="{{item.flow === 'out' && item.show_avatar }}" src="{{item.avatar || 'https://gdxz-hospital.oss-cn-chengdu.aliyuncs.com/applet/doctor/static/images/default_photo.png'}}" data-value="{{item}}" bindtap="getMemberProfile"/>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
@ -80,15 +80,4 @@
|
||||
</view>
|
||||
<wxs src = './concat.wxs' module = 'concat'/>
|
||||
|
||||
<t-dialog
|
||||
visible="{{ dialog_visible }}"
|
||||
title="温馨提示"
|
||||
content="您确认结束问诊?"
|
||||
>
|
||||
<view slot="cancel-btn" class="dialog dialog_cancel_btn" bindtap="cancelDialog">
|
||||
取消
|
||||
</view>
|
||||
<view slot="confirm-btn" class="dialog dialog_confirm_btn" bindtap="confirmDialog">
|
||||
确定
|
||||
</view>
|
||||
</t-dialog>
|
||||
|
||||
|
||||
@ -252,17 +252,3 @@
|
||||
padding-left: 5px;
|
||||
color: blue;
|
||||
}
|
||||
.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;
|
||||
}
|
||||
@ -8,11 +8,11 @@ const app = getApp();
|
||||
|
||||
const inputStyle = `
|
||||
--padding: 0px;
|
||||
z-index: 9999999;
|
||||
`;
|
||||
|
||||
let newInputStyle = `
|
||||
--padding: 0px
|
||||
--padding: 0px;
|
||||
position: absolute;
|
||||
`;
|
||||
|
||||
const setNewInputStyle = (number) => {
|
||||
@ -118,6 +118,7 @@ Component({
|
||||
viewData: {
|
||||
style: inputStyle,
|
||||
},
|
||||
input_area_style:"",
|
||||
KeyboardHeight: 0,
|
||||
showTips: false,
|
||||
showGroupTips: false,
|
||||
@ -127,13 +128,35 @@ Component({
|
||||
title: '', //导航栏 中间的标题
|
||||
},
|
||||
baseInfo: {},
|
||||
navbar_height: 0
|
||||
navbar_height: 0,
|
||||
dialog_visible: false,
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 组件的方法列表
|
||||
*/
|
||||
methods: {
|
||||
//结束问诊
|
||||
putDoctorInquiryFinish() {
|
||||
this.setData({
|
||||
dialog_visible: true
|
||||
})
|
||||
},
|
||||
cancelDialog(){
|
||||
this.setData({
|
||||
dialog_visible: false
|
||||
})
|
||||
},
|
||||
confirmDialog(){
|
||||
api.putDoctorInquiryFinish({order_inquiry_id: this.data.order_inquiry_id}).then(response => {
|
||||
console.log(response);
|
||||
|
||||
}).catch(errors => {console.error(errors);})
|
||||
this.setData({
|
||||
dialog_visible: false
|
||||
})
|
||||
},
|
||||
//获取问诊订单消息内页基础数据
|
||||
getInquiryMessageBasic() {
|
||||
console.log("order_inquiry_id: ", this.data.order_inquiry_id);
|
||||
@ -222,18 +245,41 @@ Component({
|
||||
resendMessage(event) {
|
||||
this.selectComponent('#MessageInput').onInputValueChange(event);
|
||||
},
|
||||
myhandleExtensions(e){
|
||||
console.log("myhandleExtensionsmyhandleExtensions: ", e);
|
||||
let displayFlag = e.detail.displayFlag;
|
||||
if(displayFlag){
|
||||
this.setData({
|
||||
input_area_style: "position: absolute; bottom: 30px;"
|
||||
})
|
||||
}else{
|
||||
this.setData({
|
||||
input_area_style: ""
|
||||
})
|
||||
}
|
||||
},
|
||||
// 监听键盘,获取焦点时将输入框推到键盘上方
|
||||
pullKeysBoards(event) {
|
||||
setNewInputStyle(event.detail.event.detail.height);
|
||||
this.setData({
|
||||
'viewData.style': newInputStyle,
|
||||
input_area_style: "position: absolute; bottom: 30px;"
|
||||
});
|
||||
},
|
||||
// 监听键盘,失去焦点时收起键盘
|
||||
downKeysBoards(event) {
|
||||
this.setData({
|
||||
'viewData.style': inputStyle,
|
||||
});
|
||||
console.log(event)
|
||||
let value = event.detail.event.detail.value;
|
||||
if(value){
|
||||
this.setData({
|
||||
'viewData.style': inputStyle,
|
||||
});
|
||||
}else{
|
||||
this.setData({
|
||||
'viewData.style': inputStyle,
|
||||
input_area_style: ""
|
||||
});
|
||||
}
|
||||
},
|
||||
typing(event) {
|
||||
const { STRING_TEXT, FEAT_NATIVE_CODE } = constant;
|
||||
|
||||
@ -4,7 +4,8 @@
|
||||
"MessageList": "./components/MessageList/index",
|
||||
"MessageInput": "./components/MessageInput/index",
|
||||
"TUIGroup": "../TUIGroup/index",
|
||||
"te-nav-bar": "/commpents/te_navbar"
|
||||
"te-nav-bar": "/commpents/te_navbar",
|
||||
"t-dialog": "tdesign-miniprogram/dialog/dialog"
|
||||
},
|
||||
"disableScroll":true
|
||||
}
|
||||
@ -23,20 +23,32 @@
|
||||
<span class="report" bindtap="handleReport">点此投诉</span>
|
||||
</view> -->
|
||||
<!-- </view> -->
|
||||
<scroll-view class="message-list" bindtap="triggerClose">
|
||||
<!-- <scroll-view class="message-list" bindtap="triggerClose"> -->
|
||||
<MessageList id="MessageList" conversation="{{conversation}}" unreadCount="{{unreadCount}}" bind:changeMemberCount="changeMemberCount" bind:resendMessage="resendMessage" bind:typing="typing" order_inquiry_id="{{order_inquiry_id}}"></MessageList>
|
||||
</scroll-view>
|
||||
<!-- </scroll-view> -->
|
||||
</view>
|
||||
<view class="group-profile">
|
||||
<TUIGroup id="TUIGroup" wx:if="{{isShow}}" conversation="{{conversation}}" bind:groupCall="groupCall" bind:showConversationList="showConversationList"></TUIGroup>
|
||||
</view>
|
||||
<view class="input-area">
|
||||
<view class="input-area" style="{{input_area_style}}">
|
||||
<view class="message-input" style="{{viewData.style}}" wx:if="{{showChat}}">
|
||||
<MessageInput id="MessageInput" inquiry_type="{{inquiry_type}}" order_inquiry_id="{{order_inquiry_id}}" conversation="{{conversation}}" hasCallKit="{{hasCallKit}}" bind:sendMessage="sendMessage" bind:downKeysBoards="downKeysBoards" bind:pullKeysBoards="pullKeysBoards" bind:showMessageErrorImage="showMessageErrorImage"
|
||||
<MessageInput bind:myhandleExtensions="myhandleExtensions" id="MessageInput" inquiry_type="{{inquiry_type}}" order_inquiry_id="{{order_inquiry_id}}" conversation="{{conversation}}" hasCallKit="{{hasCallKit}}" bind:sendMessage="sendMessage" bind:downKeysBoards="downKeysBoards" bind:pullKeysBoards="pullKeysBoards" bind:showMessageErrorImage="showMessageErrorImage"
|
||||
bind:handleCall="handleCall" ></MessageInput>
|
||||
</view>
|
||||
</view>
|
||||
<view style="height: 30px;position: fixed;bottom: 0;width: 100%;background-color: #fff;">
|
||||
<view style="height: 40px;position: fixed;bottom: 0;width: 100%;background-color: #fff;">
|
||||
|
||||
</view>
|
||||
</view>
|
||||
<t-dialog
|
||||
visible="{{ dialog_visible }}"
|
||||
title="温馨提示"
|
||||
content="您确认结束问诊?"
|
||||
>
|
||||
<view slot="cancel-btn" class="dialog dialog_cancel_btn" bindtap="cancelDialog">
|
||||
取消
|
||||
</view>
|
||||
<view slot="confirm-btn" class="dialog dialog_confirm_btn" bindtap="confirmDialog">
|
||||
确定
|
||||
</view>
|
||||
</t-dialog>
|
||||
@ -96,10 +96,10 @@
|
||||
top: 246rpx;
|
||||
}
|
||||
.input-area {
|
||||
position: absolute;
|
||||
bottom: 20px;
|
||||
position: relative;
|
||||
z-index: 999999;
|
||||
/* height: 200rpx; */
|
||||
/* position: absolute;
|
||||
bottom: 20px; */
|
||||
}
|
||||
.message-list {
|
||||
width: 100%;
|
||||
@ -157,10 +157,13 @@
|
||||
.name{
|
||||
font-size: 34rpx;
|
||||
color: #3CC7C0;
|
||||
flex: 1;
|
||||
text-align: center;
|
||||
}
|
||||
.age{
|
||||
font-size: 34rpx;
|
||||
color: #666666;
|
||||
flex: 1;
|
||||
}
|
||||
.status{
|
||||
background: #FFF2E8;
|
||||
@ -169,4 +172,18 @@
|
||||
font-size: 24rpx;
|
||||
color: #FA541C;
|
||||
padding: 10rpx 20rpx;
|
||||
}
|
||||
.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;
|
||||
}
|
||||
@ -39,6 +39,15 @@ const constant = {
|
||||
DIRTY_MEDIA: '您发送的消息包含违禁内容!',
|
||||
RESEND_SUCCESS: '重发成功',
|
||||
},
|
||||
//自定义消息
|
||||
GDXZ_CUSTOM_MSEEAGE: {
|
||||
TRABECULA: 1,//1:消息内页横条
|
||||
ORDER_EVALUATION: 2,//2:订单结束评价弹出
|
||||
DOCTOR_SYSTEM_NOTIFICATION: 3,//3:医生端系统通知
|
||||
DOCTOR_SERVICE_NOTIFICATION: 4,//4:医生端服务通知
|
||||
PATIENT_SYSTEM_MESSAGES: 5,//5:患者端系统消息
|
||||
PRESCRIBE: 6,//6:处方开具成功
|
||||
},
|
||||
|
||||
OPERATING_ENVIRONMENT: 'imWxTuikit'
|
||||
};
|
||||
|
||||
5
app.js
5
app.js
@ -57,8 +57,8 @@ App({
|
||||
},
|
||||
imInit(){
|
||||
|
||||
let userID = wx.getStorageSync('user_id');
|
||||
let usertype = wx.getStorageSync('usertype');
|
||||
let userID = wx.getStorageSync('user_id_'+usertype);
|
||||
if(usertype != 2){//只登录医师端
|
||||
return;
|
||||
}
|
||||
@ -121,7 +121,8 @@ App({
|
||||
$onSystemPushReceived(e){
|
||||
console.log("onSystemPushReceived from app.js");
|
||||
console.log(e)
|
||||
let userID = wx.getStorageSync('user_id');
|
||||
let usertype = wx.getStorageSync('usertype');
|
||||
let userID = wx.getStorageSync('user_id_'+usertype);
|
||||
let message = e.data[0];
|
||||
console.log(message)
|
||||
|
||||
|
||||
@ -10,11 +10,11 @@
|
||||
<view class="content_3">
|
||||
<view class="status {{ status_class }}">{{ status_text }}</view>
|
||||
<view class="btn" wx:if="{{ status == 3 }}">
|
||||
<van-button bind:click="go" data-url="/Pages/yishi/case/index?order_inquiry_id={{order_inquiry_id}}" plain custom-style="width:200rpx; height:67rpx; border-radius: 10rpx;" color="#3CC7C0">查看病历</van-button>
|
||||
<van-button type="default" bindtap="tabShow" custom-style="width:200rpx; height:67rpx; border-radius: 10rpx;margin-left:20rpx;" color="#3CC7C0">去接诊</van-button>
|
||||
<van-button bind:click="go" data-url="/Pages/yishi/case/index?order_inquiry_id={{order_inquiry_id}}" plain custom-style="padding:0 35rpx; height:67rpx; border-radius: 10rpx;" color="#3CC7C0">查看病历</van-button>
|
||||
<van-button type="default" bindtap="tabShow" custom-style="padding:0 35rpx; height:67rpx; 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-inquiry_type="{{inquiry_type}}" data-order_inquiry_id="{{order_inquiry_id}}" data-url="/Pages/yishi/chat/index" plain custom-style="width:200rpx; height:67rpx; 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="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>
|
||||
|
||||
@ -73,7 +73,7 @@ Component({
|
||||
})
|
||||
}
|
||||
let _this = this;
|
||||
let userID = wx.getStorageSync('user_id');
|
||||
let userID = wx.getStorageSync('user_id_'+usertype);
|
||||
setInterval(() => {
|
||||
let index_info = wx.getStorageSync(userID+'_index_info');
|
||||
let wenzhen_info = wx.getStorageSync(userID+'_wenzhen_info');
|
||||
@ -103,12 +103,12 @@ Component({
|
||||
// },
|
||||
onChange(e) {
|
||||
console.log("custom tab bar onChange");
|
||||
let userID = wx.getStorageSync('user_id');
|
||||
const usertype = wx.getStorageSync('usertype');
|
||||
let userID = wx.getStorageSync('user_id_'+usertype);
|
||||
let idcard_status = wx.getStorageSync(userID+'_idcard_status');
|
||||
let iden_auth_status = wx.getStorageSync(userID+'_iden_auth_status');
|
||||
let multi_point_status = wx.getStorageSync(userID+'_multi_point_status');
|
||||
let is_bind_bank = wx.getStorageSync(userID+'_is_bind_bank');
|
||||
const usertype = wx.getStorageSync('usertype');
|
||||
|
||||
console.log("idcard_status: ", idcard_status);
|
||||
console.log("iden_auth_status: ", iden_auth_status);
|
||||
@ -123,7 +123,6 @@ Component({
|
||||
})
|
||||
return;
|
||||
}
|
||||
console.log(111);
|
||||
if(iden_auth_status != 1 && usertype != 3){
|
||||
this.setData({
|
||||
dialog_visible: true,
|
||||
@ -132,7 +131,6 @@ Component({
|
||||
})
|
||||
return;
|
||||
}
|
||||
console.log(222);
|
||||
if(is_bind_bank != 1 && usertype != 3){
|
||||
this.setData({
|
||||
dialog_visible: true,
|
||||
@ -141,7 +139,6 @@ Component({
|
||||
})
|
||||
return;
|
||||
}
|
||||
console.log(333);
|
||||
let url = this.data.items[e.detail].pagePath;
|
||||
console.log(url);
|
||||
wx.switchTab({
|
||||
|
||||
@ -616,9 +616,7 @@ class API extends HTTP {
|
||||
}
|
||||
//医生接诊
|
||||
postDoctorInquiry(params) {
|
||||
console.log("params from api: ", params);
|
||||
let order_inquiry_id = params.order_inquiry_id;
|
||||
console.log("order_inquiry_id: ", order_inquiry_id);
|
||||
let order_inquiry_id = params.order_inquiry_id;
|
||||
delete params['order_inquiry_id'];
|
||||
return this.request({
|
||||
url: `${this.baseUrl}/doctor/inquiry/`+order_inquiry_id,
|
||||
@ -631,7 +629,6 @@ class API extends HTTP {
|
||||
//结束问诊
|
||||
putDoctorInquiryFinish(params) {
|
||||
let order_inquiry_id = params.order_inquiry_id;
|
||||
console.log("order_inquiry_id: ", order_inquiry_id);
|
||||
params = {}
|
||||
return this.request({
|
||||
url: `${this.baseUrl}/doctor/inquiry/finish/`+order_inquiry_id,
|
||||
@ -644,7 +641,6 @@ class API extends HTTP {
|
||||
//获取问诊订单消息内页基础数据
|
||||
getInquiryMessageBasic(params) {
|
||||
let order_inquiry_id = params.order_inquiry_id;
|
||||
console.log("order_inquiry_id: ", order_inquiry_id);
|
||||
params = {}
|
||||
return this.request({
|
||||
url: `${this.baseUrl}/inquiry/message/basic/`+order_inquiry_id,
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user