This commit is contained in:
zhaofang
2022-06-08 19:39:39 +08:00
parent cd9c1e013a
commit 911e4947ed

View File

@@ -14,9 +14,9 @@
<el-option label="未置顶" :value="false"></el-option>
</el-select>
</div>
<div style="padding: 0px 5px;"><el-input placeholder="关键词搜索" v-model="queryObj.keyWord" clearable></el-input></div>
<div style="padding: 0px 5px;"><el-input placeholder="关键词搜索" v-model="queryObj.keyWord" @input="inputOn($event)" clearable></el-input></div>
<div style="padding: 0px 5px;">
<el-button @click="getData" icon="el-icon-search" type="primary" >搜索</el-button>
<el-button @click="getData(1)" icon="el-icon-search" type="primary" >搜索</el-button>
<!-- <el-button @click="showRecords()" icon="el-icon-tickets" type="info" >推荐记录</el-button> -->
<el-button icon="el-icon-refresh-right" type="primary" @click="reset">重置</el-button>
</div>
@@ -28,9 +28,9 @@
<span class="previewStyle" @click="viewTopic(scope.row)">{{ scope.row.title }}</span>
</template>
</el-table-column>
<el-table-column label="摘要" show-overflow-tooltip prop="content">
</el-table-column>
<el-table-column label="作者" width="80px" prop="sysCreateBy"></el-table-column>
<!-- <el-table-column label="摘要" show-overflow-tooltip prop="content">
</el-table-column> -->
<el-table-column label="作者" width="80px" prop="authorName"></el-table-column>
<el-table-column label="导入时间" prop="sysCreateTime"></el-table-column>
<el-table-column label="操作">
<template slot-scope="scope">
@@ -157,13 +157,20 @@ export default {
this.getData();
},
methods: {
inputOn() {
this.$forceUpdate();
},
reset() {
this.queryObj.isTop = '';
this.queryObj.keyWord = '';
this.queryObj.pageIndex = 1;
this.getData()
},
//获取案例列表数据
getData() {
getData(num) {
if(num === 1) {
this.queryObj.pageIndex = 1;
}
apiCase
.isTopList(this.queryObj)
.then(res => {
@@ -186,7 +193,7 @@ export default {
},
handleSizeChange(val) {
this.queryObj.pageSize=val;
this.getData();
this.getData(1);
},
handleCurrentChange(val) {
this.queryObj.pageIndex=val;