From dc934dfd63fecff84d0bf996418e041b9bd4ea59 Mon Sep 17 00:00:00 2001 From: 闫增涛 <1829501689@qq.com> Date: 星期二, 30 四月 2024 18:16:13 +0800 Subject: [PATCH] bug修改 --- pages/retrievalPage/index.js | 33 ++++++++++++++------------------- 1 files changed, 14 insertions(+), 19 deletions(-) diff --git a/pages/retrievalPage/index.js b/pages/retrievalPage/index.js index ce675e7..0eaae66 100644 --- a/pages/retrievalPage/index.js +++ b/pages/retrievalPage/index.js @@ -11,6 +11,8 @@ * 椤甸潰鐨勫垵濮嬫暟鎹� */ data: { + loading: true, + hidden: true, input: '', dialogKey: '', showWithInput: false, @@ -37,14 +39,13 @@ page: 1, total: 0, }, - tabValue: '' + tabValue: '0' }, /** * 鐢熷懡鍛ㄦ湡鍑芥暟--鐩戝惉椤甸潰鍔犺浇 */ onLoad(options) { - console.log(app.config.appId); const systInfo = wx.getSystemInfoSync(); const menu = wx.getMenuButtonBoundingClientRect(); // 鑳跺泭淇℃伅 @@ -54,17 +55,14 @@ barHeight: systInfo.statusBarHeight, searchVal: options.searchVal }) - - this.retrievalPageGet() this.bibliographyGet() let event = { detail: { - value: "0" } } - this.onTabsChange(event) + // this.onTabsChange(event) }, /** @@ -131,17 +129,12 @@ //鏍囩鐨勫垏鎹� onTabsChange(event) { const value = event.detail.value - // if (this.data.bookData <= 0 || this.data.courseData <= 0 || this.data.digitalTextbooksData <= 0 || this.data.seminarData <= 0 || this.data.biblioClassificationData <= 0 || this.data.bookFairData <= 0) { - // this.setData({ - // isMore: true - // }) - // } + console.log(value); if (value === '0') { this.setData({ tabValue: value, isMore: false }) - } else if (value === '1') { console.log(value, 'tab'); this.setData({ @@ -169,14 +162,9 @@ isMore: false }) } - }, - - - retrievalPageGet() { - let fields = { liveTime: [], lecturer: [], @@ -492,7 +480,10 @@ biblioClassificationTotal: data5.totalCount }) - + this.setData({ + loading: false, + hidden: false, + }) }) @@ -574,6 +565,10 @@ }); }, onSearchSubmit() { + this.setData({ + loading: true, + hidden: true, + }) console.log(this.data.searchVal); this.retrievalPageGet() this.bibliographyGet() @@ -914,5 +909,5 @@ }, 100) } } - } + }, }) \ No newline at end of file -- Gitblit v1.9.1