mirror of
https://github.com/bigcapitalhq/bigcapital.git
synced 2026-02-22 07:40:32 +00:00
21 lines
706 B
TypeScript
21 lines
706 B
TypeScript
// @ts-nocheck
|
|
import { connect } from 'react-redux';
|
|
import {
|
|
getPaymentMadesTableStateFactory,
|
|
paymentsTableStateChangedFactory,
|
|
} from '@/store/PaymentMades/paymentMades.selector';
|
|
|
|
export const withPaymentMade = (mapState) => {
|
|
const getPaymentMadesTableState = getPaymentMadesTableStateFactory();
|
|
const paymentsTableStateChanged = paymentsTableStateChangedFactory();
|
|
|
|
const mapStateToProps = (state, props) => {
|
|
const mapped = {
|
|
paymentMadesTableState: getPaymentMadesTableState(state, props),
|
|
paymentsTableStateChanged: paymentsTableStateChanged(state, props),
|
|
};
|
|
return mapState ? mapState(mapped, state, props) : mapped;
|
|
};
|
|
return connect(mapStateToProps);
|
|
};
|