From 5c3f597fed3b703143413447089a9ffce171bf51 Mon Sep 17 00:00:00 2001 From: YM <479443481@qq.com> Date: 星期五, 26 七月 2024 11:55:35 +0800 Subject: [PATCH] Merge branch 'master' of http://182.92.203.7:2001/r/TCM_CharacterLibrary --- src/pages/knowledgeBase/knowledgeBase.vue | 21 +++++++++++++++------ 1 files changed, 15 insertions(+), 6 deletions(-) diff --git a/src/pages/knowledgeBase/knowledgeBase.vue b/src/pages/knowledgeBase/knowledgeBase.vue index ba1b20c..111bf5d 100644 --- a/src/pages/knowledgeBase/knowledgeBase.vue +++ b/src/pages/knowledgeBase/knowledgeBase.vue @@ -1,7 +1,7 @@ <template> <view> <!-- 椤堕儴 --> - <headNav idIndex="0" text="涓浗鍖诲浜虹墿鐭ヨ瘑搴�" /> + <headNav idIndex="0" text="涓浗鍘嗕唬鍖诲浜虹墿鐭ヨ瘑搴�" /> <!-- 鎼滅储 --> <view class="flex flex-center Search"> <!-- <luanqing-search class="search_bar" @onSearch="onSearch"></luanqing-search> --> @@ -340,7 +340,7 @@ label: "鏃舵湡", name: "dynasty", value: "" - }, + } // { // type: "select", // label: "鏈烘瀯", @@ -397,7 +397,8 @@ tagId: "", official: "", genderType: "" - } + }, + aSearchData: "" }; }, onLoad(options) { @@ -643,6 +644,9 @@ }, // 楂樼骇鎼滅储 async onSubmit(val) { + this.keywords = ""; + this.hotAciveIndex = ""; + this.aSearchData = val; this.profession.index = Number(val.tagId); this.profession.id = Number(val.tagId); const currentDynasty = this.dynasty.list.find( @@ -681,6 +685,7 @@ // 鍩虹鎼滅储 async onSearch(val, index) { this.keywords = val.text; + this.aSearchData = ""; if (index !== undefined) { this.keywords = ""; this.hotAciveIndex = index; @@ -744,21 +749,25 @@ CurrentChange(val) { if (this.CurrentPage != val) { this.CurrentPage = val; - this.onSearch(""); + if (this.isAdvancedSearch) { + this.onSubmit(this.aSearchData); + } else { + this.onSearch({ text: this.keywords }); + } } }, // 涓婁竴椤� PrevClick(val) { if (this.CurrentPage != val) { this.CurrentPage = val; - this.onSearch(""); + this.onSearch({ text: this.keywords }); } }, // 涓嬩竴椤� NextClick(val) { if (this.CurrentPage != val) { this.CurrentPage = val; - this.onSearch(""); + this.onSearch({ text: this.keywords }); } } } -- Gitblit v1.9.1