案例分页修改

This commit is contained in:
zhaofang
2022-06-07 20:05:57 +08:00
parent 906e1dd6df
commit a0ba8b5631
2 changed files with 15 additions and 20 deletions

View File

@@ -17,7 +17,7 @@
<div style="padding: 0px 5px;"><el-input placeholder="关键词搜索" v-model="queryObj.keyWord" clearable></el-input></div>
<div style="padding: 0px 5px;">
<el-button @click="getData" icon="el-icon-search" type="primary" >搜索</el-button>
<el-button @click="showRecords()" icon="el-icon-tickets" type="info" >推荐记录</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>
</div>
@@ -35,7 +35,7 @@
<el-table-column label="操作">
<template slot-scope="scope">
<el-button-group>
<el-button type="text" @click="shareItem(scope.row)" icon="el-icon-share" style="margin:0 5px">推荐</el-button>
<!-- <el-button type="text" @click="shareItem(scope.row)" icon="el-icon-share" style="margin:0 5px">推荐</el-button> -->
<el-button style="margin:0 5px" v-if="scope.row.isTop==0" type="text" @click="setTop(scope.row)" :icon="scope.row.isTop==1 ? 'el-icon-bottom' : 'el-icon-top'">置顶</el-button>
<el-button style="margin:0 5px" v-else type="text" @click="setTop(scope.row)" :icon="scope.row.isTop==1 ? 'el-icon-bottom' : 'el-icon-top'">取消置顶</el-button>
<el-button type="text" @click="delItem(scope.row)" icon="el-icon-delete">删除</el-button>
@@ -48,7 +48,7 @@
background
@size-change="handleSizeChange"
@current-change="handleCurrentChange"
:current-page="queryObj.pagelIndex"
:current-page="queryObj.pageIndex"
:page-sizes="[10, 20, 30, 40]"
:page-size="queryObj.pageSize"
layout="total, sizes, prev, pager, next, jumper"
@@ -117,7 +117,7 @@ export default {
data() {
return {
queryObj: {
pagelIndex:1,
pageIndex:1,
pageSize:10,
}, //查询对象
caseList: [], //案例列表
@@ -189,7 +189,7 @@ export default {
this.getData();
},
handleCurrentChange(val) {
this.queryObj.pagelIndex=val;
this.queryObj.pageIndex=val;
this.getData();
},
//暂时因为没数据,先做添加