diff --git a/index.html b/index.html new file mode 100644 index 0000000..dcba1a1 --- /dev/null +++ b/index.html @@ -0,0 +1,11 @@ + + + + + + + + + + + diff --git a/js/google_shopping_functions.js b/js/google_shopping_functions.js index bfbfdcf..b4d2e3a 100755 --- a/js/google_shopping_functions.js +++ b/js/google_shopping_functions.js @@ -4,14 +4,56 @@ * input: accepts full item data * output: returns the length of the items array */ -function getItemsCount(itemData) { - return itemData.items.length; +// function getItemsCount(itemData) { +// return itemData.items.length; +// } + +//Deliverables 1 +var getItems = function(objectData) { + return objectData.items +} + +//Deliverables 2 +var getItemsByBrand = function(items, brand) { + var brandResults = [] + for (i=0; i