From 7f5de1a6a9d5112223c3d1bf07e6a28102f3bcd3 Mon Sep 17 00:00:00 2001 From: algerkong Date: Tue, 27 Jul 2021 16:01:33 +0800 Subject: [PATCH] =?UTF-8?q?=E6=90=9C=E7=B4=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/search.ts | 2 +- src/layout/components/SearchBar.vue | 68 ++++----------------- src/views/search/index.vue | 91 ++++++++++++++++++++++++++--- 3 files changed, 95 insertions(+), 66 deletions(-) diff --git a/src/api/search.ts b/src/api/search.ts index 8a5e953..242eb09 100644 --- a/src/api/search.ts +++ b/src/api/search.ts @@ -3,7 +3,7 @@ import { ISearchDetail } from "@/type/search"; // 搜索内容 export const getSearch = (keywords: any) => { - return request.get("/cloudsearch", { + return request.get("/search", { params: { keywords: keywords, type: 1018 }, }); }; diff --git a/src/layout/components/SearchBar.vue b/src/layout/components/SearchBar.vue index e94066f..caeea35 100644 --- a/src/layout/components/SearchBar.vue +++ b/src/layout/components/SearchBar.vue @@ -5,32 +5,14 @@ size="large" round v-model:value="searchValue" - :placeholder="searchKeyword" + :placeholder="hotSearchKeyword" class="border border-gray-600" - @focus="searchFocus" - @blur="isSearch = false" @keydown.enter="search" > - -
@@ -48,43 +30,34 @@