WIP/customers

This commit is contained in:
elforjani3
2020-06-14 13:27:36 +02:00
parent 4d1dd14f8d
commit e20c912a3d
17 changed files with 544 additions and 42 deletions

View File

@@ -0,0 +1,10 @@
import { pickItemsFromIds } from 'store/selectors';
export const getCustomersItems = (state, viewId) => {
const customersView = state.customers.views[viewId || -1];
const customersItems = state.customers.items;
return typeof customersView === 'object'
? pickItemsFromIds(customersItems, customersView.ids) || []
: [];
};