diff --git a/components/dataView-V2/DataViewReducer.ts b/components/dataView-V2/DataViewReducer.ts index 308b1e86341301a32b9936eb4225cf9b0c8ab0f9..a77af5c9f5658796976bdbbfa389019b585ff76d 100644 --- a/components/dataView-V2/DataViewReducer.ts +++ b/components/dataView-V2/DataViewReducer.ts @@ -1,7 +1,7 @@ export interface Pagination { // 分页数据 pageSize?: number, pageNum?: number, - total?: number + total?: number, } interface State { loading: boolean, @@ -69,7 +69,7 @@ export const effect = (reduceArr: any, registerFun: { fetch: Function }) => { newParams = await registerFun.fetch({ pagination: { ...state.pagination, pageNum: payload.pageNum } }) break case 'onSearch': - newParams = await registerFun.fetch({ searchForm: { ...state.searchForm, ...(payload.searchForm || {}) } }) + newParams = await registerFun.fetch({ searchForm: { ...state.searchForm, ...(payload.searchForm || {}) }, pagination: initState.pagination }) break case 'onResert': newParams = await registerFun.fetch({ searchForm: null, pagination: initState.pagination }) diff --git a/components/dataView-V2/_components/table/pagination/index.tsx b/components/dataView-V2/_components/table/pagination/index.tsx index b192524d2c42a1a09df46b06331dba5d6e0c70f4..f05fd65ef608ec1adec848f58e965205cb92e246 100644 --- a/components/dataView-V2/_components/table/pagination/index.tsx +++ b/components/dataView-V2/_components/table/pagination/index.tsx @@ -10,10 +10,10 @@ import './style.less'; * */ const BIPagination = (props: any) => { - + const current = props.current || props.pageNum; return (