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K4D,aAG1DW,WAAYiU,gBAOzBhB,GAGEzD,EAAkB,CAAC2E,EAAqBC,EAA6BC,EAA2BnO,KACzG,IAAKkO,IAAcC,EACf,MAAO,GAGX,MAIMC,EADgB,IAAIC,KAAKC,eAAetO,EAHE,CAC5CuO,SAAU,QAGajT,OAAO,IAAI+E,KAAK6N,IAQrCM,EAAoB,IAAIH,KAAKC,eAAetO,EANE,CAChDyO,KAAM,UACNC,OAAQ,UACRC,QAAQ,EACRJ,SAAU,QAId,MAAO,GAAGH,MADO9S,EAAAA,EAAAA,QAAO2S,EAAaO,EAAkBlT,OAAO,IAAI+E,KAAK6N,IAAaM,EAAkBlT,OAAO,IAAI+E,KAAK8N","sources":["webpack://msdyn365.commerce.online/./src/common/address.tsx?e12e","webpack://msdyn365.commerce.online/./src/common/buy-selected-component.tsx?9efa","webpack://msdyn365.commerce.online/./src/common/get-groups.tsx?699f","webpack://msdyn365.commerce.online/./src/common/get-order-information.tsx?c2e1","webpack://msdyn365.commerce.online/./src/common/get-sales-line.tsx?61be","webpack://msdyn365.commerce.online/./src/common/get-sales-lines.tsx?10c6","webpack://msdyn365.commerce.online/./src/common/label.tsx?9c2c","webpack://msdyn365.commerce.online/./src/common/utilities.ts?0172"],"sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation.\n * All rights reserved. See LICENSE in the project root for license information.\n */\n\nimport { Address as AddressRetail } from '@msdyn365-commerce/retail-proxy';\nimport * as React from 'react';\n\nexport type addressType = 'store' | 'ship';\n\nexport interface IShippingAddressProps {\n moduleName: string;\n address: AddressRetail;\n deliveryType: string;\n showCompleteAddress?: boolean;\n resource: {\n shipToLabel: string;\n storeLabel: string;\n phoneLabel: string;\n phoneAriaLabel: string;\n };\n}\n\nconst Address: React.SFC = ({\n moduleName,\n address,\n deliveryType,\n showCompleteAddress,\n resource: { shipToLabel, storeLabel, phoneLabel }\n}) => (\n
\n
{deliveryType !== 'ship' ? storeLabel : shipToLabel}
\n {address.Name && {address.Name}}\n {showCompleteAddress ? (\n <>\n {address.Street && (\n \n {address.Street}\n {` `}\n \n )}\n {address.City && {address.City}}\n {address.State && {`, ${address.State}`}}\n {address.County && {`, ${address.County}`}}\n {address.ZipCode && {` ${address.ZipCode}`}}\n {address.ThreeLetterISORegionName && (\n {` ${address.ThreeLetterISORegionName}`}\n )}\n {address.Phone && (\n \n {phoneLabel}\n \n )}\n \n ) : (\n address.FullAddress && {address.FullAddress}\n )}\n
\n);\n\nexport default React.memo(Address);\n","/*!\n * Copyright (c) Microsoft Corporation.\n * All rights reserved. See LICENSE in the project root for license information.\n */\n\nimport { AddToCartComponent, IAddToCartResources, OrderDetailsProduct } from '@msdyn365-commerce/components';\nimport { getUrlSync, IComponentProps, ICoreContext } from '@msdyn365-commerce/core';\nimport { ArrayExtensions, ObjectExtensions } from '@msdyn365-commerce-modules/retail-actions';\nimport { Button } from '@msdyn365-commerce-modules/utilities';\nimport React from 'react';\n\n/**\n * The data which the component should operate.\n */\nexport interface IBuySelectedData {\n products: OrderDetailsProduct[];\n}\n\n/**\n * The resources needed to render a buy selected component.\n */\nexport interface IBuySelectedResources {\n orderDetailsUnavailableProductText?: string;\n orderDetailsBuySelectedButtonText?: string;\n orderDetailsBuySelectedButtonAriaLabel?: string;\n orderDetailsBuySelectedAddingToCartErrorNotificationTitle?: string;\n orderDetailsBuySelectedAddingToCartErrorNotificationCloseAriaLabel?: string;\n orderDetailsBuyItAgainLabel?: string;\n orderDetailsBuyItAgainAriaLabel?: string;\n orderDetailsGoToCartText?: string;\n orderDetailsDialogCloseText?: string;\n orderDetailsSingleItemText?: string;\n orderDetailsMultiLineItemFormatText?: string;\n orderDetailsMultiLinesFormatText?: string;\n orderDetailsHeaderMessageText?: string;\n orderDetailsMultiItemsValidationErrorMessage?: string;\n orderDetailsOneErrorText?: string;\n orderDetailsMultiErrorText?: string;\n addedQuantityText?: string;\n originalPriceText?: string;\n currentPriceText?: string;\n freePriceText?: string;\n}\n\n/**\n * Configuration of a buy selected component.\n */\nexport interface IBuySelectedProps extends IComponentProps {\n className: string;\n context: ICoreContext;\n\n resources: IBuySelectedResources;\n\n isIcon?: boolean;\n isReorderingEnabled?: boolean;\n}\n\n/**\n * Get the dialog strings.\n * @param props -- The buy selected props.\n * @returns The add to cart resources.\n */\nexport const getDialogStrings = (props: IBuySelectedProps): IAddToCartResources => {\n return {\n goToCartText: props.resources.orderDetailsGoToCartText ?? '',\n continueShoppingText: props.resources.orderDetailsDialogCloseText ?? '',\n closeNotificationLabel: props.resources.orderDetailsBuySelectedAddingToCartErrorNotificationCloseAriaLabel ?? '',\n headerItemOneText: props.resources.orderDetailsSingleItemText ?? '',\n headerItemFormatText: props.resources.orderDetailsMultiLineItemFormatText ?? '',\n headerLinesFormatText: props.resources.orderDetailsMultiLinesFormatText ?? '',\n headerMessageText: props.resources.orderDetailsHeaderMessageText ?? '',\n freePriceText: props.resources.freePriceText ?? '',\n originalPriceText: props.resources.originalPriceText ?? '',\n currentPriceText: props.resources.currentPriceText ?? '',\n addedQuantityText: props.resources.addedQuantityText ?? '',\n buyAgainNotificationTitle: props.resources.orderDetailsBuySelectedAddingToCartErrorNotificationTitle ?? '',\n buyAgainNotificationCloseAriaLabel: props.resources.orderDetailsBuySelectedAddingToCartErrorNotificationCloseAriaLabel ?? '',\n validationErrorMessage: props.resources.orderDetailsMultiItemsValidationErrorMessage,\n oneErrorText: props.resources.orderDetailsOneErrorText,\n multiErrorsText: props.resources.orderDetailsMultiErrorText\n };\n};\n\n/**\n * Renders a button which adds given products to the cart.\n * @param props - Configuration of the component.\n * @returns A react element or null if no products were given.\n */\nexport const BuySelectedComponent: React.FC = (props: IBuySelectedProps): JSX.Element | null => {\n const products = props.data.products.filter(product => !ObjectExtensions.isNullOrUndefined(product.simpleProduct));\n const buttonLabel = props.isIcon\n ? ''\n : props.resources.orderDetailsBuySelectedButtonText ?? props.resources.orderDetailsBuyItAgainLabel;\n const buttonAriaLabel = props.resources.orderDetailsBuySelectedButtonAriaLabel ?? props.resources.orderDetailsBuyItAgainAriaLabel;\n\n const singleProductCount = 1;\n if (props.data.products.length === singleProductCount && !props.data.products[0].isProductAvailable) {\n // Return disabled button\n return (\n \n {buttonLabel}\n \n );\n }\n\n if (!ArrayExtensions.hasElements(products)) {\n // Return disabled button\n return (\n \n );\n }\n\n const firstProduct: OrderDetailsProduct = products[0];\n\n // Reorder is not enable, buy again button link to product details page.\n if (!props.isReorderingEnabled) {\n return (\n \n );\n }\n\n const shouldSkipSiteSettings: boolean = true;\n const dialogStrings: IAddToCartResources = getDialogStrings(props);\n\n return (\n \n );\n};\n","/*!\n * Copyright (c) Microsoft Corporation.\n * All rights reserved. See LICENSE in the project root for license information.\n */\n\nimport { format, INodeProps } from '@msdyn365-commerce-modules/utilities';\nimport classNames from 'classnames';\nimport * as React from 'react';\n\nimport { ISalesLine } from './get-sales-line';\nimport { groupSalesLines, IDeliveryType, ISalesStatusCode } from './utilities';\n\nexport interface IGroupDelivery {\n deliveryProps: INodeProps;\n pickupProps: INodeProps;\n showTimeslot: boolean;\n heading: React.ReactNode;\n count: React.ReactNode;\n processing: React.ReactNode;\n trackingInfo: React.ReactNode;\n address: React.ReactNode;\n shippingItemsToYou?: React.ReactNode;\n pickupDateTimeslot?: React.ReactNode;\n shippedStatusCheck?: React.ReactNode;\n}\n\nexport interface IGroup {\n groupProps: INodeProps;\n salesLinesProps: INodeProps;\n delivery: IGroupDelivery;\n salesLines: ISalesLine[];\n address: React.ReactNode;\n\n // Row data\n data: {\n count: number;\n deliveryType: IDeliveryType;\n salesStatus: ISalesStatusCode;\n };\n isCashAndCarryTransaction?: boolean;\n}\n\nexport interface IGroupsInput {\n moduleName: string;\n salesLines: ISalesLine[];\n resources: {\n orderItemLabel: string;\n orderItemsLabel: string;\n pickupItemsHeader?: string;\n pickingItemsLabel?: string;\n shippingAddressTitle?: string;\n shippingItemToYouLabel?: string;\n emailItemsHeader?: string;\n emailingItemsLabel?: string;\n };\n showAddress?: boolean;\n isConfirmationView?: boolean;\n showTimeslot?: boolean;\n retailMultiplePickUpOptionEnabled?: boolean;\n isCashAndCarryTransaction?: boolean;\n isSelectionModeEnabled?: boolean;\n}\n\nexport interface IGroups {\n groupsProps: INodeProps;\n groups: IGroup[];\n}\n\n/**\n * Creates sales lines node props object.\n * @param moduleName - Module name to use as a class name prefix.\n * @param isSelectionModeEnabled - Specifies if the selection mode is enabled for the sales lines.\n * @returns Sales lines node props with the class name to use for the sales lines container.\n */\nconst getSalesLinesProps: (moduleName: string, isSelectionModeEnabled?: boolean) => INodeProps = (\n moduleName: string,\n isSelectionModeEnabled?: boolean\n): INodeProps => {\n const className = `${moduleName}__sales-lines`;\n const salesLinesProps: INodeProps = {\n className: classNames(\n className,\n isSelectionModeEnabled ? `${className}__selection-global-enabled` : `${className}__selection-global-disabled`\n )\n };\n return salesLinesProps;\n};\n\nexport const getGroups = ({\n moduleName,\n salesLines,\n showAddress,\n showTimeslot,\n isConfirmationView,\n retailMultiplePickUpOptionEnabled,\n isCashAndCarryTransaction,\n isSelectionModeEnabled,\n resources: {\n orderItemLabel,\n orderItemsLabel,\n pickupItemsHeader,\n pickingItemsLabel,\n shippingAddressTitle,\n shippingItemToYouLabel,\n emailItemsHeader,\n emailingItemsLabel\n }\n}: IGroupsInput): IGroups => {\n const groups = groupSalesLines(salesLines).map(group => {\n const { deliveryType, salesStatus, count, salesLines: _salesLines } = group;\n const itemLabel = count === 1 ? orderItemLabel : orderItemsLabel;\n const pickingItemsLabelText = pickingItemsLabel && format(pickingItemsLabel, count, itemLabel);\n const shippingItemsToYouText = shippingItemToYouLabel && format(shippingItemToYouLabel, count, itemLabel);\n const emailingItemsLabelText = emailingItemsLabel && format(emailingItemsLabel, count, itemLabel);\n const multiplePickup = deliveryType === 'ship' ? 'ship' : deliveryType === 'email' ? 'email' : 'pickup';\n const groupProps = { className: `${moduleName}__group-deliveryType-${multiplePickup} salesStatus-${salesStatus}` };\n\n const salesLinesProps = getSalesLinesProps(moduleName, isSelectionModeEnabled);\n const address = _salesLines[0].address;\n const trackingInfo = _salesLines[0].trackingInfo;\n const isProcessing = _salesLines[0].data.salesStatus === 'processing';\n const pickDateTimeslot = _salesLines[0].pickupDateTimeslot;\n const shippedStatusCheck = _salesLines[0].data.salesStatus;\n const multiplePickUp = retailMultiplePickUpOptionEnabled ? 'multiple-pickUp' : '';\n const delivery: IGroupDelivery = {\n deliveryProps: { className: `${moduleName}__group-delivery ${multiplePickUp}` },\n pickupProps: { className: `${moduleName}__delivery-container` },\n heading: (\n \n {isProcessing\n ? isConfirmationView\n ? deliveryType === 'pickUp'\n ? pickupItemsHeader\n : deliveryType === 'ship'\n ? shippingAddressTitle\n : deliveryType === 'email'\n ? emailItemsHeader\n : deliveryType\n : _salesLines[0].deliveryType\n : _salesLines[0].salesStatus}\n \n ),\n processing: isProcessing ? (\n {_salesLines[0].salesStatus}\n ) : (\n undefined\n ),\n count: !isConfirmationView && {`(${count} ${itemLabel})`},\n shippingItemsToYou:\n isConfirmationView && deliveryType === 'ship' ? (\n {shippingItemsToYouText}\n ) : deliveryType === 'pickUp' ? (\n {pickingItemsLabelText}\n ) : deliveryType === 'email' ? (\n {emailingItemsLabelText}\n ) : (\n {pickingItemsLabelText}\n ),\n trackingInfo,\n address,\n pickupDateTimeslot: pickDateTimeslot,\n showTimeslot: showTimeslot || false,\n shippedStatusCheck\n };\n return {\n groupProps,\n salesLinesProps,\n delivery,\n salesLines: _salesLines,\n address: showAddress && address,\n data: {\n count,\n deliveryType,\n salesStatus\n },\n isCashAndCarryTransaction\n };\n });\n\n return {\n groupsProps: { className: `${moduleName}__groups` },\n groups\n };\n};\n","/*!\n * Copyright (c) Microsoft Corporation.\n * All rights reserved. See LICENSE in the project root for license information.\n */\n\nimport { PriceComponent } from '@msdyn365-commerce/components';\nimport { ChannelIdentity, OrderShipments, OrgUnitLocation, SalesOrder } from '@msdyn365-commerce/retail-proxy';\nimport { ArrayExtensions } from '@msdyn365-commerce-modules/retail-actions';\nimport { INodeProps } from '@msdyn365-commerce-modules/utilities';\nimport get from 'lodash/get';\nimport QRCode from 'qrcode.react';\nimport * as React from 'react';\n\nimport { countItems, IModuleComponentProps, IPriceContext } from './utilities';\n\n/**\n * Interface for order information input resources.\n */\nexport interface IOrderInformationInputResources {\n receiptEmailMessage?: string;\n orderItemLabel: string;\n orderItemsLabel: string;\n processingLabel: string;\n orderIdLabel: string;\n receiptIdLabel: string;\n confirmationIdLabel: string;\n trackingLabel: string;\n trackingAriaLabel: string;\n trackingComingSoonLabel: string;\n posChannelNameText?: string;\n onlineStoreChannelNameText?: string;\n orderPlacedOnLabel?: string;\n qrCodeSrText?: string;\n callCenterChannelNameText?: string;\n}\n\n/**\n * Interface for order information input.\n */\nexport interface IOrderInformationInput {\n moduleName: string;\n channelReferenceId?: string;\n channelName?: string;\n channelAddress?: string;\n showChannelInfo?: boolean;\n receiptEmail?: string;\n createdDate?: string;\n amount?: number;\n priceContext: IPriceContext;\n salesId?: string;\n receiptId?: string;\n hasTrackingInfo?: boolean;\n count?: number;\n resources: IOrderInformationInputResources;\n isSalesInvoice?: boolean;\n shouldShowQrCode?: boolean;\n channelTypeValue?: number;\n}\n\nconst callCenterChannelTypeValue = 4;\n\n/**\n * Interface for order information.\n */\nexport interface IOrderInformation {\n orderInformationProps: INodeProps;\n channelName: React.ReactNode;\n channelAddress: React.ReactNode;\n salesId: React.ReactNode;\n receiptId: React.ReactNode;\n receiptEmail: React.ReactNode;\n createdDate: React.ReactNode;\n count: React.ReactNode;\n amount: React.ReactNode;\n channelReferenceId: React.ReactNode;\n}\n\n/**\n * The order confirmation ID node.\n * @param channelReferenceId - The order confirmation id.\n * @param moduleName - The module name.\n * @param confirmationIdLabel - The confirmation label.\n * @param shouldShowQrCode - Should the view show the QR code.\n * @param qrCodeSrText - The screen reader text of the QR code.\n * @returns The react node for order confirmation ID.\n */\nconst getChannelReference = (\n channelReferenceId: string | undefined,\n moduleName: string,\n confirmationIdLabel: string,\n shouldShowQrCode: boolean | undefined,\n qrCodeSrText?: string\n): React.ReactNode | undefined => {\n const confirmationIdNode: React.ReactNode = (\n \n {`${confirmationIdLabel} `}\n {channelReferenceId}\n \n );\n return (\n channelReferenceId &&\n (shouldShowQrCode !== undefined && shouldShowQrCode ? (\n
\n {confirmationIdNode}\n
\n \n \n {qrCodeSrText}\n \n
\n
\n ) : (\n confirmationIdNode\n ))\n );\n};\n\n/**\n * Get Channel name to display on order history.\n * @param channelTypeValue - The channel type.\n * @param moduleName - The module name.\n * @param callCenterChannelNameText - The call center channel name.\n * @param channelAddress - Channel Address.\n * @param posChannelNameText - POS channel name.\n * @param channelName - Channel Name.\n * @param onlineStoreChannelNameText - Online store channel name.\n * @returns The react node for channel name label.\n */\nexport const getChannelName = (\n channelTypeValue: number | undefined,\n moduleName: string,\n callCenterChannelNameText: string | undefined,\n channelAddress: string | undefined,\n posChannelNameText: string | undefined,\n channelName: string | undefined,\n onlineStoreChannelNameText: string | undefined\n): React.ReactNode => {\n let channelNameNode: React.ReactNode;\n if (channelTypeValue === callCenterChannelTypeValue) {\n channelNameNode = {callCenterChannelNameText};\n } else if (channelAddress) {\n const posChannelName = `${posChannelNameText ?? ''} ${channelName ?? ''}`;\n channelNameNode = {posChannelName};\n } else {\n channelNameNode = {onlineStoreChannelNameText};\n }\n return channelNameNode;\n};\n\n/**\n * Get order information.\n * @param {IOrderInformationInput} param0 The input for order information.\n * @returns {IOrderInformation} The order information.\n */\nexport const getOrderInformation = ({\n moduleName,\n channelReferenceId,\n channelName,\n channelAddress,\n channelTypeValue,\n showChannelInfo,\n receiptEmail,\n createdDate,\n amount,\n priceContext,\n salesId,\n receiptId,\n count,\n resources: {\n receiptEmailMessage,\n orderItemLabel,\n orderItemsLabel,\n orderIdLabel,\n receiptIdLabel,\n confirmationIdLabel,\n posChannelNameText,\n onlineStoreChannelNameText,\n orderPlacedOnLabel,\n qrCodeSrText,\n callCenterChannelNameText\n },\n isSalesInvoice,\n shouldShowQrCode\n}: IOrderInformationInput): IOrderInformation => {\n const channelNameNode: React.ReactNode = getChannelName(\n channelTypeValue,\n moduleName,\n callCenterChannelNameText,\n channelAddress,\n posChannelNameText,\n channelName,\n onlineStoreChannelNameText\n );\n\n const orderInformation = {\n orderInformationProps: { className: `${moduleName}__order-information` },\n channelName: showChannelInfo && channelName && channelNameNode,\n channelAddress: showChannelInfo && channelAddress && (\n {channelAddress}\n ),\n salesId: salesId ? {`${orderIdLabel} ${salesId}`} : '',\n receiptId: receiptId ? (\n {`${receiptIdLabel} ${receiptId}`}\n ) : (\n ''\n ),\n receiptEmail: receiptEmail && (\n \n {receiptEmailMessage}\n {receiptEmail}\n \n ),\n createdDate: !isSalesInvoice && createdDate && (\n \n {orderPlacedOnLabel}\n {` `}\n {createdDate}\n \n ),\n count: !isSalesInvoice && count !== undefined && count > 0 && (\n \n {count === 1 ? `${count} ${orderItemLabel}` : `${count} ${orderItemsLabel}`}\n \n ),\n amount: !isSalesInvoice && (amount || amount === 0) && (\n \n ),\n channelReferenceId: getChannelReference(channelReferenceId, moduleName, confirmationIdLabel, shouldShowQrCode, qrCodeSrText)\n };\n\n return orderInformation;\n};\n\n/**\n * Interface for order information props.\n */\ninterface IProps extends IModuleComponentProps {\n resources: IOrderInformationInputResources;\n}\n\n/**\n * Retrieves order channel name.\n * @param order - Order info.\n * @param channelIdentities - Channels data.\n * @returns String with the name of the channel or an empty string.\n */\nexport const getOrderChannelName: (order: SalesOrder | OrderShipments, channelIdentities?: ChannelIdentity[]) => string = (\n order: SalesOrder | OrderShipments,\n channelIdentities?: ChannelIdentity[]\n) => {\n const orderChannel = channelIdentities?.find(channel => {\n return channel.RecordId === order.ChannelId;\n });\n\n const channelName = orderChannel?.Name ?? '';\n return channelName;\n};\n\n/**\n * Retrieves order channel type value.\n * @param order - Order info.\n * @param channelIdentities - Channels data.\n * @returns The channel type value of the order.\n */\nexport const getOrderChannelTypeValue: (order: SalesOrder | OrderShipments, channelIdentities?: ChannelIdentity[]) => number | undefined = (\n order: SalesOrder | OrderShipments,\n channelIdentities?: ChannelIdentity[]\n) => {\n const orderChannel = channelIdentities?.find(channel => {\n return channel.RecordId === order.ChannelId;\n });\n\n const channelType = orderChannel?.ChannelType.Value;\n return channelType;\n};\n\n/**\n * Retrieves order channel address.\n * @param order - Order info.\n * @param orgUnitLocations - OrgUnitLocation data.\n * @returns String with the address of the channel or an empty string.\n */\nexport const getOrderChannelAddress: (order: SalesOrder | OrderShipments, orgUnitLocations?: OrgUnitLocation[]) => string = (\n order: SalesOrder | OrderShipments,\n orgUnitLocations?: OrgUnitLocation[]\n) => {\n const orderOrgUnitLocation = orgUnitLocations?.find(location => {\n return location.ChannelId === order.ChannelId;\n });\n\n const channelAddress = orderOrgUnitLocation?.Address ?? '';\n return channelAddress;\n};\n\n/**\n * Get order information input.\n * @param {IProps} props The properties.\n * @param {string} moduleName The module name.\n * @param {SalesOrder | OrderShipments} order The sales order or order shipments.\n * @param {IPriceContext} priceContext The price context.\n * @param {ChannelIdentity[]} channelIdentities A list of channel identities.\n * @param {OrgUnitLocation[]} orgUnitLocations A list of organization unit locations.\n * @param {boolean} showChannelInfo Should the view show channel information.\n * @param {boolean} isSalesInvoice Is this a sales invoice.\n * @param {boolean} shouldShowQrCode Should the view show QR code.\n * @returns {IOrderInformationInput} The order information input.\n */\nexport const getOrderInformationInput = (\n props: IProps,\n moduleName: string,\n order: SalesOrder | OrderShipments,\n priceContext: IPriceContext,\n channelIdentities?: ChannelIdentity[],\n orgUnitLocations?: OrgUnitLocation[],\n showChannelInfo?: boolean,\n isSalesInvoice?: boolean,\n shouldShowQrCode?: boolean\n): IOrderInformationInput => {\n const {\n resources,\n context: {\n request: {\n apiSettings: { channelId }\n }\n }\n } = props;\n\n // @ts-expect-error OrderShipments doesn't has ChannelId\n const showTrackingInfo = !!order.ChannelId && order.ChannelId === channelId;\n\n const locale = get(props, 'context.request.locale') || 'en-US';\n const count = order.SalesLines && ArrayExtensions.hasElements(order.SalesLines) ? countItems(order.SalesLines) : 0;\n\n return {\n moduleName,\n createdDate: (order.CreatedDateTime && new Date(order.CreatedDateTime).toLocaleDateString(locale)) || '',\n salesId: order.SalesId,\n receiptId: order.ReceiptId,\n showChannelInfo,\n\n // @ts-expect-error OrderShipments doesn't has ReceiptEmail\n receiptEmail: order.ReceiptEmail,\n channelReferenceId: order.ChannelReferenceId,\n channelName: getOrderChannelName(order, channelIdentities),\n channelAddress: getOrderChannelAddress(order, orgUnitLocations),\n amount: order.TotalAmount ?? 0,\n priceContext,\n count,\n resources,\n isSalesInvoice,\n shouldShowQrCode,\n channelTypeValue: getOrderChannelTypeValue(order, channelIdentities)\n };\n};\n","/*!\n * Copyright (c) Microsoft Corporation.\n * All rights reserved. See LICENSE in the project root for license information.\n */\n\nimport { CartLineItemComponent, OrderDetailsProduct } from '@msdyn365-commerce/components';\nimport MsDyn365, { IGridSettings, IImageSettings, Image, IRequestContext } from '@msdyn365-commerce/core';\nimport {\n ChannelDeliveryOptionConfiguration,\n format,\n ProductDeliveryOptions,\n SalesLine,\n Shipment,\n SimpleProduct\n} from '@msdyn365-commerce/retail-proxy';\nimport { ArrayExtensions, getFallbackImageUrl, getProductPageUrlSync, ObjectExtensions } from '@msdyn365-commerce-modules/retail-actions';\nimport { INodeProps, ITelemetryContent } from '@msdyn365-commerce-modules/utilities';\nimport classnames from 'classnames';\nimport { Observer } from 'mobx-react';\nimport * as React from 'react';\n\nimport Address from './address';\nimport { BuySelectedComponent } from './buy-selected-component';\nimport LabelComponent from './label';\nimport { SalesLineState } from './sales-line-state';\nimport {\n defaultImageSettings,\n getDateTimeslot,\n getSalesStatusCode,\n IDeliveryType,\n IModuleComponentProps,\n ISalesStatusCode\n} from './utilities';\n\nexport type ISalesStatusStringMap = {\n [x in ISalesStatusCode]: string | undefined;\n};\n\nexport type IDeliveryTypeStringMap = {\n [x in IDeliveryType]: string | undefined;\n};\n\nexport interface ISalesLineResources {\n productDimensionTypeSize: string;\n productDimensionTypeColor: string;\n productDimensionTypeStyle: string;\n productDimensionTypeAmount?: string;\n salesLineQuantityText: string;\n configString: string;\n shipToLabel: string;\n storeLabel: string;\n phoneLabel: string;\n phoneAriaLabel: string;\n buyItAgainAriaLabel: string;\n buyItAgainLabel: string;\n orderStatusReadyForPickup: string;\n orderStatusPickedUp: string;\n orderStatusShipped: string;\n orderStatusCanceled: string;\n orderStatusProcessing: string;\n pickedUpSalesLines: string;\n deliveredSalesLines: string;\n carryOutSalesLines: string;\n trackingLabel: string;\n trackingAriaLabel: string;\n trackingComingSoonLabel: string;\n discountStringText: string;\n orderStatusEmailed: string;\n emailSalesLines: string;\n pickupDateTimeslotText: string;\n pickupTimeslotPlaceHolder: string;\n shippingCharges?: string;\n orderDetailsUnavailableProductText?: string;\n orderDetailsBuySelectedButtonText?: string;\n orderDetailsBuySelectedButtonAriaLabel?: string;\n orderDetailsBuySelectedAddingToCartErrorNotificationTitle?: string;\n orderDetailsBuySelectedAddingToCartErrorNotificationCloseAriaLabel?: string;\n orderDetailsGoToCartText?: string;\n orderDetailsDialogCloseText?: string;\n orderDetailsSelectRadioAriaLabelText?: string;\n orderDetailsSingleItemText?: string;\n orderDetailsMultiLineItemFormatText?: string;\n orderDetailsMultiLinesFormatText?: string;\n orderDetailsHeaderMessageText?: string;\n orderDetailsMultiItemsValidationErrorMessage?: string;\n orderDetailsOneErrorText?: string;\n orderDetailsMultiErrorText?: string;\n addedQuantityText?: string;\n originalPriceText?: string;\n currentPriceText?: string;\n freePriceText?: string;\n}\n\nexport interface IGetSalesLineInput {\n moduleName: string;\n moduleComponentProps: IModuleComponentProps;\n product?: SimpleProduct;\n shipment?: Shipment;\n salesLine: SalesLine;\n isCurrentChannel: boolean;\n resources: ISalesLineResources;\n imageOnly?: boolean;\n salesLineState?: SalesLineState;\n showCompleteAddress?: boolean;\n showTimeslot: boolean;\n telemetryContent?: ITelemetryContent;\n retailMultiplePickUpOptionEnabled?: boolean;\n channelDeliveryOptionConfig?: ChannelDeliveryOptionConfiguration;\n productDeliveryOptions?: ProductDeliveryOptions[];\n isSelectionModeEnabled?: boolean;\n orderDetailsProduct?: OrderDetailsProduct;\n isReorderingEnabled?: boolean;\n isChannelMultipleCatalogsFeatureEnabled?: boolean;\n}\n\nexport interface ISalesLine {\n salesLineProps: INodeProps;\n salesLine: React.ReactNode;\n address?: React.ReactNode;\n buyAgainButton?: React.ReactNode;\n salesStatus: React.ReactNode;\n deliveryType: React.ReactNode;\n trackingInfo: React.ReactNode;\n pickupDateTimeslot: React.ReactNode;\n errors?: React.ReactNode;\n\n // Row data\n data: {\n salesLine: SalesLine;\n product?: SimpleProduct;\n shipment?: Shipment;\n deliveryType: string;\n productUrl: string;\n salesStatus: ISalesStatusCode;\n isChecked?: boolean;\n };\n}\n\nenum deliveryTypeEnum {\n ship = 'ship',\n email = 'email',\n carryOut = 'carryOut',\n pickUp = 'pickUp'\n}\n\n/**\n * The on select line call back.\n * @param orderDetailsProduct -- The current order details product.\n * @returns The call back method.\n */\nconst onSelectLine = (orderDetailsProduct: OrderDetailsProduct) => () => {\n orderDetailsProduct.isSelected = !orderDetailsProduct.isSelected;\n};\n\n/**\n * Get the checkbox element.\n * @param orderDetailsProduct -- The order details product.\n * @param orderDetailsSelectRadioAriaLabelText -- The aria label text.\n * @param moduleName -- The module name.\n * @returns The checkbox element.\n */\nconst getOrderDetailsSalesLineCheckbox = (\n orderDetailsProduct: OrderDetailsProduct,\n orderDetailsSelectRadioAriaLabelText: string | undefined,\n moduleName: string\n): JSX.Element | null => {\n const checkboxRowAriaLabel = format(orderDetailsSelectRadioAriaLabelText ?? '{0}', orderDetailsProduct.salesLine.ProductId);\n\n return (\n
\n \n
\n );\n};\n\n/**\n * Get tracking information.\n * @param deliveryType -- The delivery type.\n * @param moduleName -- Module name.\n * @param trackingLabel -- Tracking label.\n * @param trackingAriaLabel -- Tracking aria label.\n * @param trackingComingSoonLabel -- Tracking coming soon label.\n * @param shipment -- Shipment.\n * @returns The tracking information.\n */\nexport const getTrackingInfo = (\n deliveryType: string,\n moduleName: string,\n trackingLabel: string,\n trackingAriaLabel: string,\n trackingComingSoonLabel: string,\n shipment: Shipment | undefined\n): false | JSX.Element => {\n return (\n deliveryType === deliveryTypeEnum.ship && (\n \n {trackingLabel}\n {shipment ? (\n \n {shipment.TrackingNumber}\n \n ) : (\n <>{trackingComingSoonLabel}\n )}\n \n )\n );\n};\n\n/**\n * Get pick update date time lot information.\n * @param shouldShowTimeslot -- Should show time slot.\n * @param isDeliveryPickupSame -- Is delivery and pickup the same.\n * @param salesLine -- The sales line.\n * @param pickupTimeslotPlaceHolder -- The pickup time slot place holder.\n * @param moduleName -- The module name.\n * @param locale -- The locale.\n * @param pickupDateTimeslotText -- The pickup date time slot text.\n * @returns The pickup date time slot information.\n */\nexport const getPickupDateTimeslotInfo = (\n shouldShowTimeslot: boolean,\n isDeliveryPickupSame: boolean,\n salesLine: SalesLine,\n pickupTimeslotPlaceHolder: string,\n moduleName: string,\n locale: string,\n pickupDateTimeslotText: string\n): false | JSX.Element => {\n const canShowTimeslot: boolean =\n shouldShowTimeslot &&\n isDeliveryPickupSame &&\n salesLine.PickupTimeslotStartDateTime !== undefined &&\n salesLine.PickupTimeslotEndDateTime !== undefined;\n\n const pickupDateTimeslot = canShowTimeslot\n ? getDateTimeslot(pickupTimeslotPlaceHolder, salesLine.PickupTimeslotStartDateTime, salesLine.PickupTimeslotEndDateTime, locale)\n : '';\n\n return (\n canShowTimeslot && (\n
\n
{pickupDateTimeslotText}
\n
{pickupDateTimeslot}
\n
\n )\n );\n};\n\n/**\n * Get sales status.\n * @param orderStatusCanceled -- Order status canceled.\n * @param orderStatusReadyForPickup -- Order status ready for pick up.\n * @param orderStatusPickedUp -- Order status pick up.\n * @param orderStatusProcessing -- Order status processing.\n * @param orderStatusShipped -- Order status shipped.\n * @param orderStatusEmailed -- Order status emailed.\n * @returns The sales status in string.\n */\nexport const getSalesStatusStringMap = (\n orderStatusCanceled: string | undefined,\n orderStatusReadyForPickup: string | undefined,\n orderStatusPickedUp: string | undefined,\n orderStatusProcessing: string | undefined,\n orderStatusShipped: string | undefined,\n orderStatusEmailed: string | undefined\n): ISalesStatusStringMap => {\n return {\n canceled: orderStatusCanceled,\n readyForPickup: orderStatusReadyForPickup,\n pickedUp: orderStatusPickedUp,\n processing: orderStatusProcessing,\n shipped: orderStatusShipped,\n unknown: undefined,\n emailed: orderStatusEmailed\n };\n};\n\n/**\n * Get delivery type.\n * @param deliveryTypeString -- Delivery type string.\n * @param moduleName -- Module name.\n * @param deliveryTypeClass -- Delivery type class.\n * @param storePickUp -- Store pick up.\n * @param isMultiplePickUpOptionEnabled -- Is multiple pick up enabled.\n * @returns The delivery type react node.\n */\nexport const getDeliveryTypeComp = (\n deliveryTypeString: string | undefined,\n moduleName: string,\n deliveryTypeClass: string | undefined,\n storePickUp: string | null | undefined,\n isMultiplePickUpOptionEnabled: boolean | undefined\n): React.ReactNode => {\n const deliveryTypePickup = deliveryTypeString && (\n \n );\n const deliveryTypeNoPickup = deliveryTypeString && (\n \n );\n\n return isMultiplePickUpOptionEnabled ? deliveryTypePickup : deliveryTypeNoPickup;\n};\n\n/**\n * Renders sales line picture.\n * @param moduleName - Module name.\n * @param requestContext - Request context.\n * @param productName - Product name.\n * @param product - Product data.\n * @param fallbackImageUrl - Fallback image.\n * @param gridSettings - Grid settings.\n * @param imageSettings - Image settings.\n * @param salesLineState - Product state.\n * @returns React node.\n */\nconst getSalesLinePicture = (\n moduleName: string,\n requestContext: IRequestContext,\n productName: string | undefined,\n product: SimpleProduct | undefined,\n fallbackImageUrl: string | undefined,\n gridSettings: IGridSettings,\n imageSettings: IImageSettings | undefined,\n salesLineState?: SalesLineState\n) => {\n return (\n \n {() =>\n !salesLineState?.isHidden && (\n
\n \n
\n )\n }\n
\n );\n};\n\n/**\n * Renders sales line.\n * @param props - Sales line props.\n * @returns React node.\n */\nconst SalesLineComponent: React.FC = (props: IGetSalesLineInput) => {\n const productName = props.product?.Name ?? props.salesLine.Description;\n const requestContext = props.moduleComponentProps.context.actionContext.requestContext;\n\n if (props.imageOnly) {\n const fallbackImageUrl = getFallbackImageUrl(props.product?.ItemId, requestContext.apiSettings);\n return getSalesLinePicture(\n props.moduleName,\n requestContext,\n productName,\n props.product,\n fallbackImageUrl,\n requestContext.gridSettings!,\n props.moduleComponentProps.config.imageSettings,\n props.salesLineState\n );\n }\n\n const orderDetailsProducts = props.orderDetailsProduct ?? new OrderDetailsProduct(props.salesLine, props.product);\n\n const isSelectionModeEnabled = props.isSelectionModeEnabled && orderDetailsProducts.isProductAvailable;\n\n const orderDetailCheckbox = props.isChannelMultipleCatalogsFeatureEnabled\n ? null\n : isSelectionModeEnabled &&\n getOrderDetailsSalesLineCheckbox(orderDetailsProducts, props.resources.orderDetailsSelectRadioAriaLabelText, props.moduleName);\n\n let productUrl = '';\n if (!ObjectExtensions.isNullOrUndefined(productName) && !ObjectExtensions.isNullOrUndefined(props.salesLine.ProductId)) {\n productUrl = getProductPageUrlSync(productName, props.salesLine.ProductId, props.moduleComponentProps.context.actionContext);\n\n if (MsDyn365.isBrowser) {\n const fullUrl = new URL(productUrl, window.location.href);\n fullUrl.searchParams.set('catalogid', `${props.salesLine.CatalogId ?? 0}`);\n productUrl = fullUrl.href;\n }\n }\n\n const className = `${props.moduleName}__sales-line-checkbox-control`;\n\n return (\n \n {orderDetailCheckbox}\n \n \n );\n};\n\nexport const getSalesLine = (props: IGetSalesLineInput): ISalesLine => {\n const {\n moduleName,\n moduleComponentProps: {\n typeName,\n context,\n config: { imageSettings }\n },\n product,\n shipment,\n salesLine,\n resources: {\n shipToLabel,\n storeLabel,\n phoneLabel,\n phoneAriaLabel,\n buyItAgainLabel,\n buyItAgainAriaLabel,\n orderStatusReadyForPickup,\n orderStatusProcessing,\n orderStatusShipped,\n orderStatusPickedUp,\n orderStatusCanceled,\n orderStatusEmailed,\n pickedUpSalesLines,\n deliveredSalesLines,\n carryOutSalesLines,\n emailSalesLines,\n trackingLabel,\n trackingAriaLabel,\n trackingComingSoonLabel,\n pickupDateTimeslotText,\n pickupTimeslotPlaceHolder,\n orderDetailsUnavailableProductText,\n orderDetailsBuySelectedAddingToCartErrorNotificationTitle,\n orderDetailsBuySelectedAddingToCartErrorNotificationCloseAriaLabel,\n orderDetailsGoToCartText,\n orderDetailsDialogCloseText,\n orderDetailsSingleItemText,\n orderDetailsMultiLineItemFormatText,\n orderDetailsMultiLinesFormatText,\n orderDetailsHeaderMessageText,\n orderDetailsMultiItemsValidationErrorMessage,\n orderDetailsOneErrorText,\n orderDetailsMultiErrorText,\n addedQuantityText,\n originalPriceText,\n currentPriceText,\n freePriceText\n },\n channelDeliveryOptionConfig,\n productDeliveryOptions,\n isSelectionModeEnabled,\n orderDetailsProduct,\n isReorderingEnabled\n } = props;\n\n const salesStatusStringMap = getSalesStatusStringMap(\n orderStatusCanceled,\n orderStatusReadyForPickup,\n orderStatusPickedUp,\n orderStatusProcessing,\n orderStatusShipped,\n orderStatusEmailed\n );\n\n const deliveryTypeStringMap: IDeliveryTypeStringMap = {\n pickUp: pickedUpSalesLines,\n ship: deliveredSalesLines,\n carryOut: carryOutSalesLines,\n email: emailSalesLines\n };\n\n const pickupDeliveryModeCode = context.request.channel?.PickupDeliveryModeCode;\n const emailDeliveryModeCode = context.request.channel?.EmailDeliveryModeCode;\n const productName = product?.Name ?? salesLine.Description;\n let productUrl = '';\n if (!ObjectExtensions.isNullOrUndefined(productName) && !ObjectExtensions.isNullOrUndefined(salesLine.ProductId)) {\n productUrl = getProductPageUrlSync(productName, salesLine.ProductId, context.actionContext);\n\n if (MsDyn365.isBrowser) {\n const fullUrl = new URL(productUrl, window.location.href);\n fullUrl.searchParams.set('catalogid', `${salesLine.CatalogId ?? 0}`);\n productUrl = fullUrl.href;\n }\n }\n\n const pickupMode = getPickupModeDesc(product, salesLine.DeliveryMode, productDeliveryOptions, props.retailMultiplePickUpOptionEnabled);\n const deliveryType = getDeliveryType(\n pickupMode,\n salesLine,\n salesLine.DeliveryMode,\n pickupDeliveryModeCode,\n props.retailMultiplePickUpOptionEnabled,\n channelDeliveryOptionConfig,\n emailDeliveryModeCode\n );\n const salesStatus = getSalesStatusCode(deliveryType, salesLine.SalesStatusValue, pickupMode);\n const salesStatusString = salesStatusStringMap[salesStatus];\n\n const salesStatusComp = salesStatusString && ;\n const deliveryTypeString = getDeliveryTypeString(deliveryType, deliveryTypeStringMap, props.retailMultiplePickUpOptionEnabled);\n const deliveryTypeClass = getDeliveryTypeClassName(deliveryType, deliveryTypeStringMap);\n const storePickUp = getStoreName(props.retailMultiplePickUpOptionEnabled, salesLine, deliveryType);\n const deliveryTypeComp = getDeliveryTypeComp(\n deliveryTypeString,\n moduleName,\n deliveryTypeClass,\n storePickUp,\n props.retailMultiplePickUpOptionEnabled\n );\n\n const trackingInfo = getTrackingInfo(deliveryType, moduleName, trackingLabel, trackingAriaLabel, trackingComingSoonLabel, shipment);\n const orderDetailProducts = orderDetailsProduct ?? new OrderDetailsProduct(salesLine, product, productUrl);\n const orderDetailsBuyItAgainAriaLabel =\n productName && buyItAgainAriaLabel ? (buyItAgainAriaLabel || '').replace('{productName}', productName) : '';\n const pickupDateTimeslotInfo = getPickupDateTimeslotInfo(\n props.showTimeslot,\n deliveryType === pickupMode,\n salesLine,\n pickupTimeslotPlaceHolder,\n moduleName,\n context.request.locale,\n pickupDateTimeslotText\n );\n let buyItAgainLinkClassName = format('{0}__sales-line-btn-buy-it-again-link', moduleName);\n if (isSelectionModeEnabled) {\n buyItAgainLinkClassName = format('{0} {1}-padding', buyItAgainLinkClassName, buyItAgainLinkClassName);\n }\n\n if (imageSettings) {\n imageSettings.cropFocalRegion = true;\n }\n\n const salesLineClassName = `${moduleName}__sales-line`;\n const salesLineFullClassName = classnames(\n salesLineClassName,\n isSelectionModeEnabled ? `${salesLineClassName}__selection-enabled` : `${salesLineClassName}__selection-disabled`,\n props.isSelectionModeEnabled\n ? `${salesLineClassName}__selection-global-enabled`\n : `${salesLineClassName}__selection-global-disabled`,\n orderDetailProducts.isProductAvailable ? `${salesLineClassName}__available-product` : `${salesLineClassName}__unavailable-product`\n );\n\n return {\n data: {\n salesLine,\n productUrl,\n deliveryType,\n salesStatus,\n product,\n shipment,\n isChecked: orderDetailProducts.isSelected\n },\n salesLineProps: { className: salesLineFullClassName },\n salesLine: SalesLineComponent(props),\n address: salesLine.ShippingAddress && (\n \n ),\n deliveryType: deliveryTypeComp,\n salesStatus: salesStatusComp,\n trackingInfo,\n buyAgainButton: props.isChannelMultipleCatalogsFeatureEnabled ? null : (\n \n ),\n pickupDateTimeslot: pickupDateTimeslotInfo,\n errors: !orderDetailProducts.isProductAvailable && (\n
{props.resources.orderDetailsUnavailableProductText}
\n )\n };\n};\n\nexport const getDeliveryType = (\n pickupMode: string,\n salesLine: SalesLine,\n salesLineDeliveryMode?: string,\n pickupDeliveryModeCode?: string,\n retailMultiplePickupOption?: boolean,\n channelDeliveryOptionConfig?: ChannelDeliveryOptionConfiguration,\n emailDeliveryModeCode?: string\n): string => {\n let isPickupDeliveryMode: boolean;\n\n if (retailMultiplePickupOption) {\n isPickupDeliveryMode =\n salesLineDeliveryMode === channelDeliveryOptionConfig?.PickupDeliveryModeCodes?.find(dM => dM === salesLineDeliveryMode);\n } else {\n isPickupDeliveryMode =\n !!pickupDeliveryModeCode && pickupDeliveryModeCode !== '' && pickupDeliveryModeCode === salesLineDeliveryMode;\n }\n\n return isPickupDeliveryMode\n ? pickupMode\n : emailDeliveryModeCode && emailDeliveryModeCode !== '' && emailDeliveryModeCode === salesLine.DeliveryMode\n ? deliveryTypeEnum.email\n : salesLine.DeliveryMode\n ? deliveryTypeEnum.ship\n : deliveryTypeEnum.carryOut;\n};\n\nexport const getDeliveryTypeString = (\n deliveryType: string,\n deliveryTypeStringMap: IDeliveryTypeStringMap,\n retailMultiplePickupOption?: boolean\n): string | undefined => {\n if (retailMultiplePickupOption) {\n switch (deliveryType) {\n case deliveryTypeEnum.ship:\n case deliveryTypeEnum.carryOut:\n case deliveryTypeEnum.email:\n return deliveryTypeStringMap[deliveryType];\n default:\n return deliveryType;\n }\n } else {\n return deliveryTypeStringMap[deliveryType];\n }\n};\n\nexport const getDeliveryTypeClassName = (\n deliveryType: string,\n deliveryTypeStringMap: IDeliveryTypeStringMap,\n retailMultiplePickupOption?: boolean\n): string | undefined => {\n switch (deliveryType) {\n case deliveryTypeEnum.ship:\n case deliveryTypeEnum.carryOut:\n case deliveryTypeEnum.email:\n return deliveryType;\n default:\n return deliveryTypeEnum.pickUp;\n }\n};\n\nconst defaultDeliveryOption: string = 'pickup';\n\n/**\n * Retrieves the delivery description by product id.\n * @param productRecordId - Product record id.\n * @param salesLineDeliveryMode - Delivery mode from the sales line.\n * @param productDeliveryOptions - Possible delivery options.\n * @returns Delivery option description.\n */\nexport const getDeliveryDescriptionByProductId = (\n productRecordId?: number,\n salesLineDeliveryMode?: string,\n productDeliveryOptions?: ProductDeliveryOptions[]\n): string => {\n if (ObjectExtensions.isNullOrUndefined(productRecordId) || !ArrayExtensions.hasElements(productDeliveryOptions)) {\n return defaultDeliveryOption;\n }\n\n const productDeliveryOption = productDeliveryOptions.find(currentDeliveryOption => {\n return currentDeliveryOption.ProductId === productRecordId;\n });\n\n const deliveryDescription = productDeliveryOption?.DeliveryOptions?.find(option => option.Code === salesLineDeliveryMode)?.Description;\n\n return deliveryDescription ?? defaultDeliveryOption;\n};\n\nexport const getPickupModeDesc = (\n product?: SimpleProduct,\n salesLineDeliveryMode?: string,\n productDeliveryOptions?: ProductDeliveryOptions[],\n retailMultiplePickupOption?: boolean\n): string => {\n return getDeliveryDescriptionByProductId(product?.RecordId, salesLineDeliveryMode, productDeliveryOptions);\n};\n\n/**\n * Get the store name.\n * @param isMultiplePickUpOptionEnabled -- Is mutiple pick up option enabled.\n * @param salesLine -- Sales line.\n * @param deliveryType -- Delivery type.\n * @returns The store name.\n */\nexport const getStoreName = (\n isMultiplePickUpOptionEnabled: boolean | undefined,\n salesLine: SalesLine,\n deliveryType?: string\n): string | undefined | null => {\n if (!isMultiplePickUpOptionEnabled) {\n return null;\n }\n\n switch (deliveryType) {\n case deliveryTypeEnum.ship:\n case deliveryTypeEnum.email:\n case deliveryTypeEnum.carryOut:\n return '';\n default:\n return `, ${salesLine.ShippingAddress?.Name}`;\n }\n};\n","/*!\n * Copyright (c) Microsoft Corporation.\n * All rights reserved. See LICENSE in the project root for license information.\n */\n\nimport { OrderDetailsProduct } from '@msdyn365-commerce/components';\nimport { IActionContext, IGridSettings, IImageSettings } from '@msdyn365-commerce/core';\nimport {\n ChannelDeliveryOptionConfiguration,\n OrderShipments,\n ProductDeliveryOptions,\n SalesLine,\n SalesOrder,\n Shipment,\n SimpleProduct\n} from '@msdyn365-commerce/retail-proxy';\nimport { ITelemetryContent } from '@msdyn365-commerce-modules/utilities';\n\nimport { getSalesLine, ISalesLine, ISalesLineResources } from './get-sales-line';\nimport { SalesLineState } from './sales-line-state';\nimport { IModuleComponentProps, IPriceContext } from './utilities';\n\nexport interface IGetSalesLinesInput {\n moduleName: string;\n moduleComponentProps: IModuleComponentProps;\n isCurrentChannel: boolean;\n\n salesLines: SalesLine[];\n products: SimpleProduct[];\n shipments?: Shipment[];\n priceContext: IPriceContext;\n resources: ISalesLineResources;\n actionContext: IActionContext;\n gridSettings: IGridSettings;\n imageSettings?: IImageSettings;\n imageOnly?: boolean;\n salesLineStates?: SalesLineState[];\n showCompleteAddress?: boolean;\n showTimeslot: boolean;\n telemetryContent?: ITelemetryContent;\n retailMultiplePickUpOptionEnabled?: boolean;\n channelDeliveryOptionConfig?: ChannelDeliveryOptionConfiguration;\n productDeliveryOptions?: ProductDeliveryOptions[];\n isSelectionModeEnabled?: boolean;\n orderDetailsProducts?: OrderDetailsProduct[];\n isReorderingEnabled?: boolean;\n isChannelMultipleCatalogsFeatureEnabled?: boolean;\n}\n\nexport const getSalesLines = ({\n moduleName,\n moduleComponentProps,\n salesLines,\n products,\n shipments,\n resources,\n isCurrentChannel,\n imageOnly,\n showCompleteAddress,\n showTimeslot,\n telemetryContent,\n retailMultiplePickUpOptionEnabled,\n channelDeliveryOptionConfig,\n productDeliveryOptions,\n isSelectionModeEnabled,\n orderDetailsProducts,\n isReorderingEnabled,\n salesLineStates: productStates,\n isChannelMultipleCatalogsFeatureEnabled\n}: IGetSalesLinesInput): ISalesLine[] => {\n return salesLines.map((salesLine, index) => {\n const product = products.find(simpleProduct => simpleProduct.RecordId === salesLine.ProductId);\n const shipment =\n product &&\n shipments?.find(currentShipment =>\n currentShipment.ShipmentLines?.find(\n shipmentLine =>\n shipmentLine.ItemId === product.ItemId && shipmentLine.InventoryTransactionId === salesLine.InventoryTransactionId\n )\n );\n const orderDetailsProduct = isSelectionModeEnabled\n ? product && orderDetailsProducts?.find(currentProduct => currentProduct.salesLine.ProductId === product.RecordId)\n : undefined;\n const productState = productStates?.find(value => value.stateId === `${salesLine.LineId ?? ''}-${index}`);\n\n return getSalesLine({\n moduleName,\n moduleComponentProps,\n product,\n shipment,\n salesLine,\n isCurrentChannel,\n resources,\n imageOnly,\n showCompleteAddress,\n showTimeslot,\n telemetryContent,\n retailMultiplePickUpOptionEnabled,\n channelDeliveryOptionConfig,\n productDeliveryOptions,\n isSelectionModeEnabled,\n orderDetailsProduct,\n isReorderingEnabled,\n salesLineState: productState,\n isChannelMultipleCatalogsFeatureEnabled\n });\n });\n};\n\ninterface IProps extends IModuleComponentProps {\n resources: ISalesLineResources;\n}\n\nexport const getSalesLinesInput = (\n props: IProps,\n moduleName: string,\n order: SalesOrder | OrderShipments,\n products: SimpleProduct[],\n priceContext: IPriceContext,\n showCompleteAddress?: boolean,\n showTimeslot?: boolean,\n telemetryContent?: ITelemetryContent,\n retailMultiplePickUpOptionEnabled?: boolean,\n channelDeliveryOptionConfig?: ChannelDeliveryOptionConfiguration,\n productDeliveryOptions?: ProductDeliveryOptions[] | undefined,\n isSelectionModeEnabled?: boolean | undefined,\n orderDetailsProducts?: OrderDetailsProduct[] | undefined,\n isReorderingEnabled?: boolean,\n isChannelMultipleCatalogsFeatureEnabled?: boolean\n): IGetSalesLinesInput | undefined => {\n if (!order || !order.SalesLines || order.SalesLines.length === 0) {\n return;\n }\n\n const {\n resources,\n config: { imageSettings },\n context: {\n actionContext,\n request: {\n gridSettings,\n apiSettings: { channelId }\n }\n }\n } = props;\n\n const isCurrentChannel = !order.ChannelId || order.ChannelId === channelId;\n\n return {\n moduleName,\n moduleComponentProps: props,\n isCurrentChannel,\n salesLines: order.SalesLines,\n products,\n shipments: order.Shipments,\n priceContext,\n resources,\n actionContext,\n gridSettings: gridSettings!,\n imageSettings,\n showCompleteAddress,\n showTimeslot: showTimeslot ?? false,\n telemetryContent,\n retailMultiplePickUpOptionEnabled,\n channelDeliveryOptionConfig,\n productDeliveryOptions,\n isSelectionModeEnabled: isSelectionModeEnabled ?? false,\n orderDetailsProducts,\n isReorderingEnabled,\n isChannelMultipleCatalogsFeatureEnabled\n };\n};\n","/*!\n * Copyright (c) Microsoft Corporation.\n * All rights reserved. See LICENSE in the project root for license information.\n */\n\nimport * as React from 'react';\n\ninterface ILabelProps {\n className: string;\n label: string;\n}\n\nexport const Label: React.FC = ({ className, label }) => {label};\n\nexport default Label;\n","/*!\n * Copyright (c) Microsoft Corporation.\n * All rights reserved. See LICENSE in the project root for license information.\n */\n\nimport { IAny, ICoreContext, IGeneric, IImageSettings, IModule, ITelemetry } from '@msdyn365-commerce/core';\nimport { SalesLine, TenderType } from '@msdyn365-commerce/retail-proxy/dist/Entities/CommerceTypes.g';\nimport { format } from '@msdyn365-commerce-modules/utilities';\nimport groupBy from 'lodash/groupBy';\n\nimport { ISalesLine } from './get-sales-line';\n\nexport interface IModuleComponentProps extends IModule {\n config: {\n imageSettings?: IImageSettings;\n showShippingChargesForLineItems?: boolean;\n };\n}\n\nexport interface IPriceContext {\n id: string;\n typeName: string;\n context: ICoreContext>;\n telemetry: ITelemetry;\n freePriceText: string;\n}\n\nexport const getTenderIdOperationIdMap = (tenderTypes: TenderType[]): object => {\n return tenderTypes.reduce((map, tenderType) => {\n if (tenderType.TenderTypeId) {\n map[tenderType.TenderTypeId] = tenderType.OperationId;\n }\n return map;\n }, {});\n};\n\nexport const countItems = (salesLines: SalesLine[]) => {\n return salesLines.reduce((count, salesLine) => {\n return count + (salesLine.Quantity || 0);\n }, 0);\n};\n\nexport const getSalesLinesByDelivery = (salesLines?: SalesLine[], pickupDeliveryModeCode?: string): SalesLine[] => {\n if (!salesLines || salesLines.length === 0) {\n return [];\n }\n return salesLines.filter(salesLine =>\n // IsPickUp ? getPickUp : getOthers\n pickupDeliveryModeCode && pickupDeliveryModeCode !== ''\n ? salesLine.DeliveryMode === pickupDeliveryModeCode\n : salesLine.DeliveryMode !== pickupDeliveryModeCode\n );\n};\n\nexport const defaultImageSettings: IImageSettings = {\n viewports: {\n xs: { q: 'w=80&h=80&m=6', w: 0, h: 0 },\n lg: { q: 'w=147&h=147&m=6', w: 0, h: 0 }\n },\n lazyload: true,\n cropFocalRegion: true\n};\n\nexport type IDeliveryType = 'pickUp' | 'ship' | 'carryOut' | 'email';\n\nexport type ISalesStatusCode = 'canceled' | 'readyForPickup' | 'pickedUp' | 'processing' | 'shipped' | 'unknown' | 'emailed';\n\nexport const getSalesStatusCode = (deliveryType: string, statusValue?: number, pickupMode?: string): ISalesStatusCode => {\n if (statusValue === 7) {\n return 'canceled';\n }\n\n if (deliveryType === 'pickUp') {\n switch (statusValue) {\n case 3:\n return 'readyForPickup';\n case 4:\n return 'pickedUp';\n default:\n return 'processing';\n }\n } else if (deliveryType === 'ship') {\n switch (statusValue) {\n case 3:\n return 'processing';\n case 4:\n return 'shipped';\n default:\n return 'processing';\n }\n } else if (deliveryType === 'email') {\n switch (statusValue) {\n case 3:\n return 'processing';\n case 4:\n return 'emailed';\n default:\n return 'processing';\n }\n } else if (deliveryType === 'carryOut') {\n return 'processing';\n } else {\n if (pickupMode !== undefined) {\n switch (statusValue) {\n case 3:\n return 'readyForPickup';\n case 4:\n return 'pickedUp';\n default:\n return 'processing';\n }\n }\n\n return 'unknown';\n }\n};\n\nexport type ITrackingId = string | 'unknown';\nexport type IAddressId = string | 'unknown';\n\nexport interface IGroupData {\n deliveryType: IDeliveryType;\n salesStatus: ISalesStatusCode;\n addressId: IAddressId | 'unknown';\n trackingId: ITrackingId | 'unknown';\n count: number;\n salesLines: ISalesLine[];\n}\n\nexport const groupSalesLines = (salesLines: ISalesLine[]): IGroupData[] => {\n const getGroupByDeliveryType = (items: ISalesLine[]) => groupBy(items, item => item.data.deliveryType);\n const getGroupBySalesStatusCode = (items: ISalesLine[]) => groupBy(items, item => item.data.salesStatus);\n const getGroupByTrackingId = (items: ISalesLine[]) => groupBy(items, item => item.data.salesLine.TrackingId || 'unknown');\n const getGroupByAddressId = (items: ISalesLine[]) =>\n groupBy(items, item => (item.data.salesLine.ShippingAddress && item.data.salesLine.ShippingAddress.RecordId) || 'unknown');\n\n const flatGroup: IGroupData[] = [];\n\n // 1) Group by delivery type\n const group = getGroupByDeliveryType(salesLines);\n\n // 2) Group by sales status code\n Object.entries(group).forEach(([deliveryType, groupByDeliveryType]) => {\n // @ts-expect-error\n group[deliveryType] = getGroupBySalesStatusCode(groupByDeliveryType);\n\n Object.entries(group[deliveryType]).forEach(([salesStatus, groupBySalesStatusCode]) => {\n // @ts-expect-error 3) Group by address id\n groupBySalesStatusCode[salesStatus] = getGroupByAddressId(groupBySalesStatusCode);\n\n Object.entries(groupBySalesStatusCode[salesStatus]).forEach(([addressId, groupByAddressId]) => {\n // @ts-expect-error 4) Group by address id\n groupByAddressId[addressId] = getGroupByTrackingId(groupByAddressId);\n\n // @ts-expect-error\n Object.entries(groupByAddressId[addressId]).forEach(([trackingId, groupByTrackingId]) => {\n flatGroup.push({\n // @ts-expect-error\n deliveryType,\n\n // @ts-expect-error\n salesStatus,\n addressId,\n trackingId,\n\n // @ts-expect-error\n count: countItems(groupByTrackingId.map(item => item.data.salesLine)),\n\n // @ts-expect-error\n salesLines: groupByTrackingId\n });\n });\n });\n });\n });\n\n return flatGroup;\n};\n\nexport const getDateTimeslot = (placeHolder: string, startDate: Date | undefined, endDate: Date | undefined, locale: string): string => {\n if (!startDate || !endDate) {\n return '';\n }\n\n const dateOptions: Intl.DateTimeFormatOptions = {\n timeZone: 'UTC'\n };\n const dateformatter = new Intl.DateTimeFormat(locale, dateOptions);\n const date = dateformatter.format(new Date(startDate));\n\n const timeslotOptions: Intl.DateTimeFormatOptions = {\n hour: 'numeric',\n minute: 'numeric',\n hour12: true,\n timeZone: 'UTC'\n };\n const timeslotformatter = new Intl.DateTimeFormat(locale, timeslotOptions);\n const timeslot = format(placeHolder, timeslotformatter.format(new Date(startDate)), timeslotformatter.format(new Date(endDate)));\n return `${date} ${timeslot}`;\n};\n"],"names":["Address","moduleName","address","deliveryType","showCompleteAddress","resource","shipToLabel","storeLabel","phoneLabel","React","className","Name","Street","City","State","County","ZipCode","ThreeLetterISORegionName","Phone","FullAddress","BuySelectedComponent","props","products","data","filter","product","ObjectExtensions","isNullOrUndefined","simpleProduct","buttonLabel","isIcon","resources","orderDetailsBuySelectedButtonText","orderDetailsBuyItAgainLabel","buttonAriaLabel","orderDetailsBuySelectedButtonAriaLabel","orderDetailsBuyItAgainAriaLabel","length","isProductAvailable","orderDetailsUnavailableProductText","title","disabled","ArrayExtensions","hasElements","firstProduct","isReorderingEnabled","Button","href","productUrl","dialogStrings","goToCartText","orderDetailsGoToCartText","continueShoppingText","orderDetailsDialogCloseText","closeNotificationLabel","orderDetailsBuySelectedAddingToCartErrorNotificationCloseAriaLabel","headerItemOneText","orderDetailsSingleItemText","headerItemFormatText","orderDetailsMultiLineItemFormatText","headerLinesFormatText","orderDetailsMultiLinesFormatText","headerMessageText","orderDetailsHeaderMessageText","freePriceText","originalPriceText","currentPriceText","addedQuantityText","buyAgainNotificationTitle","orderDetailsBuySelectedAddingToCartErrorNotificationTitle","buyAgainNotificationCloseAriaLabel","validationErrorMessage","orderDetailsMultiItemsValidationErrorMessage","oneErrorText","orderDetailsOneErrorText","multiErrorsText","orderDetailsMultiErrorText","getDialogStrings","AddToCartComponent","addToCartText","outOfStockText","addToCartArialLabel","quantity","salesLine","Quantity","id","typeName","navigationUrl","getUrlSync","context","actionContext","shouldSkipSiteSettings","orderDetailsProducts","getGroups","salesLines","showAddress","showTimeslot","isConfirmationView","retailMultiplePickUpOptionEnabled","isCashAndCarryTransaction","isSelectionModeEnabled","orderItemLabel","orderItemsLabel","pickupItemsHeader","pickingItemsLabel","shippingAddressTitle","shippingItemToYouLabel","emailItemsHeader","emailingItemsLabel","groups","groupSalesLines","map","group","salesStatus","count","_salesLines","itemLabel","pickingItemsLabelText","format","shippingItemsToYouText","emailingItemsLabelText","groupProps","salesLinesProps","classNames","getSalesLinesProps","trackingInfo","isProcessing","pickDateTimeslot","pickupDateTimeslot","shippedStatusCheck","delivery","deliveryProps","pickupProps","heading","processing","undefined","shippingItemsToYou","groupsProps","getChannelReference","channelReferenceId","confirmationIdLabel","shouldShowQrCode","qrCodeSrText","confirmationIdNode","QRCode","value","size","getOrderInformation","channelName","channelAddress","channelTypeValue","showChannelInfo","receiptEmail","createdDate","amount","priceContext","salesId","receiptId","receiptEmailMessage","orderIdLabel","receiptIdLabel","posChannelNameText","onlineStoreChannelNameText","orderPlacedOnLabel","callCenterChannelNameText","isSalesInvoice","channelNameNode","posChannelName","getChannelName","orderInformationProps","PriceComponent","price","CustomerContextualPrice","getOrderChannelName","order","channelIdentities","orderChannel","find","channel","RecordId","ChannelId","getOrderChannelTypeValue","ChannelType","Value","getOrderChannelAddress","orgUnitLocations","orderOrgUnitLocation","location","getOrderInformationInput","request","apiSettings","channelId","locale","get","SalesLines","countItems","CreatedDateTime","Date","toLocaleDateString","SalesId","ReceiptId","ReceiptEmail","ChannelReferenceId","TotalAmount","deliveryTypeEnum","onSelectLine","orderDetailsProduct","isSelected","SalesLineComponent","productName","Description","requestContext","moduleComponentProps","imageOnly","fallbackImageUrl","getFallbackImageUrl","ItemId","gridSettings","imageSettings","salesLineState","Observer","isHidden","Image","altText","src","PrimaryImageUrl","fallBackSrc","defaultImageSettings","loadFailureBehavior","getSalesLinePicture","config","OrderDetailsProduct","orderDetailCheckbox","isChannelMultipleCatalogsFeatureEnabled","orderDetailsSelectRadioAriaLabelText","checkboxRowAriaLabel","ProductId","classnames","type","checked","onChange","getOrderDetailsSalesLineCheckbox","getProductPageUrlSync","MsDyn365","isBrowser","fullUrl","URL","window","searchParams","set","CatalogId","CartLineItemComponent","sizeString","productDimensionTypeSize","colorString","productDimensionTypeColor","styleString","productDimensionTypeStyle","amountString","productDimensionTypeAmount","quantityDisplayString","salesLineQuantityText","configString","discountStringText","inputQuantityAriaLabel","shippingChargesText","shippingCharges","primaryImageUrl","isSalesLine","cartLine","showShippingChargesForLineItems","channelDeliveryOptionConfig","getSalesLine","shipment","phoneAriaLabel","buyItAgainLabel","buyItAgainAriaLabel","orderStatusReadyForPickup","orderStatusProcessing","orderStatusShipped","orderStatusPickedUp","orderStatusCanceled","orderStatusEmailed","pickedUpSalesLines","deliveredSalesLines","carryOutSalesLines","emailSalesLines","trackingLabel","trackingAriaLabel","trackingComingSoonLabel","pickupDateTimeslotText","pickupTimeslotPlaceHolder","productDeliveryOptions","salesStatusStringMap","canceled","readyForPickup","pickedUp","shipped","unknown","emailed","getSalesStatusStringMap","deliveryTypeStringMap","pickUp","ship","carryOut","email","pickupDeliveryModeCode","PickupDeliveryModeCode","emailDeliveryModeCode","EmailDeliveryModeCode","pickupMode","getPickupModeDesc","DeliveryMode","getDeliveryType","getSalesStatusCode","SalesStatusValue","salesStatusString","salesStatusComp","LabelComponent","label","deliveryTypeComp","deliveryTypeString","deliveryTypeClass","storePickUp","isMultiplePickUpOptionEnabled","deliveryTypePickup","deliveryTypeNoPickup","getDeliveryTypeComp","getDeliveryTypeString","getDeliveryTypeClassName","getStoreName","TrackingUrl","TrackingNumber","getTrackingInfo","orderDetailProducts","replace","pickupDateTimeslotInfo","shouldShowTimeslot","isDeliveryPickupSame","canShowTimeslot","PickupTimeslotStartDateTime","PickupTimeslotEndDateTime","getDateTimeslot","getPickupDateTimeslotInfo","buyItAgainLinkClassName","cropFocalRegion","salesLineClassName","salesLineFullClassName","isChecked","salesLineProps","ShippingAddress","buyAgainButton","errors","salesLineDeliveryMode","retailMultiplePickupOption","isPickupDeliveryMode","PickupDeliveryModeCodes","dM","defaultDeliveryOption","getDeliveryDescriptionByProductId","productRecordId","productDeliveryOption","currentDeliveryOption","deliveryDescription","DeliveryOptions","option","Code","getSalesLines","shipments","isCurrentChannel","telemetryContent","salesLineStates","productStates","index","currentShipment","ShipmentLines","shipmentLine","InventoryTransactionId","currentProduct","productState","stateId","LineId","getSalesLinesInput","Shipments","Label","getTenderIdOperationIdMap","tenderTypes","reduce","tenderType","TenderTypeId","OperationId","viewports","xs","q","w","h","lg","lazyload","statusValue","flatGroup","items","groupBy","item","Object","entries","forEach","groupByDeliveryType","getGroupBySalesStatusCode","groupBySalesStatusCode","getGroupByAddressId","addressId","groupByAddressId","TrackingId","getGroupByTrackingId","trackingId","groupByTrackingId","push","placeHolder","startDate","endDate","date","Intl","DateTimeFormat","timeZone","timeslotformatter","hour","minute","hour12"],"sourceRoot":""}