feat: 自定义列表刷新“

This commit is contained in:
WANGFAN\wangf 2024-09-13 23:43:01 +08:00
parent 12c40d2dbc
commit ec7e253b80

View File

@ -89,7 +89,7 @@
下载 下载
</a-button> </a-button>
<a-tooltip content="刷新"> <a-tooltip content="刷新">
<div class="action-icon"><icon-refresh size="18" /></div> <div class="action-icon" @click="onRefresh"><icon-refresh size="18" /></div>
</a-tooltip> </a-tooltip>
<a-dropdown @select="onDensity"> <a-dropdown @select="onDensity">
<a-tooltip content="密度"> <a-tooltip content="密度">
@ -127,6 +127,7 @@
<a-table <a-table
row-key="key" row-key="key"
column-resizable column-resizable
:loading="loading"
:size="density" :size="density"
:bordered="{ :bordered="{
cell: true cell: true
@ -368,6 +369,16 @@ const densityType = ref([
label: "偏大" label: "偏大"
} }
]); ]);
//
const loading = ref<boolean>(false);
const onRefresh = () => {
loading.value = true;
setTimeout(() => {
loading.value = false;
}, 500);
};
// //
const density = ref("small"); const density = ref("small");
const onDensity = (e: string) => { const onDensity = (e: string) => {