feat: deleteList rename deleteBatch

This commit is contained in:
xingyu 2023-01-17 14:05:07 +08:00
parent 19f34acc55
commit e1341c187a
2 changed files with 4 additions and 4 deletions

View File

@ -297,7 +297,7 @@ const deleteData = async (id: string | number) => {
} }
// //
const deleteList = async () => { const deleteBatch = async () => {
const g = unref(xGrid) const g = unref(xGrid)
if (!g) { if (!g) {
return return
@ -403,7 +403,7 @@ emit('register', {
getSearchData, getSearchData,
setProps, setProps,
deleteData, deleteData,
deleteList, deleteBatch,
exportList, exportList,
getCurrentColumn, getCurrentColumn,
getRadioRecord, getRadioRecord,

View File

@ -5,7 +5,7 @@ export interface tableMethod {
reload: () => void // 刷新表格 reload: () => void // 刷新表格
setProps: (props: XTableProps) => void setProps: (props: XTableProps) => void
deleteData: (id: string | number) => void // 删除数据 deleteData: (id: string | number) => void // 删除数据
deleteList: () => void // 批量删除 deleteBatch: () => void // 批量删除
exportList: (fileName?: string) => void // 导出列表 exportList: (fileName?: string) => void // 导出列表
getCurrentColumn: () => void // 获取当前列 getCurrentColumn: () => void // 获取当前列
getRadioRecord: () => void // 获取当前选中列redio getRadioRecord: () => void // 获取当前选中列redio
@ -30,7 +30,7 @@ export const useXTable = (props: XTableProps): [Function, tableMethod] => {
reload: () => getInstance().reload(), reload: () => getInstance().reload(),
setProps: (props) => getInstance().setProps(props), setProps: (props) => getInstance().setProps(props),
deleteData: (id: string | number) => getInstance().deleteData(id), deleteData: (id: string | number) => getInstance().deleteData(id),
deleteList: () => getInstance().deleteList(), deleteBatch: () => getInstance().deleteBatch(),
exportList: (fileName?: string) => getInstance().exportList(fileName), exportList: (fileName?: string) => getInstance().exportList(fileName),
getCurrentColumn: () => getInstance().getCheckboxRecords(), getCurrentColumn: () => getInstance().getCheckboxRecords(),
getRadioRecord: () => getInstance().getRadioRecord(), getRadioRecord: () => getInstance().getRadioRecord(),