From 057199d5c5284a71e5d04e091492873ced412fa5 Mon Sep 17 00:00:00 2001 From: 闫增涛 <1829501689@qq.com> Date: 星期四, 21 三月 2024 09:28:54 +0800 Subject: [PATCH] 代码合并 --- pages/home/home.js | 29 +++++++++++++++++++++++++---- 1 files changed, 25 insertions(+), 4 deletions(-) diff --git a/pages/home/home.js b/pages/home/home.js index 4575a24..2105851 100644 --- a/pages/home/home.js +++ b/pages/home/home.js @@ -4,6 +4,9 @@ const app = getApp() Page({ data: { + barHeight: '', + navBarHeight: '', + searchVal: '', isWhite: false, backUrl: null, userInfo: {}, @@ -35,6 +38,13 @@ }, onLoad(options) { + const systInfo = wx.getSystemInfoSync(); + const menu = wx.getMenuButtonBoundingClientRect(); // 鑳跺泭淇℃伅 + const navBarHeight = (menu.top - systInfo.statusBarHeight) * 2 + menu.height; // 瀵艰埅鏍忛珮搴� + this.setData({ + barHeight: systInfo.statusBarHeight, + navBarHeight: navBarHeight, + }); if (options.backUrl) { let backUrl = JSON.parse(decodeURIComponent(options.backUrl)); if (backUrl.options) { @@ -148,7 +158,7 @@ getBannerList() { const list = [] app.MG.resource.getItem({ - path: 'jsek_banner\\jsek_homeBanner', + path: 'jsek_banner\\jsek_homeBannerApplet', fields: { jsek_link: [] }, paging: { start: 0, size: 9 } }).then(res => { @@ -423,7 +433,7 @@ goDetail(e) { const { book } = e.currentTarget.dataset; wx.navigateTo({ - url: `/pages/bookServices/detail/index?id=${book.id}&name=${book.name}`, + url: `/packageBookService/pages/bookServices/detail/index?id=${book.id}&name=${book.name}`, }); }, getShoppingCartList() { @@ -495,7 +505,7 @@ console.log(e, 1) if (type == "tushufuwu") { wx.navigateTo({ - url: '/pages/bookServices/list/index' + url: '/packageBookService/pages/bookServices/list/index' }) } else { wx.showToast({ @@ -513,6 +523,17 @@ isWhite: e.scrollTop > 50 ? true : false }) - } + }, + onRetrievalPage() { + console.log(this.data.searchVal); + wx.navigateTo({ + url: '/pages/retrievalPage/index?searchVal=' + this.data.searchVal + + + }) + + + }, + }); -- Gitblit v1.9.1