@akinon/next 1.48.0-rc.4 → 1.48.0-rc.6
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/CHANGELOG.md +12 -0
- package/data/client/checkout.ts +20 -0
- package/data/urls.ts +2 -1
- package/package.json +2 -2
- package/types/commerce/checkout.ts +2 -0
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,17 @@
|
|
|
1
1
|
# @akinon/next
|
|
2
2
|
|
|
3
|
+
## 1.48.0-rc.6
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- 04115e5: ZERO-2898: Update PreOrder type
|
|
8
|
+
|
|
9
|
+
## 1.48.0-rc.5
|
|
10
|
+
|
|
11
|
+
### Minor Changes
|
|
12
|
+
|
|
13
|
+
- 20da358: ZERO-2898: Add setDeliveryBags mutation to checkout api
|
|
14
|
+
|
|
3
15
|
## 1.48.0-rc.4
|
|
4
16
|
|
|
5
17
|
### Minor Changes
|
package/data/client/checkout.ts
CHANGED
|
@@ -677,6 +677,25 @@ export const checkoutApi = api.injectEndpoints({
|
|
|
677
677
|
}
|
|
678
678
|
})
|
|
679
679
|
}),
|
|
680
|
+
setDeliveryBags: build.mutation<
|
|
681
|
+
CheckoutResponse,
|
|
682
|
+
{ sku: string; quantity?: number }
|
|
683
|
+
>({
|
|
684
|
+
query: ({ sku, quantity }) => {
|
|
685
|
+
const body = {
|
|
686
|
+
product: sku,
|
|
687
|
+
...(quantity !== undefined && { quantity })
|
|
688
|
+
};
|
|
689
|
+
|
|
690
|
+
return {
|
|
691
|
+
url: buildClientRequestUrl(checkout.deliveryBagsPage, {
|
|
692
|
+
useFormData: true
|
|
693
|
+
}),
|
|
694
|
+
method: 'POST',
|
|
695
|
+
body
|
|
696
|
+
};
|
|
697
|
+
}
|
|
698
|
+
}),
|
|
680
699
|
setAttributeBasedShippingOptions: build.mutation<
|
|
681
700
|
CheckoutResponse,
|
|
682
701
|
Record<string, number>
|
|
@@ -731,5 +750,6 @@ export const {
|
|
|
731
750
|
useGetCheckoutLoyaltyBalanceQuery,
|
|
732
751
|
usePayWithLoyaltyBalanceMutation,
|
|
733
752
|
useSetOrderNoteMutation,
|
|
753
|
+
useSetDeliveryBagsMutation,
|
|
734
754
|
useSetAttributeBasedShippingOptionsMutation
|
|
735
755
|
} = checkoutApi;
|
package/data/urls.ts
CHANGED
|
@@ -112,7 +112,8 @@ export const checkout = {
|
|
|
112
112
|
setOrderNote: '/orders/checkout/?page=OrderNotePage',
|
|
113
113
|
couponSelectionPage: '/orders/checkout/?page=CouponSelectionPage',
|
|
114
114
|
setAttributeBasedShippingOption:
|
|
115
|
-
'/orders/checkout/?page=AttributeBasedShippingOptionSelectionPage'
|
|
115
|
+
'/orders/checkout/?page=AttributeBasedShippingOptionSelectionPage',
|
|
116
|
+
deliveryBagsPage: '/orders/checkout/?page=DeliveryBagsPage'
|
|
116
117
|
};
|
|
117
118
|
|
|
118
119
|
export const flatpage = {
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@akinon/next",
|
|
3
3
|
"description": "Core package for Project Zero Next",
|
|
4
|
-
"version": "1.48.0-rc.
|
|
4
|
+
"version": "1.48.0-rc.6",
|
|
5
5
|
"private": false,
|
|
6
6
|
"license": "MIT",
|
|
7
7
|
"bin": {
|
|
@@ -30,7 +30,7 @@
|
|
|
30
30
|
"set-cookie-parser": "2.6.0"
|
|
31
31
|
},
|
|
32
32
|
"devDependencies": {
|
|
33
|
-
"@akinon/eslint-plugin-projectzero": "1.48.0-rc.
|
|
33
|
+
"@akinon/eslint-plugin-projectzero": "1.48.0-rc.6",
|
|
34
34
|
"@types/react-redux": "7.1.30",
|
|
35
35
|
"@types/set-cookie-parser": "2.4.7",
|
|
36
36
|
"@typescript-eslint/eslint-plugin": "6.7.4",
|
|
@@ -2,6 +2,7 @@ import { Address } from './address';
|
|
|
2
2
|
import { Basket } from './basket';
|
|
3
3
|
import { RetailStore } from './misc';
|
|
4
4
|
import { PaymentOption } from './order';
|
|
5
|
+
import { Product } from './product';
|
|
5
6
|
|
|
6
7
|
export enum CheckoutStep {
|
|
7
8
|
Shipping = 'shipping',
|
|
@@ -97,6 +98,7 @@ export interface PreOrder {
|
|
|
97
98
|
credit_payment_option?: CheckoutCreditPaymentOption;
|
|
98
99
|
data_source_shipping_options: any;
|
|
99
100
|
attribute_based_shipping_options?: AttributeBasedShippingOption[];
|
|
101
|
+
bags?: Product[];
|
|
100
102
|
}
|
|
101
103
|
|
|
102
104
|
export interface GuestLoginFormParams {
|