Commit 62b80806 by 张杰

修复bug

1 parent 78bc10a9
...@@ -9,7 +9,7 @@ ...@@ -9,7 +9,7 @@
</el-table-column> </el-table-column>
</el-table> </el-table>
<div class="pagination_list"> <div class="pagination_list">
<el-pagination background layout="sizes, total,prev, pager, next, jumper" hide-on-single-page :total="pageTotal" :page-size="pageSize" :page-sizes="pageSizes" :current-page.sync="currentPage" @current-change="getList" @size-change="changePageSize" /> <el-pagination background layout="sizes, total,prev, pager, next, jumper" hide-on-single-page :total="pageTotal" :page-size.sync="pageSizeNum" :page-sizes="pageSizes" :current-page.sync="currentPage" @current-change="getList" @size-change="changePageSize" />
</div> </div>
</div> </div>
</template> </template>
...@@ -69,32 +69,33 @@ export default { ...@@ -69,32 +69,33 @@ export default {
data() { data() {
return { return {
currentPage: 1, currentPage: 1,
pageSizeNum: 10,
}; };
}, },
created() { created() {
this.pageSizeNum = this.pageSize;
//console.log(this.$scopedSlots); //console.log(this.$scopedSlots);
}, },
mounted() { mounted() {},
},
methods: { methods: {
/** /**
* 每页展示 * 每页展示
*/ */
changePageSize: function (e) { changePageSize: function (e) {
this.pageSize = e; this.pageSizeNum = e;
this.$emit("change", { pageSize: e }); this.$emit("change", { pageSize: e });
//this.getList(); //this.getList();
}, },
// 获取列表 // 获取列表
getList(current) { getList(current) {
this.$emit("change", { pageNumber: current, pageSize: this.pageSize }); this.$emit("change", { pageNumber: current, pageSize: this.pageSizeNum });
}, },
// 重置 // 重置
rest() { rest() {
this.currentPage = 1; this.currentPage = 1;
this.pageSize = 10 this.pageSizeNum = 10;
}, },
}, },
}; };
......
...@@ -125,12 +125,13 @@ export default { ...@@ -125,12 +125,13 @@ export default {
{ label: "假性离线原因", prop: "reason" }, { label: "假性离线原因", prop: "reason" },
], ],
pageTotal: 0, pageTotal: 0,
pageSize: 10,
filterVisible: false, filterVisible: false,
dloading: false, dloading: false,
showPopover: false, showPopover: false,
cloading: false, cloading: false,
loading: false, loading: false,
aloading:false, aloading: false,
isTimeOut: false, isTimeOut: false,
sTime: "", sTime: "",
eTime: "", eTime: "",
...@@ -175,8 +176,10 @@ export default { ...@@ -175,8 +176,10 @@ export default {
// 获取列表 // 获取列表
getList(options) { getList(options) {
let oParams = this.getParams(); let oParams = this.getParams();
oParams.pageSize = this.$refs.glsxTable.pageSize; console.log(this.$refs.glsxTable.pageSizeNum);
oParams.pageSize = options?options.pageSize : this.$refs.glsxTable.pageSizeNum;
oParams.pageNumber = options ? options.pageNumber || 1 : 1; oParams.pageNumber = options ? options.pageNumber || 1 : 1;
this.loading = true; this.loading = true;
//GET_FAKEOFFLINE_LIST 等后台部署后替换 //GET_FAKEOFFLINE_LIST 等后台部署后替换
GET_FAKEOFFLINE_LIST(oParams) GET_FAKEOFFLINE_LIST(oParams)
...@@ -248,8 +251,8 @@ export default { ...@@ -248,8 +251,8 @@ export default {
// 重置 // 重置
rest() { rest() {
this.searchForm = {}; this.searchForm = {};
this.getList();
this.$refs.glsxTable.rest(); this.$refs.glsxTable.rest();
this.getList();
}, },
// 监听文件导入 // 监听文件导入
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!