feat: 优化 PureTableBar 组件,添加列展示功能

This commit is contained in:
xiaoxian521
2023-05-09 14:33:19 +08:00
parent 42f5a36145
commit 723cb46eaf
12 changed files with 137 additions and 59 deletions

View File

@@ -85,13 +85,13 @@ const {
</el-form-item>
</el-form>
<PureTableBar title="角色列表" @refresh="onSearch">
<PureTableBar title="角色列表" :columns="columns" @refresh="onSearch">
<template #buttons>
<el-button type="primary" :icon="useRenderIcon(AddFill)">
新增角色
</el-button>
</template>
<template v-slot="{ size, checkList }">
<template v-slot="{ size, dynamicColumns }">
<pure-table
border
align-whole="center"
@@ -100,8 +100,7 @@ const {
:loading="loading"
:size="size"
:data="dataList"
:columns="columns"
:checkList="checkList"
:columns="dynamicColumns"
:pagination="pagination"
:paginationSmall="size === 'small' ? true : false"
:header-cell-style="{