更新功能
This commit is contained in:
@@ -125,10 +125,10 @@ export function useTable(options = {}) {
|
||||
// 调用API函数,确保this上下文正确
|
||||
const res = await api(requestParams)
|
||||
|
||||
if (res.code === 1) {
|
||||
if (res.code === 200) {
|
||||
// 如果是分页数据
|
||||
if (needPagination) {
|
||||
tableData.value = res.data?.data || []
|
||||
tableData.value = res.data?.list || []
|
||||
pagination.total = res.data?.total || 0
|
||||
} else {
|
||||
// 非分页数据(如树形数据)
|
||||
|
||||
Reference in New Issue
Block a user