tmp
This commit is contained in:
@@ -1,43 +1,47 @@
|
||||
Page({
|
||||
data: {
|
||||
contact: {
|
||||
icon: 'logo-wechat-stroke',
|
||||
phone: '18618162956'
|
||||
},
|
||||
services: {},
|
||||
assistServices: [
|
||||
{ id: 1, name: '陪诊', icon: 'user-vip', iconColor: '#2D6A4F' },
|
||||
{ id: 2, name: '代办问诊', icon: 'chat', iconColor: '#2D6A4F' },
|
||||
{ id: 3, name: '代办买药', icon: 'cart', iconColor: '#2D6A4F' },
|
||||
{ id: 4, name: '代取结果', icon: 'file-paste', iconColor: '#2D6A4F' },
|
||||
{ id: 5, name: '检查预约', icon: 'calendar', iconColor: '#2D6A4F' },
|
||||
{ id: 6, name: '出入院办理', icon: 'chart-bar', iconColor: '#2D6A4F' },
|
||||
{ id: 7, name: 'vip陪诊', icon: 'user-star', iconColor: '#2D6A4F' },
|
||||
{ id: 8, name: '其他服务', icon: 'app', iconColor: '#2D6A4F' }
|
||||
],
|
||||
otherServices: [
|
||||
{ id: 1, name: '代办问诊', icon: 'heart', iconColor: '#D4A853' },
|
||||
{ id: 2, name: '代办买药', icon: 'cart', iconColor: '#D4A853' },
|
||||
{ id: 3, name: '代取结果', icon: 'ai-article', iconColor: '#D4A853' },
|
||||
]
|
||||
},
|
||||
|
||||
async onLoad() {
|
||||
const app = getApp()
|
||||
const services = await app.globalData.servicesReady
|
||||
this.setData({
|
||||
services: services.sort((a, b) => parseFloat(a.price) - parseFloat(b.price))
|
||||
},
|
||||
|
||||
goToEscort() {
|
||||
wx.navigateTo({
|
||||
url: '/pages/escort/itemlist'
|
||||
});
|
||||
},
|
||||
|
||||
makePhoneCall() {
|
||||
const phoneNumber = this.data.contact.phone;
|
||||
wx.makePhoneCall({
|
||||
phoneNumber: phoneNumber,
|
||||
success: () => {
|
||||
console.log('拨打电话成功');
|
||||
},
|
||||
fail: () => {
|
||||
console.log('拨打电话失败');
|
||||
}
|
||||
goToVipEscort() {
|
||||
wx.navigateTo({
|
||||
url: '/pages/escort/itemlist?type=vip'
|
||||
});
|
||||
},
|
||||
|
||||
goToDetail(e) {
|
||||
goToServiceList() {
|
||||
wx.navigateTo({
|
||||
url: '/pages/escort/itemlist'
|
||||
});
|
||||
},
|
||||
|
||||
goToAssistDetail(e) {
|
||||
const id = e.currentTarget.dataset.id;
|
||||
wx.navigateTo({
|
||||
url: `/pages/escort/itemdetail?id=${id}`
|
||||
});
|
||||
},
|
||||
|
||||
goToAIChat() {
|
||||
wx.switchTab({
|
||||
url: '/pages/ai/aichat'
|
||||
url: `/pages/escort/itemlist?assistId=${id}`
|
||||
});
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user