From fcfef0416b7c5adc23175c4930b6ab6e98e874df Mon Sep 17 00:00:00 2001 From: Default User Date: Wed, 17 Dec 2025 17:34:28 +0800 Subject: [PATCH] =?UTF-8?q?=E5=B0=86=E8=81=94=E7=B3=BB=E5=AE=A2=E6=9C=8D?= =?UTF-8?q?=E6=8C=89=E9=92=AE=E6=B7=BB=E5=8A=A0=E5=88=B0=E4=B8=BB=E9=A1=B5?= =?UTF-8?q?=E9=9D=A2=EF=BC=8C=E4=B8=8E=E6=B6=88=E6=81=AF=E4=B8=AD=E5=BF=83?= =?UTF-8?q?=E6=8C=89=E9=92=AE=E5=B9=B6=E6=8E=92=E6=98=BE=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pages/index/index.js | 17 +++++++++++++++++ pages/index/index.wxml | 5 ++++- pages/index/index.wxss | 21 ++++++++++++++++++++- 3 files changed, 41 insertions(+), 2 deletions(-) diff --git a/pages/index/index.js b/pages/index/index.js index 8f660f4..5b0f6fc 100644 --- a/pages/index/index.js +++ b/pages/index/index.js @@ -29,6 +29,23 @@ Page({ }); }, + // 跳转到客服列表页面 + navigateToCustomerService() { + wx.navigateTo({ + url: '/pages/customer-service/index', + success: function() { + console.log('成功跳转到客服列表页面'); + }, + fail: function(error) { + console.error('跳转到客服列表页面失败:', error); + wx.showToast({ + title: '跳转失败,请稍后重试', + icon: 'none' + }); + } + }); + }, + onLoad() { console.log('首页初始化') }, diff --git a/pages/index/index.wxml b/pages/index/index.wxml index e8dd7b6..fe199f8 100644 --- a/pages/index/index.wxml +++ b/pages/index/index.wxml @@ -1,7 +1,10 @@ 中国最专业的鸡蛋现货交易平台 - + + + + diff --git a/pages/index/index.wxss b/pages/index/index.wxss index 2c0efed..46f69f2 100644 --- a/pages/index/index.wxss +++ b/pages/index/index.wxss @@ -68,11 +68,30 @@ page { background: rgba(76, 175, 80, 0.15); } +/* 按钮容器样式,用于并排显示按钮 */ +.btn-container { + display: flex; + flex-direction: row; + justify-content: space-around; + margin: 30rpx auto 0; + width: 80%; + gap: 20rpx; +} + /* 消息按钮样式 */ .message-btn { color: #FF6B6B; background: rgba(255, 107, 107, 0.15); - margin-top: 30rpx; + margin: 0; + width: 48%; +} + +/* 联系客服按钮样式 */ +.service-btn { + color: #1677ff; + background: rgba(22, 119, 255, 0.15); + margin: 0; + width: 48%; } /* 立即入驻按钮样式 */