mirror of
https://github.com/bigcapitalhq/bigcapital.git
synced 2026-02-17 21:30:31 +00:00
fix(BillPayment): Validate the opened payment bills. fix(redux): presist redux state. fix(useRequestQuery): hook.
27 lines
565 B
JavaScript
27 lines
565 B
JavaScript
import { createReducer } from '@reduxjs/toolkit';
|
|
import { persistReducer } from 'redux-persist';
|
|
import storage from 'redux-persist/lib/storage';
|
|
import { createTableStateReducers } from 'store/tableState.reducer';
|
|
|
|
const initialState = {
|
|
tableState: {
|
|
pageSize: 12,
|
|
pageIndex: 0,
|
|
},
|
|
};
|
|
|
|
const reducerInstance = createReducer(initialState, {
|
|
...createTableStateReducers('CUSTOMERS'),
|
|
});
|
|
|
|
const STORAGE_KEY = 'bigcapital:estimates';
|
|
|
|
export default persistReducer(
|
|
{
|
|
key: STORAGE_KEY,
|
|
whitelist: ['tableState'],
|
|
storage,
|
|
},
|
|
reducerInstance,
|
|
);
|