From 8bffcbb7f5fca4e1e7a308f6f786b63d0773704c Mon Sep 17 00:00:00 2001
From: zhongshujie <2862698242@qq.com>
Date: 星期一, 28 四月 2025 19:28:29 +0800
Subject: [PATCH] 页面优化

---
 src/views/home/components/searchBox.vue |   23 ++++++++++++++++++-----
 1 files changed, 18 insertions(+), 5 deletions(-)

diff --git a/src/views/home/components/searchBox.vue b/src/views/home/components/searchBox.vue
index 6737ac3..86497ad 100644
--- a/src/views/home/components/searchBox.vue
+++ b/src/views/home/components/searchBox.vue
@@ -36,20 +36,29 @@
         { value: "abstract", label: "鎽樿" },
         { value: "source", label: "鏉ユ簮" },
       ],
+      searchFun: {
+        type: Function,
+        default: () => {},
+      },
     },
   },
   data() {
     return {
       searchText: "", // 杈撳叆妗嗗唴瀹�
-      selectedType: "", // 涓嬫媺妗嗛�変腑鍊�
+      selectedType: "all", // 涓嬫媺妗嗛�変腑鍊�
     };
   },
   methods: {
     // 鎼滅储澶勭悊
     handleSearch() {
+    // 鎵惧埌閫変腑鐨勯�夐」鐨刲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 
       });
     },
   },
@@ -62,18 +71,22 @@
   max-width: 800px;
   display: flex;
   align-items: center;
+  background-color: #fff;
 }
 
 /* 杈撳叆妗嗘牱寮� */
 .search-input {
+  width: 100%;
+
 }
 
 .inputBox {
-  border: 1px solid #B9A587;
+  border: 1px solid #b9a587;
   height: 38px;
   width: 400px;
   display: flex;
   justify-content: space-between;
+  background-color: transparent !important;
   align-items: center;
   padding-right: 5px;
   border-radius: 5px;
@@ -86,6 +99,7 @@
   width: 70px;
   height: 30px;
   background-color: #937950;
+  border-radius: 5px;
   margin-left: 10px;
   cursor: pointer;
   font-size: 14px;
@@ -103,10 +117,9 @@
 .el-select /deep/ .el-input__inner {
   border-top-right-radius: 0;
   border-bottom-right-radius: 0;
-  border: 1px solid #B9A587;
-
+  border: 1px solid #b9a587;
+  background-color: transparent;
   border-right: none;
-
 }
 
 .el-input-group__prepend {

--
Gitblit v1.9.1