orderiom-api-package 0.4.57 → 0.4.59
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 +1 -1
- package/src/modules/order.js +7 -1
package/package.json
CHANGED
package/src/modules/order.js
CHANGED
|
@@ -192,6 +192,7 @@ const actions = {
|
|
|
192
192
|
.post("api/basket/add", {
|
|
193
193
|
basketId,
|
|
194
194
|
productId: data.productId,
|
|
195
|
+
basketProductId: data.basketProductId ? data.basketProductId : undefined,
|
|
195
196
|
quantity: !data.quantity || data.quantity < 1 ? 1 : data.quantity,
|
|
196
197
|
attributeItems: data.attributeItems.length
|
|
197
198
|
? data.attributeItems
|
|
@@ -845,7 +846,12 @@ const actions = {
|
|
|
845
846
|
duration: data.duration || undefined,
|
|
846
847
|
restaurantId: data.restaurantId,
|
|
847
848
|
}).then(res => {
|
|
848
|
-
|
|
849
|
+
if(data.getBasket === undefined || !!data.getBasket){
|
|
850
|
+
dispatch("product/getBasket", data.restaurantId, {root: true});
|
|
851
|
+
}else{
|
|
852
|
+
commit('product/setDeliveryTime', delivery_time + ':00');
|
|
853
|
+
}
|
|
854
|
+
|
|
849
855
|
return res;
|
|
850
856
|
}).catch(error => {
|
|
851
857
|
const status = error.response ? error.response.status : null;
|