Add package bundles

This commit is contained in:
Almira Krdzic
2018-08-26 15:41:08 +02:00
parent 6017ae8cf3
commit 5ac3bfff36
9 changed files with 90 additions and 30 deletions

View File

@@ -9,6 +9,8 @@ import {
RECIEVE_SHOP_COMMERCIAL_LEADS,
SELECT_SHOP_COMMERCIAL_LEAD
} from '../../constants/coMarketConstants';
import { fromWCPackage } from '../../helpers/PackageHelper';
const client = new HtmlClient();
const requestShopPackages = () => ({
@@ -37,7 +39,7 @@ export const fetchShopPackages = (cl, search) => {
})
.then(response => {
if (response.data) {
dispatch(recieveShopPackages(response.data))
dispatch(recieveShopPackages(response.data.map(wcPackage => fromWCPackage(wcPackage))))
}
})
.catch(error => {