mirror of
https://github.com/continew-org/continew-admin-ui.git
synced 2025-09-09 20:57:17 +08:00
feat: useTable 支持 “无分页” 列表
This commit is contained in:
@@ -93,13 +93,6 @@ const {
|
||||
handleDelete
|
||||
} = useTable((p) => listStorage({ ...queryForm, page: p.page, size: p.size }), { immediate: true })
|
||||
|
||||
// 重置
|
||||
const reset = () => {
|
||||
queryForm.description = undefined
|
||||
queryForm.status = undefined
|
||||
search()
|
||||
}
|
||||
|
||||
const columns: TableInstanceColumns[] = [
|
||||
{
|
||||
title: '序号',
|
||||
@@ -130,6 +123,13 @@ const columns: TableInstanceColumns[] = [
|
||||
}
|
||||
]
|
||||
|
||||
// 重置
|
||||
const reset = () => {
|
||||
queryForm.description = undefined
|
||||
queryForm.status = undefined
|
||||
search()
|
||||
}
|
||||
|
||||
// 删除
|
||||
const onDelete = (item: StorageResp) => {
|
||||
return handleDelete(() => deleteStorage(item.id), { content: `是否确定删除存储 [${item.name}]?`, showModal: true })
|
||||
|
Reference in New Issue
Block a user