From bb5455da328724ba3b4ccb61da0a71eb5beed016 Mon Sep 17 00:00:00 2001 From: 杨磊 <505174330@qq.com> Date: 星期日, 27 四月 2025 18:08:07 +0800 Subject: [PATCH] 样式修改 --- src/views/home/components/searchBox.vue | 14 +++++++++++--- 1 files changed, 11 insertions(+), 3 deletions(-) diff --git a/src/views/home/components/searchBox.vue b/src/views/home/components/searchBox.vue index b003316..86497ad 100644 --- a/src/views/home/components/searchBox.vue +++ b/src/views/home/components/searchBox.vue @@ -45,15 +45,20 @@ data() { return { searchText: "", // 杈撳叆妗嗗唴瀹� - selectedType: "", // 涓嬫媺妗嗛�変腑鍊� + selectedType: "all", // 涓嬫媺妗嗛�変腑鍊� }; }, methods: { // 鎼滅储澶勭悊 handleSearch() { - this.$emit("searchFun", { + // 鎵惧埌閫変腑鐨勯�夐」鐨刲abel + const selectedOption = this.options.find(option => option.value === this.selectedType); + const selectedLabel = selectedOption ? selectedOption.label : ''; + console.log(selectedLabel,"001") + this.$emit("search", { text: this.searchText, type: this.selectedType, + label: selectedLabel }); }, }, @@ -71,7 +76,8 @@ /* 杈撳叆妗嗘牱寮� */ .search-input { - background-color: transparent; + width: 100%; + } .inputBox { @@ -80,6 +86,7 @@ width: 400px; display: flex; justify-content: space-between; + background-color: transparent !important; align-items: center; padding-right: 5px; border-radius: 5px; @@ -92,6 +99,7 @@ width: 70px; height: 30px; background-color: #937950; + border-radius: 5px; margin-left: 10px; cursor: pointer; font-size: 14px; -- Gitblit v1.9.1