This commit is contained in:
BianLzhaoMin 2025-12-02 13:52:42 +08:00
parent 0a8e5e5f8c
commit 3f36f1943f
4 changed files with 20 additions and 2 deletions

View File

@ -158,7 +158,7 @@
:index=" :index="
indexContinuation(queryParams.pageNum, queryParams.pageSize) indexContinuation(queryParams.pageNum, queryParams.pageSize)
" "
v-if="indexNumShow" v-if="indexNumShow && isIndexShow"
/> />
<el-table-column <el-table-column
:key="v" :key="v"
@ -197,6 +197,7 @@
<!-- 分页 --> <!-- 分页 -->
<pagination <pagination
:total="total" :total="total"
:pageSizes="pageSizes"
@pagination="getTableList" @pagination="getTableList"
:page.sync="queryParams.pageNum" :page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize" :limit.sync="queryParams.pageSize"
@ -282,6 +283,16 @@ export default {
type: Boolean, type: Boolean,
default: false, default: false,
}, },
//
isIndexShow: {
type: Boolean,
default: true,
},
//
pageSizes: {
type: Array,
default: () => [10, 20, 30, 50],
},
}, },
computed: { computed: {
/* 根据操作栏控制表头是否显示 */ /* 根据操作栏控制表头是否显示 */

View File

@ -9,6 +9,7 @@
:showOperation="true" :showOperation="true"
:isSelectShow="true" :isSelectShow="true"
:sendParams="sendParams" :sendParams="sendParams"
:isIndexShow="false"
ref="tableRef" ref="tableRef"
@selection-change="handleSelectionChange" @selection-change="handleSelectionChange"
> >

View File

@ -9,7 +9,9 @@
:showOperation="false" :showOperation="false"
:isSelectShow="true" :isSelectShow="true"
:sendParams="sendParams" :sendParams="sendParams"
:isIndexShow="false"
ref="tableRef" ref="tableRef"
:pageSizes="[100, 200, 500]"
@selection-change="handleSelectionChange" @selection-change="handleSelectionChange"
> >
<template slot="btn"> <template slot="btn">
@ -182,6 +184,7 @@ export default {
sendParams() { sendParams() {
return { return {
deviceCode: this.macNo || '', deviceCode: this.macNo || '',
pageSize: 100,
} }
}, },
}, },

View File

@ -8,7 +8,9 @@
:request-api="requestApi" :request-api="requestApi"
:showOperation="false" :showOperation="false"
:isSelectShow="true" :isSelectShow="true"
:isIndexShow="false"
:sendParams="sendParams" :sendParams="sendParams"
:pageSizes="[100, 200, 500]"
ref="tableRef" ref="tableRef"
@selection-change="handleSelectionChange" @selection-change="handleSelectionChange"
> >
@ -179,6 +181,7 @@ export default {
sendParams() { sendParams() {
return { return {
deviceCode: this.macNo || '', deviceCode: this.macNo || '',
pageSize: 100,
} }
}, },
}, },
@ -219,7 +222,7 @@ export default {
) )
.then(() => { .then(() => {
const ids = this.selectedData.map((item) => item.taskId) const ids = this.selectedData.map((item) => item.taskId)
deletePersonAPI({ deleteTaskAPI({
taskId: ids.join(','), taskId: ids.join(','),
}) })
.then((res) => { .then((res) => {