|
@@ -32,7 +32,7 @@
|
|
|
|
|
|
|
|
|
<el-form-item>
|
|
|
- <el-button @click="getArticalList" type="primary">搜索</el-button>
|
|
|
+ <el-button @click="handleSearch" type="primary">搜索</el-button>
|
|
|
</el-form-item>
|
|
|
</el-form>
|
|
|
</div>
|
|
@@ -134,6 +134,7 @@ export default {
|
|
|
})
|
|
|
},
|
|
|
"searchInfo.category"(val){
|
|
|
+ this.page = 1
|
|
|
this.getArticalList()
|
|
|
}
|
|
|
},
|
|
@@ -153,12 +154,17 @@ export default {
|
|
|
this.pageSize = size
|
|
|
this.getArticalList()
|
|
|
},
|
|
|
+ handleSearch(){
|
|
|
+ this.page = 1
|
|
|
+ this.getArticalList()
|
|
|
+ },
|
|
|
handleCurrentChange(page){
|
|
|
this.page = page
|
|
|
this.getArticalList()
|
|
|
},
|
|
|
selectDepartment(item){
|
|
|
- this.departmentId = +item.departmentId
|
|
|
+ this.departmentId = +item.departmentId||0
|
|
|
+ this.page =1
|
|
|
localStorage.setItem("@departmentId", this.departmentId)
|
|
|
this.getArticalList()
|
|
|
},
|
|
@@ -168,7 +174,7 @@ export default {
|
|
|
},
|
|
|
getArticalList(){
|
|
|
let param = {
|
|
|
- departmentId:+this.departmentId,
|
|
|
+ departmentId:+this.departmentId||0,
|
|
|
keyword: this.searchInfo.keyword,
|
|
|
category: this.searchInfo.category,
|
|
|
page: this.page,
|