mirror of
https://github.com/bigcapitalhq/bigcapital.git
synced 2026-02-19 14:20:31 +00:00
20 lines
634 B
JavaScript
20 lines
634 B
JavaScript
import { connect } from 'react-redux';
|
|
import {
|
|
getVendorsTableStateFactory,
|
|
vendorsTableStateChangedFactory,
|
|
} from 'store/vendors/vendors.selectors';
|
|
|
|
export default (mapState) => {
|
|
const getVendorsTableState = getVendorsTableStateFactory();
|
|
const vendorsTableStateChanged = vendorsTableStateChangedFactory();
|
|
|
|
const mapStateToProps = (state, props) => {
|
|
const mapped = {
|
|
vendorsTableState: getVendorsTableState(state, props),
|
|
vendorsTableStateChanged: vendorsTableStateChanged(state, props),
|
|
};
|
|
return mapState ? mapState(mapped, state, props) : mapped;
|
|
};
|
|
return connect(mapStateToProps);
|
|
};
|