Implement pagination for members reports and update UI components
- Added a new `setPagination` action to manage pagination state in the members reports slice. - Updated the members reports page to display the total number of members in the header. - Enhanced the members reports table to handle pagination changes, ensuring data is fetched correctly based on the current page and page size.
This commit is contained in:
@@ -107,6 +107,10 @@ const membersReportsSlice = createSlice({
|
||||
setDateRange: (state, action) => {
|
||||
state.dateRange = action.payload;
|
||||
},
|
||||
setPagination: (state, action) => {
|
||||
state.index = action.payload.index;
|
||||
state.pageSize = action.payload.pageSize;
|
||||
},
|
||||
},
|
||||
extraReducers: builder => {
|
||||
builder
|
||||
@@ -139,5 +143,6 @@ export const {
|
||||
setOrder,
|
||||
setDuration,
|
||||
setDateRange,
|
||||
setPagination,
|
||||
} = membersReportsSlice.actions;
|
||||
export default membersReportsSlice.reducer;
|
||||
|
||||
Reference in New Issue
Block a user