Просмотр исходного кода

✨ feat<TopSearchTerm Table&Rank>: 清空输入框后更改查询条件发送请求; 改变部分UI;

WanGxC 11 месяцев назад
Родитель
Сommit
25a3770c0e

+ 7 - 10
src/views/keyword/topSearchTermRank/index.vue

@@ -106,14 +106,11 @@ function handleJump() {
 </script>
 
 <template>
-  <div class="mx-3" style="margin-top: -8px">
+  <div class="mx-3">
     <el-divider>
-      <!--<el-icon>-->
-      <!--  <star-filled />-->
-      <!--</el-icon>-->
       <div class="font-bold text-lg">
         <el-icon style="top: 3px">
-          <Memo />
+          <DataLine />
         </el-icon>
         Top Search Term - Rank
       </div>
@@ -149,7 +146,8 @@ function handleJump() {
             :prefix-icon="Search"
             placeholder="输入后回车查询"
             clearable
-            style="width: 300px"></el-input>
+            @clear="handleSelectChange"
+            style="width: 300px" />
         </div>
         <div>
           <span class="font-medium mr-0.5">ASIN </span>
@@ -159,7 +157,8 @@ function handleJump() {
             :prefix-icon="Search"
             placeholder="输入后回车查询"
             clearable
-            style="width: 180px"></el-input>
+            @clear="handleSelectChange"
+            style="width: 180px" />
         </div>
         <div>
           <span class="font-medium mr-0.5">报告日期 </span>
@@ -170,9 +169,7 @@ function handleJump() {
             :popper-options="{ placement: 'bottom-end' }"
             :clearable="false"
             :disabled-date="(time: Date) => time > new Date()"
-            range-separator="至"
-            start-placeholder="开始日期"
-            end-placeholder="结束日期" />
+            range-separator="至" />
         </div>
       </div>
       <div class="flex">

+ 8 - 8
src/views/keyword/topSearchTermTable/index.vue

@@ -30,14 +30,12 @@ import dayjs from 'dayjs';
 const router = useRouter();
 
 const { tableData, total, currentPage, pageSize, handlePageChange } = usePagination(fetchTableData);
-
 const date = ref([dayjs().subtract(7, 'day').format('YYYY-MM-DD'), dayjs().subtract(1, 'day').format('YYYY-MM-DD')]);
-const searchTermInp = ref('');
-const asinInp = ref('');
 const marketplaceSelect = ref(marketplaceIdEnum[0].value); // 当前只有美国区 默认第一个为美国
 const marketplaceOptions = marketplaceIdEnum;
 const reportTypeSelect = ref('weekly');
-
+const searchTermInp = ref('');
+const asinInp = ref('');
 const tableLoading = ref(false);
 
 onMounted(() => {
@@ -134,11 +132,11 @@ function getTagStyle(clickShareRank: number): Record<string, string> {
 </script>
 
 <template>
-  <div class="mx-3" style="margin-top: -8px">
+  <div class="mx-3">
     <el-divider>
       <div class="font-bold text-lg">
         <el-icon style="top: 3px">
-          <Memo />
+          <DataAnalysis />
         </el-icon>
         Top Search Term - Table
       </div>
@@ -174,7 +172,8 @@ function getTagStyle(clickShareRank: number): Record<string, string> {
             :prefix-icon="Search"
             placeholder="输入后回车查询"
             clearable
-            style="width: 300px"></el-input>
+            @clear="handleSelectChange"
+            style="width: 300px" />
         </div>
         <div>
           <span class="font-medium mr-0.5">ASIN </span>
@@ -184,7 +183,8 @@ function getTagStyle(clickShareRank: number): Record<string, string> {
             :prefix-icon="Search"
             placeholder="输入后回车查询"
             clearable
-            style="width: 180px"></el-input>
+            @clear="handleSelectChange"
+            style="width: 180px" />
         </div>
         <div>
           <span class="font-medium mr-0.5">报告日期 </span>