This commit is contained in:
elforjani3
2020-10-28 19:15:44 +02:00
12 changed files with 182 additions and 42 deletions

View File

@@ -4,12 +4,14 @@ import {
getBillCurrentPageFactory,
getBillPaginationMetaFactory,
getBillTableQueryFactory,
getVendorDueBillsFactory
} from 'store/Bills/bills.selectors';
export default (mapState) => {
const getBillsItems = getBillCurrentPageFactory();
const getBillsPaginationMeta = getBillPaginationMetaFactory();
const getBillTableQuery = getBillTableQueryFactory();
const getVendorDueBills = getVendorDueBillsFactory();
const mapStateToProps = (state, props) => {
const tableQuery = getBillTableQuery(state, props);
@@ -23,6 +25,8 @@ export default (mapState) => {
billsPageination: getBillsPaginationMeta(state, props, tableQuery),
billsLoading: state.bills.loading,
nextBillNumberChanged: state.bills.nextBillNumberChanged,
vendorDueBills: getVendorDueBills(state, props),
};
return mapState ? mapState(mapped, state, props) : mapped;
};