Commit 33066c62 authored by “yiyousong”'s avatar “yiyousong”

fix:修改搜索和事项显示

parent 76333111
<template> <template>
<div class="search-box" :style="{ width }"> <div class="search-box" :style="{ width }">
<el-input <el-input placeholder="输入关键词查询" :value="value" @input="changeInput">
placeholder="输入关键词查询" <i
:value="value" v-show="value"
@input="changeInput" slot="suffix"
></el-input> class="el-icon-circle-close"
@click="handleClose"
></i>
</el-input>
<el-button class="search-btn" @click="handleSearch"> <el-button class="search-btn" @click="handleSearch">
<span class="flex aic jcc"> <span class="flex aic jcc">
<img class="mr10" src="../assets/img/sousuo.png" /> 搜索 <img class="mr10" src="../assets/img/sousuo.png" /> 搜索
...@@ -40,6 +43,9 @@ export default { ...@@ -40,6 +43,9 @@ export default {
handleSearch() { handleSearch() {
this.$emit("click"); this.$emit("click");
}, },
handleClose() {
this.$emit("clear");
},
}, },
}; };
</script> </script>
...@@ -65,10 +71,19 @@ export default { ...@@ -65,10 +71,19 @@ export default {
right: 5px; right: 5px;
top: 5px; top: 5px;
} }
:deep(.el-input__suffix) {
/deep/.el-input__inner { display: flex;
align-items: center;
justify-content: center;
position: absolute;
right: 200px;
}
.el-icon-circle-close {
font-size: 20px;
}
:deep(.el-input__inner) {
height: 72px; height: 72px;
padding-right: 200px; padding-right: 240px;
font-size: 24px; font-size: 24px;
border-radius: 8px; border-radius: 8px;
color: #333; color: #333;
......
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
<div class="main flex1 flex flexc"> <div class="main flex1 flex flexc">
<PageTop> <PageTop>
<div slot="count" class="count"> <div slot="count" class="count">
共计<span class="data-count">{{ matterTotal }}</span 共计<span class="data-count">{{ total }}</span
>件事项 >件事项
<!-- ,<span class="data-count">{{ matterDatumTotal }}</span <!-- ,<span class="data-count">{{ matterDatumTotal }}</span
>份表单 --> >份表单 -->
...@@ -15,6 +15,7 @@ ...@@ -15,6 +15,7 @@
slot="search" slot="search"
width="834px" width="834px"
@click="handleSearch" @click="handleSearch"
@clear="handleClear"
v-model="searchVal" v-model="searchVal"
></SearchBox> ></SearchBox>
</PageTop> </PageTop>
...@@ -140,7 +141,7 @@ export default { ...@@ -140,7 +141,7 @@ export default {
}); });
let { total, matterDatumTotal, data } = res.data.data; let { total, matterDatumTotal, data } = res.data.data;
this.matterList = data; this.matterList = data;
this.matterTotal = total; this.total = total;
this.matterDatumTotal = matterDatumTotal; this.matterDatumTotal = matterDatumTotal;
console.log(data); console.log(data);
}, },
...@@ -159,6 +160,10 @@ export default { ...@@ -159,6 +160,10 @@ export default {
this.matterInfo = row; this.matterInfo = row;
this.visible = true; this.visible = true;
}, },
// 重置搜索
handleClear() {
this.searchVal = "";
},
}, },
}; };
</script> </script>
...@@ -196,7 +201,7 @@ export default { ...@@ -196,7 +201,7 @@ export default {
.matter-item { .matter-item {
width: 426px; width: 426px;
height: 200px; height: 200px;
padding: 10px; padding: 20px;
margin-bottom: 34px; margin-bottom: 34px;
background: #edf6fe; background: #edf6fe;
border-radius: 16px; border-radius: 16px;
...@@ -228,7 +233,7 @@ export default { ...@@ -228,7 +233,7 @@ export default {
color: #333333; color: #333333;
line-height: 28px; line-height: 28px;
.isMore { .isMore {
max-width: 320px; max-width: 310px;
} }
.count { .count {
color: #2878ff; color: #2878ff;
......
...@@ -22,6 +22,7 @@ ...@@ -22,6 +22,7 @@
width="834px" width="834px"
v-model="searchVal" v-model="searchVal"
@click="handleSearch" @click="handleSearch"
@clear="handleClear"
></SearchBox> ></SearchBox>
</PageTop> </PageTop>
<!-- 事项列表 --> <!-- 事项列表 -->
...@@ -145,6 +146,10 @@ export default { ...@@ -145,6 +146,10 @@ export default {
this.matterInfo = row; this.matterInfo = row;
this.visible = true; this.visible = true;
}, },
// 重置搜索
handleClear() {
this.searchVal = "";
},
}, },
}; };
</script> </script>
...@@ -193,7 +198,7 @@ export default { ...@@ -193,7 +198,7 @@ export default {
width: 460px; width: 460px;
height: 150px; height: 150px;
margin-bottom: 30px; margin-bottom: 30px;
padding: 10px; padding: 20px;
background: #edf6fe; background: #edf6fe;
border-radius: 16px; border-radius: 16px;
cursor: pointer; cursor: pointer;
...@@ -224,7 +229,7 @@ export default { ...@@ -224,7 +229,7 @@ export default {
letter-spacing: 1px; letter-spacing: 1px;
display: -webkit-box; display: -webkit-box;
-webkit-box-orient: vertical; -webkit-box-orient: vertical;
-webkit-line-clamp: 2; -webkit-line-clamp: 1;
overflow: hidden; overflow: hidden;
} }
.isRecommend { .isRecommend {
......
...@@ -58,16 +58,16 @@ export default { ...@@ -58,16 +58,16 @@ export default {
padding: 15px 0px; padding: 15px 0px;
overflow-y: auto; overflow-y: auto;
&::-webkit-scrollbar { &::-webkit-scrollbar {
width: 6px; width: 4px;
overflow-y: auto; overflow-y: auto;
} }
&::-webkit-scrollbar-thumb { &::-webkit-scrollbar-thumb {
border-radius: 6px; border-radius: 4px;
background-color: rgba(144, 147, 153, 0.5); background-color: rgba(144, 147, 153, 0.5);
} }
&::-webkit-scrollbar-track { &::-webkit-scrollbar-track {
border-radius: 6px; border-radius: 4px;
background: #fff; background: #fff;
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment