Skip to content

Commit

Permalink
updated Order dropin
Browse files Browse the repository at this point in the history
  • Loading branch information
KostiantynFandeliuk committed Feb 18, 2025
1 parent b607bf8 commit 8ef9c8d
Show file tree
Hide file tree
Showing 6 changed files with 26 additions and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
export declare const PRODUCT_DETAILS_FRAGMENT = "\n fragment PRODUCT_DETAILS_FRAGMENT on ProductInterface {\n __typename\n canonical_url\n url_key\n uid\n name\n sku\n only_x_left_in_stock\n gift_wrapping_price {\n currency\n value\n }\n stock_status\n thumbnail {\n label\n url\n }\n price_range {\n maximum_price {\n regular_price {\n currency\n value\n }\n }\n }\n }\n";
export declare const PRICE_DETAILS_FRAGMENT = "\n fragment PRICE_DETAILS_FRAGMENT on OrderItemInterface {\n prices {\n price_including_tax {\n value\n currency\n }\n original_price {\n value\n currency\n }\n original_price_including_tax {\n value\n currency\n }\n price {\n value\n currency\n }\n }\n }\n";
export declare const GIFT_CARD_DETAILS_FRAGMENT = "\n fragment GIFT_CARD_DETAILS_FRAGMENT on GiftCardOrderItem {\n ...PRICE_DETAILS_FRAGMENT\n gift_message {\n message\n }\n gift_card {\n recipient_name\n recipient_email\n sender_name\n sender_email\n message\n }\n }\n";
export declare const ORDER_ITEM_DETAILS_FRAGMENT = "\n fragment ORDER_ITEM_DETAILS_FRAGMENT on OrderItemInterface {\n gift_wrapping {\n __typename\n uid\n design\n image {\n url\n label\n }\n price {\n currency\n value\n }\n }\n __typename\n status\n product_sku\n eligible_for_return\n product_name\n product_url_key\n id\n quantity_ordered\n quantity_shipped\n quantity_canceled\n quantity_invoiced\n quantity_refunded\n quantity_return_requested\n product_sale_price {\n value\n currency\n }\n selected_options {\n label\n value\n }\n product {\n ...PRODUCT_DETAILS_FRAGMENT\n }\n ...PRICE_DETAILS_FRAGMENT\n }\n";
export declare const ORDER_ITEM_DETAILS_FRAGMENT = "\n fragment ORDER_ITEM_DETAILS_FRAGMENT on OrderItemInterface {\n gift_wrapping {\n __typename\n uid\n design\n image {\n url\n label\n }\n price {\n currency\n value\n }\n }\n __typename\n status\n product_sku\n eligible_for_return\n product_name\n product_url_key\n id\n quantity_ordered\n quantity_shipped\n quantity_canceled\n quantity_invoiced\n quantity_refunded\n quantity_return_requested\n gift_message {\n ...GIFT_MESSAGE_FRAGMENT\n }\n product_sale_price {\n value\n currency\n }\n selected_options {\n label\n value\n }\n product {\n ...PRODUCT_DETAILS_FRAGMENT\n }\n ...PRICE_DETAILS_FRAGMENT\n }\n";
export declare const BUNDLE_ORDER_ITEM_DETAILS_FRAGMENT = "\n fragment BUNDLE_ORDER_ITEM_DETAILS_FRAGMENT on BundleOrderItem {\n ...PRICE_DETAILS_FRAGMENT\n bundle_options {\n uid\n label\n values {\n uid\n product_name\n }\n }\n }\n";
export declare const DOWNLOADABLE_ORDER_ITEMS_FRAGMENT = "\n fragment DOWNLOADABLE_ORDER_ITEMS_FRAGMENT on DownloadableOrderItem {\n product_name\n downloadable_links {\n sort_order\n title\n }\n }\n";
export declare const ORDER_ITEM_FRAGMENT: string;
Expand Down
7 changes: 4 additions & 3 deletions scripts/__dropins__/storefront-order/chunks/initialize.js

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -42,13 +42,19 @@ export type OrderItemProductModel = {
};
};
export type OrderItemModel = {
giftMessage: {
senderName: string;
recipientName: string;
message: string;
};
giftWrappingPrice: MoneyProps;
productGiftWrapping: {
uid: string;
design: string;
selected: boolean;
image: {
url: string;
design: string;
label: string;
};
price: MoneyProps;
}[];
Expand Down
11 changes: 7 additions & 4 deletions scripts/__dropins__/storefront-order/fragments.js
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,9 @@ const u=`
quantity_invoiced
quantity_refunded
quantity_return_requested
gift_message {
...GIFT_MESSAGE_FRAGMENT
}
product_sale_price {
value
currency
Expand Down Expand Up @@ -358,7 +361,7 @@ const u=`
${e}
${R}
${E}
`,o=`
`,A=`
fragment APPLIED_GIFT_CARDS_FRAGMENT on ApplyGiftCardToOrder {
__typename
code
Expand All @@ -367,7 +370,7 @@ const u=`
currency
}
}
`,A=`
`,o=`
fragment GIFT_MESSAGE_FRAGMENT on GiftMessage {
__typename
from
Expand All @@ -387,7 +390,7 @@ const u=`
currency
}
}
`,l=`
`,s=`
fragment AVAILABLE_GIFT_WRAPPING_FRAGMENT on GiftWrapping {
__typename
uid
Expand All @@ -401,4 +404,4 @@ const u=`
value
}
}
`;export{e as ADDRESS_FRAGMENT,o as APPLIED_GIFT_CARDS_FRAGMENT,l as AVAILABLE_GIFT_WRAPPING_FRAGMENT,a as BUNDLE_ORDER_ITEM_DETAILS_FRAGMENT,i as DOWNLOADABLE_ORDER_ITEMS_FRAGMENT,t as GIFT_CARD_DETAILS_FRAGMENT,A as GIFT_MESSAGE_FRAGMENT,d as GIFT_WRAPPING_FRAGMENT,T as GUEST_ORDER_FRAGMENT,n as ORDER_ITEM_DETAILS_FRAGMENT,E as ORDER_ITEM_FRAGMENT,c as ORDER_SUMMARY_FRAGMENT,r as PRICE_DETAILS_FRAGMENT,_ as PRODUCT_DETAILS_FRAGMENT,u as REQUEST_RETURN_ORDER_FRAGMENT,R as RETURNS_FRAGMENT};
`;export{e as ADDRESS_FRAGMENT,A as APPLIED_GIFT_CARDS_FRAGMENT,s as AVAILABLE_GIFT_WRAPPING_FRAGMENT,a as BUNDLE_ORDER_ITEM_DETAILS_FRAGMENT,i as DOWNLOADABLE_ORDER_ITEMS_FRAGMENT,t as GIFT_CARD_DETAILS_FRAGMENT,o as GIFT_MESSAGE_FRAGMENT,d as GIFT_WRAPPING_FRAGMENT,T as GUEST_ORDER_FRAGMENT,n as ORDER_ITEM_DETAILS_FRAGMENT,E as ORDER_ITEM_FRAGMENT,c as ORDER_SUMMARY_FRAGMENT,r as PRICE_DETAILS_FRAGMENT,_ as PRODUCT_DETAILS_FRAGMENT,u as REQUEST_RETURN_ORDER_FRAGMENT,R as RETURNS_FRAGMENT};
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,19 @@ import { OrderDataModel, OrderItemModel } from '../data/models';
export declare const categorizeProducts: (order: OrderDataModel) => {
returnedList: {
totalQuantity: number;
giftMessage: {
senderName: string;
recipientName: string;
message: string;
};
giftWrappingPrice: import('../types/index').MoneyProps;
productGiftWrapping: {
uid: string;
design: string;
selected: boolean;
image: {
url: string;
design: string;
label: string;
};
price: import('../types/index').MoneyProps;
}[];
Expand Down
1 change: 0 additions & 1 deletion scripts/__dropins__/storefront-order/reload

This file was deleted.

0 comments on commit 8ef9c8d

Please sign in to comment.