orderiom-api-package 0.5.4 → 0.5.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "orderiom-api-package",
3
- "version": "0.5.4",
3
+ "version": "0.5.5",
4
4
  "description": "This package will install all necessary API calls for every orderiom restaurant",
5
5
  "main": "index.js",
6
6
  "types": "index.d.ts",
package/src/common.js CHANGED
@@ -63,6 +63,7 @@ export function updateBasket({commit, basketId, res, restaurantId}){
63
63
  commit(`product/setPostalCode`, basketInfo.postalCode, { root: true });
64
64
  commit(`product/setTip`, basketInfo.tip, { root: true });
65
65
  commit(`product/setshippingPrice`, basketInfo.shipping_price, { root: true });
66
+ commit(`product/setUnavailableProducts`, basketInfo.unavailableProducts, {root: true});
66
67
 
67
68
  if (parseInt(basketInfo.id) !== parseInt(basketId)) {
68
69
  const baskets = JSON.parse(localStorage.getItem('basket'));
@@ -32,6 +32,7 @@ const state = () => ({
32
32
  categoriesFetchedOnce: false,
33
33
  pinnedProductsFetchedOnce: false,
34
34
  fetchingProductsHappyHour: false,
35
+ unavailableProducts: [] // unavailable products for delivery method
35
36
  });
36
37
 
37
38
  function selectedCategoryIsNull(state) {
@@ -285,7 +286,10 @@ const mutations = {
285
286
  },
286
287
  setFetchingProductsHappyHour(state, value){
287
288
  state.fetchingProductsHappyHour = value;
288
- }
289
+ },
290
+ setUnavailableProducts(state, value) {
291
+ state.unavailableProducts = value;
292
+ }
289
293
  };
290
294
  const actions = {
291
295
  chooseCategory({commit, dispatch, state}, {category, restaurantId}){