路径图

This commit is contained in:
yuping
2022-12-12 17:39:32 +08:00
parent 23021328c4
commit 743cc6f4a5
3 changed files with 6 additions and 5 deletions

View File

@@ -21,7 +21,7 @@ export function usePage(_url, param) {
function fetchData() {
state.loading = true
request(_url, state.params).then(r => {
state.params.pageNo === 1 ? (state.data = r.data.records) : (state.data = [...state.data, ...r.data.records])
state.params.pageNo === 1 ? (state.data = (r.data.records||r.data.rows)) : (state.data = [...state.data, ...(r.data.records||r.data.rows)])
state.size = r.data.size
state.total = r.data.total
state.current = r.data.current