Checkout logic
This commit is contained in:
@@ -70,6 +70,10 @@ export const fetchCartCount = () => {
|
||||
}
|
||||
}
|
||||
|
||||
export const fetchCartNotices = () => {
|
||||
|
||||
};
|
||||
|
||||
export const fetchCartItems = (isForSteps = false) => {
|
||||
return dispatch => {
|
||||
dispatch(requestShopCartItems());
|
||||
@@ -326,6 +330,19 @@ export const placeOrder = (orderInfo) => {
|
||||
project_id: orderDetails.details.idProject,
|
||||
delivery_address_id: orderDetails.delivery.id,
|
||||
billing_address_id: orderDetails.billing.id,
|
||||
shipping_city: orderDetails.delivery.city,
|
||||
shipping_country: orderDetails.delivery.countryName,
|
||||
shipping_address_1: orderDetails.delivery.detailedAddress,
|
||||
shipping_postcode: orderDetails.delivery.zipCode,
|
||||
shipping_first_name: orderDetails.delivery.firstName,
|
||||
shipping_last_name: orderDetails.delivery.lastName,
|
||||
billing_city: orderDetails.billing.city,
|
||||
billing_country: orderDetails.billing.countryName,
|
||||
billing_address_1: orderDetails.billing.detailedAddress,
|
||||
billing_postcode: orderDetails.billing.zipCode,
|
||||
billing_first_name: orderDetails.billing.firstName,
|
||||
billing_last_name: orderDetails.billing.lastName,
|
||||
billing_last_email: orderDetails.billing.invoiceMail
|
||||
}
|
||||
}).then(response => {
|
||||
if (typeof response.data !== 'undefined' && 'messages' in response.data) {
|
||||
|
||||
Reference in New Issue
Block a user