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AAk7B,OAAA,EAAZA,EAAcN,WAAWvgB,MAAAA,OAAgB,EAAhBA,EAAkBugB,WAChGO,GAAkBH,MAAAA,OAAO,EAAPA,EAASI,kBAAkB,EACnD,OACIN,IACCK,GAAmBznC,MAAAA,GAAsB,QAAfw3B,EAAPx3B,EAASsD,qBAAa,IAAAk0B,GAAgB,QAAhBA,EAAtBA,EAAwB71B,sBAAc,IAAA61B,GAAM,QAANA,EAAtCA,EAAwCt0B,YAAI,IAAAs0B,GAA5CA,EAA8Cr0B,kBACrC,KAA7BwjB,MAAAA,OAAgB,EAAhBA,EAAkB9nB,QAGdkO,IAAAA,cAAA,OACIhO,UAAU,QACV6S,MAAO+U,EACP/mB,IAAK+mB,EACLY,MAAO,CAAEogB,YAAYL,MAAAA,OAAO,EAAPA,EAASM,UAAW,GAAIpgB,OAAO8f,MAAAA,OAAO,EAAPA,EAASO,YAAa,KAEzElhB,GAIN","sources":["webpack://Msdyn365.Commerce.Online/./src/actions/customProxy/ATP1/DataServiceEntities.g.ts?128a","webpack://Msdyn365.Commerce.Online/./src/actions/customProxy/ATP1/DataActionExtension.g.ts?7656","webpack://Msdyn365.Commerce.Online/./src/actions/get-address-purposes.ts?3461","webpack://Msdyn365.Commerce.Online/./src/actions/get-state-provinces.ts?a6ba","webpack://Msdyn365.Commerce.Online/./src/common/address-common.ts?e30a","webpack://Msdyn365.Commerce.Online/./src/common/address-format.data.ts?f2e7","webpack://Msdyn365.Commerce.Online/./src/common/address-format.ts?b845","webpack://Msdyn365.Commerce.Online/./src/common/address-meta-data.ts?c0c5","webpack://Msdyn365.Commerce.Online/./src/common/address-module.data.ts?1c51","webpack://Msdyn365.Commerce.Online/./src/common/components/address-alert.tsx?e0a2","webpack://Msdyn365.Commerce.Online/./src/common/components/address-checkbox.tsx?a2d4","webpack://Msdyn365.Commerce.Online/./src/common/components/address-dropdown.tsx?34b0","webpack://Msdyn365.Commerce.Online/./src/common/components/address-label.tsx?1e7b","webpack://Msdyn365.Commerce.Online/./src/common/components/address-add.tsx?876e","webpack://Msdyn365.Commerce.Online/./src/common/components/address-button.tsx?ce28","webpack://Msdyn365.Commerce.Online/./src/common/components/address-error-message.tsx?73f9","webpack://Msdyn365.Commerce.Online/./src/common/components/address-error-title.tsx?b6f8","webpack://Msdyn365.Commerce.Online/./src/common/components/address-input.tsx?2742","webpack://Msdyn365.Commerce.Online/./src/modules/krannich-c-business-account-address/krannich-c-business-account-address.tsx?acea","webpack://Msdyn365.Commerce.Online/./src/modules/krannich-c-business-account-address/krannich-c-business-account-address.view.tsx?e981","webpack://Msdyn365.Commerce.Online/./src/themes/krannich/views/buybox.view.tsx?519c","webpack://Msdyn365.Commerce.Online/./src/themes/krannich/views/components/price.component.tsx?7e44","webpack://Msdyn365.Commerce.Online/./src/themes/krannich/views/order-details.view.tsx?450a","webpack://Msdyn365.Commerce.Online/./src/themes/krannich/views/quickview.view.tsx?7bec","webpack://Msdyn365.Commerce.Online/./src/utils/ATP/atpESD.tsx?4eac","webpack://Msdyn365.Commerce.Online/./src/utils/ATP/atpESDMessage.tsx?7cba","webpack://Msdyn365.Commerce.Online/./src/utils/ATP/atpKitESD.tsx?229a","webpack://Msdyn365.Commerce.Online/./src/utils/Kits/kits.tsx?777d","webpack://Msdyn365.Commerce.Online/./src/utils/atp-utils.tsx?854b","webpack://Msdyn365.Commerce.Online/./src/utils/badges.tsx?5a27"],"sourcesContent":["// tslint:disable\r\nimport * as EntityClasses from '@msdyn365-commerce/retail-proxy/dist/Entities/CommerceModels.g';\r\nimport * as Entities from '@msdyn365-commerce/retail-proxy/dist/Entities/CommerceTypes.g';\r\n\r\n/**\r\n * KRV_ATPLeadTimePropertiesDate entity interface.\r\n */\r\nexport interface IKRV_ATPLeadTimePropertiesDate {\r\n Id: number;\r\n ATPDate?: string;\r\n Quantity: number;\r\n Message?: string;\r\n PODate?: string;\r\n POQuantity: number;\r\n POMessage?: string;\r\n PurchaseLeadTimeDate?: string;\r\n PurchaseLeadTimeQuantity: number;\r\n PurchaseLeadTimeMessage?: string;\r\n ItemStatusMessage?: string;\r\n StatusCode?: string;\r\n TrafficLight?: string;\r\n ExtensionProperties?: Entities.CommerceProperty[];\r\n}\r\n\r\n/**\r\n * KRV_ATPLeadTimePropertiesQuantityRequestEntity entity interface.\r\n */\r\nexport interface IKRV_ATPLeadTimePropertiesQuantityRequestEntity {\r\n itemID?: string;\r\n Qty: number;\r\n ExtensionProperties?: Entities.CommerceProperty[];\r\n}\r\n\r\nexport interface IKRV_ATPLeadTimeQuantityRequestBody {\r\n itemID: string;\r\n Qty: number;\r\n}\r\n\r\n/**\r\n * KRV_ATPLeadTimePropertiesQuantityResponseEntity entity interface.\r\n */\r\nexport interface IKRV_ATPLeadTimePropertiesQuantityResponseEntity {\r\n ItemId?: string;\r\n ATPDate?: string;\r\n Message?: string;\r\n ExtensionProperties?: Entities.CommerceProperty[];\r\n}\r\n\r\n/**\r\n * KRV_GetATPLeadTimeResponseQuantity entity interface.\r\n */\r\nexport interface IKRV_GetATPLeadTimeResponseQuantity {\r\n ATPLeadTimePropertiesQuantityResponseEntityList?: IKRV_ATPLeadTimePropertiesQuantityResponseEntity[];\r\n HighestDate?: string;\r\n}\r\n\r\n/**\r\n * KRV_ATPLeadTimePropertiesDate entity class.\r\n */\r\nexport class KRV_ATPLeadTimePropertiesDateExtensionClass implements IKRV_ATPLeadTimePropertiesDate {\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n public Id: number;\r\n\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n public ATPDate: string;\r\n\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n public Quantity: number;\r\n\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n public Message: string;\r\n\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n public PODate: string;\r\n\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n public POQuantity: number;\r\n\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n public POMessage: string;\r\n\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n public PurchaseLeadTimeDate: string;\r\n\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n public PurchaseLeadTimeQuantity: number;\r\n\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n public PurchaseLeadTimeMessage: string;\r\n\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n public ItemStatusMessage: string;\r\n\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n public StatusCode: string;\r\n\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n public TrafficLight: string;\r\n\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n public ExtensionProperties: Entities.CommerceProperty[];\r\n\r\n // Navigation properties names\r\n\r\n /**\r\n * Construct an object from odata response.\r\n * @param {any} odataObject The odata result object.\r\n */\r\n constructor(odataObject?: any) {\r\n odataObject = odataObject || {};\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n this.Id = odataObject.Id ? parseInt(odataObject.Id, 10) : 0;\r\n\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n this.ATPDate = odataObject.ATPDate;\r\n\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n this.Quantity = odataObject.Quantity ? parseFloat(odataObject.Quantity) : 0;\r\n\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n this.Message = odataObject.Message;\r\n\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n this.PODate = odataObject.PODate;\r\n\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n this.POQuantity = odataObject.POQuantity ? parseFloat(odataObject.POQuantity) : 0;\r\n\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n this.POMessage = odataObject.POMessage;\r\n\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n this.PurchaseLeadTimeDate = odataObject.PurchaseLeadTimeDate;\r\n\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n this.PurchaseLeadTimeQuantity = odataObject.PurchaseLeadTimeQuantity ? parseFloat(odataObject.PurchaseLeadTimeQuantity) : 0;\r\n\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n this.PurchaseLeadTimeMessage = odataObject.PurchaseLeadTimeMessage;\r\n\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n this.ItemStatusMessage = odataObject.ItemStatusMessage;\r\n\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n this.StatusCode = odataObject.StatusCode;\r\n\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n this.TrafficLight = odataObject.TrafficLight;\r\n\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n this.ExtensionProperties = undefined;\r\n if (odataObject.ExtensionProperties) {\r\n this.ExtensionProperties = [];\r\n for (var i = 0; i < odataObject.ExtensionProperties.length; i++) {\r\n if (odataObject.ExtensionProperties[Number(i)]) {\r\n if (odataObject.ExtensionProperties[Number(i)]['@odata.type']) {\r\n var className: string = odataObject.ExtensionProperties[Number(i)]['@odata.type'];\r\n className = className.substr(className.lastIndexOf('.') + 1).concat('Class');\r\n if (EntityClasses[String(className)]) {\r\n this.ExtensionProperties[Number(i)] = new EntityClasses[String(className)](\r\n odataObject.ExtensionProperties[Number(i)]\r\n );\r\n }\r\n } else {\r\n this.ExtensionProperties[Number(i)] = new EntityClasses.CommercePropertyClass(\r\n odataObject.ExtensionProperties[Number(i)]\r\n );\r\n }\r\n } else {\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n this.ExtensionProperties[Number(i)] = undefined;\r\n }\r\n }\r\n }\r\n }\r\n}\r\n\r\n/**\r\n * KRV_ATPLeadTimePropertiesQuantityRequestEntity entity class.\r\n */\r\nexport class KRV_ATPLeadTimePropertiesQuantityRequestEntityExtensionClass implements IKRV_ATPLeadTimePropertiesQuantityRequestEntity {\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n public itemID: string;\r\n\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n public Qty: number;\r\n\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n public ExtensionProperties: Entities.CommerceProperty[];\r\n\r\n // Navigation properties names\r\n\r\n /**\r\n * Construct an object from odata response.\r\n * @param {any} odataObject The odata result object.\r\n */\r\n constructor(odataObject?: any) {\r\n odataObject = odataObject || {};\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n this.itemID = odataObject.itemID;\r\n\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n this.Qty = odataObject.Qty;\r\n\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n this.ExtensionProperties = undefined;\r\n if (odataObject.ExtensionProperties) {\r\n this.ExtensionProperties = [];\r\n for (var i = 0; i < odataObject.ExtensionProperties.length; i++) {\r\n if (odataObject.ExtensionProperties[Number(i)]) {\r\n if (odataObject.ExtensionProperties[Number(i)]['@odata.type']) {\r\n var className: string = odataObject.ExtensionProperties[Number(i)]['@odata.type'];\r\n className = className.substr(className.lastIndexOf('.') + 1).concat('Class');\r\n if (EntityClasses[String(className)]) {\r\n this.ExtensionProperties[Number(i)] = new EntityClasses[String(className)](\r\n odataObject.ExtensionProperties[Number(i)]\r\n );\r\n }\r\n } else {\r\n this.ExtensionProperties[Number(i)] = new EntityClasses.CommercePropertyClass(\r\n odataObject.ExtensionProperties[Number(i)]\r\n );\r\n }\r\n } else {\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n this.ExtensionProperties[Number(i)] = undefined;\r\n }\r\n }\r\n }\r\n }\r\n}\r\n\r\n/**\r\n * KRV_ATPLeadTimePropertiesQuantityResponseEntity entity class.\r\n */\r\nexport class KRV_ATPLeadTimePropertiesQuantityResponseEntityExtensionClass implements IKRV_ATPLeadTimePropertiesQuantityResponseEntity {\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n public ItemId: string;\r\n\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n public ATPDate: string;\r\n\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n public Message: string;\r\n\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n public ExtensionProperties: Entities.CommerceProperty[];\r\n\r\n // Navigation properties names\r\n\r\n /**\r\n * Construct an object from odata response.\r\n * @param {any} odataObject The odata result object.\r\n */\r\n constructor(odataObject?: any) {\r\n odataObject = odataObject || {};\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n this.ItemId = odataObject.ItemId;\r\n\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n this.ATPDate = odataObject.ATPDate;\r\n\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n this.Message = odataObject.Message;\r\n\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n this.ExtensionProperties = undefined;\r\n if (odataObject.ExtensionProperties) {\r\n this.ExtensionProperties = [];\r\n for (var i = 0; i < odataObject.ExtensionProperties.length; i++) {\r\n if (odataObject.ExtensionProperties[Number(i)]) {\r\n if (odataObject.ExtensionProperties[Number(i)]['@odata.type']) {\r\n var className: string = odataObject.ExtensionProperties[Number(i)]['@odata.type'];\r\n className = className.substr(className.lastIndexOf('.') + 1).concat('Class');\r\n if (EntityClasses[String(className)]) {\r\n this.ExtensionProperties[Number(i)] = new EntityClasses[String(className)](\r\n odataObject.ExtensionProperties[Number(i)]\r\n );\r\n }\r\n } else {\r\n this.ExtensionProperties[Number(i)] = new EntityClasses.CommercePropertyClass(\r\n odataObject.ExtensionProperties[Number(i)]\r\n );\r\n }\r\n } else {\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n this.ExtensionProperties[Number(i)] = undefined;\r\n }\r\n }\r\n }\r\n }\r\n}\r\n\r\n/**\r\n * KRV_GetATPLeadTimeResponseQuantity entity class.\r\n */\r\nexport class KRV_GetATPLeadTimeResponseQuantityExtensionClass implements IKRV_GetATPLeadTimeResponseQuantity {\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n public ATPLeadTimePropertiesQuantityResponseEntityList: IKRV_ATPLeadTimePropertiesQuantityResponseEntity[];\r\n\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n public HighestDate: string;\r\n\r\n // Navigation properties names\r\n\r\n /**\r\n * Construct an object from odata response.\r\n * @param {any} odataObject The odata result object.\r\n */\r\n constructor(odataObject?: any) {\r\n odataObject = odataObject || {};\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n this.ATPLeadTimePropertiesQuantityResponseEntityList = undefined;\r\n if (odataObject.ATPLeadTimePropertiesQuantityResponseEntityList) {\r\n this.ATPLeadTimePropertiesQuantityResponseEntityList = [];\r\n for (var i = 0; i < odataObject.ATPLeadTimePropertiesQuantityResponseEntityList.length; i++) {\r\n if (odataObject.ATPLeadTimePropertiesQuantityResponseEntityList[Number(i)]) {\r\n if (odataObject.ATPLeadTimePropertiesQuantityResponseEntityList[Number(i)]['@odata.type']) {\r\n var className: string = odataObject.ATPLeadTimePropertiesQuantityResponseEntityList[Number(i)]['@odata.type'];\r\n className = className.substr(className.lastIndexOf('.') + 1).concat('Class');\r\n if (EntityClasses[String(className)]) {\r\n this.ATPLeadTimePropertiesQuantityResponseEntityList[Number(i)] = new EntityClasses[String(className)](\r\n odataObject.ATPLeadTimePropertiesQuantityResponseEntityList[Number(i)]\r\n );\r\n }\r\n } else {\r\n this.ATPLeadTimePropertiesQuantityResponseEntityList[\r\n Number(i)\r\n ] = new KRV_ATPLeadTimePropertiesQuantityResponseEntityExtensionClass(\r\n odataObject.ATPLeadTimePropertiesQuantityResponseEntityList[Number(i)]\r\n );\r\n }\r\n } else {\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n this.ATPLeadTimePropertiesQuantityResponseEntityList[Number(i)] = undefined;\r\n }\r\n }\r\n }\r\n\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n this.HighestDate = odataObject.HighestDate;\r\n }\r\n}\r\n","/*!\r\n * Copyright (c) Microsoft Corporation.\r\n * All rights reserved. See LICENSE in the project root for license information.\r\n * THIS FILE IS AN AUTOGENERATED TYPESCRIPT PROXY EXTENSION.\r\n * TO USE THIS FILE, IT MUST BE ADDED TO A D365COMMERCE APPLICATION\r\n */\r\n// tslint:disable\r\nimport { AsyncResult, callActionOrExecute, DataServiceQuery, IContext, IDataServiceRequest } from '@msdyn365-commerce/retail-proxy';\r\n// @ts-ignore\r\nimport * as EntityClasses from '@msdyn365-commerce/retail-proxy/dist/Entities/CommerceModels.g';\r\nimport * as DataServiceEntities from './DataServiceEntities.g';\r\n\r\n// @ts-ignore\r\nfunction kRV_ATPQuery(id?: number): DataServiceQuery {\r\n const key = id ? { Id: id } : null;\r\n return new DataServiceQuery(\r\n 'KRV_ATP',\r\n 'KRV_ATPLeadTimePropertiesDate',\r\n DataServiceEntities.KRV_ATPLeadTimePropertiesDateExtensionClass,\r\n key\r\n );\r\n}\r\n\r\nexport function createKRV_GetATPLeadTimeWithDateInput(itemId: string, requestedDate: string): IDataServiceRequest {\r\n const query = kRV_ATPQuery();\r\n return query.createDataServiceRequestForOperation(\r\n 'KRV_GetATPLeadTimeWithDate',\r\n true,\r\n DataServiceEntities.KRV_ATPLeadTimePropertiesDateExtensionClass,\r\n 'false',\r\n { bypassCache: 'get', returnEntity: 'DataServiceEntities.IKRV_ATPLeadTimePropertiesDate' },\r\n { itemId: itemId, requestedDate: requestedDate }\r\n );\r\n}\r\n\r\nexport function kRV_GetATPLeadTimeWithDateAsync(\r\n context: IContext,\r\n itemId: string,\r\n requestedDate: string\r\n): AsyncResult {\r\n const request = createKRV_GetATPLeadTimeWithDateInput(itemId, requestedDate);\r\n return callActionOrExecute(request, context.callerContext);\r\n}\r\n\r\nexport function createKRV_GetATPLeadTimeWithQuantityInput(\r\n kRVATPLeadTimeQuantity: DataServiceEntities.IKRV_ATPLeadTimePropertiesQuantityRequestEntity[]\r\n): IDataServiceRequest {\r\n const query = kRV_ATPQuery();\r\n return query.createDataServiceRequestForOperation(\r\n 'KRV_GetATPLeadTimeWithQuantity',\r\n true,\r\n DataServiceEntities.KRV_GetATPLeadTimeResponseQuantityExtensionClass,\r\n 'false',\r\n { bypassCache: 'get', returnEntity: 'DataServiceEntities.IKRV_GetATPLeadTimeResponseQuantity' },\r\n { KRVATPLeadTimeQuantity: kRVATPLeadTimeQuantity }\r\n );\r\n}\r\n\r\nexport function kRV_GetATPLeadTimeWithQuantityAsync(\r\n context: IContext,\r\n kRVATPLeadTimeQuantity: DataServiceEntities.IKRV_ATPLeadTimePropertiesQuantityRequestEntity[]\r\n): AsyncResult {\r\n const request = createKRV_GetATPLeadTimeWithQuantityInput(kRVATPLeadTimeQuantity);\r\n return callActionOrExecute(request, context.callerContext);\r\n}\r\n","/*--------------------------------------------------------------\r\n * Copyright (c) Microsoft Corporation. All rights reserved.\r\n * See License.txt in the project root for license information.\r\n *--------------------------------------------------------------*/\r\n\r\nimport {\r\n CacheType,\r\n createObservableDataAction,\r\n IAction,\r\n IActionContext,\r\n IActionInput,\r\n IAny,\r\n ICommerceApiSettings,\r\n ICreateActionContext,\r\n IGeneric\r\n} from '@msdyn365-commerce/core';\r\nimport { getAddressPurposesAsync } from '@msdyn365-commerce/retail-proxy/dist/DataActions/StoreOperationsDataActions.g';\r\nimport { AddressPurpose } from '@msdyn365-commerce/retail-proxy/dist/Entities/CommerceTypes.g';\r\nimport { buildCacheKey, QueryResultSettingsProxy } from '@msdyn365-commerce-modules/retail-actions';\r\n\r\n/**\r\n * Input class for get Address Purposes data action.\r\n */\r\nexport class GetAddressPurposesInput implements IActionInput {\r\n private readonly apiSettings: ICommerceApiSettings;\r\n\r\n constructor(apiSettings: ICommerceApiSettings) {\r\n this.apiSettings = apiSettings;\r\n }\r\n\r\n public getCacheKey = () => buildCacheKey('AddressPurpose', this.apiSettings);\r\n\r\n public getCacheObjectType = () => 'AddressPurpose';\r\n\r\n public dataCacheType = (): CacheType => 'application';\r\n}\r\n\r\n/**\r\n * Creates the input required to make the retail api call.\r\n * @param inputData\r\n */\r\nconst createInput = (inputData: ICreateActionContext>): GetAddressPurposesInput => {\r\n return new GetAddressPurposesInput(inputData.requestContext.apiSettings);\r\n};\r\n\r\nexport async function getAddressPurposesAction(input: GetAddressPurposesInput, ctx: IActionContext): Promise {\r\n return getAddressPurposesAsync({\r\n callerContext: ctx,\r\n queryResultSettings: QueryResultSettingsProxy.getPagingFromInputDataOrDefaultValue(ctx)\r\n });\r\n}\r\n\r\nexport const getAddressPurposesActionDataAction = createObservableDataAction({\r\n id: '@msdyn365-commerce-modules/address/get-address-purposes',\r\n action: >getAddressPurposesAction,\r\n input: createInput\r\n});\r\n\r\nexport default getAddressPurposesActionDataAction;\r\n","/*--------------------------------------------------------------\r\n * Copyright (c) Microsoft Corporation. All rights reserved.\r\n * See License.txt in the project root for license information.\r\n *--------------------------------------------------------------*/\r\n\r\nimport {\r\n CacheType,\r\n createObservableDataAction,\r\n IAction,\r\n IActionContext,\r\n IActionInput,\r\n ICommerceApiSettings\r\n} from '@msdyn365-commerce/core';\r\nimport { getStateProvincesAsync } from '@msdyn365-commerce/retail-proxy/dist/DataActions/StoreOperationsDataActions.g';\r\nimport { StateProvinceInfo } from '@msdyn365-commerce/retail-proxy/dist/Entities/CommerceTypes.g';\r\nimport { buildCacheKey, QueryResultSettingsProxy } from '@msdyn365-commerce-modules/retail-actions';\r\n\r\n/**\r\n * Input class for get state provinces data action.\r\n */\r\nexport class GetStateProvincesInput implements IActionInput {\r\n public countryRegionId: string;\r\n\r\n private readonly apiSettings: ICommerceApiSettings;\r\n\r\n constructor(countryRegionId: string, apiSettings: ICommerceApiSettings) {\r\n this.countryRegionId = countryRegionId;\r\n this.apiSettings = apiSettings;\r\n }\r\n\r\n public getCacheKey = () => buildCacheKey(`StateProvinceInfo-${this.countryRegionId}`, this.apiSettings);\r\n\r\n public getCacheObjectType = () => 'StateProvinceInfo';\r\n\r\n public dataCacheType = (): CacheType => 'request';\r\n}\r\n\r\nexport async function getStateProvinceAction(input: GetStateProvincesInput, ctx: IActionContext): Promise {\r\n return getStateProvincesAsync(\r\n {\r\n callerContext: ctx,\r\n queryResultSettings: QueryResultSettingsProxy.getPagingFromInputDataOrDefaultValue(ctx)\r\n },\r\n input.countryRegionId\r\n );\r\n}\r\n\r\nexport const getStateProvinceActionDataAction = createObservableDataAction({\r\n action: >getStateProvinceAction\r\n});\r\n\r\nexport default getStateProvinceActionDataAction;\r\n","/*--------------------------------------------------------------\r\n * Copyright (c) Microsoft Corporation. All rights reserved.\r\n * See License.txt in the project root for license information.\r\n *--------------------------------------------------------------*/\r\n\r\nimport { IActionInput, ICoreContext, IObservableAction, ITelemetry } from '@msdyn365-commerce/core';\r\nimport {\r\n Address,\r\n AddressPurpose,\r\n CountryRegionInfo,\r\n StateProvinceInfo\r\n} from '@msdyn365-commerce/retail-proxy/dist/Entities/CommerceTypes.g';\r\nimport {\r\n addAddress,\r\n AddressManagementInput,\r\n ArrayExtensions,\r\n updateAddress,\r\n updatePrimaryAddress\r\n} from '@msdyn365-commerce-modules/retail-actions';\r\n\r\nimport { getAddressPurposesAction, GetAddressPurposesInput } from '../actions/get-address-purposes';\r\nimport { getStateProvinceAction, GetStateProvincesInput } from '../actions/get-state-provinces';\r\n// import { IAddressResource, IAddressResponse } from './address-module.data';\r\nimport { IAddressResource, IAddressResponse } from '../common/address-module.data';\r\n\r\n/**\r\n *\r\n * Address common.\r\n */\r\nexport class AddressCommon {\r\n private readonly context: ICoreContext;\r\n\r\n private readonly resources: IAddressResource;\r\n\r\n private readonly telemetry: ITelemetry;\r\n\r\n constructor(context: ICoreContext, resources: IAddressResource, telemetry: ITelemetry) {\r\n this.context = context;\r\n this.resources = resources;\r\n this.telemetry = telemetry;\r\n }\r\n\r\n public getDefaultCountryRegionId = (countryRegionId: string, countryRegions: CountryRegionInfo[], market?: string): string => {\r\n const marketISOCode = market || 'US';\r\n const currentCountryRegion = countryRegions.find(countryRegion => (countryRegion.ISOCode || '') === marketISOCode);\r\n return (currentCountryRegion && currentCountryRegion.CountryRegionId) || countryRegionId;\r\n };\r\n\r\n public parseRetailException = (resources: IAddressResource): IAddressResponse => {\r\n return {\r\n errorTitle: resources.addressErrorMessageTitle,\r\n errorMessage: resources.addressGenericErrorMessage\r\n };\r\n };\r\n\r\n public isAuthenticatedFlow = (): boolean => {\r\n return this.context.request.user.isAuthenticated;\r\n };\r\n\r\n public getStateProvinces = async (countryRegionId: string): Promise => {\r\n let response: StateProvinceInfo[] = [];\r\n if (this.context && this.context.actionContext) {\r\n try {\r\n const input = new GetStateProvincesInput(countryRegionId, this.context.request.apiSettings);\r\n response = await getStateProvinceAction(input, this.context.actionContext);\r\n } catch (error) {\r\n if (this.telemetry) {\r\n this.telemetry.error(`Error encountered ${error}`);\r\n this.telemetry.debug('Unable to get state provinces');\r\n }\r\n }\r\n }\r\n return Promise.resolve(response);\r\n };\r\n\r\n // For any address, check for common requried field else treat it as invalid\\empty address.\r\n public isEmpty = (address: Address): boolean => {\r\n if (address && address.ThreeLetterISORegionName && (address.State || address.City)) {\r\n return false;\r\n }\r\n\r\n return true;\r\n };\r\n\r\n public addCustomerAddress = async (address: Address): Promise => {\r\n await this.updateLogisticsLocationRoleRecordId(address);\r\n return this.submitCustomerAddress(addAddress, address);\r\n };\r\n\r\n public updateCustomerAddress = async (address: Address): Promise => {\r\n await this.updateLogisticsLocationRoleRecordId(address);\r\n return this.submitCustomerAddress(updateAddress, address);\r\n };\r\n\r\n public updateCustomerPrimaryAddress = async (address: Address): Promise => {\r\n return this.submitCustomerAddress(updatePrimaryAddress, address);\r\n };\r\n\r\n private readonly submitCustomerAddress = async (\r\n addressAction: IObservableAction,\r\n address: Address\r\n ): Promise => {\r\n address.AddressTypeValue = address.AddressTypeValue || 7; // 7 sets it to HOME by default\r\n\r\n const input = new AddressManagementInput(address);\r\n return this.execAddressAction(addressAction, input, address);\r\n };\r\n\r\n private readonly execAddressAction = async (\r\n addressAction: IObservableAction,\r\n input: IActionInput | IActionInput[],\r\n address: Address\r\n ): Promise => {\r\n let response: IAddressResponse = {};\r\n\r\n if (this.context && this.context.actionContext) {\r\n try {\r\n const addresses = await addressAction(input, this.context.actionContext);\r\n if (addresses.length > 0) {\r\n response.address = address.RecordId ? address : addresses[addresses.length - 1];\r\n } else {\r\n response.address = address;\r\n }\r\n response.customerAddresses = addresses;\r\n } catch (error) {\r\n if (this.telemetry) {\r\n this.telemetry.error(`Error encountered ${error}`);\r\n this.telemetry.debug('Unable to exec address action');\r\n }\r\n response = this.parseRetailException(this.resources);\r\n }\r\n }\r\n return Promise.resolve(response);\r\n };\r\n\r\n /**\r\n * Function to get the address purposes and update the LogisticsLocationRoleRecordId to update the address type.\r\n * @param address - Address object.\r\n * @returns Returns void.\r\n */\r\n private readonly updateLogisticsLocationRoleRecordId = async (address: Address): Promise => {\r\n let addressPurposes: AddressPurpose[] = [];\r\n try {\r\n const input: GetAddressPurposesInput = new GetAddressPurposesInput(this.context.request.apiSettings);\r\n addressPurposes = await getAddressPurposesAction(input, this.context.actionContext);\r\n } catch (error) {\r\n // eslint-disable-next-line @typescript-eslint/restrict-template-expressions -- Supparsing the any type for error.\r\n this.telemetry.error(`Error encountered ${error}`);\r\n this.telemetry.debug('Unable to get address purposes');\r\n }\r\n if (ArrayExtensions.hasElements(addressPurposes)) {\r\n const addressPurpose: AddressPurpose | undefined = addressPurposes.find(\r\n purpose => purpose.AddressType === address.AddressTypeValue\r\n );\r\n if (addressPurpose) {\r\n address.LogisticsLocationRoleRecordId = addressPurpose.RecordId;\r\n }\r\n }\r\n };\r\n}\r\n","/*--------------------------------------------------------------\r\n * Copyright (c) Microsoft Corporation. All rights reserved.\r\n * See License.txt in the project root for license information.\r\n *--------------------------------------------------------------*/\r\n\r\nexport enum AddressItemDisplayType {\r\n Input = 'Input',\r\n Dropdown = 'Dropdown',\r\n Checkbox = 'Checkbox',\r\n Number = 'number' // VSI Customization for phone number\r\n}\r\n\r\nexport enum AddressValidationRuleType {\r\n Required = 'Required',\r\n Format = 'Format'\r\n}\r\n\r\nexport enum AddressItemType {\r\n Name = 1001,\r\n Phone = 1002,\r\n IsPrimary = 1003,\r\n AddressTypeValue = 1004,\r\n ZipCode = 1,\r\n City = 2,\r\n County = 3,\r\n State = 4,\r\n ThreeLetterISORegionName = 5,\r\n Street = 6,\r\n DistrictName = 7,\r\n StreetNumber = 8,\r\n BuildingCompliment = 9,\r\n Postbox = 10,\r\n House_RU = 21,\r\n Flat_RU = 22,\r\n CountryOKSMCode_RU = 23\r\n}\r\n\r\nexport interface IAddressItem {\r\n name: string;\r\n type: AddressItemType;\r\n label: string;\r\n maxLength: number;\r\n displayType: AddressItemDisplayType;\r\n validationRules?: IAddressValidationRule[];\r\n isNewLine: boolean;\r\n}\r\n\r\nexport interface IAddressValidationRule {\r\n type: AddressValidationRuleType;\r\n regEx: string;\r\n message: string;\r\n}\r\n\r\nexport interface IAddressDropdownsData {\r\n [index: string]: { key?: string | number; value?: string }[];\r\n}\r\n\r\n// tslint:disable-next-line: no-empty-interface\r\nexport interface IAddressFormatData {}\r\n","/* eslint-disable security/detect-non-literal-regexp */\r\n/*--------------------------------------------------------------\r\n * Copyright (c) Microsoft Corporation. All rights reserved.\r\n * See License.txt in the project root for license information.\r\n *--------------------------------------------------------------*/\r\n\r\nimport {\r\n Address,\r\n AddressPurpose,\r\n CountryRegionInfo,\r\n StateProvinceInfo\r\n} from '@msdyn365-commerce/retail-proxy/dist/Entities/CommerceTypes.g';\r\nimport { get, set } from 'mobx';\r\n\r\nimport { AddressItemType, IAddressDropdownsData, IAddressItem, IAddressValidationRule } from '../common/address-format.data';\r\nimport { AddressMetaData } from '../common/address-meta-data';\r\n/**\r\n *\r\n * Retail Service Address format parser.\r\n */\r\nexport class AddressFormat {\r\n private readonly countryRegionsInfo?: CountryRegionInfo[];\r\n\r\n private readonly addressPurposes?: AddressPurpose[];\r\n\r\n private readonly addressMetaData: AddressMetaData;\r\n\r\n constructor(countryRegionsInfo: CountryRegionInfo[], addressMetaData: AddressMetaData, addressPurposes: AddressPurpose[]) {\r\n this.countryRegionsInfo = countryRegionsInfo;\r\n this.addressMetaData = addressMetaData;\r\n this.addressPurposes = addressPurposes;\r\n }\r\n\r\n public getAddressFormat(countryRegionId: string): IAddressItem[] {\r\n const countryRegionInfo = this._getCountryRegionInfo(countryRegionId);\r\n if (countryRegionInfo) {\r\n return this._getAddressDisplayFormat(countryRegionInfo);\r\n }\r\n return [];\r\n }\r\n\r\n public getCountryFormat(): { key?: string; value?: string }[] {\r\n return (this.countryRegionsInfo || []).map(countryRegion => {\r\n return {\r\n key: countryRegion.CountryRegionId,\r\n value: countryRegion.ShortName\r\n };\r\n });\r\n }\r\n\r\n public getStateFormat(stateProvinceInfo?: StateProvinceInfo[]): { key?: string; value?: string }[] {\r\n return (stateProvinceInfo || []).map(state => {\r\n return {\r\n key: state.StateId,\r\n value: state.StateName\r\n };\r\n });\r\n }\r\n\r\n public getAddressTypeFormat(): { key?: number; value?: string }[] {\r\n return (this.addressPurposes || []).map(addressPurpose => {\r\n return {\r\n key: addressPurpose.AddressType,\r\n value: addressPurpose.Name\r\n };\r\n });\r\n }\r\n\r\n public getPrefilledAddressDropdownData = (\r\n stateDefaultSelectionText: string,\r\n stateProvinceInfo?: StateProvinceInfo[]\r\n ): IAddressDropdownsData => {\r\n const defaultStateText = {\r\n key: '',\r\n value: stateDefaultSelectionText\r\n };\r\n const dropdownData: IAddressDropdownsData = {};\r\n\r\n dropdownData[AddressItemType[AddressItemType.ThreeLetterISORegionName]] = this.getCountryFormat();\r\n dropdownData[AddressItemType[AddressItemType.State]] = this.getStateFormat(stateProvinceInfo);\r\n dropdownData[AddressItemType[AddressItemType.State]].unshift(defaultStateText);\r\n dropdownData[AddressItemType[AddressItemType.AddressTypeValue]] = this.getAddressTypeFormat();\r\n\r\n return dropdownData;\r\n };\r\n\r\n public getTwoLetterISORegionName = (countryRegionId: string): string | undefined => {\r\n const countryRegionInfo = this._getCountryRegionInfo(countryRegionId);\r\n\r\n return countryRegionInfo!.ISOCode;\r\n };\r\n\r\n public validateAddressFormat = (\r\n address: Address,\r\n validationError: Address,\r\n countryRegionId: string,\r\n propertyName?: string\r\n ): boolean => {\r\n let isValid: boolean = true;\r\n let validationtor;\r\n const addressFormat = this.getAddressFormat(address.ThreeLetterISORegionName || countryRegionId);\r\n\r\n addressFormat.forEach(addressFormatItem => {\r\n if (!propertyName || (propertyName && addressFormatItem.name === propertyName)) {\r\n validationtor = this._inputValidation(addressFormatItem, validationError, address);\r\n if (validationtor !== undefined) {\r\n isValid = validationtor;\r\n }\r\n }\r\n });\r\n\r\n return isValid;\r\n };\r\n\r\n public getTranformedAddress = (result: Microsoft.Maps.ISuggestionResult, stateProvinceInfo?: StateProvinceInfo[]): Address => {\r\n const address: Address = {};\r\n\r\n // Zip Code\r\n if (result.address.postalCode !== undefined) {\r\n address.ZipCode = result.address.postalCode;\r\n } else {\r\n address.ZipCode = '';\r\n }\r\n\r\n // State\r\n if (stateProvinceInfo) {\r\n const selectedState = stateProvinceInfo.find(state => state.StateName === result.address.adminDistrict);\r\n if (!selectedState) {\r\n address.State = '';\r\n address.StateName = result.address.adminDistrict;\r\n } else {\r\n address.State = selectedState.StateId;\r\n address.StateName = selectedState.StateName;\r\n }\r\n }\r\n\r\n // Street\r\n if (result.address.addressLine !== undefined) {\r\n address.Street = result.address.addressLine;\r\n } else {\r\n address.Street = ' ';\r\n }\r\n\r\n // City\r\n if (result.address.locality !== undefined) {\r\n address.City = result.address.locality;\r\n } else {\r\n address.City = '';\r\n }\r\n\r\n // District\r\n if (result.address.district !== undefined) {\r\n address.DistrictName = result.address.district;\r\n address.CountyName = result.address.district;\r\n } else {\r\n address.DistrictName = '';\r\n }\r\n\r\n // Formatted Address\r\n address.FullAddress = result.address.formattedAddress;\r\n\r\n return address;\r\n };\r\n\r\n private _inputValidation(addressFormatItem: IAddressItem, validationError: Address, address: Address): boolean | undefined {\r\n set(validationError, { [addressFormatItem.name]: null });\r\n for (const validationRule of addressFormatItem.validationRules || []) {\r\n if (!this._validateRegEx(address, addressFormatItem.name, validationRule)) {\r\n set(validationError, { [addressFormatItem.name]: validationRule.message });\r\n return false;\r\n }\r\n }\r\n return undefined;\r\n }\r\n\r\n private readonly _validateRegEx = (address: Address, propertyName: string, validationRule: IAddressValidationRule): boolean => {\r\n if (validationRule.regEx && validationRule.regEx.length > 0) {\r\n const regex = new RegExp(validationRule.regEx);\r\n return regex.test((get(address, propertyName) as string) || '');\r\n }\r\n return true;\r\n };\r\n\r\n private _getCountryRegionInfo(countryRegionId: string): CountryRegionInfo | undefined {\r\n return (this.countryRegionsInfo || []).find(countryRegion => {\r\n return (countryRegion.CountryRegionId || '').toLowerCase() === countryRegionId.toLowerCase();\r\n });\r\n }\r\n\r\n private _getAddressDisplayFormat(countryRegionInfo: CountryRegionInfo): IAddressItem[] {\r\n const addressDisplayItem: IAddressItem[] = [];\r\n\r\n if (countryRegionInfo && countryRegionInfo.AddressFormatLines) {\r\n const AddressTypeItem = this._extendAddressDisplayFormat(AddressItemType.AddressTypeValue, true);\r\n if (AddressTypeItem) {\r\n addressDisplayItem.push(AddressTypeItem);\r\n }\r\n\r\n const nameDisplayItem = this._extendAddressDisplayFormat(AddressItemType.Name, true);\r\n if (nameDisplayItem) {\r\n addressDisplayItem.push(nameDisplayItem);\r\n }\r\n\r\n countryRegionInfo.AddressFormatLines.forEach(formatLine => {\r\n if (formatLine.AddressComponentNameValue) {\r\n const addressItem = this.addressMetaData.getItemFormat(formatLine.AddressComponentNameValue);\r\n if (addressItem) {\r\n addressItem.isNewLine = formatLine.NewLine || false;\r\n addressDisplayItem.push(addressItem);\r\n }\r\n }\r\n });\r\n\r\n const phoneDisplayItem = this._extendAddressDisplayFormat(AddressItemType.Phone, false);\r\n if (phoneDisplayItem) {\r\n addressDisplayItem.push(phoneDisplayItem);\r\n }\r\n\r\n const isPrimaryDisplayItem = this._extendAddressDisplayFormat(AddressItemType.IsPrimary, false);\r\n if (isPrimaryDisplayItem) {\r\n addressDisplayItem.push(isPrimaryDisplayItem);\r\n }\r\n }\r\n\r\n return addressDisplayItem;\r\n }\r\n\r\n private _extendAddressDisplayFormat(type: AddressItemType, isNewLine: boolean): IAddressItem | undefined {\r\n const addressItem = this.addressMetaData.getItemFormat(type);\r\n if (addressItem) {\r\n addressItem.isNewLine = isNewLine;\r\n }\r\n return addressItem;\r\n }\r\n}\r\n","/* eslint-disable security/detect-object-injection */\r\n/*--------------------------------------------------------------\r\n * Copyright (c) Microsoft Corporation. All rights reserved.\r\n * See License.txt in the project root for license information.\r\n *--------------------------------------------------------------*/\r\n\r\n// import { PhoneRegex } from '@msdyn365-commerce-modules/retail-actions';\r\nimport { PhoneRegex } from '@msdyn365-commerce-modules/retail-actions';\r\n\r\nimport {\r\n AddressItemDisplayType,\r\n AddressItemType,\r\n AddressValidationRuleType,\r\n IAddressItem,\r\n IAddressValidationRule\r\n} from '../common/address-format.data';\r\nimport { IAddressResource } from '../common/address-module.data';\r\n\r\n/**\r\n * Address meta data.\r\n */\r\nexport class AddressMetaData {\r\n private readonly metaData: IAddressItem[] = [];\r\n\r\n private readonly resources: IAddressResource;\r\n\r\n private readonly requiredFieldRegEx: string = '\\\\S';\r\n\r\n private readonly resourcesPrefix: string = 'address';\r\n\r\n private readonly maxLength: number = 64;\r\n\r\n private readonly requiredFields: AddressItemType[];\r\n\r\n private readonly excludedTypes: AddressItemType[];\r\n\r\n constructor(resources: IAddressResource, excluded?: AddressItemType[], required?: AddressItemType[]) {\r\n this.resources = resources || {};\r\n this.excludedTypes = excluded || [];\r\n this.requiredFields =\r\n required !== undefined\r\n ? required\r\n : [\r\n AddressItemType.Name,\r\n AddressItemType.ZipCode,\r\n AddressItemType.City,\r\n AddressItemType.State,\r\n AddressItemType.ThreeLetterISORegionName,\r\n AddressItemType.Street,\r\n AddressItemType.Phone\r\n ];\r\n this._init();\r\n }\r\n\r\n public getItemFormat(id: number): IAddressItem | undefined {\r\n return this.metaData.find(item => {\r\n return item.type === id;\r\n });\r\n }\r\n\r\n private _init(): void {\r\n this._addItem(AddressItemType.Name, AddressItemDisplayType.Input);\r\n this._addItem(AddressItemType.Phone, AddressItemDisplayType.Input, PhoneRegex.defaultRegex); // VSI Customization for phone number and change error message from resources. Account management address, Buisness Account address, checkout shipping address.\r\n this._addItem(AddressItemType.ZipCode, AddressItemDisplayType.Input);\r\n this._addItem(AddressItemType.City, AddressItemDisplayType.Input);\r\n this._addItem(AddressItemType.County, AddressItemDisplayType.Input);\r\n this._addItem(AddressItemType.State, AddressItemDisplayType.Dropdown);\r\n this._addItem(AddressItemType.ThreeLetterISORegionName, AddressItemDisplayType.Dropdown);\r\n this._addItem(AddressItemType.Street, AddressItemDisplayType.Input);\r\n this._addItem(AddressItemType.DistrictName, AddressItemDisplayType.Input);\r\n this._addItem(AddressItemType.StreetNumber, AddressItemDisplayType.Input);\r\n this._addItem(AddressItemType.BuildingCompliment, AddressItemDisplayType.Input);\r\n this._addItem(AddressItemType.Postbox, AddressItemDisplayType.Input);\r\n this._addItem(AddressItemType.House_RU, AddressItemDisplayType.Input);\r\n this._addItem(AddressItemType.Flat_RU, AddressItemDisplayType.Input);\r\n this._addItem(AddressItemType.CountryOKSMCode_RU, AddressItemDisplayType.Input);\r\n this._addItem(AddressItemType.AddressTypeValue, AddressItemDisplayType.Dropdown);\r\n this._addItem(AddressItemType.IsPrimary, AddressItemDisplayType.Checkbox);\r\n }\r\n\r\n private _addItem(type: AddressItemType, displayType: AddressItemDisplayType, format?: string): void {\r\n if (this.excludedTypes.includes(type)) {\r\n return;\r\n }\r\n const nameKey = AddressItemType[type].replace('_', '');\r\n\r\n // Find out if currentItem is required field\r\n const validationRules = this._validationRules(type, nameKey, format);\r\n const isRequired = validationRules.some(rule => rule.type === AddressValidationRuleType.Required);\r\n\r\n // If no optional string is provided in resource file, use the original label text\r\n const optionalString =\r\n this.resources[`${this.resourcesPrefix}${nameKey}LabelOptional`] || this.resources[`${this.resourcesPrefix}${nameKey}Label`];\r\n const item: IAddressItem = {\r\n type,\r\n displayType,\r\n name: AddressItemType[type],\r\n label: isRequired ? this.resources[`${this.resourcesPrefix}${nameKey}Label`] : optionalString,\r\n maxLength: type === 1002 ? 11 : this.maxLength,\r\n validationRules,\r\n isNewLine: true\r\n };\r\n this.metaData.push(item);\r\n }\r\n\r\n private _validationRules(type: AddressItemType, name: string, format?: string): IAddressValidationRule[] {\r\n const validationRules: IAddressValidationRule[] = [];\r\n\r\n for (const ruleType of Object.keys(AddressValidationRuleType)) {\r\n const key = `${this.resourcesPrefix}${name}${ruleType}`;\r\n const message: string = this.resources[`${key}ErrorMessage`];\r\n switch (ruleType) {\r\n case AddressValidationRuleType.Required: {\r\n if (this.requiredFields.find((itemType: AddressItemType) => itemType === type)) {\r\n validationRules.push(this._validationRule(ruleType, this.requiredFieldRegEx, message));\r\n }\r\n break;\r\n }\r\n case AddressValidationRuleType.Format: {\r\n validationRules.push(this._validationRule(ruleType, format!, message));\r\n break;\r\n }\r\n default:\r\n }\r\n }\r\n return validationRules;\r\n }\r\n\r\n private _validationRule(type: AddressValidationRuleType, regEx: string, message: string): IAddressValidationRule {\r\n return {\r\n type,\r\n regEx,\r\n message\r\n };\r\n }\r\n}\r\n","/*--------------------------------------------------------------\r\n * Copyright (c) Microsoft Corporation. All rights reserved.\r\n * See License.txt in the project root for license information.\r\n *--------------------------------------------------------------*/\r\n\r\nimport { Address } from '@msdyn365-commerce/retail-proxy';\r\nimport { Heading } from '@msdyn365-commerce-modules/data-types';\r\n\r\nexport enum AddressOperation {\r\n Add = 'Add',\r\n Show = 'Show',\r\n Update = 'Update',\r\n List = 'List',\r\n Multiple = 'Multiple'\r\n}\r\n\r\nexport enum AddressType {\r\n Shipping = 'Shipping',\r\n Billing = 'Billing',\r\n Invoice = 'Invoice',\r\n Company = 'Company'\r\n}\r\n\r\nexport interface IDropdownDisplayData {\r\n [index: string]: { key?: string; value?: string }[];\r\n}\r\n\r\nexport interface IAddressResponse {\r\n errorTitle?: string;\r\n errorMessage?: string;\r\n customerAddresses?: Address[];\r\n address?: Address;\r\n}\r\n\r\nexport interface IAddressConfig {\r\n heading?: Heading;\r\n primaryAddressSectionHeading?: Heading;\r\n otherAddressSectionHeading?: Heading;\r\n addAddressHeading?: Heading;\r\n editAddressHeading?: Heading;\r\n}\r\n\r\nexport interface IAddressResource {\r\n addressChangeCheckboxAriaLabel: string;\r\n addressAddButtonText: string;\r\n addressAddButtonAriaLabel: string;\r\n addressAddNewButtonText?: string;\r\n addressAddNewButtonAriaLabel?: string;\r\n addressPrimaryButtonText: string;\r\n addressPrimaryButtonAriaLabel: string;\r\n addressEditButtonText: string;\r\n addressEditButtonAriaLabel: string;\r\n addressRemoveButtonText: string;\r\n addressRemoveButtonAriaLabel: string;\r\n addressSaveButtonText: string;\r\n addressSaveButtonAriaLabel: string;\r\n addressCancelButtonText: string;\r\n addressCancelButtonAriaLabel: string;\r\n addressStateDefaultSelectionText: string;\r\n addressNameLabel: string;\r\n addressNameLabelOptional?: string;\r\n addressNameRequiredErrorMessage: string;\r\n addressPhoneLabel: string;\r\n addressPhoneLabelOptional?: string;\r\n addressPhoneRequiredErrorMessage: string;\r\n addressZipCodeLabel: string;\r\n addressZipCodeLabelOptional?: string;\r\n addressZipCodeRequiredErrorMessage: string;\r\n addressCityLabel: string;\r\n addressCityLabelOptional?: string;\r\n addressCityRequiredErrorMessage: string;\r\n addressCountyLabel: string;\r\n addressCountyLabelOptional?: string;\r\n addressCountyRequiredErrorMessage: string;\r\n addressStateLabel: string;\r\n addressStateLabelOptional?: string;\r\n addressStateRequiredErrorMessage: string;\r\n addressThreeLetterISORegionNameLabel: string;\r\n addressThreeLetterISORegionNameLabelOptional?: string;\r\n addressThreeLetterISORegionNameRequiredErrorMessage: string;\r\n addressStreetRequiredErrorMessage: string;\r\n addressDistrictLabel: string;\r\n addressDistrictLabelOptional?: string;\r\n addressDistrictNameLabel: string;\r\n addressDistrictNameLabelOptional?: string;\r\n addressDistrictRequiredErrorMessage: string;\r\n addressStreetNumberLabel: string;\r\n addressStreetNumberLabelOptional?: string;\r\n addressStreetNumberRequiredErrorMessage: string;\r\n addressBuildingComplimentLabel: string;\r\n addressBuildingComplimentLabelOptional?: string;\r\n addressBuildingComplimentRequiredErrorMessage: string;\r\n addressPostboxLabel: string;\r\n addressPostboxLabelOptional?: string;\r\n addressPostboxRequiredErrorMessage: string;\r\n addressHouseRULabel: string;\r\n addressHouseRULabelOptional?: string;\r\n addressHouseRURequiredErrorMessage: string;\r\n addressFlatRULabel: string;\r\n addressFlatRULabelOptional?: string;\r\n addressFlatRURequiredErrorMessage: string;\r\n addressCountryOKSMCodeRULabel: string;\r\n addressCountryOKSMCodeRURequiredErrorMessage: string;\r\n addressErrorMessageTitle: string;\r\n addressGenericErrorMessage: string;\r\n addressEmptyListAddressMessage: string;\r\n removeAddressNotification?: string;\r\n addressProductImage?: string;\r\n addressProductNumberText?: string;\r\n addressProductText?: string;\r\n addressProductUnitPriceText?: string;\r\n addressProductUOMText?: string;\r\n addressProductQuantityText?: string;\r\n addressProductActionsText?: string;\r\n addressSelectAllRowsText?: string;\r\n addressProductAddressText?: string;\r\n addressShipMultipleText?: string;\r\n addressShipMultipleAriaLabel?: string;\r\n saveAndContinueBtnLabel?: string;\r\n addressShipSingleText?: string;\r\n addressShipSingleAriaLabel?: string;\r\n clearSelectionButtonText?: string;\r\n clearSelectionButtonAriaLabel?: string;\r\n chooseAddressForSelectedItemsText?: string;\r\n chooseAddressForSelectedItemsAriaLabel?: string;\r\n noAddressSelectedAriaLabel?: string;\r\n unavailableProductErrorMessage?: string;\r\n outOfStockProductErrorMessage?: string;\r\n}\r\n\r\n// tslint:disable-next-line: no-empty-interface\r\nexport interface IAddressModuleData {}\r\n","/*--------------------------------------------------------------\r\n * Copyright (c) Microsoft Corporation. All rights reserved.\r\n * See License.txt in the project root for license information.\r\n *--------------------------------------------------------------*/\r\n\r\nimport * as React from 'react';\r\n\r\nexport interface IAdressAlert {\r\n message?: string;\r\n}\r\n\r\n/**\r\n * Address alert.\r\n * @param props - Configuration of the functional component.\r\n * @returns React functional component.\r\n */\r\nexport const AddressAlertFunctionComponent: React.FC = (props: IAdressAlert) => {\r\n const message = props.message;\r\n return (\r\n \r\n {message && <>{message}}\r\n \r\n );\r\n};\r\n\r\nexport default AddressAlertFunctionComponent;\r\n","/*--------------------------------------------------------------\r\n * Copyright (c) Microsoft Corporation. All rights reserved.\r\n * See License.txt in the project root for license information.\r\n *--------------------------------------------------------------*/\r\n\r\nimport { getPayloadObject, getTelemetryAttributes, ITelemetryContent } from '@msdyn365-commerce-modules/utilities';\r\nimport * as React from 'react';\r\n\r\nexport interface IAdressCheckbox {\r\n id?: string;\r\n name?: string;\r\n className: string;\r\n type: string;\r\n isChecked: boolean;\r\n autoFocus?: boolean;\r\n additionalAddributes?: object;\r\n telemetryContent?: ITelemetryContent;\r\n onChange(event: React.ChangeEvent): void;\r\n}\r\n\r\n/**\r\n * Address checkbox.\r\n * @param props - Configuration of the functional component.\r\n * @returns React functional component.\r\n */\r\nexport const AddressCheckboxFunctionComponent: React.FC = (props: IAdressCheckbox) => {\r\n const {\r\n id: itemId,\r\n name,\r\n className,\r\n type,\r\n isChecked,\r\n additionalAddributes,\r\n telemetryContent,\r\n autoFocus: shouldBeAutoFocused,\r\n onChange\r\n } = props;\r\n\r\n const payLoad = getPayloadObject('click', telemetryContent!, name!);\r\n const attributes = getTelemetryAttributes(telemetryContent!, payLoad);\r\n return (\r\n \r\n );\r\n};\r\n\r\nexport default AddressCheckboxFunctionComponent;\r\n","/*--------------------------------------------------------------\r\n * Copyright (c) Microsoft Corporation. All rights reserved.\r\n * See License.txt in the project root for license information.\r\n *--------------------------------------------------------------*/\r\n\r\nimport * as React from 'react';\r\n\r\nexport interface IAdressDropdown {\r\n id: string;\r\n name: string;\r\n className: string;\r\n value: string | number;\r\n additionalAddributes?: object;\r\n displayData: { key?: string | number; value?: string }[];\r\n onChange(event: React.ChangeEvent): void;\r\n}\r\n\r\nconst getDropdownItem = (key?: string | number, value?: string, selectedValue?: string | number): React.ReactNode => {\r\n let isSelected: boolean;\r\n if (typeof key === 'number') {\r\n isSelected = key === selectedValue;\r\n } else {\r\n isSelected = typeof selectedValue === 'string' && (key || '').toLowerCase() === (selectedValue || '').toLowerCase();\r\n }\r\n\r\n return (\r\n \r\n );\r\n};\r\n\r\n/**\r\n * Address dropdown.\r\n * @param props - Configuration of the functional component.\r\n * @returns React functional component.\r\n */\r\nexport const AddressDropdownFunctionComponent: React.FC = (props: IAdressDropdown) => {\r\n const { id: itemId, name, className, value, additionalAddributes, displayData, onChange } = props;\r\n\r\n return (\r\n \r\n {displayData && displayData.map(item => getDropdownItem(item.key, item.value, value))}\r\n \r\n );\r\n};\r\n\r\nexport default AddressDropdownFunctionComponent;\r\n","/*--------------------------------------------------------------\r\n * Copyright (c) Microsoft Corporation. All rights reserved.\r\n * See License.txt in the project root for license information.\r\n *--------------------------------------------------------------*/\r\n\r\nimport * as React from 'react';\r\n\r\nexport interface IAdressLabel {\r\n id: string;\r\n text: string;\r\n}\r\n\r\n/**\r\n * Address label.\r\n * @param props - Configuration of the functional component.\r\n * @returns React functional component.\r\n */\r\nexport const AddressLabelFunctionComponent: React.FC = (props: IAdressLabel) => {\r\n const { id: itemId, text } = props;\r\n\r\n return (\r\n \r\n );\r\n};\r\n\r\nexport default AddressLabelFunctionComponent;\r\n","/*--------------------------------------------------------------\r\n * Copyright (c) Microsoft Corporation. All rights reserved.\r\n * See License.txt in the project root for license information.\r\n *--------------------------------------------------------------*/\r\n\r\nimport { Address } from '@msdyn365-commerce/retail-proxy/dist/Entities/CommerceTypes.g';\r\nimport { Heading as HeadingData } from '@msdyn365-commerce-modules/data-types';\r\nimport { Heading, INodeProps, ITelemetryContent } from '@msdyn365-commerce-modules/utilities';\r\nimport classname from 'classnames';\r\nimport { get } from 'mobx';\r\nimport * as React from 'react';\r\n\r\nimport {\r\n AddressItemDisplayType,\r\n AddressItemType,\r\n AddressValidationRuleType,\r\n IAddressDropdownsData,\r\n IAddressItem,\r\n IAddressValidationRule\r\n} from '../address-format.data';\r\nimport { AddressType, IAddressResource, IAddressResponse } from '../address-module.data';\r\nimport AddressAlertComponent from './address-alert';\r\nimport AddressButtonComponent from './address-button';\r\nimport AdressCheckboxComponent from './address-checkbox';\r\nimport AdressDropdownComponent from './address-dropdown';\r\nimport AddressErrorMessageComponent from './address-error-message';\r\nimport AddressErrorTitleComponent from './address-error-title';\r\nimport AddressInputComponent from './address-input';\r\nimport AddressLabelComponent from './address-label';\r\n\r\nexport interface IAddressAddInputProps {\r\n isUpdating?: boolean;\r\n hasError?: boolean;\r\n hasExternalSubmitGroup?: boolean;\r\n addressType: AddressType;\r\n addressFormat: IAddressItem[];\r\n defaultCountryRegionId: string;\r\n defaultAddressType: number;\r\n selectedAddress?: Address;\r\n dropdownDisplayData: IAddressDropdownsData;\r\n resources: IAddressResource;\r\n addressActionResponse?: IAddressResponse;\r\n addAddressHeading?: HeadingData;\r\n editAddressHeading?: HeadingData;\r\n validationError?: object;\r\n telemetryContent?: ITelemetryContent;\r\n shouldAutoFocus?: boolean;\r\n onInputChange(event: React.ChangeEvent): void;\r\n onDropdownChange(event: React.ChangeEvent): void;\r\n onSave?(): void;\r\n onCancel?(): void;\r\n usSiteFlag: boolean;\r\n mexicoSiteFlag: boolean;\r\n}\r\n\r\nexport interface IAddressError {\r\n AddressError: INodeProps;\r\n title: React.ReactNode;\r\n message: React.ReactNode;\r\n}\r\n\r\nexport interface IAddressAddItem {\r\n key: string;\r\n AddressItem: INodeProps;\r\n label: React.ReactNode;\r\n alert: React.ReactNode;\r\n input: React.ReactNode;\r\n customAlert: React.ReactNode;\r\n customLabel?: React.ReactNode;\r\n}\r\n\r\nexport interface IAddressAddUpdateProps {\r\n AddressForm: INodeProps;\r\n heading: React.ReactNode;\r\n items: IAddressAddItem[];\r\n hasError: boolean;\r\n error: IAddressError;\r\n isShowSaveButton: boolean;\r\n saveButton: React.ReactNode;\r\n isShowCancelButton: boolean;\r\n cancelButton: React.ReactNode;\r\n usSiteFlag?: boolean;\r\n mexicoSiteFlag?: boolean;\r\n}\r\n\r\nconst getRequriedAttribute = (validationRules?: IAddressValidationRule[]): object => {\r\n const requriedRule = (validationRules || []).find(validationRule => {\r\n return validationRule.type === AddressValidationRuleType.Required;\r\n });\r\n\r\n return requriedRule ? { 'aria-required': true } : {};\r\n};\r\n\r\nconst getAddessItems = (selectedAddress: Address, props: IAddressAddInputProps): IAddressAddItem[] => {\r\n const {\r\n addressFormat,\r\n addressType,\r\n dropdownDisplayData,\r\n defaultCountryRegionId,\r\n defaultAddressType,\r\n validationError = {},\r\n onInputChange,\r\n onDropdownChange,\r\n shouldAutoFocus,\r\n usSiteFlag,\r\n mexicoSiteFlag\r\n } = props;\r\n return addressFormat.map((addressFormatItem, index) => {\r\n const elementId = `${addressType.toLowerCase()}_address${addressFormatItem.name.toLowerCase()}`;\r\n const errorMessage = get(validationError, addressFormatItem.name);\r\n const className = classname(\r\n 'msc-address-form__item',\r\n addressFormatItem.name === 'Phone' && usSiteFlag && 'us-phone-format',\r\n `msc-address-form__item-${addressFormatItem.name.toLowerCase()}`,\r\n {\r\n 'msc-address-form__item-newline': addressFormatItem.isNewLine,\r\n 'address-form__item-invalid': errorMessage\r\n }\r\n );\r\n let input;\r\n if (addressFormatItem.displayType === AddressItemDisplayType.Input) {\r\n input = (\r\n \r\n );\r\n }\r\n // VSI Customization for type number\r\n else if (addressFormatItem.displayType === AddressItemDisplayType.Number) {\r\n input = (\r\n \r\n );\r\n } else if (addressFormatItem.displayType === AddressItemDisplayType.Checkbox) {\r\n input = (\r\n \r\n );\r\n } else {\r\n const displayData = dropdownDisplayData[addressFormatItem.name];\r\n let selectedValue = selectedAddress[addressFormatItem.name];\r\n\r\n if (addressFormatItem.type === AddressItemType.ThreeLetterISORegionName) {\r\n selectedValue = selectedValue || defaultCountryRegionId;\r\n }\r\n\r\n if (addressFormatItem.type === AddressItemType.AddressTypeValue) {\r\n selectedValue = selectedValue || defaultAddressType;\r\n }\r\n\r\n input = (\r\n \r\n );\r\n }\r\n const zipcodeError = errorMessage?.replace('Post code', 'Zip Code');\r\n const postcodeError = errorMessage?.replace('Post code', 'Postal Code');\r\n return {\r\n key: addressFormatItem.name,\r\n AddressItem: { className, id: `${elementId}_container` },\r\n label: ,\r\n customLabel:\r\n addressFormatItem.name.toLowerCase() === 'zipcode' ? (\r\n \r\n ) : null,\r\n alert: (\r\n \r\n ),\r\n input,\r\n customAlert:\r\n addressFormatItem.name === 'ZipCode' && selectedAddress[addressFormatItem.name]?.length === 10 ? (\r\n \r\n ) : (\r\n returnAddressAlertComponent(addressFormatItem.name, selectedAddress[addressFormatItem.name], usSiteFlag, mexicoSiteFlag)\r\n )\r\n };\r\n });\r\n};\r\n\r\nconst returnAddressAlertComponent = (AddressName: string, value: string, usSiteFlag?: boolean, mexicoSiteFlag?: boolean) => {\r\n if (usSiteFlag) {\r\n if (AddressName === 'Phone' && (value?.length <= 12 || value?.length === 14)) {\r\n return (\r\n \r\n );\r\n } else {\r\n return null;\r\n }\r\n } else if (mexicoSiteFlag) {\r\n if (AddressName === 'Phone' && (value?.length <= 12 || value?.length === 15)) {\r\n return (\r\n \r\n );\r\n } else {\r\n return null;\r\n }\r\n } else {\r\n if (AddressName === 'Phone' && value?.length === 14) {\r\n return (\r\n \r\n );\r\n } else {\r\n return null;\r\n }\r\n }\r\n};\r\n\r\nexport const AddressAddUpdate = (props: IAddressAddInputProps): IAddressAddUpdateProps => {\r\n const {\r\n editAddressHeading,\r\n addAddressHeading,\r\n selectedAddress = {},\r\n resources,\r\n hasError,\r\n onCancel,\r\n onSave,\r\n hasExternalSubmitGroup,\r\n isUpdating,\r\n addressActionResponse,\r\n telemetryContent\r\n } = props;\r\n const heading = selectedAddress.RecordId ? editAddressHeading : addAddressHeading;\r\n return {\r\n AddressForm: { className: 'msc-address-form' },\r\n heading: heading && ,\r\n items: getAddessItems(selectedAddress, props),\r\n isShowSaveButton: !hasExternalSubmitGroup,\r\n saveButton: onSave && (\r\n \r\n ),\r\n isShowCancelButton: !hasExternalSubmitGroup,\r\n cancelButton: onCancel && (\r\n \r\n ),\r\n hasError: hasError || false,\r\n error: {\r\n AddressError: { className: 'msc-address-form__error' },\r\n title: addressActionResponse && addressActionResponse.errorTitle && ,\r\n message: addressActionResponse && addressActionResponse.errorMessage && (\r\n \r\n )\r\n }\r\n };\r\n};\r\n","/*--------------------------------------------------------------\r\n * Copyright (c) Microsoft Corporation. All rights reserved.\r\n * See License.txt in the project root for license information.\r\n *--------------------------------------------------------------*/\r\n\r\nimport { getPayloadObject, getTelemetryAttributes, ITelemetryContent } from '@msdyn365-commerce-modules/utilities';\r\nimport * as React from 'react';\r\n\r\nexport interface IAddressButton {\r\n className: string;\r\n text: string;\r\n ariaLabel: string;\r\n disabled?: boolean;\r\n telemetryContent?: ITelemetryContent;\r\n role?: string;\r\n onClick(event: React.MouseEvent): void;\r\n}\r\n\r\n/**\r\n * Address button.\r\n * @param props - Configuration of the functional component.\r\n * @returns React functional component.\r\n */\r\nexport const AddressButtonFunctionComponent: React.FC = (props: IAddressButton) => {\r\n const { className, text, ariaLabel, disabled: isDisabled, telemetryContent, onClick, role } = props;\r\n const payLoad = getPayloadObject('click', telemetryContent!, text);\r\n const attributes = getTelemetryAttributes(telemetryContent!, payLoad);\r\n return (\r\n \r\n );\r\n};\r\n\r\nexport default AddressButtonFunctionComponent;\r\n","/*--------------------------------------------------------------\r\n * Copyright (c) Microsoft Corporation. All rights reserved.\r\n * See License.txt in the project root for license information.\r\n *--------------------------------------------------------------*/\r\n\r\nimport * as React from 'react';\r\n\r\nexport interface IAdressErrorMessage {\r\n message: string;\r\n}\r\n\r\n/**\r\n * Address error message.\r\n * @param props - Configuration of the functional component.\r\n * @returns React functional component.\r\n */\r\nexport const AddressErrorMessageFunctionComponent: React.FC = (props: IAdressErrorMessage) => {\r\n const { message } = props;\r\n\r\n return

{message}

;\r\n};\r\n\r\nexport default AddressErrorMessageFunctionComponent;\r\n","/*--------------------------------------------------------------\r\n * Copyright (c) Microsoft Corporation. All rights reserved.\r\n * See License.txt in the project root for license information.\r\n *--------------------------------------------------------------*/\r\n\r\nimport * as React from 'react';\r\n\r\nexport interface IAdressErrorTitle {\r\n title: string;\r\n}\r\n\r\n/**\r\n * Address error title.\r\n * @param props - Configuration of the functional component.\r\n * @returns React functional component.\r\n */\r\nexport const AddressErrorTitleFunctionComponent: React.FC = (props: IAdressErrorTitle) => {\r\n const { title } = props;\r\n\r\n return

{title}

;\r\n};\r\n\r\nexport default AddressErrorTitleFunctionComponent;\r\n","/*--------------------------------------------------------------\r\n * Copyright (c) Microsoft Corporation. All rights reserved.\r\n * See License.txt in the project root for license information.\r\n *--------------------------------------------------------------*/\r\n\r\nimport { getPayloadObject, getTelemetryAttributes, ITelemetryContent } from '@msdyn365-commerce-modules/utilities';\r\nimport * as React from 'react';\r\n\r\nexport interface IAdressInput {\r\n id?: string;\r\n name?: string;\r\n className: string;\r\n type: string;\r\n value: string;\r\n maxLength?: number;\r\n autoFocus?: boolean;\r\n additionalAddributes?: object;\r\n telemetryContent?: ITelemetryContent;\r\n onChange(event: React.ChangeEvent): void;\r\n defaultCountryRegionId?: string;\r\n usSiteFlag?: boolean;\r\n mexicoSiteFlag?: boolean;\r\n}\r\n\r\n/**\r\n * Address input.\r\n * @param props - Configuration of the functional component.\r\n * @returns React functional component.\r\n */\r\nexport const AddressInputFunctionComponent: React.FC = (props: IAdressInput) => {\r\n const {\r\n id: itemId,\r\n name,\r\n className,\r\n type,\r\n value,\r\n maxLength,\r\n additionalAddributes,\r\n autoFocus: shouldUseAutoFocus,\r\n telemetryContent,\r\n onChange,\r\n defaultCountryRegionId\r\n } = props;\r\n const usSiteFlag = props.usSiteFlag ? props.usSiteFlag : undefined;\r\n const mexicoSiteFlag = props.mexicoSiteFlag ? props.mexicoSiteFlag : undefined;\r\n const payLoad = getPayloadObject('click', telemetryContent!, name!);\r\n const attributes = getTelemetryAttributes(telemetryContent!, payLoad);\r\n //VSI customization for business-sign-up\r\n let numberValue = '';\r\n const customMaxLength = usSiteFlag && name === 'Phone' ? 14 : maxLength;\r\n if (name === 'Phone' && value !== undefined) {\r\n if (usSiteFlag) {\r\n const rawPhoneNumber = value.replace(/\\D/g, ''); // Remove non-numeric characters\r\n let formattedPhoneNumber = '';\r\n if (rawPhoneNumber.length >= 11) {\r\n formattedPhoneNumber = rawPhoneNumber.substring(1);\r\n formattedPhoneNumber = formattedPhoneNumber?.split(' ').join('');\r\n // Apply formatting\r\n const areaCode = formattedPhoneNumber?.slice(0, 3);\r\n const firstPart = formattedPhoneNumber?.slice(3, 6);\r\n const secondPart = formattedPhoneNumber?.slice(6);\r\n formattedPhoneNumber = `(${areaCode}) ${firstPart}-${secondPart}`;\r\n } else if (mexicoSiteFlag) {\r\n formattedPhoneNumber = (value || '').replace(new RegExp('[<>]', 'gi'), '');\r\n const tempValue = formattedPhoneNumber.split(' ').join('');\r\n formattedPhoneNumber = tempValue.replace(/(\\d{2})(\\d{2})(\\d{4})(\\d{4})/, '$1 $2 $3 $4');\r\n } else {\r\n if (rawPhoneNumber.length >= 1) {\r\n formattedPhoneNumber = `(${rawPhoneNumber.slice(0, 3)}`;\r\n if (rawPhoneNumber.length > 3) {\r\n formattedPhoneNumber += `) ${rawPhoneNumber.slice(3, 6)}`;\r\n if (rawPhoneNumber.length > 6) {\r\n formattedPhoneNumber += `-${rawPhoneNumber.slice(6, 10)}`;\r\n }\r\n }\r\n }\r\n }\r\n numberValue = formattedPhoneNumber;\r\n } else {\r\n const phoneReg = /^[0-9\\s]*$/;\r\n if (phoneReg.test(value)) {\r\n numberValue = value;\r\n } else {\r\n numberValue = value.slice(0, -1);\r\n }\r\n }\r\n } else if (name === 'ZipCode' && value !== undefined) {\r\n const zipCodeRegex = /^[a-zA-Z0-9_.-]*$/;\r\n if (zipCodeRegex.test(value)) {\r\n numberValue = value;\r\n } else {\r\n numberValue = value.slice(0, -1);\r\n }\r\n }\r\n return (\r\n \r\n );\r\n};\r\n\r\nexport default AddressInputFunctionComponent;\r\n","/* eslint-disable @typescript-eslint/no-floating-promises */\r\n/*!\r\n * Copyright (c) Microsoft Corporation.\r\n * All rights reserved. See LICENSE in the project root for license information.\r\n */\r\n\r\n/* eslint-disable no-duplicate-imports */\r\nimport { Address, AddressPurpose, CountryRegionInfo, StateProvinceInfo } from '@msdyn365-commerce/retail-proxy';\r\nimport { ObjectExtensions } from '@msdyn365-commerce-modules/retail-actions';\r\nimport { getTelemetryObject, IModuleProps, ITelemetryContent } from '@msdyn365-commerce-modules/utilities';\r\nimport classnames from 'classnames';\r\nimport { observable, reaction, set } from 'mobx';\r\nimport * as React from 'react';\r\n\r\nimport { AddressCommon } from '../../common/address-common';\r\nimport { AddressFormat } from '../../common/address-format';\r\nimport { AddressItemDisplayType, AddressItemType, AddressValidationRuleType, IAddressItem } from '../../common/address-format.data';\r\nimport { AddressMetaData } from '../../common/address-meta-data';\r\nimport { AddressOperation, AddressType, IAddressResource, IAddressResponse } from '../../common/address-module.data';\r\nimport { AddressAddUpdate, IAddressAddUpdateProps } from '../../common/components/address-add';\r\nimport { IKrannichCBusinessAccountAddressData } from './krannich-c-business-account-address.data';\r\nimport { IKrannichCBusinessAccountAddressProps } from './krannich-c-business-account-address.props.autogenerated';\r\n\r\n/**\r\n * Interface for IBusinessAccountAddressExtendedProps.\r\n */\r\nexport interface IBusinessAccountAddressExtendedProps extends IKrannichCBusinessAccountAddressProps {\r\n hasError: boolean;\r\n isRequired: boolean;\r\n resetAddress: boolean;\r\n updateForm(errors: boolean, currentAddress?: Address): void;\r\n}\r\n\r\n/**\r\n * Interface for IBusinessAccountAddressState.\r\n */\r\nexport interface IBusinessAccountAddressState {\r\n countryId?: string;\r\n states?: StateProvinceInfo[];\r\n}\r\n\r\n/**\r\n * Interface for IBusinessAccountAddressViewProps.\r\n */\r\nexport interface IBusinessAccountAddressViewProps {\r\n className: string;\r\n currentOperation: AddressOperation;\r\n selectedAddress?: Address;\r\n addUpdateAddress: Address;\r\n addressListSelectedAddress: Address;\r\n countryRegionId: string;\r\n stateProvinceInfo?: StateProvinceInfo[];\r\n customerAddresses: Address[];\r\n validationError: object;\r\n addressActionResponse?: IAddressResponse;\r\n BusinessAccountAddress: IModuleProps;\r\n isUpdating: boolean;\r\n hasError: boolean;\r\n showAddOrUpdateAddress: IAddressAddUpdateProps;\r\n usSiteFlag?: boolean;\r\n mexicoSiteFlag?: boolean;\r\n}\r\n\r\n/**\r\n *\r\n * Address component.\r\n * @extends {React.Component, IBusinessAccountAddressState>}\r\n */\r\nclass BusinessAccountAddress extends React.Component {\r\n @observable private addUpdateAddress: Address;\r\n\r\n @observable private countryRegionId: string = 'USA';\r\n\r\n @observable private stateProvinceInfo?: StateProvinceInfo[];\r\n\r\n @observable private readonly validationError: object;\r\n\r\n private readonly addressActionResponse?: IAddressResponse;\r\n\r\n private readonly isUpdating?: boolean;\r\n\r\n private readonly addressCommon: AddressCommon;\r\n\r\n private addressFormat: AddressFormat;\r\n\r\n private countryRegions: CountryRegionInfo[] = [];\r\n\r\n private addressPurposes: AddressPurpose[] = [];\r\n\r\n private readonly resources: IAddressResource;\r\n\r\n private readonly defaultAddressType: number = 0; // Default to None (This value set in HQ as Business)\r\n\r\n private readonly shouldAutoFocus?: boolean = false;\r\n\r\n private readonly excludedList: AddressItemType[] = [AddressItemType.Name, AddressItemType.AddressTypeValue, AddressItemType.IsPrimary]; // Default to hiding Name and AddressType inputs\r\n\r\n private readonly telemetryContent: ITelemetryContent;\r\n\r\n public constructor(props: IBusinessAccountAddressExtendedProps) {\r\n super(props);\r\n\r\n const { context, data, resources, telemetry } = this.props;\r\n this.addUpdateAddress = {};\r\n this.resources = resources;\r\n this.countryRegions = data.countryRegions.result || [];\r\n this.addressPurposes = data.addressPurposes.result || [];\r\n this.stateProvinceInfo = data.countryStates.result || [];\r\n this.addressFormat = new AddressFormat(\r\n this.countryRegions,\r\n new AddressMetaData({ ...resources }, this.excludedList, props.isRequired ? undefined : []),\r\n this.addressPurposes\r\n );\r\n this.addressCommon = new AddressCommon(context, resources, telemetry);\r\n this.validationError = {};\r\n this.telemetryContent = getTelemetryObject(\r\n this.props.context.request.telemetryPageName!,\r\n this.props.friendlyName,\r\n this.props.telemetry\r\n );\r\n }\r\n\r\n public componentDidMount(): void {\r\n // Initializing data props\r\n this._dataInitialize(this.props);\r\n\r\n this._setDefaultCountryRegionId();\r\n }\r\n\r\n public shouldComponentUpdate(nextProps: IBusinessAccountAddressExtendedProps, nextState: IBusinessAccountAddressState): boolean {\r\n if (this.state === nextState && this.props.data === nextProps.data) {\r\n return false;\r\n }\r\n return true;\r\n }\r\n\r\n public render(): JSX.Element | null {\r\n const { renderView, config, hasError, resetAddress } = this.props;\r\n\r\n // Business-sign-up will pass this flag when cancel button is clicked\r\n if (resetAddress) {\r\n this._resetAddressFields();\r\n }\r\n const viewProps = {\r\n ...this.props,\r\n countryRegionId: this.countryRegionId,\r\n stateProvinceInfo: this.stateProvinceInfo,\r\n validationError: this.validationError,\r\n addressActionResponse: this.addressActionResponse,\r\n hasError,\r\n className: config.className,\r\n BusinessAccountAddress: {\r\n moduleProps: this.props,\r\n className: classnames('ms-business-account-address', config.className)\r\n },\r\n showAddOrUpdateAddress: this._renderAddOrUpdateAddress(),\r\n usSiteFlag:\r\n this.props?.context?.actionContext?.requestContext?.apiSettings?.oun === this.props.context.app.config.ounNumberForUsSite,\r\n mexicoSiteFlag:\r\n this.props?.context?.actionContext?.requestContext?.apiSettings?.oun ===\r\n this.props.context.app.config.ounNumberForMexicoSite\r\n };\r\n\r\n return renderView(viewProps) as React.ReactElement;\r\n }\r\n\r\n /**\r\n * Reset Address.\r\n */\r\n // eslint-disable-next-line @typescript-eslint/naming-convention\r\n public _resetAddressFields = () => {\r\n const addressFormat = this.addressFormat.getAddressFormat(this.countryRegionId);\r\n\r\n addressFormat.map(addressFormatItem => {\r\n switch (addressFormatItem.displayType) {\r\n case AddressItemDisplayType.Input:\r\n this.addUpdateAddress[addressFormatItem.name] = '';\r\n break;\r\n case AddressItemDisplayType.Checkbox:\r\n this.addUpdateAddress[addressFormatItem.name] = false;\r\n break;\r\n default:\r\n switch (addressFormatItem.type) {\r\n case AddressItemType.ThreeLetterISORegionName:\r\n this.addUpdateAddress[addressFormatItem.name] = this.countryRegionId;\r\n break;\r\n case AddressItemType.AddressTypeValue:\r\n this.addUpdateAddress[addressFormatItem.name] = this.defaultAddressType;\r\n break;\r\n case AddressItemType.State:\r\n this.addUpdateAddress[addressFormatItem.name] = '';\r\n break;\r\n default:\r\n this.addUpdateAddress[addressFormatItem.name] = undefined;\r\n }\r\n }\r\n });\r\n };\r\n\r\n /**\r\n * Method data initialization.\r\n * @param props -The account management props.\r\n */\r\n private readonly _dataInitialize = (props: IBusinessAccountAddressExtendedProps): void => {\r\n const { data } = props;\r\n\r\n reaction(\r\n () => data.countryRegions.result,\r\n () => {\r\n this.countryRegions = data.countryRegions.result ?? [];\r\n }\r\n );\r\n\r\n reaction(\r\n () => data.addressPurposes.result,\r\n () => {\r\n this.addressPurposes = data.addressPurposes.result ?? [];\r\n }\r\n );\r\n\r\n reaction(\r\n () => data.countryStates.result,\r\n () => {\r\n this.stateProvinceInfo = data.countryStates.result ?? [];\r\n }\r\n );\r\n };\r\n\r\n // Set validationError and hasError to hide error messages since in the B2B\r\n // request form, no errors would visually show since user wont be able to submit\r\n // until form is filled and correct\r\n /**\r\n * Render Add Or Update Address Function.\r\n * @returns - AddressAddUpdate.\r\n */\r\n\r\n private readonly _renderAddOrUpdateAddress = (): IAddressAddUpdateProps => {\r\n const usSiteFlag =\r\n this.props?.context?.actionContext?.requestContext?.apiSettings?.oun === this.props.context.app.config.ounNumberForUsSite;\r\n const mexicoSiteFlag =\r\n this.props?.context?.actionContext?.requestContext?.apiSettings?.oun === this.props.context.app.config.ounNumberForMexicoSite;\r\n return AddressAddUpdate({\r\n isUpdating: this.isUpdating,\r\n resources: this.resources,\r\n addressType: AddressType.Company,\r\n addressFormat: this.addressFormat.getAddressFormat(this.countryRegionId),\r\n defaultCountryRegionId: this.countryRegionId,\r\n defaultAddressType: this.defaultAddressType,\r\n selectedAddress: this.addUpdateAddress,\r\n shouldAutoFocus: this.shouldAutoFocus,\r\n validationError: this.validationError,\r\n hasError: this.props.hasError,\r\n addressActionResponse: this.addressActionResponse,\r\n telemetryContent: this.telemetryContent,\r\n dropdownDisplayData: this.addressFormat.getPrefilledAddressDropdownData(\r\n this.resources.addressStateDefaultSelectionText,\r\n this.stateProvinceInfo\r\n ),\r\n onInputChange: this._onAddressAddUpdateInputChange,\r\n onDropdownChange: this._onAddressAddUpdateDropdownChange,\r\n usSiteFlag,\r\n mexicoSiteFlag\r\n });\r\n };\r\n\r\n /**\r\n * On Address Add Update Input Change Function.\r\n * @param event - Input event change function.\r\n */\r\n private readonly _onAddressAddUpdateInputChange = (event: React.ChangeEvent): void => {\r\n this._updateAddress(event.target.name, event.target.value);\r\n };\r\n\r\n /**\r\n * On Address Add Update Dropdown Change Function.\r\n * @param event - Change dropdown event.\r\n */\r\n private readonly _onAddressAddUpdateDropdownChange = async (event: React.ChangeEvent): Promise => {\r\n if (event.target.name === AddressItemType[AddressItemType.ThreeLetterISORegionName]) {\r\n await this._updateCountryRegionId(event.target.value);\r\n } else {\r\n this._updateAddress(event.target.name, event.target.value);\r\n }\r\n };\r\n\r\n /**\r\n * Update Address Function.\r\n * @param name - String.\r\n * @param value - String.\r\n */\r\n private readonly _updateAddress = (name: string, value: string | number) => {\r\n const usSiteFlag =\r\n this.props?.context?.actionContext?.requestContext?.apiSettings?.oun === this.props.context.app.config.ounNumberForUsSite;\r\n const mexicoSiteFlag =\r\n this.props?.context?.actionContext?.requestContext?.apiSettings?.oun === this.props.context.app.config.ounNumberForMexicoSite;\r\n const { updateForm, isRequired, resources } = this.props;\r\n let cleanValue = value;\r\n if (typeof value === 'string') {\r\n if (name === 'Phone') {\r\n if (usSiteFlag) {\r\n cleanValue = value.replace(/\\D/g, ''); // Remove non-numeric characters\r\n } else if (mexicoSiteFlag) {\r\n cleanValue = (value || '').replace(new RegExp('[<>]', 'gi'), '');\r\n const tempValue = cleanValue.split(' ').join('');\r\n cleanValue = tempValue.replace(/(\\d{2})(\\d{2})(\\d{4})(\\d{4})/, '$1 $2 $3 $4');\r\n } else {\r\n cleanValue = (value || '').replace(new RegExp('[<>]', 'gi'), '');\r\n const tempValue = cleanValue.split(' ').join('');\r\n cleanValue = tempValue.replace(/(\\d{2})(\\d{1})(\\d{4})(\\d{4})/, '$1 $2 $3 $4');\r\n // VSI CUSOTMIZATION TO REPLACE STRING WITH NUMBER FORMAT\r\n }\r\n } else {\r\n cleanValue = (value || '').replace(new RegExp('[<>]', 'gi'), '');\r\n }\r\n }\r\n set(this.addUpdateAddress, { [name]: cleanValue });\r\n\r\n if (this._isEmpty()) {\r\n if (isRequired) {\r\n updateForm(true, undefined);\r\n } else {\r\n // Reset addressFormat as if address was NOT a required field\r\n this.addressFormat = new AddressFormat(\r\n this.countryRegions,\r\n new AddressMetaData({ ...resources }, this.excludedList, []),\r\n this.addressPurposes\r\n );\r\n updateForm(false, this.addUpdateAddress);\r\n }\r\n } else {\r\n // Get new addressFormat if address was a required field\r\n this.addressFormat = new AddressFormat(\r\n this.countryRegions,\r\n new AddressMetaData({ ...resources }, this.excludedList, undefined),\r\n this.addressPurposes\r\n );\r\n\r\n // Verify with new rules\r\n if (this.addressFormat.validateAddressFormat(this.addUpdateAddress, this.validationError, this.countryRegionId)) {\r\n updateForm(false, this.addUpdateAddress);\r\n } else {\r\n updateForm(true, undefined);\r\n }\r\n }\r\n };\r\n\r\n /**\r\n * Is empty Function.\r\n * @returns - Boolean.\r\n */\r\n // Walk through array and check if valued is defined or value is not an empty string\r\n private readonly _isEmpty = () => {\r\n const addressFormat = this.addressFormat.getAddressFormat(this.countryRegionId);\r\n for (const addressFormatItem of addressFormat) {\r\n if (addressFormatItem.type !== AddressItemType.ThreeLetterISORegionName || this._isInputRequired(addressFormatItem)) {\r\n const addressItemValue = this.addUpdateAddress[addressFormatItem.name];\r\n\r\n // Check each input field, if value is defined and not an empty string --> address is not empty\r\n if (addressItemValue || (addressItemValue && addressItemValue !== '')) {\r\n return false;\r\n }\r\n }\r\n }\r\n\r\n return true;\r\n };\r\n\r\n /**\r\n * Is Input Required Function.\r\n * @param addressFormatItem - IAddressItem.\r\n * @returns - Boolean.\r\n */\r\n private readonly _isInputRequired = (addressFormatItem: IAddressItem): boolean => {\r\n if (\r\n ObjectExtensions.isNullOrUndefined(addressFormatItem) ||\r\n !addressFormatItem.validationRules ||\r\n addressFormatItem.validationRules.length === 0\r\n ) {\r\n return false;\r\n }\r\n\r\n for (const validationRule of addressFormatItem.validationRules) {\r\n if (validationRule.type === AddressValidationRuleType.Required) {\r\n return false;\r\n }\r\n }\r\n\r\n return true;\r\n };\r\n\r\n private _setDefaultCountryRegionId(): void {\r\n const { request } = this.props.context;\r\n const market = request.channel?.ChannelCountryRegionISOCode;\r\n\r\n this._updateCountryRegionId(this.addressCommon.getDefaultCountryRegionId(this.countryRegionId, this.countryRegions, market));\r\n\r\n // Set default AddressType\r\n set(this.addUpdateAddress, { AddressTypeValue: this.defaultAddressType });\r\n }\r\n\r\n /**\r\n * Update Country Region Id Function.\r\n * @param value - String.\r\n */\r\n private readonly _updateCountryRegionId = async (value: string) => {\r\n this.countryRegionId = value;\r\n\r\n await this.addressCommon.getStateProvinces(this.countryRegionId).then((result: StateProvinceInfo[]) => {\r\n const stateInfo = result.some(state => state.StateId === this.addUpdateAddress.State);\r\n\r\n // Reset state if selected state not found in the list.\r\n if (!stateInfo) {\r\n this._updateAddress('State', '');\r\n }\r\n\r\n this.stateProvinceInfo = result;\r\n });\r\n\r\n this._updateAddress('ThreeLetterISORegionName', this.countryRegionId);\r\n };\r\n}\r\n\r\nexport default BusinessAccountAddress;\r\n","/*!\r\n * Copyright (c) Microsoft Corporation.\r\n * All rights reserved. See LICENSE in the project root for license information.\r\n */\r\n\r\n/* eslint-disable no-duplicate-imports */\r\nimport { Module, Node } from '@msdyn365-commerce-modules/utilities';\r\nimport * as React from 'react';\r\n\r\nimport { IAddressAddItem, IAddressAddUpdateProps } from '../../common/components/address-add';\r\nimport { IBusinessAccountAddressViewProps } from './krannich-c-business-account-address';\r\n\r\n/**\r\n * Address Add Update Component.\r\n * @param param0 - Root param.\r\n * @param param0.AddressForm - Address form.\r\n * @param param0.heading - Address Heading.\r\n * @param param0.items - IAddressAddItem[].\r\n * @param param0.hasError - Boolean.\r\n * @param param0.error - IAddressError.\r\n * @param param0.isShowSaveButton - Boolean.\r\n * @param param0.saveButton - Save button.\r\n * @param param0.isShowCancelButton - Boolean.\r\n * @param param0.cancelButton - Cancel button.\r\n * @returns - AddressForm Node.\r\n */\r\nconst AddressAddUpdate: React.FC = ({\r\n AddressForm,\r\n heading,\r\n items,\r\n hasError,\r\n error,\r\n isShowSaveButton,\r\n saveButton,\r\n isShowCancelButton,\r\n cancelButton,\r\n usSiteFlag,\r\n mexicoSiteFlag\r\n}) => {\r\n return (\r\n \r\n {heading}\r\n {items.map((item: IAddressAddItem) => {\r\n const { AddressItem, key, label, alert, input, customAlert, customLabel } = item;\r\n if (key === 'County' || key === 'BuildingCompliment' || key === 'DistrictName' || key === 'StreetNumber') {\r\n return null;\r\n }\r\n return (\r\n \r\n {customLabel !== null && (usSiteFlag || mexicoSiteFlag) ? customLabel : label}\r\n {hasError && alert}\r\n {customAlert !== null ? customAlert : null}\r\n {input}\r\n \r\n );\r\n })}\r\n {hasError && (\r\n \r\n {error.title}\r\n {error.message}\r\n \r\n )}\r\n {isShowSaveButton && saveButton}\r\n {isShowCancelButton && cancelButton}\r\n \r\n );\r\n};\r\n\r\n/**\r\n * Business Account Address View Component.\r\n * @param props - Props.\r\n * @returns - BusinessAccountAddress Module.\r\n */\r\nconst BusinessAccountAddressView: React.FC = props => {\r\n const { BusinessAccountAddress, showAddOrUpdateAddress, usSiteFlag, mexicoSiteFlag } = props;\r\n\r\n return (\r\n \r\n \r\n \r\n );\r\n};\r\n\r\nexport default BusinessAccountAddressView;\r\n","/*--------------------------------------------------------------\r\n * Copyright (c) Microsoft Corporation. All rights reserved.\r\n * See License.txt in the project root for license information.\r\n *--------------------------------------------------------------*/\r\n\r\nimport {\r\n IBuyboxAddToCartViewProps,\r\n IBuyboxAddToOrderTemplateViewProps,\r\n // IBuyboxAddToWishlistViewProps,\r\n IBuyboxCallbacks,\r\n IBuyboxData,\r\n IBuyboxFindInStoreViewProps,\r\n IBuyboxKeyInPriceViewProps,\r\n IBuyboxProductConfigureDropdownViewProps,\r\n IBuyboxProductConfigureViewProps,\r\n IBuyboxProductQuantityViewProps,\r\n IBuyboxProps,\r\n IBuyboxShopSimilarLookViewProps,\r\n IBuyboxState,\r\n IBuyboxViewProps,\r\n IBuyboxCommonData,\r\n IBuyboxExtentedProps\r\n} from '@msdyn365-commerce-modules/buybox';\r\nimport {\r\n IncrementalQuantity,\r\n ITelemetryContent,\r\n Module,\r\n Node,\r\n // Button,\r\n // INodeProps,\r\n Modal,\r\n ModalBody,\r\n // ModalFooter,\r\n ModalHeader,\r\n Waiting\r\n} from '@msdyn365-commerce-modules/utilities';\r\nimport { RichTextComponent } from '@msdyn365-commerce/core';\r\nimport * as React from 'react';\r\nimport { AttributeValue, ProductAvailableQuantity } from '@msdyn365-commerce/retail-proxy';\r\nimport {\r\n IBuyboxProps as IBuyboxExtentionProps,\r\n IBuyboxResources as IBuyboxExtentionResources\r\n} from '../definition-extensions/buybox.ext.props.autogenerated';\r\nimport { getAttributeValuesAsync } from '@msdyn365-commerce/retail-proxy/dist/DataActions/ProductsDataActions.g';\r\nimport { generateImageUrl } from '@msdyn365-commerce-modules/retail-actions';\r\nimport { trafficLightsAtpaction, TrafficLightsAtpInput } from '../../../actions/traffic-lights-atp.action';\r\nimport { ATPMessage, TrafficLights } from '../../../utils/atp-utils';\r\nimport EstimatedShipDateComponent from '../../../utils/ATP/atpESD';\r\nimport { KitProduct } from '../../../utils/Kits/kits';\r\nimport { kRV_GetMultipleATPLeadTimeDateAsync } from '../../../actions/customProxy/ATP-update/DataActionExtension.g';\r\nimport {\r\n IKRV_ATPLeadTimePropertiesDate,\r\n IKRV_GetMultipleATPLeadTimeResponseDate\r\n} from '../../../actions/customProxy/ATP-update/DataServiceEntities.g';\r\nimport EstimatedShipDateKitComponent from '../../../utils/ATP/atpKitESD';\r\nimport { PriceComponent } from './components/price.component';\r\nimport { filteredProductAttributeList, incExcPriceFormat, isRequestPrice, taxPercentage } from '../../../utils/helper';\r\nimport { PromotionBadges } from '../../../utils/badges';\r\nconst BuyboxView: React.FC & ProductAvailableQuantity> = props => {\r\n const {\r\n ModuleProps,\r\n MediaGalleryContainerProps,\r\n ProductInfoContainerProps,\r\n addToCart,\r\n addToOrderTemplate,\r\n // addToWishlist,\r\n telemetryContent,\r\n configure,\r\n description,\r\n findInStore,\r\n quantity,\r\n // price,\r\n title,\r\n rating,\r\n callbacks,\r\n state,\r\n resources,\r\n inventoryLabel,\r\n shopSimilarLook,\r\n keyInPrice,\r\n quantityLimitsMessages,\r\n max,\r\n shopSimilarDescription,\r\n unitOfMeasure,\r\n productComparisonButton\r\n } = props;\r\n\r\n const Auth = props.context.request.user.isAuthenticated;\r\n const { minErrorMessage, maxErrorMessage, promotionalTextEnable, promotionalTextColor } = props.config;\r\n const { zeroPriceProductText } = props.resources;\r\n const {\r\n context: {\r\n actionContext,\r\n request: {\r\n apiSettings: { channelId, catalogId }\r\n }\r\n }\r\n } = props;\r\n\r\n const linkedProducts: any[] | undefined = props.data.product.result?.Components;\r\n const [producerName, setProducerName] = React.useState('');\r\n const [producerKeyName, setProducerKeyName] = React.useState('');\r\n const [manufacturerItemNumber, setManufacturerItemNumber] = React.useState('');\r\n const [itemNumber, setItemNumber] = React.useState('');\r\n const [isMax, setIsMax] = React.useState(false);\r\n const [isMin, setIsMin] = React.useState(true);\r\n const [isMaxPop, setIsMaxPop] = React.useState(false);\r\n const [showMore, setShowMore] = React.useState(false);\r\n const [isClassName, setIsClassName] = React.useState(true);\r\n const [attributes, setAttributes] = React.useState();\r\n const [disountedWpPrice, setDiscountedwpPrice] = React.useState('');\r\n const [productName, setProductName] = React.useState('');\r\n const [promotionalText, setPromotionalText] = React.useState('');\r\n const [importantNotice, setimportantNotice] = React.useState('');\r\n const [longDescription, setlongDescription] = React.useState('');\r\n const [disableAddToCartATP, setDisableAddToCartATP] = React.useState(false);\r\n\r\n const extensionsProps = props.data.product.result?.ExtensionProperties;\r\n let promotionBadge = '';\r\n if (extensionsProps?.find(e => e?.Key === 'PromotionBadge')) {\r\n promotionBadge = extensionsProps?.find(e => e?.Key === 'PromotionBadge')?.Value?.StringValue || '';\r\n }\r\n // ************ VSI Customization Starts for Bundle kit ATP ****************//\r\n const [atpData, setAtpData] = React.useState>([]);\r\n const [kitProductATP, setKitProductATP] = React.useState(false);\r\n const [isKitProductATPDiscontinued, setIsKitProductATPDiscontinued] = React.useState(false);\r\n const productAttributes = filteredProductAttributeList(attributes, props.context.app.config.kcProductAttribute);\r\n const findProducerName = () => {\r\n productAttributes?.map(e => {\r\n if (e.identifier === 'Manufacturer') {\r\n setProducerName(e?.TextValue);\r\n }\r\n });\r\n };\r\n const findProducerKeyName = () => {\r\n productAttributes?.map(e => {\r\n if (e.identifier === 'Manufacturer') {\r\n setProducerKeyName(e?.Name);\r\n }\r\n });\r\n };\r\n const globalProducerName = () => {\r\n let globalProducerName: string = '';\r\n productAttributes?.map(e => {\r\n if (e.identifier === 'Manufacturer') {\r\n const manufactuerValueforImage = e.ExtensionProperties?.find(eProperty => eProperty.Key === 'globalAttributeValue')?.Value;\r\n globalProducerName = manufactuerValueforImage?.StringValue || '';\r\n }\r\n });\r\n return globalProducerName;\r\n };\r\n\r\n const _atpData = async (products: any[] | undefined) => {\r\n const KRVATPLeadTimeDate: any[] = [];\r\n //Create date according to API\r\n const objectDate = new Date();\r\n const day = objectDate.getDate();\r\n const month = objectDate.getMonth();\r\n const year = objectDate.getFullYear();\r\n const requestedDate = `${day}/${month + 1}/${year}`;\r\n\r\n if (products && products.length > 0) {\r\n products?.map((e: any) => {\r\n KRVATPLeadTimeDate.push({\r\n itemID: e.ItemId,\r\n requestedDate: requestedDate\r\n });\r\n });\r\n }\r\n const ctx = { callerContext: props.context.actionContext };\r\n try {\r\n const response = await kRV_GetMultipleATPLeadTimeDateAsync(ctx, KRVATPLeadTimeDate);\r\n setAtpData([response] || []);\r\n setKitProductATP(true);\r\n } catch (err) {\r\n console.error(err, 'ERR');\r\n }\r\n };\r\n function kitProductATPCall() {\r\n if (linkedProducts?.length !== 0) {\r\n _atpData(linkedProducts);\r\n }\r\n }\r\n React.useEffect(() => {\r\n if (linkedProducts?.length !== 0 && Auth) {\r\n if (!kitProductATP) {\r\n kitProductATPCall();\r\n }\r\n const anyRed = atpData[0]?.ATPTrafficLights?.filter(item => item.TrafficLight === 'Red');\r\n if (anyRed?.length) {\r\n setIsKitProductATPDiscontinued(true);\r\n }\r\n }\r\n }, [linkedProducts, atpData]);\r\n // ************ VSI Customization Ends for Bundle kit ATP ****************//\r\n // ************ VSI Customization Start ATP ****************//\r\n\r\n const [isLoading, setIsLoading] = React.useState(true);\r\n const [trafficLightsResponse, settrafficLightsResponse] = React.useState();\r\n const [propMax, setPropMax] = React.useState(max!);\r\n\r\n const [maxESD, setMaxESD] = React.useState(max!);\r\n\r\n //Create date according to API\r\n let objectDate = new Date();\r\n let day = objectDate.getDate();\r\n let month = objectDate.getMonth();\r\n let year = objectDate.getFullYear();\r\n let requestedDate = `${month + 1}/${day}/${year}`;\r\n\r\n //Call Traffic Light Data Action\r\n async function trafficLightsDataActionCall() {\r\n setIsLoading(true);\r\n const requestBody: any = {\r\n itemId: itemNumber!,\r\n requestedDate: requestedDate\r\n };\r\n try {\r\n const trafficLightsParams = new TrafficLightsAtpInput(requestBody.itemId, requestBody.requestedDate);\r\n const trafficLightsSlots = await trafficLightsAtpaction(trafficLightsParams, props.context.actionContext);\r\n settrafficLightsResponse(trafficLightsSlots);\r\n } catch (error) {\r\n props.telemetry.warning('error');\r\n props.telemetry.debug('Unable to get response for traffic lights slots');\r\n }\r\n setIsLoading(false);\r\n }\r\n\r\n //VSI Customization Start React.useEffect & Function of ATP calculation\r\n React.useEffect(() => {\r\n if (max) {\r\n setPropMax(max);\r\n }\r\n }, [max]);\r\n\r\n //Use this Effect for set max values of product in state according to status\r\n React.useEffect(() => {\r\n if (trafficLightsResponse) {\r\n if (trafficLightsResponse.StatusCode === '500') {\r\n setPropMax(trafficLightsResponse?.Quantity);\r\n setMaxESD(trafficLightsResponse?.Quantity);\r\n } else if (trafficLightsResponse.StatusCode === '501') {\r\n if (trafficLightsResponse.POQuantity > props.state.max!) {\r\n setPropMax(props.state.max!);\r\n setMaxESD(trafficLightsResponse.POQuantity!);\r\n } else {\r\n setPropMax(trafficLightsResponse.POQuantity!);\r\n setMaxESD(trafficLightsResponse.POQuantity!);\r\n }\r\n } else if (trafficLightsResponse.StatusCode === '502') {\r\n setPropMax(trafficLightsResponse?.Quantity);\r\n setMaxESD(trafficLightsResponse?.Quantity);\r\n } else if (trafficLightsResponse.StatusCode === '503') {\r\n if (trafficLightsResponse?.Quantity + trafficLightsResponse.POQuantity > props.state.max!) {\r\n setPropMax(props.state.max!);\r\n setMaxESD(trafficLightsResponse?.Quantity + trafficLightsResponse.POQuantity);\r\n } else {\r\n setPropMax(trafficLightsResponse?.Quantity + trafficLightsResponse.POQuantity);\r\n setMaxESD(trafficLightsResponse?.Quantity + trafficLightsResponse.POQuantity);\r\n }\r\n } else if (\r\n trafficLightsResponse.StatusCode === '204' &&\r\n trafficLightsResponse?.Message?.toLocaleLowerCase() === props.resources.noFurtherSuppliesText\r\n ) {\r\n //checking if already same product exist in cart\r\n let productOfInterestQuantity: number | undefined;\r\n props.data.cart.result?.cart.CartLines?.map(item => {\r\n if (item.ItemId === itemNumber) {\r\n productOfInterestQuantity = item.Quantity;\r\n }\r\n return undefined;\r\n });\r\n setPropMax(\r\n productOfInterestQuantity !== undefined\r\n ? trafficLightsResponse?.Quantity - productOfInterestQuantity!\r\n : trafficLightsResponse?.Quantity\r\n );\r\n setMaxESD(trafficLightsResponse?.Quantity);\r\n } else {\r\n setPropMax(props.state.max!);\r\n }\r\n }\r\n }, [trafficLightsResponse]);\r\n React.useEffect(() => {\r\n if (props.data.cart.result?.cart.CartLines && trafficLightsResponse?.StatusCode === '204') {\r\n //checking if already same product exist in cart\r\n let productOfInterestQuantity: number | undefined;\r\n props.data.cart.result?.cart.CartLines?.map(item => {\r\n if (item.ItemId === itemNumber) {\r\n productOfInterestQuantity = item.Quantity;\r\n }\r\n return undefined;\r\n });\r\n //condition to disable add to cart\r\n if (productOfInterestQuantity && productOfInterestQuantity >= trafficLightsResponse?.Quantity!) {\r\n setDisableAddToCartATP(true);\r\n }\r\n }\r\n }, [props.data.cart.result?.cart.CartLines, trafficLightsResponse, props.state]);\r\n\r\n React.useEffect(() => {\r\n if (requestedDate && itemNumber) trafficLightsDataActionCall();\r\n }, [requestedDate, itemNumber]);\r\n\r\n // ************ VSI Customization END ATP ****************//\r\n\r\n async function findAttributesValues() {\r\n const recordId: any = props.data.product.result?.RecordId;\r\n\r\n const attributes: AttributeValue[] = await getAttributeValuesAsync(\r\n { callerContext: actionContext, queryResultSettings: {} },\r\n recordId,\r\n channelId,\r\n catalogId\r\n );\r\n setAttributes(attributes);\r\n }\r\n\r\n React.useEffect(() => {\r\n findAttributesValues();\r\n setPromotionalTextFunction();\r\n }, []);\r\n\r\n React.useEffect(() => {\r\n state.quantity <= props.data.product.result?.Behavior?.MinimumQuantity! && state.quantity !== 1 ? setIsMin(true) : setIsMin(false);\r\n state.quantity < props.data.product.result?.Behavior?.MinimumQuantity! ? setIsClassName(true) : setIsClassName(false);\r\n state.quantity === propMax ? setIsMax(true) : setIsMax(false);\r\n }, [state.quantity]);\r\n\r\n React.useEffect(() => {\r\n if (isMaxPop !== true) {\r\n state.quantity === propMax ? setIsMaxPop(true) : setIsMaxPop(false);\r\n }\r\n }, [state.quantity]);\r\n\r\n React.useEffect(() => {\r\n if (attributes) {\r\n findProducerName();\r\n findProducerKeyName();\r\n findItemNumber();\r\n calculateWpPrice();\r\n findProductName();\r\n findManufacturerItemNumber();\r\n findImportantNotice();\r\n findlongDescription();\r\n }\r\n }, [attributes]);\r\n\r\n const findManufacturerItemNumber = () => {\r\n attributes?.map(e => {\r\n if (e.Name === 'Manufacturer item number') {\r\n setManufacturerItemNumber(e?.TextValue);\r\n }\r\n });\r\n };\r\n const findProductName = () => {\r\n const product = props.data.product?.result?.Name;\r\n setProductName(product);\r\n };\r\n const findItemNumber = () => {\r\n let itemId = props.data.product.result?.ItemId;\r\n\r\n setItemNumber(itemId);\r\n };\r\n const setPromotionalTextFunction = () => {\r\n if (props.data.product.result?.ExtensionProperties) {\r\n props.data.product.result?.ExtensionProperties?.map(e => {\r\n if (e.Key?.toLowerCase() === 'promotion') {\r\n setPromotionalText(e?.Value?.StringValue!);\r\n }\r\n });\r\n }\r\n };\r\n\r\n const findImportantNotice = () => {\r\n let importantNotice = props.data.product.result?.ExtensionProperties;\r\n importantNotice?.map(e => {\r\n if (e.Key === 'ImportantNotice') {\r\n setimportantNotice(e.Value?.StringValue);\r\n }\r\n });\r\n };\r\n const findlongDescription = () => {\r\n let longDescription = props.data.product.result?.ExtensionProperties;\r\n longDescription?.map(e => {\r\n if (e.Key === 'LongDescription') {\r\n setlongDescription(e.Value?.StringValue);\r\n }\r\n });\r\n };\r\n const calculateWpPrice = () => {\r\n let basePrice = props.data.productPrice.result?.CustomerContextualPrice;\r\n let discountedPrice = props.data.productPrice.result?.CustomerContextualPrice;\r\n let tempBasePrice, tempDiscountedPrice, displayWpPrice;\r\n\r\n if (basePrice === discountedPrice) {\r\n attributes?.map(e => {\r\n if (e.Name === 'Power rating Pmax (Wp)') {\r\n if (e.IntegerValue !== 0) {\r\n tempBasePrice = basePrice! / e.IntegerValue!;\r\n }\r\n }\r\n if (e.KeyName === 'DisplayWPPrice' || e.Name === 'Display WP Price') {\r\n displayWpPrice = e.BooleanValue;\r\n }\r\n });\r\n\r\n if (displayWpPrice && tempBasePrice !== undefined) {\r\n setDiscountedwpPrice(tempBasePrice);\r\n }\r\n } else {\r\n attributes?.map(e => {\r\n if (e.Name === 'Power rating Pmax (Wp)') {\r\n if (e.IntegerValue !== 0) {\r\n tempBasePrice = basePrice! / e.IntegerValue!;\r\n tempDiscountedPrice = discountedPrice! / e.IntegerValue!;\r\n }\r\n }\r\n if (e.KeyName === 'DisplayWPPrice' || e.Name === 'Display WP Price') {\r\n displayWpPrice = e.BooleanValue;\r\n }\r\n });\r\n\r\n if (displayWpPrice && tempBasePrice !== undefined && tempDiscountedPrice !== undefined) {\r\n setDiscountedwpPrice(tempDiscountedPrice);\r\n }\r\n }\r\n };\r\n\r\n const _renderQuantity = (\r\n quantityComponent: IBuyboxProductQuantityViewProps,\r\n callbacks: IBuyboxCallbacks,\r\n props: IBuyboxProps,\r\n state: IBuyboxState,\r\n extentionResources: IBuyboxExtentionResources,\r\n quantityLimitsMessages: React.ReactNode,\r\n propMax: number | undefined,\r\n telemetryContent?: ITelemetryContent,\r\n max?: number\r\n ): JSX.Element => {\r\n const { ContainerProps, LabelContainerProps, heading, errors } = quantityComponent;\r\n const { quantity, min } = state;\r\n return (\r\n \r\n \r\n {heading}\r\n {errors}\r\n \r\n\r\n {min && (\r\n \r\n )}\r\n
\r\n {min && isMin && (\r\n

\r\n {resources.informationHeading}\r\n \r\n {`${minErrorMessage} ${min}`}\r\n

\r\n )}\r\n {(isMax || disableAddToCartATP) && !isMin && (\r\n

\r\n {resources.informationHeading}\r\n \r\n {disableAddToCartATP\r\n ? resources.maxQuantityAlertMessage.replace('{Quantity}', String(trafficLightsResponse?.Quantity) || '')\r\n : `${maxErrorMessage} ${propMax}`}\r\n

\r\n )}\r\n {/* {_generateStockErrorMessage()} */}\r\n
\r\n
\r\n );\r\n };\r\n\r\n const getText = (text: any, showMoreText: string) => {\r\n // For Text that is shorter than desired length\r\n if (text?.props?.children?.length <= 100) return text.props.children;\r\n\r\n if (text?.props?.children?.length > 100) {\r\n return (\r\n <>\r\n

\r\n {`${text?.props?.children?.slice(0, 120)}...... `}\r\n \r\n

\r\n \r\n );\r\n }\r\n };\r\n\r\n const [imgURI, setImgURL] = React.useState();\r\n\r\n //To set the producer name\r\n React.useEffect(() => {\r\n const producerGlobalName: string = globalProducerName() || '';\r\n if (producerGlobalName) {\r\n setImgURL(producerGlobalName);\r\n }\r\n }, [producerName]);\r\n\r\n //to generate Image url after getting img url from api call\r\n React.useEffect(() => {\r\n if (imgURI) {\r\n let imageUrl = generateImageUrl(imgURI, props.context.actionContext.requestContext.apiSettings);\r\n imageUrl = imageUrl?.replace('=/', '=') || '';\r\n setImgURL(imageUrl);\r\n }\r\n }, [imgURI]);\r\n\r\n //use this function to render or display category image\r\n const _renderCategoryImg = (imgURI: string) => {\r\n return producer-images;\r\n };\r\n\r\n //use this function to render item number\r\n const _renderItemNumber = () => {\r\n return (\r\n
\r\n {props.resources.itemNumberText}:\r\n {itemNumber}\r\n
\r\n );\r\n };\r\n //use this function to render Manufacturer item number\r\n const _renderManufacturerItemNumber = () => {\r\n return (\r\n
\r\n {props.resources.manufacturerItemNumberText}:\r\n {manufacturerItemNumber}\r\n
\r\n );\r\n };\r\n //use this function to render Promotional Text\r\n const _renderPromotionalText = () => {\r\n return (\r\n \r\n
\r\n \r\n
\r\n
\r\n );\r\n };\r\n\r\n const _renderlongDescriptionAndImportantNotice = () => {\r\n return (\r\n \r\n

{resources.productInfoHeading}

\r\n
\r\n {importantNotice && (\r\n
\r\n \r\n
\r\n )}\r\n {longDescription && (\r\n
\r\n \r\n
\r\n )}\r\n
\r\n
\r\n );\r\n };\r\n\r\n React.useEffect(() => {\r\n _renderPrice();\r\n }, [disountedWpPrice]);\r\n\r\n //use this function to render price\r\n const _renderPrice = () => {\r\n const { productPrice, customerInformation } = props.data;\r\n const customClass = linkedProducts?.length !== 0 ? '-bundle' : null;\r\n const {\r\n context: {\r\n app: {\r\n config: { enabledIncExPrices }\r\n }\r\n }\r\n } = props;\r\n const ppwPrice =\r\n props?.context?.actionContext?.requestContext?.apiSettings?.oun !== props.context.app.config.ounNumberForUsSite\r\n ? 'WP Price:'\r\n : 'PPW Price:';\r\n const customerTaxPercentage = taxPercentage(props.data.customerInformation?.result!);\r\n return (\r\n
\r\n {Auth &&\r\n isRequestPrice(productPrice?.result!, customerInformation?.result?.LineDiscountGroup!, linkedProducts?.length !== 0) ? (\r\n
\r\n {props.resources.requestPriceText}\r\n
\r\n \r\n {zeroPriceProductText}\r\n
\r\n
\r\n ) : (\r\n <>\r\n {/* {Auth && price} */}\r\n {Auth && getBuyboxProductPrice(props, props.state)}\r\n {Auth && linkedProducts?.length !== 0 ?

{'For Bundle'}

: null}\r\n {/* VSI Customization WP Base price show once we have no discount on product & Wp base price\r\n and Wp Discount price only shoes when we have discount on our product */}\r\n {Auth && disountedWpPrice && linkedProducts?.length === 0 && (\r\n
\r\n {ppwPrice}\r\n
\r\n \r\n {incExcPriceFormat(\r\n Number(disountedWpPrice),\r\n props.context,\r\n enabledIncExPrices,\r\n customerTaxPercentage,\r\n 3\r\n )}\r\n \r\n
\r\n
\r\n )}\r\n \r\n )}\r\n
\r\n );\r\n };\r\n\r\n const _renderAddToCart = (addToCart: IBuyboxAddToCartViewProps, propMax: number): JSX.Element => {\r\n const { errorBlock, button } = addToCart;\r\n let customAddBundleToCartButton;\r\n\r\n if (linkedProducts?.length !== 0) {\r\n customAddBundleToCartButton =\r\n button &&\r\n React.cloneElement(button as JSX.Element, {\r\n title: 'Add Bundle to Cart',\r\n children: 'Add Bundle to Cart',\r\n addToCartText: 'Add Bundle to Cart',\r\n className: 'add-bundle_cta'\r\n });\r\n }\r\n const customAddToCartButton =\r\n button &&\r\n React.cloneElement(button as JSX.Element, {\r\n isStatusTwoZeroFour: trafficLightsResponse?.StatusCode === '204' ? true : false\r\n });\r\n return (\r\n
\r\n {errorBlock}\r\n
\r\n {linkedProducts?.length !== 0\r\n ? Auth && (\r\n \r\n )\r\n : isClassName ||\r\n propMax === 0 ||\r\n isRequestPrice(\r\n props.data?.productPrice?.result!,\r\n props.data.customerInformation.result?.LineDiscountGroup!,\r\n linkedProducts?.length !== 0\r\n ) ||\r\n trafficLightsResponse?.TrafficLight === 'Red' ||\r\n trafficLightsResponse?.IsAddToCart === 'No' ||\r\n trafficLightsResponse?.IsDiscontinuedProduct === 'Yes' ||\r\n disableAddToCartATP ||\r\n isLoading\r\n ? Auth && (\r\n \r\n )\r\n : Auth && linkedProducts?.length !== 0\r\n ? isKitProductATPDiscontinued\r\n ? Auth && (\r\n \r\n )\r\n : customAddBundleToCartButton\r\n : Auth && customAddToCartButton}\r\n {Auth &&\r\n addToOrderTemplate &&\r\n !isRequestPrice(\r\n props.data?.productPrice?.result!,\r\n props.data.customerInformation.result?.LineDiscountGroup!,\r\n linkedProducts?.length !== 0\r\n ) &&\r\n !isKitProductATPDiscontinued &&\r\n trafficLightsResponse?.TrafficLight !== 'Red' &&\r\n trafficLightsResponse?.IsAddToCart !== 'No' &&\r\n !disableAddToCartATP &&\r\n _renderAddToOrderTemplate(addToOrderTemplate)}\r\n
\r\n
\r\n );\r\n };\r\n\r\n // ***** VSI CUSTOMIZATION START AVAILABLE use this useState and useEffect for disable request price link untill all data available *****//\r\n const [isDisableLink, setIsDisableLink] = React.useState(true);\r\n\r\n React.useEffect(() => {\r\n if (producerName && productName && itemNumber) {\r\n setIsDisableLink(false);\r\n }\r\n }, [producerName, productName, itemNumber]);\r\n\r\n // ***** VSI CUSTOMIZATION END *****//\r\n return (\r\n <>\r\n {isMaxPop && (\r\n {\r\n setIsMaxPop(false);\r\n }}\r\n >\r\n
\r\n {\r\n setIsMaxPop(!setIsMaxPop);\r\n }}\r\n >\r\n {props.resources.alertText}\r\n \r\n \r\n {props.resources.maxPurchaseAlertMessage\r\n .replace('{productName}', producerName || '')\r\n .replace('{propMax}', String(propMax) || '')}\r\n {/* {state.quantity && state.quantity === propMax && state.quantity >= propMax!\r\n ? _generateStockErrorMessage()\r\n : ` 'Maximum purchase quantity of the artice ${productName} is limited to ${propMax} piece per order.`} */}\r\n \r\n
\r\n \r\n )}\r\n {showMore && (\r\n {\r\n setShowMore(!showMore);\r\n }}\r\n >\r\n
\r\n {\r\n setShowMore(!showMore);\r\n }}\r\n >\r\n {props.resources.descriptionText}\r\n \r\n {description}\r\n
\r\n \r\n )}\r\n \r\n \r\n {props.mediaGallery}\r\n \r\n
{imgURI && _renderCategoryImg(imgURI)}
\r\n {title}\r\n
{getText(description, props.resources.showMoreText)}
\r\n
\r\n {itemNumber && _renderItemNumber()}\r\n {manufacturerItemNumber && _renderManufacturerItemNumber()}\r\n
\r\n {promotionalText && promotionalTextEnable && _renderPromotionalText()}\r\n {/* *********** VSI CUSTOMIZATION STARTS FOR Kit Bundles ************ */}\r\n {linkedProducts?.length !== 0 && Auth ? (\r\n \r\n ) : (\r\n <>\r\n {unitOfMeasure}\r\n {props.bulkPurchaseLink}\r\n {_renderTextBlock(props.slots.textBlocks)}\r\n {/* {description} */}\r\n {rating}\r\n {configure && _renderConfigure(configure)}\r\n {Auth ? keyInPrice && _renderKeyInPrice(keyInPrice) : false}\r\n \r\n )}\r\n {/* *********** VSI CUSTOMIZATION START FOR ATP ************ */}\r\n
\r\n {Auth ? (\r\n isLoading ? (\r\n \r\n ) : (\r\n
\r\n {trafficLightsResponse && (\r\n <>\r\n
\r\n \r\n {linkedProducts?.length !== 0 ? (\r\n
\r\n

{props.resources.callOfficeText}

\r\n
\r\n ) : isKitProductATPDiscontinued ? (\r\n
\r\n

\r\n {props.resources.noFurtherSuppliesText}{' '}\r\n

\r\n
\r\n ) : (\r\n \r\n )}\r\n
\r\n \r\n )}\r\n {linkedProducts?.length !== 0 ? (\r\n \r\n ) : isKitProductATPDiscontinued ? null : (\r\n \r\n )}\r\n
\r\n )\r\n ) : (\r\n false\r\n )}\r\n
\r\n {/* *********** VSI CUSTOMIZATION End FOR ATP ************ */}\r\n {/* *********** VSI CUSTOMIZATION END FOR Kit Bundles ************ */}\r\n {inventoryLabel}\r\n
\r\n
\r\n {Auth ? (\r\n linkedProducts?.length !== 0 ? (\r\n
\r\n
{props.resources.quantityText}
\r\n
\r\n ) : (\r\n quantity &&\r\n _renderQuantity(\r\n quantity,\r\n callbacks,\r\n props,\r\n state,\r\n resources,\r\n quantityLimitsMessages,\r\n propMax,\r\n telemetryContent,\r\n max\r\n )\r\n )\r\n ) : (\r\n false\r\n )}\r\n {_renderPrice()}\r\n
\r\n {addToCart && _renderAddToCart(addToCart, propMax)}\r\n {/* {Auth ? _renderCartAndActions(addToCart, addToOrderTemplate, addToWishlist) : false} */}\r\n {!Auth ? (\r\n
\r\n {props.config.requestPriceButton && props.config.requestPriceButton.linkText && }\r\n \r\n {props.config.requestPriceButton?.linkText}\r\n \r\n
\r\n ) : (\r\n false\r\n )}\r\n
\r\n {findInStore && _renderFindInStore(findInStore)}\r\n {_renderSocialShare(props.slots && props.slots.socialShare)}\r\n {productComparisonButton}\r\n {shopSimilarLook && _renderShopSimilarItem(shopSimilarLook)}\r\n {shopSimilarDescription && _renderShopSimilarItem(shopSimilarDescription)}\r\n
\r\n
\r\n {(longDescription || importantNotice) && _renderlongDescriptionAndImportantNotice()}\r\n \r\n );\r\n};\r\n\r\nconst _renderTextBlock = (textBlocks: React.ReactNode[]): JSX.Element | undefined => {\r\n if (!textBlocks || textBlocks.length === 0) {\r\n return undefined;\r\n }\r\n\r\n return <>{textBlocks[0]};\r\n};\r\n\r\nconst _renderAddToOrderTemplate = (addToOrderTemplate: IBuyboxAddToOrderTemplateViewProps): JSX.Element => {\r\n const { ContainerProps, errorBlock, button } = addToOrderTemplate;\r\n\r\n return (\r\n \r\n {errorBlock}\r\n {button}\r\n \r\n );\r\n};\r\n\r\nconst _renderSocialShare = (socialShare: React.ReactNode[]): JSX.Element | undefined => {\r\n if (!socialShare || socialShare.length === 0) {\r\n return undefined;\r\n }\r\n\r\n return <>{socialShare[0]};\r\n};\r\nconst _renderConfigure = (configure: IBuyboxProductConfigureViewProps): JSX.Element => {\r\n const { ContainerProps, dropdowns } = configure;\r\n\r\n return {dropdowns.map(_renderConfigureDropdown)};\r\n};\r\n\r\nconst _renderConfigureDropdown = (dropdown: IBuyboxProductConfigureDropdownViewProps): JSX.Element => {\r\n const { ContainerProps, LabelContainerProps, heading, errors, select } = dropdown;\r\n\r\n return (\r\n \r\n \r\n {heading}\r\n {errors}\r\n \r\n {select}\r\n \r\n );\r\n};\r\n\r\nconst _renderFindInStore = (findInStore: IBuyboxFindInStoreViewProps): JSX.Element => {\r\n const { ContainerProps, storeSelector, heading, description, errors, button, modal, productPickupOptionList } = findInStore;\r\n\r\n return (\r\n \r\n {storeSelector}\r\n {heading}\r\n {productPickupOptionList}\r\n {description}\r\n {errors}\r\n {button}\r\n {modal}\r\n \r\n );\r\n};\r\n\r\n/**\r\n * On Change function.\r\n * @param callbacks -Callbacks.\r\n * @returns Update quantity.\r\n */\r\nconst onChangeHandler = (callbacks: IBuyboxCallbacks) => (newValue: number): boolean => {\r\n if (callbacks.updateQuantity) {\r\n return callbacks.updateQuantity(newValue);\r\n }\r\n return true;\r\n};\r\nconst _renderKeyInPrice = (keyInPrice: IBuyboxKeyInPriceViewProps): JSX.Element => {\r\n const { ContainerProps, LabelContainerProps, heading, input } = keyInPrice;\r\n\r\n return (\r\n \r\n {heading}\r\n {input}\r\n \r\n );\r\n};\r\n\r\nconst _renderShopSimilarItem = (shopSimilarItem: IBuyboxShopSimilarLookViewProps): JSX.Element => {\r\n const { ContainerProps, errors, input } = shopSimilarItem;\r\n\r\n return (\r\n \r\n {errors}\r\n {input}\r\n \r\n );\r\n};\r\n\r\nconst getBuyboxProductPrice = (props: IBuyboxExtentedProps, state: IBuyboxState): React.ReactElement | undefined => {\r\n const { id, typeName, context, resources } = props;\r\n const customerTaxPercentage = taxPercentage(props.data.customerInformation?.result!);\r\n\r\n return (\r\n state.productPrice && (\r\n featureState.Name === 'Dynamics.AX.Application.RetailSearchPriceRangeFeature'\r\n )?.IsEnabled\r\n }\r\n isSalesAgreementPriceFeatureEnabled={\r\n props.data.featureState.result?.find(\r\n featureState => featureState.Name === 'Dynamics.AX.Application.RetailSalesAgreementPriceSupportFeature'\r\n )?.IsEnabled\r\n }\r\n useLegacySalesAgreementHTMLFeature={\r\n props.data.featureState.result?.find(featureState => featureState.Name === 'UseLegacySalesAgreementHTMLFeature')\r\n ?.IsEnabled\r\n }\r\n priceResources={{\r\n priceRangeSeparator: resources.priceRangeSeparator,\r\n salesAgreementPricePrompt: resources.salesAgreementPricePrompt,\r\n salesAgreementExpirationDatePrompt: resources.salesAgreementExpirationDatePrompt,\r\n salesAgreementCommittedQuantityPrompt: resources.salesAgreementCommittedQuantityPrompt,\r\n salesAgreementRemainingQuantityPrompt: resources.salesAgreementRemainingQuantityPrompt\r\n }}\r\n freePriceText={resources.priceFree}\r\n originalPriceText={resources.originalPriceText}\r\n currentPriceText={resources.currentPriceText}\r\n isIncExPriceFormatEnabled={true}\r\n customerTaxPercentage={customerTaxPercentage}\r\n />\r\n )\r\n );\r\n};\r\nexport default BuyboxView;\r\n","/*!\r\n * Copyright (c) Microsoft Corporation.\r\n * All rights reserved. See LICENSE in the project root for license information.\r\n */\r\n\r\nimport { IComponent, IComponentProps, msdyn365Commerce } from '@msdyn365-commerce/core';\r\nimport { PriceLine, ProductPrice, SalesAgreementPriceLine } from '@msdyn365-commerce/retail-proxy';\r\nimport { Button, Collapse, format, ICollapseProps } from '@msdyn365-commerce-modules/utilities';\r\nimport classnames from 'classnames';\r\nimport * as React from 'react';\r\nimport { incExcPriceFormat } from '../../../../utils/helper';\r\n\r\nconst defaultPrice: number = 0;\r\nconst freePrice: number = 0;\r\n\r\n/**\r\n * Interface for price component resources.\r\n * @param {string} priceRangeSeparator - The price range separator.\r\n */\r\nexport interface IPriceComponentResources {\r\n priceRangeSeparator?: string;\r\n salesAgreementPricePrompt?: string;\r\n salesAgreementExpirationDatePrompt?: string;\r\n salesAgreementCommittedQuantityPrompt?: string;\r\n salesAgreementRemainingQuantityPrompt?: string;\r\n}\r\n\r\n/**\r\n * Interface for price component props.\r\n * @param {boolean} isPriceMinMaxEnabled - Whether the price range feature is enabled or not.\r\n * @param {IPriceComponentResources} priceResources - The price range resources.\r\n */\r\nexport interface IPriceComponentProps extends IComponentProps<{ price: ProductPrice }> {\r\n className?: string;\r\n savingsText?: string;\r\n freePriceText?: string;\r\n originalPriceText?: string;\r\n currentPriceText?: string;\r\n isPriceMinMaxEnabled?: boolean;\r\n isSalesAgreementPriceFeatureEnabled?: boolean;\r\n useLegacySalesAgreementHTMLFeature?: boolean;\r\n salesAgreementLineId?: number;\r\n priceResources?: IPriceComponentResources;\r\n salesAgreementDetailCollapseProps?: ICollapseProps;\r\n salesAgreementDetailOnClick?(event: React.MouseEvent | React.KeyboardEvent): void;\r\n isIncExPriceFormatEnabled?: boolean;\r\n wpPrice?: JSX.Element;\r\n currencyCode?: string;\r\n customerTaxPercentage?: number;\r\n}\r\n\r\n/**\r\n * The interface of price component.\r\n */\r\nexport interface IPriceComponent extends IComponent {}\r\n\r\nconst priceComponentActions = {};\r\n\r\n/**\r\n * Get the original price from price component props.\r\n * @param props - The IPriceComponentProps.\r\n * @returns The original price.\r\n */\r\nconst getOriginalPrice = (props: IPriceComponentProps): number => {\r\n return Math.max(\r\n props.data.price.BasePrice ?? defaultPrice,\r\n props.data.price.TradeAgreementPrice ?? defaultPrice,\r\n props.data.price.AdjustedPrice ?? defaultPrice\r\n );\r\n};\r\n\r\n/**\r\n * Get the formatted currency.\r\n * @param props - The props.\r\n * @param price - The price.\r\n * @param shouldUseFreePriceText - The shouldUseFreePriceText.\r\n * @returns The formatted currency.\r\n */\r\nconst formatCurrency = (\r\n props: IPriceComponentProps,\r\n price: number | undefined,\r\n shouldUseFreePriceText: boolean | undefined,\r\n currencyCode?: string | undefined\r\n): string | JSX.Element => {\r\n if (price === undefined) {\r\n return '';\r\n }\r\n\r\n if (shouldUseFreePriceText && price === freePrice && props.freePriceText) {\r\n return props.freePriceText;\r\n }\r\n const { enabledIncExPrices } = props.context.app.config;\r\n // modify the below return statement of price with currency format\r\n // return props.context.cultureFormatter.formatCurrency(price);\r\n return props.isIncExPriceFormatEnabled\r\n ? incExcPriceFormat(price, props.context, enabledIncExPrices, props.customerTaxPercentage || 0)\r\n : props.context.cultureFormatter.formatCurrency(price, currencyCode);\r\n};\r\n\r\n/**\r\n * ShowStrikethroughPricing.\r\n * @param props - The props.\r\n * @returns True if showStrikethroughPricing, false otherwise.\r\n */\r\nconst showStrikethroughPricing = (props: IPriceComponentProps): boolean => {\r\n const originalPrice = getOriginalPrice(props);\r\n if (\r\n props.isPriceMinMaxEnabled &&\r\n props.data.price.MaxVariantPrice &&\r\n props.data.price.MinVariantPrice &&\r\n props.data.price.MaxVariantPrice > props.data.price.MinVariantPrice\r\n ) {\r\n return props.data.price.MinVariantPrice < originalPrice;\r\n }\r\n\r\n if (originalPrice && props.data.price?.CustomerContextualPrice) {\r\n return originalPrice > props.data.price?.CustomerContextualPrice;\r\n }\r\n\r\n return false;\r\n};\r\n\r\n/**\r\n * Render current price.\r\n * @param props - The props.\r\n * @returns The JSX.Element.\r\n */\r\nconst renderCurrentPrice = (props: IPriceComponentProps): JSX.Element => {\r\n const maxVariantPrice: string | JSX.Element = formatCurrency(props, props.data.price.MaxVariantPrice, false, props.currencyCode);\r\n const minVariantPrice: string | JSX.Element = formatCurrency(props, props.data.price.MinVariantPrice, false, props.currencyCode);\r\n if (\r\n props.isPriceMinMaxEnabled &&\r\n props.data.price.MaxVariantPrice &&\r\n props.data.price.MinVariantPrice &&\r\n props.data.price.MaxVariantPrice > props.data.price.MinVariantPrice\r\n ) {\r\n return (\r\n \r\n \r\n {minVariantPrice}\r\n \r\n \r\n {props.priceResources?.priceRangeSeparator}\r\n \r\n \r\n {maxVariantPrice}\r\n \r\n \r\n );\r\n }\r\n return (\r\n \r\n {formatCurrency(props, props.data.price?.CustomerContextualPrice, true, props.currencyCode)}\r\n {props?.wpPrice && props?.wpPrice}\r\n \r\n );\r\n};\r\n\r\n/**\r\n * Render current price with original price.\r\n * @param props - The props.\r\n * @returns The JSX.Element.\r\n */\r\nconst renderCurrentPriceWithOriginalPrice = (props: IPriceComponentProps): JSX.Element => {\r\n const originalPrice: number = getOriginalPrice(props);\r\n const initialPrice: string | JSX.Element = formatCurrency(props, originalPrice, true);\r\n return (\r\n <>\r\n \r\n {` `}\r\n {props.originalPriceText}\r\n {` `}\r\n {initialPrice}\r\n {` `}\r\n {props.currentPriceText}\r\n {` `}\r\n {renderCurrentPrice(props)}\r\n \r\n {/* */}\r\n \r\n {props.savingsText && {props.savingsText}}\r\n \r\n );\r\n};\r\n\r\n/**\r\n * The state of sales agreement details.\r\n * @deprecated This will be removed with SalesAgreementPrice class soon.\r\n */\r\nexport interface ISalesAgreementDetailState {\r\n isOpen: boolean;\r\n}\r\n\r\n/**\r\n * The SalesAgreementPrice class.\r\n * @deprecated This implementation is deprecated. It will be removed soon. Please use the implementation in the Price function component.\r\n */\r\n// eslint-disable-next-line react/require-optimization -- Not needed.\r\nclass SalesAgreementPrice extends React.Component {\r\n public constructor(props: IPriceComponentProps) {\r\n super(props);\r\n this._toggle = this._toggle.bind(this);\r\n this.state = {\r\n isOpen: true\r\n } as ISalesAgreementDetailState;\r\n }\r\n\r\n public render(): React.ReactElement {\r\n const priceLines: PriceLine[] = this.props.data.price.AttainablePriceLines ?? [];\r\n const firstPriceLine: SalesAgreementPriceLine = priceLines[0] as SalesAgreementPriceLine;\r\n if (this.props.salesAgreementDetailCollapseProps) {\r\n this.props.salesAgreementDetailCollapseProps.isOpen = this.state.isOpen;\r\n }\r\n return (\r\n \r\n

\r\n {formatCurrency(\r\n this.props,\r\n this.props.data.price.SalesAgreementPrice ?? this.props.data.price?.CustomerContextualPrice,\r\n true\r\n )}\r\n

\r\n \r\n {this.props.priceResources?.salesAgreementPricePrompt}\r\n

\r\n \r\n

\r\n \r\n {/* Available date */}\r\n {// eslint-disable-next-line prefer-template -- Copied from other class.\r\n ' · ' +\r\n format(\r\n this.props.priceResources?.salesAgreementExpirationDatePrompt ?? '',\r\n this.props.context.cultureFormatter.formatDate(firstPriceLine.EffectiveDate as Date),\r\n this.props.context.cultureFormatter.formatDate(firstPriceLine.ExpirationDate as Date)\r\n )}\r\n \r\n \r\n {/* Quantity commitment */}\r\n {// eslint-disable-next-line prefer-template -- Copied from other class.\r\n ' · ' +\r\n format(\r\n this.props.priceResources?.salesAgreementCommittedQuantityPrompt ?? '',\r\n firstPriceLine.CommittedQuantity\r\n )}\r\n \r\n \r\n {/* Remaining quantity to qualify */}\r\n {// eslint-disable-next-line prefer-template -- Copied from other class.\r\n ' · ' +\r\n format(\r\n this.props.priceResources?.salesAgreementRemainingQuantityPrompt ?? '',\r\n firstPriceLine.RemainingQuantity\r\n )}\r\n \r\n

\r\n
\r\n
\r\n );\r\n }\r\n\r\n /**\r\n * Callback which toggles collapse mode.\r\n * @param event - The mouse or keyboard event.\r\n */\r\n private _toggle(event: React.MouseEvent | React.KeyboardEvent): void {\r\n event.preventDefault();\r\n // eslint-disable-next-line react/no-access-state-in-setstate -- Copied from other class.\r\n this.setState({ isOpen: !this.state.isOpen });\r\n }\r\n}\r\n\r\nconst renderSalesAgreementDetail = (props: IPriceComponentProps): JSX.Element => {\r\n // In most cases there should be only one sales agreement line.\r\n // If there are more than one, only the first one will be shown.\r\n const firstPriceLine: SalesAgreementPriceLine = (props.data.price.AttainablePriceLines ?? [])[0] as SalesAgreementPriceLine;\r\n return (\r\n

\r\n

\r\n {/* Available date */}\r\n {// eslint-disable-next-line prefer-template -- Copied from other class.\r\n ' · ' +\r\n format(\r\n props.priceResources?.salesAgreementExpirationDatePrompt ?? '',\r\n props.context.cultureFormatter.formatDate(firstPriceLine.EffectiveDate as Date),\r\n props.context.cultureFormatter.formatDate(firstPriceLine.ExpirationDate as Date)\r\n )}\r\n

\r\n

\r\n {/* Quantity commitment */}\r\n {// eslint-disable-next-line prefer-template -- Copied from other class.\r\n ' · ' + format(props.priceResources?.salesAgreementCommittedQuantityPrompt ?? '', firstPriceLine.CommittedQuantity)}\r\n

\r\n

\r\n {/* Remaining quantity to qualify */}\r\n {// eslint-disable-next-line prefer-template -- Copied from other class.\r\n ' · ' + format(props.priceResources?.salesAgreementRemainingQuantityPrompt ?? '', firstPriceLine.RemainingQuantity)}\r\n

\r\n

\r\n );\r\n};\r\n\r\n/**\r\n * Price.\r\n * @param props - The props.\r\n * @returns The JSX.Element.\r\n */\r\nconst Price: React.FC = (props: IPriceComponentProps): JSX.Element | null => {\r\n // CustomerContextualPrice could be zero);\r\n if (props.data.price?.CustomerContextualPrice === undefined) {\r\n return null;\r\n }\r\n\r\n // Determine if contract price is avaiable/applied by:\r\n // isFeatureEnabled and SA price != 0, for PDP.\r\n // SA line id != 0, for cart line.\r\n if (props.isSalesAgreementPriceFeatureEnabled && props.data.price.SalesAgreementPrice !== 0) {\r\n if (props.useLegacySalesAgreementHTMLFeature) {\r\n const salesAgreementPrice = new SalesAgreementPrice(props);\r\n return {salesAgreementPrice.render()};\r\n } else {\r\n const [isExpanded, setIsExpanded] = React.useState(false);\r\n const toggle = () => {\r\n setIsExpanded(!isExpanded);\r\n };\r\n return (\r\n \r\n \r\n

\r\n {formatCurrency(props, props.data.price.SalesAgreementPrice ?? props.data.price.CustomerContextualPrice, true)}\r\n

\r\n \r\n {props.priceResources?.salesAgreementPricePrompt}\r\n \r\n {isExpanded && renderSalesAgreementDetail(props)}\r\n
\r\n
\r\n );\r\n }\r\n }\r\n\r\n return (\r\n \r\n {showStrikethroughPricing(props) ? renderCurrentPriceWithOriginalPrice(props) : renderCurrentPrice(props)}\r\n \r\n );\r\n};\r\n\r\n/**\r\n * The PriceComponent.\r\n */\r\nexport const PriceComponent: React.FunctionComponent = msdyn365Commerce.createComponentOverride(\r\n 'Price',\r\n {\r\n component: Price,\r\n ...priceComponentActions\r\n }\r\n);\r\n\r\nexport default PriceComponent;\r\n","/*!\r\n * Copyright (c) Microsoft Corporation.\r\n * All rights reserved. See LICENSE in the project root for license information.\r\n */\r\n\r\nimport { Module, Node, INodeProps, Modal, ModalBody, ModalHeader } from '@msdyn365-commerce-modules/utilities';\r\nimport * as Msdyn365 from '@msdyn365-commerce/core';\r\nimport * as React from 'react';\r\nimport MsDyn365, { getUrlSync } from '@msdyn365-commerce/core';\r\nimport { IHelp, IOrderSummary, IPaymentMethods } from '@msdyn365-commerce-modules/order-management/src/modules/order-details/../../common';\r\nimport { IGroup } from '@msdyn365-commerce-modules/order-management/src/modules/order-details/../../common/get-groups';\r\nimport { ISalesLine } from '@msdyn365-commerce-modules/order-management/src/modules/order-details/../../common/get-sales-line';\r\nimport { IOrderDetailsViewProps } from '@msdyn365-commerce-modules/order-management/src/modules/order-details/./order-details';\r\nimport { IOrderDetailsProps, IOrderDetailsResources } from '../definition-extensions/order-details.ext.props.autogenerated';\r\nimport { AsyncResult, AttributeValue, Customer } from '@msdyn365-commerce/retail-proxy';\r\nimport { IAny, ICoreContext, IGeneric } from '@msdyn365-commerce/core-internal';\r\nimport { currencyFormat, dateFormatByLocale, filteredProductAttributeList, formatUrlPath, getOrderStatus } from '../../../utils/helper';\r\nimport { IContentBlockConfig } from '../definition-extensions/content-block.ext.props.autogenerated';\r\nimport { GridSize } from '../../../modules/krannich-c-search-result-container/krannich-c-search-result-container';\r\nimport { getActivePricesAsync, getAttributeValuesAsync } from '@msdyn365-commerce/retail-proxy/dist/DataActions/ProductsDataActions.g';\r\nimport ModalFooter from 'reactstrap/lib/ModalFooter';\r\nimport { IOrderDetailsData } from './order-details.data';\r\nimport { ICartState } from '@msdyn365-commerce/global-state';\r\nimport { kRV_GetMultipleATPLeadTimeDateAsync } from '../../../actions/customProxy/ATP-update/DataActionExtension.g';\r\ninterface IGroupsExtended {\r\n groupsProps: INodeProps;\r\n groups: IGroup[];\r\n resources: IOrderDetailsResources;\r\n salesId: React.ReactNode;\r\n createdDate: React.ReactNode;\r\n statusValue?: number;\r\n context?: ICoreContext>;\r\n cart?: AsyncResult | undefined;\r\n customer?: AsyncResult | undefined;\r\n}\r\n\r\ninterface IGroupExtended {\r\n context?: ICoreContext>;\r\n group: IGroup;\r\n resources: IOrderDetailsResources;\r\n salesId: React.ReactNode;\r\n createdDate: React.ReactNode;\r\n statusValue?: number;\r\n cart?: AsyncResult | undefined;\r\n customer?: AsyncResult | undefined;\r\n}\r\n\r\ninterface IGroupDeliveryExtended {\r\n deliveryProps: INodeProps;\r\n pickupProps: INodeProps;\r\n showTimeslot: boolean;\r\n heading: React.ReactNode;\r\n count: React.ReactNode;\r\n processing: React.ReactNode;\r\n trackingInfo: React.ReactNode;\r\n address: React.ReactNode;\r\n shippingItemsToYou?: React.ReactNode;\r\n pickupDateTimeslot?: React.ReactNode;\r\n shippedStatusCheck?: React.ReactNode;\r\n statusValue?: number;\r\n cart?: ICartState | undefined;\r\n}\r\n\r\nexport const OrderDetailsSalesLine: React.FC = ({ salesLineProps, salesLine, buyAgainButton, errors }) => (\r\n \r\n
\r\n
{buyAgainButton}
\r\n
\r\n {errors}\r\n
\r\n);\r\n\r\nexport const OrderDetailsGroupDelivery: React.FC = ({ deliveryProps, heading, count, statusValue }) => (\r\n \r\n \r\n {getOrderStatus(statusValue)}\r\n \r\n {/* {count} */}\r\n \r\n);\r\n\r\nexport const OrderDetailsGroup: React.FC = ({\r\n group,\r\n resources,\r\n salesId,\r\n context,\r\n createdDate,\r\n statusValue,\r\n cart,\r\n customer\r\n}) => {\r\n const { groupProps, delivery, address, salesLinesProps, salesLines } = group;\r\n const productManufacturerIdentifier = 'Manufacturer';\r\n const productWeightAttribute = context?.app?.config?.productWeightAttribute || 'Weight (kg)';\r\n\r\n //Configs For Mobile View\r\n const [isMobile, setIsMobile] = React.useState();\r\n const [buyAgainModal, setBuyAgainModal] = React.useState(false);\r\n const [attributeValues, setAttributeValues] = React.useState([]);\r\n const [prodAttrIdentifier, setProdAttrIdentifier] = React.useState('');\r\n const [atpData, setAtpData] = React.useState([]);\r\n const [messageForBuyAgainPopUp, setMessageForBuyAgainPopUp] = React.useState('');\r\n const _updateViewport = (): void => {\r\n const viewport = _getViewport();\r\n viewport === 'xs' || viewport === 'sm' ? setIsMobile(true) : setIsMobile(false);\r\n };\r\n const _getViewport = (): GridSize => {\r\n // const { context } = productManufacturarAttribute;\r\n\r\n // Always render in mobile viewport on a mobile device\r\n if (context?.request && context.request.device && context.request.device.Type === 'Mobile') {\r\n return 'xs';\r\n }\r\n\r\n if (MsDyn365.isBrowser && window.innerWidth) {\r\n const gridSettings = context?.request.gridSettings;\r\n if (gridSettings) {\r\n if (gridSettings.xs && window.innerWidth <= gridSettings.xs.w) {\r\n return 'xs';\r\n } else if (gridSettings.sm && window.innerWidth <= gridSettings.sm.w) {\r\n return 'sm';\r\n } else if (gridSettings.md && window.innerWidth <= gridSettings.md.w) {\r\n return 'md';\r\n } else if (gridSettings.lg && window.innerWidth <= gridSettings.lg.w) {\r\n return 'lg';\r\n }\r\n return 'xl';\r\n }\r\n }\r\n\r\n return 'lg';\r\n };\r\n React.useEffect(() => {\r\n _updateViewport();\r\n if (MsDyn365.isBrowser && window.addEventListener) {\r\n // eslint-disable-next-line @typescript-eslint/no-floating-promises\r\n window.addEventListener('resize', _updateViewport);\r\n }\r\n }, []);\r\n React.useEffect(() => {\r\n const fetchData = async () => {\r\n let prodAttributeIdentifier = 'Manufacturer';\r\n if (salesLines.length) {\r\n const res: { recId: number; manufacturer: AttributeValue | undefined }[] = [];\r\n for (const salesLine of salesLines) {\r\n const productAttributes = await getAttributeValuesAsync(\r\n { callerContext: context?.actionContext!, queryResultSettings: {} },\r\n salesLine.data.product?.RecordId!,\r\n context?.request?.apiSettings?.channelId!,\r\n context?.request?.apiSettings?.catalogId!\r\n );\r\n const productAttributesFiltered = filteredProductAttributeList(\r\n productAttributes,\r\n context?.request.app.config.kcProductAttribute\r\n );\r\n const manufacturer = productAttributesFiltered?.find(item => item.identifier === productManufacturerIdentifier);\r\n if (manufacturer) {\r\n prodAttributeIdentifier = manufacturer?.Name! || '';\r\n }\r\n res.push({ recId: salesLine.data.product?.RecordId!, manufacturer });\r\n }\r\n setProdAttrIdentifier(prodAttributeIdentifier);\r\n setAttributeValues(res);\r\n }\r\n };\r\n fetchData();\r\n }, [salesLines]);\r\n //Ending configuration//\r\n\r\n const createdDateJSX = createdDate as JSX.Element;\r\n const createdDateJSXProps = createdDateJSX.props as any;\r\n const createdDateJSXPropsChildren = createdDateJSXProps?.children as any;\r\n const customDate = createdDateJSXPropsChildren[2];\r\n // Split the date string\r\n const dateParts = customDate?.split('/');\r\n // Create a Date object using the parts\r\n const formattedDate = new Date(dateParts?.[2], dateParts?.[0] - 1, dateParts?.[1]);\r\n // Format the date as \"DD/MM/YYYY\" using toLocaleDateString()\r\n const formattedDateString = formattedDate.toLocaleDateString('en-GB');\r\n const usSiteFlag = context?.actionContext?.requestContext?.apiSettings?.oun === context?.app.config.ounNumberForUsSite;\r\n const dateLocale = context?.app.config.dateFormat;\r\n const currency = context?.request.channel?.Currency;\r\n const formattedDateStringBylocale =\r\n (dateLocale && currency && formattedDateString && dateFormatByLocale(dateLocale, currency, formattedDateString)) || undefined;\r\n const cartUrl = getUrlSync('cart', context!.actionContext) || '';\r\n React.useEffect(() => {\r\n const KRVATPLeadTimeQuantity: any = [];\r\n const context1 = { callerContext: context?.actionContext! };\r\n //Create date according to API\r\n const objectDate = new Date();\r\n const day = objectDate.getDate();\r\n const month = objectDate.getMonth();\r\n const year = objectDate.getFullYear();\r\n const requestedDate = `${day}/${month + 1}/${year}`;\r\n salesLines?.map(saleline => {\r\n KRVATPLeadTimeQuantity.push({ itemID: saleline.data.salesLine?.ItemId, requestedDate: requestedDate });\r\n });\r\n kRV_GetMultipleATPLeadTimeDateAsync(context1, KRVATPLeadTimeQuantity)\r\n .then((res: any) => {\r\n setAtpData(res.ATPTrafficLights || []);\r\n })\r\n .catch(err => {\r\n console.error(err, 'ERR');\r\n });\r\n }, []);\r\n const _getActivePrices = async (customer: AsyncResult | undefined, recordIds: any[]) => {\r\n return getActivePricesAsync(\r\n { callerContext: context?.actionContext! },\r\n {\r\n ChannelId: context?.request.apiSettings.channelId,\r\n CatalogId: context?.request.apiSettings.catalogId\r\n },\r\n recordIds,\r\n new Date(),\r\n customer?.result?.AccountNumber ?? null,\r\n undefined,\r\n true\r\n );\r\n };\r\n const buyAgainMethod = async () => {\r\n let isProductsAvailable = false;\r\n let isPriceDiffers = false;\r\n let productsWithChangedPrices: any[] = [];\r\n const productsToAddInCart: any = [];\r\n\r\n if (atpData.length) {\r\n const salesData = salesLines?.map(saleline => ({\r\n itemId: saleline.data.salesLine?.ItemId,\r\n quantity: saleline.data.salesLine?.Quantity,\r\n product: saleline.data.product,\r\n price: saleline.data.product?.Price,\r\n recordId: saleline.data.product?.RecordId,\r\n salesline: saleline.data.salesLine\r\n }));\r\n\r\n // Checking for active prices comparison\r\n const recordIds = salesData.map(item => item.recordId);\r\n const salesOrderPrices = salesData.map(item => ({ itemId: item.itemId, price: item.salesline.Price }));\r\n const activePrices = await _getActivePrices(customer, recordIds);\r\n const activePricesScrutinized = activePrices?.map(item => ({ itemId: item.ItemId, price: item.AdjustedPrice }));\r\n\r\n // Create a lookup object for activePrice\r\n const activePriceLookup = activePricesScrutinized.reduce((acc, item) => {\r\n acc[item.itemId!] = item.price?.toFixed(2);\r\n return acc;\r\n }, {});\r\n\r\n // Compare prices and find itemIds with price differences\r\n const differingItemIds = salesOrderPrices\r\n .filter(item => activePriceLookup[item.itemId!] !== undefined && activePriceLookup[item.itemId!] !== item.price?.toFixed(2))\r\n .map(item => item.itemId);\r\n\r\n if (differingItemIds.length) {\r\n productsWithChangedPrices = differingItemIds;\r\n isPriceDiffers = true;\r\n }\r\n\r\n // ATP check\r\n const processProducts = salesData?.map(async item => {\r\n const currentAtpItem = atpData?.find((obj: { ItemId: string | undefined }) => obj?.ItemId === item.itemId);\r\n const jsonObject = JSON.parse(currentAtpItem?.JsonResponseObject);\r\n\r\n if (currentAtpItem?.StatusCode === '204') {\r\n const cartLines = (await cart)?.cart.CartLines;\r\n\r\n if (cartLines?.length) {\r\n const currentProductInCart = cartLines?.find(obj => obj?.ItemId === item.itemId);\r\n const currentProductInCartQuantity = currentProductInCart?.Quantity;\r\n\r\n if (currentProductInCartQuantity && jsonObject?.Quantity > 0) {\r\n if (item?.quantity! + currentProductInCartQuantity > jsonObject?.Quantity) {\r\n if (jsonObject?.Quantity! - currentProductInCartQuantity !== 0) {\r\n productsToAddInCart.push({\r\n product: item.product,\r\n count: jsonObject?.Quantity - currentProductInCartQuantity\r\n });\r\n isProductsAvailable = true;\r\n } else {\r\n isProductsAvailable = true;\r\n setMessageForBuyAgainPopUp(\r\n 'Only those items that do not exceed the quantity limits and have a price are added to cart.'\r\n );\r\n }\r\n } else {\r\n productsToAddInCart.push({ product: item.product, count: item.quantity });\r\n }\r\n } else {\r\n productsToAddInCart.push({ product: item.product, count: item.quantity });\r\n }\r\n } else {\r\n productsToAddInCart.push({ product: item.product, count: item.quantity });\r\n }\r\n } else if (\r\n currentAtpItem?.StatusCode === '200' ||\r\n currentAtpItem?.StatusCode === '201' ||\r\n currentAtpItem?.StatusCode === '202' ||\r\n currentAtpItem?.StatusCode === '203'\r\n ) {\r\n productsToAddInCart.push({ product: item.product, count: item.quantity });\r\n } else {\r\n setMessageForBuyAgainPopUp(\r\n 'Only those items that do not exceed the quantity limits and have a price are added to cart.'\r\n );\r\n }\r\n });\r\n\r\n // Wait for all asynchronous processes to complete\r\n await Promise.all(processProducts);\r\n\r\n try {\r\n if (productsToAddInCart.length) {\r\n const result = await (await cart)?.addProductsToCart(productsToAddInCart);\r\n\r\n if (result?.status === 'FAILED') {\r\n const containsPhrase = result?.errorDetails?.LocalizedMessage?.includes(\r\n 'The maximum purchase quantity for this product is'\r\n );\r\n const containsPhraseValidationError = result?.validationResults![0].LocalizedMessage?.includes(\r\n 'Zero price is not allowed for selected product'\r\n );\r\n setMessageForBuyAgainPopUp(\r\n containsPhrase\r\n ? 'The maximum purchase quantity for some product(s) is exceeding, Product(s) are not added to cart.'\r\n : containsPhraseValidationError\r\n ? 'A validation error occurred, products from this order can not be added.'\r\n : result.errorDetails?.LocalizedMessage!\r\n );\r\n } else if (result?.status === 'SUCCESS') {\r\n if (isPriceDiffers && isProductsAvailable) {\r\n const message =\r\n 'Only those items that do not exceed the quantity limits and have a price are added to cart.' +\r\n `\\n` +\r\n `Some product prices might be updated. Please view cart for latest prices. ${productsWithChangedPrices.join(\r\n ', '\r\n )}`;\r\n setMessageForBuyAgainPopUp(message);\r\n } else if (isProductsAvailable) {\r\n setMessageForBuyAgainPopUp(\r\n 'Only those items that do not exceed the quantity limits and have a price are added to cart.'\r\n );\r\n } else if (isPriceDiffers) {\r\n setMessageForBuyAgainPopUp(\r\n `Some product prices might be updated. Please view cart for latest prices. ${productsWithChangedPrices.join(\r\n ', '\r\n )}`\r\n );\r\n } else {\r\n setMessageForBuyAgainPopUp(`Product(s) successfully added to cart.`);\r\n }\r\n }\r\n }\r\n } catch (error) {\r\n console.error('error', error);\r\n }\r\n }\r\n };\r\n\r\n const toggleBuyagainModalPopUp = () => {\r\n setBuyAgainModal(true);\r\n buyAgainMethod();\r\n };\r\n if (isMobile) {\r\n //View Shown in case of Mobile\r\n return (\r\n \r\n {buyAgainModal && messageForBuyAgainPopUp && (\r\n {\r\n setBuyAgainModal(!buyAgainModal);\r\n setMessageForBuyAgainPopUp('');\r\n }}\r\n >\r\n
\r\n {\r\n setBuyAgainModal(!buyAgainModal);\r\n setMessageForBuyAgainPopUp('');\r\n }}\r\n >\r\n Item(s) Added to Cart\r\n \r\n \r\n
{messageForBuyAgainPopUp}
\r\n
\r\n \r\n \r\n View Cart and Checkout\r\n \r\n {\r\n setBuyAgainModal(!buyAgainModal);\r\n setMessageForBuyAgainPopUp('');\r\n }}\r\n >\r\n Close\r\n \r\n \r\n
\r\n \r\n )}\r\n \r\n {salesLines.map(salesLine => {\r\n const salesLineAttr = salesLine.data.salesLine.AttributeValues;\r\n\r\n const productAttrManufactrValue: AttributeValue | undefined = salesLineAttr?.find(\r\n (item: AttributeValue) => item.Name === prodAttrIdentifier\r\n );\r\n const productAttrWeightValue: AttributeValue | undefined = salesLineAttr?.find(\r\n (item: AttributeValue) => item.Name === productWeightAttribute\r\n );\r\n const lineTotal = Number(salesLine?.data?.salesLine?.GrossAmount) - Number(salesLine?.data?.salesLine?.DiscountAmount);\r\n const manufItemTypeNameObj = salesLine.data.product?.ExtensionProperties?.find(item => {\r\n if (item.Key === 'ManufItemTypeName') {\r\n return item;\r\n }\r\n return null;\r\n });\r\n\r\n const manufacturerObj =\r\n attributeValues.length &&\r\n attributeValues.find((item: { recId: number | undefined }) => item.recId === salesLine?.data?.product?.RecordId);\r\n const urlPath = formatUrlPath(manufacturerObj?.manufacturer?.TextValue, manufItemTypeNameObj?.Value?.StringValue!);\r\n const pathName = context?.actionContext.requestContext.url.requestUrl.pathname.split('/');\r\n const isAddingPathWithUrl = context?.actionContext.requestContext.app.config.addPathWithUrl ?? false;\r\n let productUrl =\r\n salesLine &&\r\n (isAddingPathWithUrl\r\n ? `${context?.actionContext.requestContext.url.requestUrl.origin}/${pathName![1]}/${urlPath}/${\r\n salesLine?.data?.product?.RecordId\r\n }.p`\r\n : `${context?.actionContext.requestContext.url.requestUrl.origin}/${urlPath}/${salesLine?.data?.product?.RecordId}.p`);\r\n const buyAgainButtonCloned = (\r\n \r\n {resources.buyAgain}\r\n \r\n );\r\n salesLine.buyAgainButton = buyAgainButtonCloned;\r\n return (\r\n
\r\n {createdDate && (\r\n \r\n {resources.documentedDateTabelHeaderLabel} : {formattedDateStringBylocale}\r\n \r\n )}\r\n {salesId && (\r\n \r\n {resources.salesIDHeaderLabel}\r\n : {salesId}\r\n \r\n )}\r\n {\r\n \r\n {resources.weightTabelHeaderLabel}{' '}\r\n : {productAttrWeightValue?.TextValue ? productAttrWeightValue?.TextValue : '-'}\r\n \r\n }\r\n {\r\n \r\n {/* {resources.manufacturerHeaderLabel} : {productAttrManufactrValue?.TextValue} */}\r\n {prodAttrIdentifier || resources.manufacturerHeaderLabel}{' '}\r\n : {productAttrManufactrValue?.TextValue}\r\n \r\n }\r\n {\r\n \r\n {resources.productTabelHeaderLabel} : {salesLine.data.product?.Name}\r\n \r\n }\r\n {\r\n \r\n {resources.productNumberTabelHeaderLabel}\r\n : {salesLine.data.product?.ItemId}\r\n \r\n }\r\n {\r\n \r\n {resources.quantityTabelHeaderLabel} : {salesLine.data.salesLine.Quantity}\r\n \r\n }\r\n {\r\n \r\n {resources.netAmountTabelHeaderLabel} : {currencyFormat(lineTotal, context)}\r\n \r\n }\r\n {\r\n \r\n {resources.grossAmountTabelHeaderLabel}{' '}\r\n : {currencyFormat(salesLine?.data?.salesLine?.TotalAmount, context)}\r\n \r\n }\r\n {\r\n \r\n {resources.currencyTabelHeaderLabel} {usSiteFlag ? : $ : : A$}\r\n \r\n }\r\n {createdDate && (\r\n \r\n {resources.fulfilledTabelHeaderLabel}{' '}\r\n : {getOrderStatus(salesLine.data.salesLine.SalesStatusValue)}\r\n \r\n )}\r\n \r\n
\r\n );\r\n })}\r\n
\r\n );\r\n } else {\r\n //View Shown in case of Web\r\n return (\r\n <>\r\n {buyAgainModal && messageForBuyAgainPopUp && (\r\n {\r\n setBuyAgainModal(!buyAgainModal);\r\n setMessageForBuyAgainPopUp('');\r\n }}\r\n >\r\n
\r\n {\r\n setBuyAgainModal(!buyAgainModal);\r\n setMessageForBuyAgainPopUp('');\r\n }}\r\n >\r\n Item(s) Added to Cart\r\n \r\n \r\n
{messageForBuyAgainPopUp}
\r\n
\r\n \r\n \r\n View Cart and Checkout\r\n \r\n {\r\n setBuyAgainModal(!buyAgainModal);\r\n setMessageForBuyAgainPopUp('');\r\n }}\r\n >\r\n Close\r\n \r\n \r\n
\r\n \r\n )}\r\n \r\n
\r\n {resources.orderStateLabel}\r\n {delivery && }\r\n \r\n
\r\n \r\n {salesLines && (\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n {salesLines.map(salesLine => {\r\n const salesLineAttr = salesLine.data.salesLine.AttributeValues;\r\n\r\n const productAttrManufactrValue: AttributeValue | undefined = salesLineAttr?.find(\r\n (item: AttributeValue) => item.Name === prodAttrIdentifier\r\n );\r\n const productAttrWeightValue: AttributeValue | undefined = salesLineAttr?.find(\r\n (item: AttributeValue) => item.Name === productWeightAttribute\r\n );\r\n const lineTotal =\r\n Number(salesLine?.data?.salesLine?.GrossAmount) -\r\n Number(salesLine?.data?.salesLine?.DiscountAmount);\r\n const manufItemTypeNameObj = salesLine.data.product?.ExtensionProperties?.find(item => {\r\n if (item.Key === 'ManufItemTypeName') {\r\n return item;\r\n }\r\n return null;\r\n });\r\n\r\n const manufacturerObj =\r\n attributeValues.length &&\r\n attributeValues.find(\r\n (item: { recId: number | undefined }) => item.recId === salesLine?.data?.product?.RecordId\r\n );\r\n const urlPath = formatUrlPath(\r\n manufacturerObj?.manufacturer?.TextValue ?? '',\r\n manufItemTypeNameObj?.Value?.StringValue! ?? ''\r\n );\r\n const pathName = context?.actionContext.requestContext.url.requestUrl.pathname.split('/');\r\n const isAddingPathWithUrl =\r\n context?.actionContext.requestContext.app.config.addPathWithUrl ?? false;\r\n let productUrl =\r\n salesLine &&\r\n (isAddingPathWithUrl\r\n ? `${context?.actionContext.requestContext.url.requestUrl.origin}/${\r\n pathName![1]\r\n }/${urlPath}/${salesLine?.data?.product?.RecordId}.p`\r\n : `${context?.actionContext.requestContext.url.requestUrl.origin}/${urlPath}/${salesLine?.data?.product?.RecordId}.p`);\r\n const buyAgainButtonCloned = (\r\n \r\n {resources.buyAgain}\r\n \r\n );\r\n salesLine.buyAgainButton = buyAgainButtonCloned;\r\n return (\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n {usSiteFlag ? : }\r\n \r\n \r\n \r\n );\r\n })}\r\n
{resources.documentedDateTabelHeaderLabel}{resources.salesIDHeaderLabel}{resources.weightTabelHeaderLabel}{prodAttrIdentifier || resources.manufacturerHeaderLabel}{resources.productTabelHeaderLabel}{resources.productNumberTabelHeaderLabel}{resources.quantityTabelHeaderLabel}{resources.netAmountTabelHeaderLabel}{resources.grossAmountTabelHeaderLabel}{resources.currencyTabelHeaderLabel}{resources.fulfilledTabelHeaderLabel}{resources.actionTabelHeaderLabel}
{formattedDateStringBylocale}{salesId}{productAttrWeightValue?.TextValue ? productAttrWeightValue?.TextValue : '-'}{productAttrManufactrValue?.TextValue ? productAttrManufactrValue?.TextValue : '-'}\r\n {salesLine.data.product?.Name}\r\n {salesLine.data.product?.ItemId}{salesLine.data.salesLine.Quantity}{currencyFormat(lineTotal, context)}{currencyFormat(salesLine?.data?.salesLine?.TotalAmount, context)}$A$ {getOrderStatus(salesLine.data.salesLine.SalesStatusValue)}\r\n \r\n
\r\n
\r\n )}\r\n {!delivery.showTimeslot && address}\r\n {delivery.showTimeslot && (\r\n \r\n {address}\r\n {delivery.pickupDateTimeslot}\r\n \r\n )}\r\n
\r\n
\r\n \r\n );\r\n }\r\n};\r\n\r\nexport const OrderDetailsGroups: React.FC = ({\r\n groupsProps,\r\n groups,\r\n resources,\r\n salesId,\r\n createdDate,\r\n statusValue,\r\n context,\r\n cart,\r\n customer\r\n}) => (\r\n \r\n {groups.map((group: IGroup, index: number) => (\r\n \r\n ))}\r\n \r\n);\r\ninterface IOrderSummaryExtend {\r\n discountAmount?: number;\r\n context?: ICoreContext>;\r\n deliveryMode?: string;\r\n chargeAmount?: number;\r\n resources?: any;\r\n}\r\n\r\ninterface JSXNumberValue {\r\n value: number;\r\n}\r\nexport const OrderDetailsOrderSummary: React.FC = ({\r\n orderSummaryProps,\r\n heading,\r\n subtotal,\r\n shipping,\r\n tax,\r\n totalAmount,\r\n earnedPoints,\r\n discountAmount,\r\n context,\r\n deliveryMode,\r\n chargeAmount,\r\n resources\r\n}) => {\r\n const subTotalJSX = subtotal as JSX.Element;\r\n const subTotalJSXValue = subTotalJSX.props as JSXNumberValue;\r\n const subTotalAmount = subTotalJSXValue?.value;\r\n\r\n const taxProps = tax as JSX.Element;\r\n const taxValue = taxProps.props.value;\r\n\r\n const totalProps = totalAmount as JSX.Element;\r\n const totalAmountValue = totalProps.props.value;\r\n return (\r\n \r\n <>\r\n

{resources?.paymentSummaryText}

\r\n
\r\n {heading}\r\n

\r\n {resources?.subTotalText}\r\n \r\n \r\n {subTotalAmount === 0 ? '-' : currencyFormat(subTotalAmount, context)}\r\n \r\n \r\n

\r\n

\r\n {resources?.shippingFeeText}\r\n \r\n {deliveryMode && deliveryMode === 'Collection' ? (\r\n \r\n {resources?.freeText}\r\n \r\n ) : chargeAmount === 0 ? (\r\n

\r\n {resources?.toBeCalculatedText}\r\n
\r\n \r\n {resources?.excludingFreightCostMessage}\r\n
\r\n
\r\n ) : (\r\n {currencyFormat(chargeAmount, context)}\r\n )}\r\n \r\n

\r\n

\r\n Tax\r\n \r\n \r\n {taxValue === 0 ? '-' : currencyFormat(taxValue, context)}\r\n \r\n \r\n

\r\n

\r\n Total\r\n \r\n \r\n {totalAmountValue === 0 ? '-' : currencyFormat(totalAmountValue, context)}\r\n \r\n \r\n

\r\n {earnedPoints}\r\n
\r\n \r\n
\r\n );\r\n};\r\n\r\nexport const OrderDetailsPayment: React.FC = ({ paymentMethodsProps, title, methods }) => (\r\n \r\n {title}\r\n {methods}\r\n \r\n);\r\n\r\nexport const OrderDetailsHelp: React.FC = ({ helpProps, needHelpLabel, helpLineNumberLabel, contactNumber }) => (\r\n \r\n {needHelpLabel}\r\n {helpLineNumberLabel}\r\n {contactNumber}\r\n \r\n);\r\n\r\nconst OrderDetailsView: React.FC> = ({\r\n moduleProps,\r\n viewModes,\r\n tableViewActions,\r\n table,\r\n placedBy,\r\n heading,\r\n alert,\r\n loading,\r\n orderInfomation,\r\n orderSummary,\r\n groups,\r\n resources,\r\n config: { bannerImage, bannerLink },\r\n context: {\r\n request: { gridSettings },\r\n actionContext: { requestContext }\r\n },\r\n context,\r\n data: {\r\n orderHydration: { result },\r\n customerInformation,\r\n cart\r\n }\r\n}) => {\r\n const { salesOrder } = result!;\r\n const imageProps = {\r\n gridSettings: gridSettings ?? {},\r\n imageSettings: bannerImage?.imageSettings\r\n };\r\n interface IContentBlockFullConfig extends IContentBlockConfig {\r\n // eslint-disable-next-line @typescript-eslint/naming-convention -- This field comes from SDK.\r\n msdyn365__moduleLayout?: string;\r\n }\r\n\r\n const defaultImageSettings: Msdyn365.IImageSettings = {\r\n viewports: {\r\n xs: { q: 'w=613&h=270&m=6', w: 0, h: 0 },\r\n lg: { q: 'w=613&h=270&m=6', w: 0, h: 0 }\r\n },\r\n lazyload: true\r\n };\r\n\r\n const contentBlockImage = (\r\n \r\n );\r\n return (\r\n <>\r\n \r\n {heading}\r\n {alert}\r\n {loading}\r\n {tableViewActions}\r\n {result?.salesOrder?.Name ? (\r\n
\r\n {resources.orderPlacedBy} {result?.salesOrder?.Name?.split(' ')[0]}\r\n
\r\n ) : (\r\n placedBy\r\n )}\r\n {viewModes}\r\n {table}\r\n\r\n {groups && orderInfomation && (\r\n \r\n )}\r\n \r\n {orderSummary && (\r\n \r\n )}\r\n {bannerLink && bannerLink.linkUrl && bannerLink.linkUrl.destinationUrl && (\r\n
\r\n {' '}\r\n \r\n {contentBlockImage}\r\n \r\n
\r\n )}\r\n {/* {payment && } */}\r\n
\r\n
\r\n \r\n );\r\n};\r\n\r\nexport default OrderDetailsView;\r\n","/*--------------------------------------------------------------\r\n * Copyright (c) Microsoft Corporation. All rights reserved.\r\n * See License.txt in the project root for license information.\r\n *--------------------------------------------------------------*/\r\n\r\nimport { Module, Node, Waiting, IncrementalQuantity } from '@msdyn365-commerce-modules/utilities';\r\nimport * as React from 'react';\r\n\r\nimport {\r\n IBuyboxAddToCartViewProps,\r\n IBuyboxAddToWishlistViewProps,\r\n IBuyboxKeyInPriceViewProps,\r\n IBuyboxProductConfigureDropdownViewProps,\r\n IBuyboxProductConfigureViewProps,\r\n IBuyboxProductQuantityViewProps\r\n} from '@msdyn365-commerce-modules/buybox/src/modules/quickview/../../common';\r\nimport { IQuickviewViewProps } from '@msdyn365-commerce-modules/buybox/src/modules/quickview/./quickview';\r\nimport { IQuickviewProps } from '../definition-extensions/quickview.ext.props.autogenerated';\r\nimport { IQuickviewData } from '@msdyn365-commerce-modules/buybox/src/modules/quickview/quickview.data';\r\nimport { generateImageUrl } from '@msdyn365-commerce-modules/retail-actions';\r\nimport { trafficLightsAtpaction, TrafficLightsAtpInput } from '../../../actions/traffic-lights-atp.action';\r\nimport { ATPMessage, TrafficLights } from '../../../utils/atp-utils';\r\nimport EstimatedShipDateComponent from '../../../utils/ATP/atpESD';\r\nimport { KitProduct } from '../../../utils/Kits/kits';\r\nimport { kRV_GetMultipleATPLeadTimeDateAsync } from '../../../actions/customProxy/ATP-update/DataActionExtension.g';\r\nimport {\r\n IKRV_ATPLeadTimePropertiesDate,\r\n IKRV_GetMultipleATPLeadTimeResponseDate\r\n} from '../../../actions/customProxy/ATP-update/DataServiceEntities.g';\r\nimport EstimatedShipDateKitComponent from '../../../utils/ATP/atpKitESD';\r\nimport { IBuyboxState, IBuyboxCommonData, IBuyboxExtentedProps } from '@msdyn365-commerce-modules/buybox';\r\nimport { PriceComponent } from './components/price.component';\r\nimport { filteredProductAttributeList, incExcPriceFormat, isRequestPrice, taxPercentage } from '../../../utils/helper';\r\nimport { PromotionBadges } from '../../../utils/badges';\r\n\r\nconst _renderAddToWishlist = (addToWishlist: IBuyboxAddToWishlistViewProps): JSX.Element => {\r\n const { ContainerProps, errorBlock, button } = addToWishlist;\r\n\r\n return (\r\n \r\n {errorBlock}\r\n {button}\r\n \r\n );\r\n};\r\n\r\nconst _renderConfigureDropdown = (dropdown: IBuyboxProductConfigureDropdownViewProps): JSX.Element => {\r\n const { ContainerProps, LabelContainerProps, heading, errors, select } = dropdown;\r\n\r\n return (\r\n \r\n \r\n {heading}\r\n {errors}\r\n \r\n {select}\r\n \r\n );\r\n};\r\n\r\nconst _renderKeyInPrice = (keyInPrice: IBuyboxKeyInPriceViewProps): JSX.Element => {\r\n const { ContainerProps, LabelContainerProps, heading, input } = keyInPrice;\r\n return (\r\n \r\n {heading}\r\n {input}\r\n \r\n );\r\n};\r\n\r\nconst _renderConfigure = (configure: IBuyboxProductConfigureViewProps): JSX.Element => {\r\n const { ContainerProps, dropdowns } = configure;\r\n\r\n return {dropdowns.map(_renderConfigureDropdown)};\r\n};\r\ninterface IQuickviewViewPropsExtended extends IQuickviewViewProps {\r\n cart?: any;\r\n}\r\ninterface CommercePropertyValue {\r\n BooleanValue?: boolean;\r\n ByteValue?: number;\r\n DateTimeOffsetValue?: Date;\r\n DecimalValue?: number;\r\n IntegerValue?: number;\r\n LongValue?: number;\r\n StringValue?: string;\r\n}\r\ninterface CommerceProperty {\r\n Key?: string;\r\n Value?: CommercePropertyValue;\r\n}\r\ninterface AttributeSwatch {\r\n SwatchValue?: string;\r\n SwatchImageUrl?: string;\r\n SwatchColorHexCode?: string;\r\n IsDefault?: boolean;\r\n ProductImageUrls?: string[];\r\n ExtensionProperties?: CommerceProperty[];\r\n}\r\ninterface AttributeValue {\r\n Name?: string;\r\n KeyName?: string;\r\n UnitOfMeasureSymbol?: string;\r\n DataTypeValue?: number;\r\n BooleanValue?: boolean;\r\n DateTimeOffsetValue?: Date;\r\n FloatValue?: number;\r\n IntegerValue?: number;\r\n TextValue?: string;\r\n CurrencyValue?: number;\r\n CurrencyCode?: string;\r\n AttributeValueId?: number;\r\n RecordId?: number;\r\n Swatches?: AttributeSwatch[];\r\n ExtensionProperties?: CommerceProperty[];\r\n}\r\ninterface customAttribute {\r\n attributevalues?: AttributeValue[];\r\n}\r\n\r\n/**\r\n * Functional component which renders quick view button and popup based by the given props file.\r\n * @param {IQuickviewViewProps} props - Configuration for the quick view component.\r\n * @returns {React.FC} - Functional component of the quick view.\r\n */\r\nexport const QuickViewFunctionalComponent: React.FC> = (\r\n props: IQuickviewViewPropsExtended & IQuickviewProps & customAttribute\r\n) => {\r\n const { quickView, quickViewButton, isModalOpen, isMobileDevice, resources } = props;\r\n const isUserAuth = props.context.actionContext.requestContext.user.isAuthenticated;\r\n const [isMax, setIsMax] = React.useState(false);\r\n const [isMin, setIsMin] = React.useState(true);\r\n const [isClassName, setIsClassName] = React.useState(true);\r\n const [producerName, setProducerName] = React.useState('');\r\n const [isProductDiscontinued, setIsProductDiscontinued] = React.useState(false);\r\n const [isAddToCartDisabled, setIsAddToCartDisabled] = React.useState(false);\r\n const [disableAddToCartATP, setDisableAddToCartATP] = React.useState(false);\r\n const [twoZeroFourProdMax, setTwoZeroFourProdMax] = React.useState(0);\r\n //To set Image Url\r\n const [imgURI, setImgURL] = React.useState();\r\n const productAttributes = filteredProductAttributeList(props.attributevalues, props.context.app.config.kcProductAttribute);\r\n const findProducerName = () => {\r\n productAttributes?.map(e => {\r\n if (e.identifier === 'Manufacturer') {\r\n setProducerName(e?.TextValue);\r\n }\r\n });\r\n };\r\n\r\n //use this function to render or display category image\r\n const _renderCategoryImg = (imgURI: string) => {\r\n return (\r\n
\r\n producer-images\r\n
\r\n );\r\n };\r\n //To set the producer name\r\n React.useEffect(() => {\r\n findProducerName();\r\n if (producerName) {\r\n setImgURL(producerName);\r\n }\r\n }, [props.attributevalues]);\r\n\r\n //to generate Image url after getting img url from api call\r\n React.useEffect(() => {\r\n if (imgURI) {\r\n let imageUrl = generateImageUrl(imgURI, props.context.actionContext.requestContext.apiSettings);\r\n imageUrl = imageUrl?.replace('=/', '=') || '';\r\n setImgURL(imageUrl);\r\n }\r\n }, [imgURI]);\r\n\r\n React.useEffect(() => {\r\n props.state.quantity <= props.state.min! && props.state.quantity !== 1 ? setIsMin(true) : setIsMin(false);\r\n props.state.quantity === props.state.max! ? setIsMax(true) : setIsMax(false);\r\n props.state.quantity < props.state.min! ? setIsClassName(true) : setIsClassName(false);\r\n }, [props.state.quantity, props.state.min, props.state.max]);\r\n\r\n const _renderAddToCart = (addToCart: IBuyboxAddToCartViewProps): JSX.Element => {\r\n const { ContainerProps, errorBlock, button } = addToCart;\r\n let customAddBundleToCartButton;\r\n if (props?.productDetails?.product?.Components?.length !== 0) {\r\n customAddBundleToCartButton =\r\n button &&\r\n React.cloneElement(button as JSX.Element, {\r\n title: props.resources.addBundleToCartButtonLabel,\r\n children: props.resources.addBundleToCartButtonLabel,\r\n addToCartText: props.resources.addBundleToCartButtonLabel\r\n });\r\n }\r\n return (\r\n \r\n {errorBlock}\r\n
\r\n {props.productDetails?.product?.Components?.length !== 0 ? (\r\n \r\n ) : isRequestPrice(\r\n props.productDetails?.productPrice!,\r\n props.data.customerInformation.result?.LineDiscountGroup!,\r\n props.productDetails?.product?.Components?.length !== 0\r\n ) ||\r\n isClassName ||\r\n isProductDiscontinued ||\r\n isAddToCartDisabled ||\r\n disableAddToCartATP ? (\r\n \r\n ) : props?.productDetails?.product?.Components?.length !== 0 ? (\r\n
{customAddBundleToCartButton}
\r\n ) : (\r\n
{button}
\r\n )}\r\n
\r\n
\r\n );\r\n };\r\n\r\n const _renderQuantity = (\r\n quantity: IBuyboxProductQuantityViewProps,\r\n quantityLimitsMessages: React.ReactNode,\r\n propMax: number\r\n ): JSX.Element => {\r\n const { ContainerProps, LabelContainerProps, heading, input, errors } = quantity;\r\n const customInput =\r\n input &&\r\n React.cloneElement(input as JSX.Element, {\r\n max: propMax,\r\n disable: disableAddToCartATP ? true : false,\r\n min: 1\r\n });\r\n\r\n return (\r\n \r\n \r\n {heading}\r\n {errors}\r\n \r\n {isRequestPrice(\r\n props.productDetails?.productPrice!,\r\n props.data.customerInformation.result?.LineDiscountGroup!,\r\n props.productDetails?.product?.Components?.length !== 0\r\n ) ||\r\n isProductDiscontinued ||\r\n isAddToCartDisabled ||\r\n disableAddToCartATP ? (\r\n \r\n ) : (\r\n customInput\r\n )}\r\n {/* {quantityLimitsMessages} */}\r\n
\r\n {props.state.min && isMin && (\r\n

\r\n {props.resources.informationHeading}\r\n \r\n {`${props.resources.minErrorMessage} ${props.state.min}`}\r\n

\r\n )}\r\n\r\n {(isMax || disableAddToCartATP) && !isMin && (\r\n

\r\n {props.resources.informationHeading}\r\n \r\n {disableAddToCartATP\r\n ? props.resources.maxQuantityMessage.replace('{propMax}', String(propMax))\r\n : `${props.resources.maxErrorMessage} ${twoZeroFourProdMax !== 0 ? twoZeroFourProdMax : props.state.max}`}\r\n

\r\n )}\r\n
\r\n
\r\n );\r\n };\r\n\r\n const RenderBodyContent: React.FC = (\r\n props: IQuickviewViewPropsExtended & customAttribute\r\n ) => {\r\n const {\r\n title,\r\n price,\r\n rating,\r\n keyInPrice,\r\n quantity,\r\n configure,\r\n inventoryLabel,\r\n quantityLimitsMessages,\r\n // seeDetailsbutton,\r\n loading,\r\n ProductInfoContainerProps,\r\n MediaGalleryContainerProps,\r\n CarouselProps,\r\n unitOfMeasure,\r\n productDetails,\r\n cart\r\n } = props;\r\n const buyBoxProps = props as IBuyboxExtentedProps;\r\n const { enabledIncExPrices } = props.context.app.config;\r\n const renderItemNumber = () => {\r\n let itemNumber;\r\n itemNumber = props.productDetails?.product?.ItemId;\r\n return `${itemNumber}`;\r\n };\r\n const customerTaxPercentage = taxPercentage(props.data.customerInformation?.result!);\r\n const calculateWpPrice = () => {\r\n let price;\r\n let discountedWpPrice: number;\r\n let displayValue;\r\n\r\n props.attributevalues?.map(e => {\r\n if (e.KeyName === 'PowerratingPmax(Wp)') {\r\n price = props.productDetails?.productPrice?.CustomerContextualPrice! / e.IntegerValue!;\r\n discountedWpPrice = props.productDetails?.productPrice?.CustomerContextualPrice! / e.IntegerValue!;\r\n }\r\n if (e.KeyName === 'DisplayWPPrice') {\r\n displayValue = e.BooleanValue;\r\n }\r\n });\r\n if (displayValue && price !== undefined) {\r\n const ppwPrice =\r\n props?.context?.actionContext?.requestContext?.apiSettings?.oun !== props.context.app.config.ounNumberForUsSite\r\n ? resources.wpPriceLabel\r\n : resources.ppwPriceLabel;\r\n return (\r\n Number.isFinite(discountedWpPrice!) && (\r\n
\r\n {ppwPrice}:\r\n \r\n {incExcPriceFormat(Number(discountedWpPrice!), props.context, enabledIncExPrices, customerTaxPercentage, 3)}\r\n \r\n
\r\n )\r\n );\r\n }\r\n return <>;\r\n };\r\n\r\n if (loading) {\r\n return <>{loading};\r\n }\r\n let linkedProducts: any[] | undefined;\r\n if (productDetails) {\r\n linkedProducts = productDetails.product?.Components;\r\n }\r\n const extensionsProps = props?.productDetails?.product?.ExtensionProperties;\r\n let promotionBadge = '';\r\n if (extensionsProps?.find(e => e?.Key === 'PromotionBadge')) {\r\n promotionBadge = extensionsProps?.find(e => e?.Key === 'PromotionBadge')?.Value?.StringValue || '';\r\n }\r\n // ************ VSI Customization Starts for Bundle kit ATP ****************//\r\n const [atpData, setAtpData] = React.useState>([]);\r\n const [kitProductATP, setKitProductATP] = React.useState(false);\r\n const [isKitProductATPDiscontinued, setIsKitProductATPDiscontinued] = React.useState(false);\r\n const _atpData = async (products: any[] | undefined) => {\r\n const KRVATPLeadTimeDate: any[] = [];\r\n //Create date according to API\r\n const objectDate = new Date();\r\n const day = objectDate.getDate();\r\n const month = objectDate.getMonth();\r\n const year = objectDate.getFullYear();\r\n const requestedDate = `${day}/${month + 1}/${year}`;\r\n\r\n if (products && products.length > 0) {\r\n products?.map((e: any) => {\r\n KRVATPLeadTimeDate.push({\r\n itemID: e.ItemId,\r\n requestedDate: requestedDate\r\n });\r\n });\r\n }\r\n const ctx = { callerContext: props.context.actionContext };\r\n try {\r\n const response = await kRV_GetMultipleATPLeadTimeDateAsync(ctx, KRVATPLeadTimeDate);\r\n setAtpData([response] || []);\r\n setKitProductATP(true);\r\n } catch (err) {\r\n console.error(err, 'ERR');\r\n }\r\n };\r\n function kitProductATPCall() {\r\n if (linkedProducts?.length !== 0) {\r\n _atpData(linkedProducts);\r\n }\r\n }\r\n\r\n React.useEffect(() => {\r\n if (linkedProducts?.length !== 0 && props.context.request.user.isAuthenticated) {\r\n if (!kitProductATP) {\r\n kitProductATPCall();\r\n }\r\n const anyRed = atpData[0]?.ATPTrafficLights?.filter(item => item.TrafficLight === 'Red');\r\n if (anyRed?.length || trafficLightsResponse?.IsDiscontinuedProduct === 'Yes') {\r\n setIsKitProductATPDiscontinued(true);\r\n setIsProductDiscontinued(true);\r\n }\r\n if (trafficLightsResponse?.IsAddToCart === 'No') {\r\n setIsAddToCartDisabled(true);\r\n }\r\n }\r\n }, [linkedProducts, atpData]);\r\n // ************ VSI Customization Ends for Bundle kit ATP ****************//\r\n // ********** VSI Customization Start ****************//\r\n const itemId = productDetails?.product?.ItemId;\r\n const [isLoading, setIsLoading] = React.useState(true);\r\n const [propMax, setPropMax] = React.useState(props.state.max!);\r\n const [maxESD, setMaxESD] = React.useState(props.state.max!);\r\n const [trafficLightsResponse, settrafficLightsResponse] = React.useState();\r\n\r\n React.useEffect(() => {\r\n if (props.state.max) {\r\n setPropMax(props.state.max);\r\n }\r\n }, [props.state.max]);\r\n\r\n //Use this Effect for set max values of product in state according to status\r\n React.useEffect(() => {\r\n if (trafficLightsResponse) {\r\n if (trafficLightsResponse.StatusCode === '500') {\r\n setIsClassName(true);\r\n setPropMax(trafficLightsResponse?.Quantity);\r\n setMaxESD(trafficLightsResponse?.Quantity);\r\n } else if (trafficLightsResponse.StatusCode === '501') {\r\n if (trafficLightsResponse.POQuantity > props.state.max!) {\r\n setPropMax(props.state.max!);\r\n setMaxESD(props.state.max!);\r\n } else {\r\n setPropMax(trafficLightsResponse.POQuantity!);\r\n setMaxESD(trafficLightsResponse.POQuantity!);\r\n }\r\n } else if (trafficLightsResponse.StatusCode === '502') {\r\n setPropMax(trafficLightsResponse?.Quantity);\r\n setMaxESD(trafficLightsResponse?.Quantity);\r\n } else if (trafficLightsResponse.StatusCode === '503') {\r\n if (trafficLightsResponse?.Quantity + trafficLightsResponse.POQuantity > props.state.max!) {\r\n setPropMax(props.state.max!);\r\n setMaxESD(trafficLightsResponse?.Quantity + trafficLightsResponse.POQuantity);\r\n } else {\r\n setPropMax(trafficLightsResponse?.Quantity + trafficLightsResponse.POQuantity);\r\n setMaxESD(trafficLightsResponse?.Quantity + trafficLightsResponse.POQuantity);\r\n }\r\n } else if (\r\n trafficLightsResponse.StatusCode === '204' &&\r\n trafficLightsResponse?.Message?.toLocaleLowerCase() === resources.noFurtherSuppliesText\r\n ) {\r\n //checking if already same product exist in cart\r\n let productOfInterestQuantity: number | undefined;\r\n\r\n cart?.result?.cart?.CartLines?.map((item: { ItemId: string | undefined; Quantity: number | undefined }) => {\r\n if (item.ItemId === itemId) {\r\n productOfInterestQuantity = item.Quantity;\r\n }\r\n return undefined;\r\n });\r\n setPropMax(\r\n productOfInterestQuantity !== undefined\r\n ? trafficLightsResponse?.Quantity - productOfInterestQuantity!\r\n : trafficLightsResponse?.Quantity\r\n );\r\n setMaxESD(trafficLightsResponse?.Quantity);\r\n } else {\r\n setPropMax(props.state.max!);\r\n }\r\n }\r\n }, [trafficLightsResponse]);\r\n React.useEffect(() => {\r\n if (cart?.result?.cart?.CartLines && trafficLightsResponse?.StatusCode === '204') {\r\n //checking if already same product exist in cart\r\n let productOfInterestQuantity: number | undefined;\r\n cart?.result?.cart?.CartLines?.map((item: { ItemId: string | undefined; Quantity: number | undefined }) => {\r\n if (item.ItemId === itemId) {\r\n productOfInterestQuantity = item.Quantity;\r\n }\r\n return undefined;\r\n });\r\n //condition to disable add to cart\r\n if (productOfInterestQuantity && productOfInterestQuantity >= trafficLightsResponse?.Quantity!) {\r\n setDisableAddToCartATP(true);\r\n setPropMax(trafficLightsResponse?.Quantity!);\r\n }\r\n }\r\n }, [cart?.result?.cart, trafficLightsResponse]);\r\n React.useEffect(() => {\r\n if (trafficLightsResponse?.StatusCode === '204') {\r\n //condition to set new max\r\n if (\r\n (props.state.max && props.state.max > trafficLightsResponse?.Quantity!) ||\r\n props.state.quantity === trafficLightsResponse?.Quantity!\r\n ) {\r\n setTwoZeroFourProdMax(trafficLightsResponse?.Quantity!);\r\n setIsMax(true);\r\n } else if (props.state.quantity < trafficLightsResponse?.Quantity!) {\r\n setIsMax(false);\r\n }\r\n }\r\n }, [props.state.quantity, trafficLightsResponse]);\r\n //VSI Customization Start States of traffic lights\r\n let objectDate = new Date();\r\n let day = objectDate.getDate();\r\n let month = objectDate.getMonth();\r\n let year = objectDate.getFullYear();\r\n let requestedDate = `${month + 1}/${day}/${year}`;\r\n\r\n //VSI Customization END States of traffic lights\r\n async function trafficLightsDataActionCall() {\r\n setIsLoading(true);\r\n const requestBody = {\r\n itemId: itemId!,\r\n requestedDate: requestedDate\r\n };\r\n try {\r\n const trafficLightsParams = new TrafficLightsAtpInput(requestBody.itemId, requestBody.requestedDate);\r\n const trafficLightsSlots = await trafficLightsAtpaction(trafficLightsParams, props.context.actionContext);\r\n settrafficLightsResponse(trafficLightsSlots);\r\n if (trafficLightsSlots.TrafficLight === 'Red' || trafficLightsResponse?.IsDiscontinuedProduct === 'Yes') {\r\n setIsProductDiscontinued(true);\r\n }\r\n if (trafficLightsResponse?.IsAddToCart === 'No') {\r\n setIsAddToCartDisabled(true);\r\n }\r\n } catch (error) {\r\n props.telemetry.warning('error');\r\n props.telemetry.debug('Unable to get response for traffic lights slots');\r\n }\r\n setIsLoading(false);\r\n }\r\n\r\n React.useEffect(() => {\r\n if (requestedDate && itemId) trafficLightsDataActionCall();\r\n }, [requestedDate, itemId]);\r\n\r\n // ********** VSI Customization END ****************//\r\n\r\n if (CarouselProps.items) {\r\n if (CarouselProps.items[0]?.props.children) {\r\n CarouselProps.items[0].props.children.props.role = '';\r\n }\r\n }\r\n\r\n return (\r\n <>\r\n \r\n \r\n \r\n \r\n \r\n
{imgURI && _renderCategoryImg(imgURI)}
\r\n {title}\r\n
\r\n {resources.itemNnLabel}: \r\n {renderItemNumber()}\r\n
\r\n {linkedProducts?.length !== 0 ? (\r\n \r\n ) : (\r\n <>\r\n {unitOfMeasure}\r\n {rating}\r\n {configure && _renderConfigure(configure)}\r\n {keyInPrice && _renderKeyInPrice(keyInPrice)}\r\n \r\n )}\r\n {/* *********** VSI CUSTOMIZATION START FOR ATP ************ */}\r\n
\r\n {isLoading ? (\r\n \r\n ) : (\r\n
\r\n {trafficLightsResponse && (\r\n
\r\n \r\n {linkedProducts?.length !== 0 ? (\r\n
\r\n

{resources.contactSalesOfficeMessage}

\r\n
\r\n ) : isKitProductATPDiscontinued ? (\r\n
\r\n

{resources.noFurtherSuppliesText}

\r\n
\r\n ) : (\r\n \r\n )}\r\n
\r\n )}\r\n\r\n {linkedProducts?.length !== 0 ? (\r\n \r\n ) : isKitProductATPDiscontinued ? null : (\r\n \r\n )}\r\n
\r\n )}\r\n
\r\n {/* *********** VSI CUSTOMIZATION End FOR ATP ************ */}\r\n\r\n
\r\n {linkedProducts?.length !== 0 ? (\r\n
\r\n
{resources.quantityLabel}
\r\n
\r\n ) : (\r\n quantity && _renderQuantity(quantity, quantityLimitsMessages, propMax)\r\n )}\r\n
\r\n {isRequestPrice(\r\n props.productDetails?.productPrice!,\r\n props.data.customerInformation?.result?.LineDiscountGroup!,\r\n linkedProducts?.length !== 0\r\n ) ? (\r\n
\r\n {resources.requestPriceLabel}\r\n
\r\n \r\n {resources.cantAddContactSalesOfficeMessage}\r\n
\r\n
\r\n ) : (\r\n <>\r\n {price && getBuyboxProductPrice(buyBoxProps, props.state)}\r\n {linkedProducts?.length !== 0 ?

{resources.forBundleLabel}

: null}\r\n \r\n )}\r\n {props.context.actionContext.requestContext.user.isAuthenticated &&\r\n !isRequestPrice(\r\n props.productDetails?.productPrice!,\r\n props.data.customerInformation?.result?.LineDiscountGroup!,\r\n linkedProducts?.length !== 0\r\n ) &&\r\n calculateWpPrice()}\r\n
\r\n
\r\n {/* {seeDetailsbutton} */}\r\n {inventoryLabel}\r\n
\r\n \r\n );\r\n };\r\n\r\n const _renderQuickViewPopup = (props: IQuickviewViewPropsExtended): JSX.Element => {\r\n const {\r\n ModalContainer,\r\n ModalHeaderContainer,\r\n ModalFooterContainer,\r\n ModalHeaderContent,\r\n ModalBodyContainer,\r\n addToWishlist,\r\n addToCart,\r\n cartContainerProps\r\n } = props;\r\n return (\r\n \r\n {ModalHeaderContent}\r\n {}\r\n \r\n \r\n {addToCart && _renderAddToCart(addToCart)}\r\n {addToWishlist && _renderAddToWishlist(addToWishlist)}\r\n \r\n \r\n \r\n );\r\n };\r\n\r\n return (\r\n \r\n {!isMobileDevice && isUserAuth && quickViewButton}\r\n {isModalOpen && _renderQuickViewPopup(props)}\r\n \r\n );\r\n};\r\n\r\nconst getBuyboxProductPrice = (props: IBuyboxExtentedProps, state: IBuyboxState): React.ReactElement | undefined => {\r\n const { id, typeName, context, resources } = props;\r\n const customerTaxPercentage = taxPercentage(props.data.customerInformation?.result!);\r\n return (\r\n state.productPrice && (\r\n featureState.Name === 'Dynamics.AX.Application.RetailSearchPriceRangeFeature'\r\n )?.IsEnabled\r\n }\r\n isSalesAgreementPriceFeatureEnabled={\r\n props.data.featureState.result?.find(\r\n featureState => featureState.Name === 'Dynamics.AX.Application.RetailSalesAgreementPriceSupportFeature'\r\n )?.IsEnabled\r\n }\r\n useLegacySalesAgreementHTMLFeature={\r\n props.data.featureState.result?.find(featureState => featureState.Name === 'UseLegacySalesAgreementHTMLFeature')\r\n ?.IsEnabled\r\n }\r\n priceResources={{\r\n priceRangeSeparator: resources.priceRangeSeparator,\r\n salesAgreementPricePrompt: resources.salesAgreementPricePrompt,\r\n salesAgreementExpirationDatePrompt: resources.salesAgreementExpirationDatePrompt,\r\n salesAgreementCommittedQuantityPrompt: resources.salesAgreementCommittedQuantityPrompt,\r\n salesAgreementRemainingQuantityPrompt: resources.salesAgreementRemainingQuantityPrompt\r\n }}\r\n freePriceText={resources.priceFree}\r\n originalPriceText={resources.originalPriceText}\r\n currentPriceText={resources.currentPriceText}\r\n isIncExPriceFormatEnabled={true}\r\n customerTaxPercentage={customerTaxPercentage}\r\n />\r\n )\r\n );\r\n};\r\n\r\nexport default QuickViewFunctionalComponent;\r\n","import React from 'react';\r\nimport { Button } from 'reactstrap';\r\nimport ATPESDMessageComponent from './atpESDMessage';\r\nimport { kRV_GetATPLeadTimeWithQuantityAsync } from '../../actions/customProxy/ATP1/DataActionExtension.g';\r\nimport { IKRV_GetATPLeadTimeResponseQuantity } from '../../actions/customProxy/ATP1/DataServiceEntities.g';\r\n\r\nconst EstimatedShipDateComponent: React.FC = ({ itemNumber, propMax, context, trafficLightsResponse }) => {\r\n const [quanATP, setQuanAtp] = React.useState();\r\n const [isLoadingAtpResponse, setIsLoadingAtpResponse] = React.useState(false);\r\n const [atpResponse, setAtpResponse] = React.useState();\r\n const [isCalculateBtnDisable, setIsCalculateBtnDisable] = React.useState(false);\r\n const [isMaxExceeded, setIsMaxExceeded] = React.useState(false);\r\n React.useEffect(() => {\r\n quanATP! < 1 || trafficLightsResponse?.IsCalShipping === 'No' || trafficLightsResponse?.IsDiscontinuedProduct === 'Yes'\r\n ? setIsCalculateBtnDisable(true)\r\n : setIsCalculateBtnDisable(false);\r\n if (quanATP! > propMax && trafficLightsResponse?.StatusCode === '500') {\r\n setQuanAtp(propMax);\r\n } else if (quanATP! > propMax && trafficLightsResponse?.StatusCode === '502') {\r\n setQuanAtp(propMax);\r\n } else if (quanATP! > propMax && trafficLightsResponse?.StatusCode === '501') {\r\n setQuanAtp(propMax);\r\n } else if (quanATP! > propMax && trafficLightsResponse?.StatusCode === '503') {\r\n // eslint-disable-next-line @typescript-eslint/restrict-plus-operands\r\n setQuanAtp(trafficLightsResponse?.Quantity + trafficLightsResponse.POQuantity);\r\n } else if (quanATP! > propMax && trafficLightsResponse?.StatusCode === '204') {\r\n setQuanAtp(propMax);\r\n setIsMaxExceeded(true);\r\n setTimeout(() => {\r\n setIsMaxExceeded(false);\r\n }, 4000);\r\n }\r\n }, [quanATP]);\r\n\r\n async function buttonATPCalculationDataActionCall() {\r\n setIsLoadingAtpResponse(true);\r\n try {\r\n const KRVATPLeadTimeQuantity = [\r\n {\r\n itemID: itemNumber,\r\n Qty: quanATP!\r\n }\r\n ];\r\n const context1 = { callerContext: context.actionContext };\r\n await kRV_GetATPLeadTimeWithQuantityAsync(context1, KRVATPLeadTimeQuantity).then(res => {\r\n setAtpResponse(res);\r\n setIsLoadingAtpResponse(false);\r\n });\r\n } catch (error) {\r\n const errorBody: any = {\r\n Id: 0,\r\n ATPDate: '0',\r\n Message: 'Unable to get response for Estimated Availability',\r\n ExtensionProperties: []\r\n };\r\n setAtpResponse(errorBody);\r\n setIsLoadingAtpResponse(false);\r\n }\r\n }\r\n const handleCalculateATPDate = () => {\r\n if (itemNumber && quanATP) {\r\n void buttonATPCalculationDataActionCall();\r\n }\r\n };\r\n //These symbols are not be typed on input box\r\n const exceptThisSymbols = ['e', 'E', '+', '-', '.'];\r\n\r\n return (\r\n <>\r\n
\r\n \r\n {\r\n setQuanAtp(e.target.value);\r\n }}\r\n onKeyDown={e => exceptThisSymbols.includes(e.key) && e.preventDefault()}\r\n disabled={\r\n trafficLightsResponse?.TrafficLight! === 'Red' ||\r\n trafficLightsResponse?.IsCalShipping === 'No' ||\r\n trafficLightsResponse?.IsDiscontinuedProduct === 'Yes'\r\n }\r\n />\r\n \r\n Calculate Shipping Date\r\n \r\n
\r\n {/*Message to be changed and moved to resources */}\r\n {isMaxExceeded &&

{`Only available stock quantity can be entered (${propMax})`}

}\r\n \r\n \r\n );\r\n};\r\n\r\nexport default EstimatedShipDateComponent;\r\n","/* eslint-disable @typescript-eslint/no-unnecessary-type-assertion */\r\n/* eslint-disable @typescript-eslint/restrict-plus-operands */\r\nimport React from 'react';\r\nimport { Waiting } from '@msdyn365-commerce-modules/utilities';\r\nimport { dateFormatByLocale } from '../helper';\r\n\r\nconst ATPESDMessageComponent: React.FC = ({ quanATP, propMax, trafficLightsResponse, isLoadingAtpResponse, atpResponse, context }) => {\r\n let estShipDate;\r\n let atpHighestDate;\r\n if (\r\n atpResponse?.ATPLeadTimePropertiesQuantityResponseEntityList[0]?.ATPDate &&\r\n context.app.config.dateFormat &&\r\n context.request.channel?.Currency\r\n ) {\r\n estShipDate =\r\n dateFormatByLocale(\r\n context.app.config.dateFormat,\r\n context.request.channel?.Currency,\r\n atpResponse?.ATPLeadTimePropertiesQuantityResponseEntityList[0]?.ATPDate\r\n ) ?? '';\r\n }\r\n if (atpResponse?.HighestDate.toString() && context.app.config.dateFormat && context.request.channel?.Currency) {\r\n atpHighestDate =\r\n dateFormatByLocale(context.app.config.dateFormat, context.request.channel?.Currency, atpResponse?.HighestDate.toString()) ?? '';\r\n }\r\n if (quanATP! >= propMax && trafficLightsResponse?.StatusCode === '500') {\r\n return (\r\n
\r\n

\r\n Information\r\n \r\n On-Hand Quantity Is {propMax} , And Item Is Discontinued For Future.\r\n

\r\n {isLoadingAtpResponse ? (\r\n \r\n ) : atpResponse?.ATPLeadTimePropertiesQuantityResponseEntityList[0]?.ATPDate &&\r\n atpResponse?.ATPLeadTimePropertiesQuantityResponseEntityList[0]?.ATPDate !== '0' ? (\r\n atpResponse?.ATPLeadTimePropertiesQuantityResponseEntityList[0]?.ATPDate && (\r\n

Estimated Shipping Date : {estShipDate}

\r\n )\r\n ) : (\r\n

{atpResponse?.ATPLeadTimePropertiesQuantityResponseEntityList[0]?.Message}

\r\n )}\r\n
\r\n );\r\n } else if (\r\n quanATP >= trafficLightsResponse?.Quantity! + trafficLightsResponse?.POQuantity &&\r\n trafficLightsResponse?.StatusCode === '503'\r\n ) {\r\n return (\r\n
\r\n

\r\n Information\r\n \r\n On-Hand Quantity Is {trafficLightsResponse?.Quantity! + trafficLightsResponse?.POQuantity!} , And Item Is Discontinued\r\n For Future.\r\n

\r\n {isLoadingAtpResponse ? (\r\n \r\n ) : atpResponse?.ATPLeadTimePropertiesQuantityResponseEntityList[0]?.ATPDate &&\r\n atpResponse?.ATPLeadTimePropertiesQuantityResponseEntityList[0]?.ATPDate !== '0' ? (\r\n atpResponse?.ATPLeadTimePropertiesQuantityResponseEntityList[0]?.ATPDate && (\r\n

Estimated Shipping Date : {estShipDate}

\r\n )\r\n ) : (\r\n

{atpResponse?.ATPLeadTimePropertiesQuantityResponseEntityList[0]?.Message}

\r\n )}\r\n
\r\n );\r\n } else {\r\n if (isLoadingAtpResponse) {\r\n return ;\r\n } else {\r\n if (atpResponse?.ATPLeadTimePropertiesQuantityResponseEntityList.length === 1) {\r\n if (atpResponse?.ATPLeadTimePropertiesQuantityResponseEntityList[0]?.ATPDate !== '0') {\r\n return

Estimated Shipping Date : {estShipDate}

;\r\n } else {\r\n return

{atpResponse?.ATPLeadTimePropertiesQuantityResponseEntityList[0]?.Message}

;\r\n }\r\n } else {\r\n if (atpResponse?.HighestDate !== undefined) {\r\n return

Estimated Shipping Date : {atpHighestDate}

;\r\n } else {\r\n return

{atpResponse?.ATPLeadTimePropertiesQuantityResponseEntityList[0]?.Message}

;\r\n }\r\n }\r\n }\r\n }\r\n};\r\n\r\nexport default ATPESDMessageComponent;\r\n","import React from 'react';\r\nimport { Button } from 'reactstrap';\r\n// import { IKRV_ATPLeadTimePropertiesQuantity } from '../../actions/customProxy/ATP/DataServiceEntities.g';\r\n// import { CalculateEstDateAtpInput, estimatedAvailabilityAction } from '../../actions/calculate-est-date-atp.action';\r\nimport ATPESDMessageComponent from './atpESDMessage';\r\nimport { kRV_GetATPLeadTimeWithQuantityAsync } from '../../actions/customProxy/ATP1/DataActionExtension.g';\r\nimport { IKRV_GetATPLeadTimeResponseQuantity } from '../../actions/customProxy/ATP1/DataServiceEntities.g';\r\n\r\nconst EstimatedShipDateKitComponent: React.FC = ({\r\n linkedProducts,\r\n itemNumber,\r\n propMax,\r\n context,\r\n trafficLightsResponse,\r\n anyChildWithRedLight\r\n}) => {\r\n const [quanATP, setQuanAtp] = React.useState();\r\n const [isLoadingAtpResponse, setIsLoadingAtpResponse] = React.useState(false);\r\n const [atpResponse, setAtpResponse] = React.useState();\r\n const [isCalculateBtnDisable, setIsCalculateBtnDisable] = React.useState(false);\r\n\r\n React.useEffect(() => {\r\n quanATP! < 1 ? setIsCalculateBtnDisable(true) : setIsCalculateBtnDisable(false);\r\n if (quanATP! > propMax && trafficLightsResponse?.StatusCode === '500') {\r\n setQuanAtp(propMax);\r\n } else if (quanATP! > propMax && trafficLightsResponse?.StatusCode === '502') {\r\n setQuanAtp(propMax);\r\n } else if (quanATP! > propMax && trafficLightsResponse?.StatusCode === '501') {\r\n setQuanAtp(propMax);\r\n } else if (quanATP! > propMax && trafficLightsResponse?.StatusCode === '503') {\r\n // eslint-disable-next-line @typescript-eslint/restrict-plus-operands\r\n setQuanAtp(trafficLightsResponse?.Quantity + trafficLightsResponse.POQuantity);\r\n }\r\n }, [quanATP]);\r\n\r\n async function buttonATPCalculationDataActionCall() {\r\n setIsLoadingAtpResponse(true);\r\n try {\r\n //gathering all the child products payload\r\n const KRVATPLeadTimeChildsQuantity: any[] = linkedProducts.map((item: any) => {\r\n return {\r\n itemID: item.ItemId,\r\n Qty: String(item.Quantity * quanATP!)\r\n };\r\n });\r\n\r\n const context1 = { callerContext: context.actionContext };\r\n await kRV_GetATPLeadTimeWithQuantityAsync(context1, KRVATPLeadTimeChildsQuantity).then(res => {\r\n setAtpResponse(res);\r\n setIsLoadingAtpResponse(false);\r\n });\r\n } catch (error) {\r\n const errorBody: any = {\r\n Id: 0,\r\n ATPDate: '0',\r\n Message: 'Unable to get response for Estimated Availability',\r\n ExtensionProperties: []\r\n };\r\n setAtpResponse(errorBody);\r\n setIsLoadingAtpResponse(false);\r\n }\r\n }\r\n const handleCalculateATPDate = () => {\r\n if (itemNumber && quanATP) {\r\n void buttonATPCalculationDataActionCall();\r\n }\r\n };\r\n //These symbols are not be typed on input box\r\n const exceptThisSymbols = ['e', 'E', '+', '-', '.'];\r\n\r\n return (\r\n <>\r\n
\r\n \r\n {\r\n setQuanAtp(e.target.value);\r\n }}\r\n onKeyDown={e => exceptThisSymbols.includes(e.key) && e.preventDefault()}\r\n />\r\n \r\n Calculate Shipping Date\r\n \r\n
\r\n \r\n \r\n );\r\n};\r\n\r\nexport default EstimatedShipDateKitComponent;\r\n","import React, { PropsWithChildren } from 'react';\r\nimport { IBuyboxData, IBuyboxViewProps } from '@msdyn365-commerce-modules/buybox';\r\nimport { IQuickviewViewProps } from '@msdyn365-commerce-modules/buybox/src/modules/quickview/./quickview';\r\nimport { IBuyboxProps } from '../../themes/krannich/definition-extensions/buybox.ext.props.autogenerated';\r\nimport { ProductAvailableQuantity } from '@msdyn365-commerce/retail-proxy';\r\nimport { generateImageUrl } from '@msdyn365-commerce-modules/retail-actions';\r\nimport { ICartViewProps } from '../../modules/krannich-c-cart/krannich-c-cart';\r\ninterface CommercePropertyValue {\r\n BooleanValue?: boolean;\r\n ByteValue?: number;\r\n DateTimeOffsetValue?: Date;\r\n DecimalValue?: number;\r\n IntegerValue?: number;\r\n LongValue?: number;\r\n StringValue?: string;\r\n}\r\n\r\ninterface CommerceProperty {\r\n Key?: string;\r\n Value?: CommercePropertyValue;\r\n}\r\ninterface AttributeSwatch {\r\n SwatchValue?: string;\r\n SwatchImageUrl?: string;\r\n SwatchColorHexCode?: string;\r\n IsDefault?: boolean;\r\n ProductImageUrls?: string[];\r\n ExtensionProperties?: CommerceProperty[];\r\n}\r\ninterface AttributeValue {\r\n Name?: string;\r\n KeyName?: string;\r\n UnitOfMeasureSymbol?: string;\r\n DataTypeValue?: number;\r\n BooleanValue?: boolean;\r\n DateTimeOffsetValue?: Date;\r\n FloatValue?: number;\r\n IntegerValue?: number;\r\n TextValue?: string;\r\n CurrencyValue?: number;\r\n CurrencyCode?: string;\r\n AttributeValueId?: number;\r\n RecordId?: number;\r\n Swatches?: AttributeSwatch[];\r\n ExtensionProperties?: CommerceProperty[];\r\n}\r\ninterface customAttribute {\r\n attributevalues?: AttributeValue[];\r\n}\r\nexport const KitProduct = ({\r\n linkedProducts,\r\n props\r\n}: {\r\n linkedProducts: any[] | undefined;\r\n props:\r\n | PropsWithChildren & ProductAvailableQuantity>\r\n | (IQuickviewViewProps & customAttribute)\r\n | ICartViewProps;\r\n}) => {\r\n return (\r\n
\r\n
\r\n

Bundle Contains

\r\n {linkedProducts?.length.toString()} Items\r\n
\r\n
\r\n {linkedProducts &&\r\n linkedProducts?.map((e: any, index: number) => {\r\n return (\r\n
\r\n
\r\n \r\n
\r\n
\r\n

{e.Name!}

\r\n
\r\n
\r\n
\r\n {'Item number: '}\r\n {e.ItemId!}\r\n
\r\n {/*
\r\n {'Price:'} \r\n \r\n {props.context.cultureFormatter.formatCurrency(Number(e.Product?.Price!))}\r\n \r\n
*/}\r\n
\r\n {'Quantity: '}\r\n {e.Quantity!}\r\n
\r\n
\r\n
\r\n
\r\n
\r\n );\r\n })}\r\n
\r\n
\r\n );\r\n};\r\n","import React from 'react';\r\nimport { IKRV_ATPLeadTimePropertiesDate } from '../actions/customProxy/ATP-update/DataServiceEntities.g';\r\nimport { dateFormatByLocale } from './helper';\r\n\r\ninterface ITrafficLight {\r\n lightColor?: string;\r\n isVisible?: string;\r\n}\r\n\r\ninterface IKRV_ATPLeadTimePropertiesDateFormat extends IKRV_ATPLeadTimePropertiesDate {\r\n locale?: string;\r\n currency?: string;\r\n}\r\n\r\nexport const TrafficLights: React.FC = ({ lightColor, isVisible }) => (\r\n
\r\n
\r\n
\r\n);\r\n\r\nexport const ATPMessage: React.FC = props => {\r\n /* VSI CUSTOMIZATION | DATE FORMAT | START */\r\n let PurchaseLeadTimeDate = props.PurchaseLeadTimeDate;\r\n if (props.currency && props.locale && PurchaseLeadTimeDate) {\r\n PurchaseLeadTimeDate = dateFormatByLocale(props.locale, props.currency, PurchaseLeadTimeDate);\r\n }\r\n let PODate = props.PODate;\r\n if (props.currency && props.locale && PODate) {\r\n PODate = dateFormatByLocale(props.locale, props.currency, PODate);\r\n }\r\n /* VSI CUSTOMIZATION | DATE FORMAT | END */\r\n let atpMessage = '';\r\n if (props.IsVisible === 'No') {\r\n atpMessage = 'no further supplies';\r\n } else if (props.IsDiscontinuedProduct === 'Yes') {\r\n atpMessage = props?.Message!.toLowerCase();\r\n } else if (PurchaseLeadTimeDate !== '' && props.Quantity === 0 && props.POQuantity === 0) {\r\n atpMessage = `${props.Quantity} in stock, more from ${PurchaseLeadTimeDate}`;\r\n } else if (PurchaseLeadTimeDate === '' && props.Quantity === 0 && props.POQuantity > 0) {\r\n atpMessage = `${props.Quantity} in stock, more from ${PODate}`;\r\n } else if (PurchaseLeadTimeDate !== '' && props.Quantity > 0 && props.POQuantity === 0) {\r\n atpMessage = `${props.Quantity} in stock, more from ${PurchaseLeadTimeDate}`;\r\n } else if (PurchaseLeadTimeDate === '' && props.Quantity > 0 && props.POQuantity > 0) {\r\n atpMessage = `${props.Quantity} in stock, more from ${PODate}`;\r\n } else if (PurchaseLeadTimeDate === '' && props.Quantity >= 0 && props.POQuantity === 0) {\r\n atpMessage = props?.Message ? `${props.Quantity} in stock, ${props?.Message.toLowerCase()}` : `${props.Quantity} in stock`;\r\n }\r\n if (atpMessage !== '') {\r\n return (\r\n
\r\n

{atpMessage}

\r\n
\r\n );\r\n }\r\n return (\r\n
\r\n

\r\n

\r\n Information\r\n \r\n Error while fetching the data!!!\r\n

\r\n

\r\n
\r\n );\r\n};\r\n","import React from 'react';\r\nexport const PromotionBadges: React.FC = ({ promotionalBadge, context }) => {\r\n const { enableBadges, badges } = context?.actionContext?.requestContext?.app.config;\r\n const badgeUI = badges?.find((badge: { label: string }) => badge?.label?.trim() === promotionalBadge?.trim());\r\n const enabledForGuest = badgeUI?.enableForGuest || false;\r\n if (\r\n enableBadges &&\r\n (enabledForGuest || context?.actionContext?.requestContext?.user?.isAuthenticated) &&\r\n promotionalBadge?.length !== 0\r\n ) {\r\n return (\r\n \r\n {promotionalBadge}\r\n
\r\n );\r\n }\r\n return null;\r\n};\r\n"],"names":["KRV_ATPLeadTimePropertiesDateExtensionClass","constructor","odataObject","this","Id","parseInt","ATPDate","Quantity","parseFloat","Message","PODate","POQuantity","POMessage","PurchaseLeadTimeDate","PurchaseLeadTimeQuantity","PurchaseLeadTimeMessage","ItemStatusMessage","StatusCode","TrafficLight","ExtensionProperties","undefined","i","length","Number","className","substr","lastIndexOf","concat","EntityClasses","String","KRV_ATPLeadTimePropertiesQuantityResponseEntityExtensionClass","ItemId","KRV_GetATPLeadTimeResponseQuantityExtensionClass","ATPLeadTimePropertiesQuantityResponseEntityList","HighestDate","kRV_ATPQuery","id","key","DataServiceQuery","DataServiceEntities","kRV_GetATPLeadTimeWithQuantityAsync","context","kRVATPLeadTimeQuantity","request","createDataServiceRequestForOperation","bypassCache","returnEntity","KRVATPLeadTimeQuantity","createKRV_GetATPLeadTimeWithQuantityInput","callActionOrExecute","callerContext","GetAddressPurposesInput","apiSettings","getCacheKey","buildCacheKey","getCacheObjectType","dataCacheType","async","getAddressPurposesAction","input","ctx","getAddressPurposesAsync","queryResultSettings","QueryResultSettingsProxy","getPagingFromInputDataOrDefaultValue","createObservableDataAction","action","inputData","requestContext","GetStateProvincesInput","countryRegionId","getStateProvinceAction","getStateProvincesAsync","AddressCommon","resources","telemetry","getDefaultCountryRegionId","countryRegions","market","marketISOCode","currentCountryRegion","find","countryRegion","ISOCode","CountryRegionId","parseRetailException","errorTitle","addressErrorMessageTitle","errorMessage","addressGenericErrorMessage","isAuthenticatedFlow","user","isAuthenticated","getStateProvinces","response","actionContext","error","debug","Promise","resolve","isEmpty","address","ThreeLetterISORegionName","State","City","addCustomerAddress","updateLogisticsLocationRoleRecordId","submitCustomerAddress","addAddress","updateCustomerAddress","updateAddress","updateCustomerPrimaryAddress","updatePrimaryAddress","addressAction","AddressTypeValue","AddressManagementInput","execAddressAction","addresses","RecordId","customerAddresses","addressPurposes","ArrayExtensions","hasElements","addressPurpose","purpose","AddressType","LogisticsLocationRoleRecordId","AddressItemDisplayType","AddressValidationRuleType","AddressItemType","AddressFormat","countryRegionsInfo","addressMetaData","getPrefilledAddressDropdownData","stateDefaultSelectionText","stateProvinceInfo","defaultStateText","value","dropdownData","getCountryFormat","getStateFormat","unshift","getAddressTypeFormat","getTwoLetterISORegionName","_getCountryRegionInfo","validateAddressFormat","validationError","propertyName","validationtor","isValid","getAddressFormat","forEach","addressFormatItem","name","_inputValidation","getTranformedAddress","result","postalCode","ZipCode","selectedState","state","StateName","adminDistrict","StateId","addressLine","Street","locality","district","DistrictName","CountyName","FullAddress","formattedAddress","_validateRegEx","validationRule","regEx","RegExp","test","get","countryRegionInfo","_getAddressDisplayFormat","map","ShortName","Name","set","validationRules","message","toLowerCase","addressDisplayItem","AddressFormatLines","AddressTypeItem","_extendAddressDisplayFormat","push","nameDisplayItem","formatLine","AddressComponentNameValue","addressItem","getItemFormat","isNewLine","NewLine","phoneDisplayItem","Phone","isPrimaryDisplayItem","IsPrimary","type","AddressMetaData","excluded","required","metaData","requiredFieldRegEx","resourcesPrefix","maxLength","excludedTypes","requiredFields","_init","item","_addItem","Input","PhoneRegex","defaultRegex","County","Dropdown","StreetNumber","BuildingCompliment","Postbox","House_RU","Flat_RU","CountryOKSMCode_RU","Checkbox","displayType","format","includes","nameKey","replace","_validationRules","isRequired","some","rule","Required","optionalString","label","ruleType","Object","keys","itemType","_validationRule","Format","AddressOperation","props","React","role","itemId","isChecked","additionalAddributes","telemetryContent","autoFocus","shouldBeAutoFocused","onChange","payLoad","getPayloadObject","attributes","getTelemetryAttributes","assign","checked","displayData","getDropdownItem","selectedValue","isSelected","text","htmlFor","getRequriedAttribute","getAddessItems","selectedAddress","addressFormat","addressType","dropdownDisplayData","defaultCountryRegionId","defaultAddressType","onInputChange","onDropdownChange","shouldAutoFocus","usSiteFlag","mexicoSiteFlag","index","_selectedAddress$addr","elementId","classname","AddressInputComponent","AdressCheckboxComponent","AdressDropdownComponent","zipcodeError","postcodeError","AddressItem","AddressLabelComponent","customLabel","alert","AddressAlertComponent","customAlert","returnAddressAlertComponent","AddressName","AddressAddUpdate","editAddressHeading","addAddressHeading","hasError","onCancel","onSave","hasExternalSubmitGroup","isUpdating","addressActionResponse","heading","AddressForm","Heading","items","isShowSaveButton","saveButton","AddressButtonComponent","addressSaveButtonText","ariaLabel","addressSaveButtonAriaLabel","disabled","onClick","isShowCancelButton","cancelButton","addressCancelButtonText","addressCancelButtonAriaLabel","AddressError","title","AddressErrorTitleComponent","AddressErrorMessageComponent","isDisabled","shouldUseAutoFocus","numberValue","customMaxLength","rawPhoneNumber","formattedPhoneNumber","_formattedPhoneNumber","_formattedPhoneNumber2","_formattedPhoneNumber3","_formattedPhoneNumber4","substring","split","join","slice","tempValue","placeholder","BusinessAccountAddress","super","excludedList","_resetAddressFields","addUpdateAddress","_dataInitialize","data","reaction","_data$countryRegions$","_data$addressPurposes","countryStates","_data$countryStates$r","_renderAddOrUpdateAddress","_this$props","_this$props2","oun","app","config","ounNumberForUsSite","ounNumberForMexicoSite","Company","addressStateDefaultSelectionText","_onAddressAddUpdateInputChange","_onAddressAddUpdateDropdownChange","event","_updateAddress","target","_updateCountryRegionId","_this$props3","_this$props4","updateForm","cleanValue","_isEmpty","_objectSpread","_isInputRequired","addressItemValue","ObjectExtensions","isNullOrUndefined","addressCommon","then","getTelemetryObject","telemetryPageName","friendlyName","componentDidMount","_setDefaultCountryRegionId","shouldComponentUpdate","nextProps","nextState","render","_this$props5","_this$props6","renderView","resetAddress","moduleProps","classnames","showAddOrUpdateAddress","_request$channel","channel","ChannelCountryRegionISOCode","__decorate","observable","_ref","Node","Module","_renderTextBlock","textBlocks","_renderAddToOrderTemplate","addToOrderTemplate","ContainerProps","errorBlock","button","_renderSocialShare","socialShare","_renderConfigure","configure","dropdowns","_renderConfigureDropdown","dropdown","LabelContainerProps","errors","select","_renderFindInStore","findInStore","storeSelector","description","modal","productPickupOptionList","onChangeHandler","callbacks","newValue","updateQuantity","_renderKeyInPrice","keyInPrice","_renderShopSimilarItem","shopSimilarItem","getBuyboxProductPrice","_props$data$customerI4","_props$data$featureSt","_props$data$featureSt2","_props$data$featureSt3","typeName","customerTaxPercentage","taxPercentage","customerInformation","productPrice","PriceComponent","price","isPriceMinMaxEnabled","featureState","IsEnabled","isSalesAgreementPriceFeatureEnabled","useLegacySalesAgreementHTMLFeature","priceResources","priceRangeSeparator","salesAgreementPricePrompt","salesAgreementExpirationDatePrompt","salesAgreementCommittedQuantityPrompt","salesAgreementRemainingQuantityPrompt","freePriceText","priceFree","originalPriceText","currentPriceText","isIncExPriceFormatEnabled","_props$data$product$r","_props$data$product$r2","_props$data$cart$resu4","_props$context$reques","_props$config$request","ModuleProps","MediaGalleryContainerProps","ProductInfoContainerProps","addToCart","quantity","rating","inventoryLabel","shopSimilarLook","quantityLimitsMessages","max","shopSimilarDescription","unitOfMeasure","productComparisonButton","Auth","minErrorMessage","maxErrorMessage","promotionalTextEnable","promotionalTextColor","zeroPriceProductText","channelId","catalogId","linkedProducts","product","Components","producerName","setProducerName","producerKeyName","setProducerKeyName","manufacturerItemNumber","setManufacturerItemNumber","itemNumber","setItemNumber","isMax","setIsMax","isMin","setIsMin","isMaxPop","setIsMaxPop","showMore","setShowMore","isClassName","setIsClassName","setAttributes","disountedWpPrice","setDiscountedwpPrice","productName","setProductName","promotionalText","setPromotionalText","importantNotice","setimportantNotice","longDescription","setlongDescription","disableAddToCartATP","setDisableAddToCartATP","extensionsProps","promotionBadge","_extensionsProps$find","e","Key","Value","StringValue","atpData","setAtpData","kitProductATP","setKitProductATP","isKitProductATPDiscontinued","setIsKitProductATPDiscontinued","productAttributes","filteredProductAttributeList","kcProductAttribute","kitProductATPCall","KRVATPLeadTimeDate","objectDate","Date","requestedDate","getDate","getMonth","getFullYear","products","itemID","kRV_GetMultipleATPLeadTimeDateAsync","err","console","_atpData","_atpData$","anyRed","ATPTrafficLights","filter","isLoading","setIsLoading","trafficLightsResponse","settrafficLightsResponse","propMax","setPropMax","maxESD","setMaxESD","day","_trafficLightsRespons","toLocaleLowerCase","noFurtherSuppliesText","_props$data$cart$resu","productOfInterestQuantity","cart","CartLines","_props$data$cart$resu2","_props$data$cart$resu3","requestBody","trafficLightsParams","TrafficLightsAtpInput","trafficLightsSlots","trafficLightsAtpaction","warning","trafficLightsDataActionCall","_props$data$product$r3","recordId","getAttributeValuesAsync","findAttributesValues","setPromotionalTextFunction","_props$data$product$r4","_props$data$product$r5","Behavior","MinimumQuantity","identifier","TextValue","findItemNumber","calculateWpPrice","findProductName","findManufacturerItemNumber","findImportantNotice","findlongDescription","_props$data$product","_props$data$product$r6","_props$data$product$r7","_props$data$product$r8","_e$Key","_e$Value","_props$data$product$r9","_e$Value2","_props$data$product$r10","_e$Value3","_props$data$productPr","_props$data$productPr2","tempBasePrice","tempDiscountedPrice","displayWpPrice","basePrice","CustomerContextualPrice","discountedPrice","IntegerValue","KeyName","BooleanValue","imgURI","setImgURL","producerGlobalName","globalProducerName","_e$ExtensionPropertie","manufactuerValueforImage","eProperty","_imageUrl","imageUrl","generateImageUrl","_renderPrice","_props$context","_props$data$customerI","_customerInformation$","customClass","enabledIncExPrices","ppwPrice","isRequestPrice","LineDiscountGroup","requestPriceText","tabIndex","incExcPriceFormat","isDisableLink","setIsDisableLink","Modal","wrapClassName","fade","applicationNode","isOpen","toggle","ModalHeader","alertText","ModalBody","maxPurchaseAlertMessage","descriptionText","PromotionBadges","promotionalBadge","mediaGallery","src","alt","_renderCategoryImg","showMoreText","_text$props","children","_text$props2","_text$props3","itemNumberText","manufacturerItemNumberText","style","color","RichTextComponent","KitProduct","bulkPurchaseLink","slots","Waiting","TrafficLights","lightColor","isVisible","IsVisible","callOfficeText","ATPMessage","locale","dateFormat","currency","Currency","EstimatedShipDateKitComponent","anyChildWithRedLight","EstimatedShipDateComponent","quantityText","_renderQuantity","quantityComponent","extentionResources","min","IncrementalQuantity","currentCount","inputQuantityAriaLabel","decrementButtonAriaLabel","incrementButtonAriaLabel","minQuantityText","maxQuantityText","IsDiscontinuedProduct","IsAddToCart","informationHeading","maxQuantityAlertMessage","_renderAddToCart","_props$data","_props$data$customerI2","_props$data2","_props$data$customerI3","customAddBundleToCartButton","addToCartText","customAddToCartButton","isStatusTwoZeroFour","addBundleToCartText","requestPriceButton","linkText","href","linkUrl","destinationUrl","productInfoHeading","getText","getOriginalPrice","_props$data$price$Bas","_props$data$price$Tra","_props$data$price$Adj","Math","BasePrice","TradeAgreementPrice","AdjustedPrice","formatCurrency","shouldUseFreePriceText","currencyCode","cultureFormatter","renderCurrentPrice","_props$data$price3","maxVariantPrice","MaxVariantPrice","minVariantPrice","MinVariantPrice","_props$priceResources","itemProp","wpPrice","SalesAgreementPrice","_toggle","bind","_this$props$data$pric","_this$props$data$pric2","_this$props$data$pric3","_this$props$priceReso","_this$props$priceReso2","_this$props$priceReso3","_this$props$priceReso4","_this$props$priceReso5","_this$props$priceReso6","_this$props$priceReso7","firstPriceLine","AttainablePriceLines","salesAgreementDetailCollapseProps","Collapse","formatDate","EffectiveDate","ExpirationDate","CommittedQuantity","RemainingQuantity","preventDefault","setState","msdyn365Commerce","createComponentOverride","component","_props$data$price4","salesAgreementPrice","_props$data$price$Sal","_props$priceResources8","_props$priceResources9","isExpanded","setIsExpanded","Button","_props$data$price$Att","_props$priceResources2","_props$priceResources3","_props$priceResources4","_props$priceResources5","_props$priceResources6","_props$priceResources7","renderSalesAgreementDetail","_props$data$price","originalPrice","_props$data$price2","showStrikethroughPricing","initialPrice","savingsText","renderCurrentPriceWithOriginalPrice","OrderDetailsSalesLine","salesLineProps","salesLine","buyAgainButton","OrderDetailsGroupDelivery","_ref2","deliveryProps","count","statusValue","getOrderStatus","OrderDetailsGroup","_ref3","_context$app","_context$actionContex","_context$request$chan","group","salesId","createdDate","customer","groupProps","delivery","salesLinesProps","salesLines","productWeightAttribute","isMobile","setIsMobile","buyAgainModal","setBuyAgainModal","attributeValues","setAttributeValues","prodAttrIdentifier","setProdAttrIdentifier","messageForBuyAgainPopUp","setMessageForBuyAgainPopUp","_updateViewport","viewport","_getViewport","device","Type","MsDyn365","isBrowser","window","innerWidth","gridSettings","xs","w","sm","md","lg","addEventListener","prodAttributeIdentifier","res","_salesLine$data$produ","_context$request","_context$request2","_salesLine$data$produ2","productAttributesFiltered","manufacturer","recId","fetchData","createdDateJSXProps","customDate","dateParts","formattedDateString","toLocaleDateString","dateLocale","formattedDateStringBylocale","dateFormatByLocale","cartUrl","getUrlSync","context1","saleline","_saleline$data$salesL","catch","buyAgainMethod","isProductsAvailable","isPriceDiffers","productsWithChangedPrices","productsToAddInCart","salesData","_saleline$data$salesL2","_saleline$data$salesL3","_saleline$data$produc","_saleline$data$produc2","Price","salesline","recordIds","salesOrderPrices","activePrices","_customer$result$Acco","_customer$result","getActivePricesAsync","ChannelId","CatalogId","AccountNumber","_getActivePrices","activePriceLookup","reduce","acc","_item$price","toFixed","differingItemIds","_item$price2","processProducts","currentAtpItem","obj","jsonObject","JSON","parse","JsonResponseObject","_await$cart","cartLines","currentProductInCart","currentProductInCartQuantity","all","_await$cart2","addProductsToCart","status","_result$errorDetails","_result$validationRes","_result$errorDetails2","containsPhrase","errorDetails","LocalizedMessage","containsPhraseValidationError","validationResults","toggleBuyagainModalPopUp","ModalFooter","_salesLine$data","_salesLine$data2","_salesLine$data$produ3","_manufacturerObj$manu","_manufItemTypeNameObj","_context$actionContex2","_salesLine$data4","_salesLine$data5","_salesLine$data$produ4","_salesLine$data$produ5","_salesLine$data$produ6","_salesLine$data6","salesLineAttr","AttributeValues","productAttrManufactrValue","productAttrWeightValue","lineTotal","GrossAmount","DiscountAmount","manufItemTypeNameObj","manufacturerObj","_salesLine$data3","urlPath","formatUrlPath","pathName","url","requestUrl","pathname","isAddingPathWithUrl","addPathWithUrl","productUrl","origin","buyAgainButtonCloned","buyAgain","documentedDateTabelHeaderLabel","salesIDHeaderLabel","weightTabelHeaderLabel","manufacturerHeaderLabel","productTabelHeaderLabel","productNumberTabelHeaderLabel","quantityTabelHeaderLabel","netAmountTabelHeaderLabel","currencyFormat","grossAmountTabelHeaderLabel","TotalAmount","currencyTabelHeaderLabel","fulfilledTabelHeaderLabel","SalesStatusValue","orderStateLabel","actionTabelHeaderLabel","_salesLine$data7","_salesLine$data8","_salesLine$data$produ7","_manufacturerObj$manu2","_manufacturerObj$manu3","_manufItemTypeNameObj2","_manufItemTypeNameObj3","_context$actionContex3","_salesLine$data10","_salesLine$data11","_salesLine$data$produ8","_salesLine$data$produ9","_salesLine$data$produ10","_salesLine$data12","_salesLine$data9","showTimeslot","pickupProps","pickupDateTimeslot","OrderDetailsGroups","_ref4","groupsProps","groups","OrderDetailsOrderSummary","_ref5","orderSummaryProps","subtotal","shipping","tax","totalAmount","earnedPoints","discountAmount","deliveryMode","chargeAmount","subTotalJSXValue","subTotalAmount","taxValue","totalAmountValue","paymentSummaryText","subTotalText","shippingFeeText","freeText","toBeCalculatedText","excludingFreightCostMessage","OrderDetailsPayment","_ref6","paymentMethodsProps","methods","OrderDetailsHelp","_ref7","helpProps","needHelpLabel","helpLineNumberLabel","contactNumber","_ref8","_result$salesOrder","_result$salesOrder2","_bannerLink$linkUrl","viewModes","tableViewActions","table","placedBy","loading","orderInfomation","orderSummary","bannerImage","bannerLink","orderHydration","salesOrder","imageProps","imageSettings","contentBlockImage","Msdyn365","viewports","q","h","lazyload","editProps","imagePropertyName","layout","msdyn365__moduleLayout","shouldSkipToMainImage","orderPlacedBy","StatusValue","DeliveryMode","ChargeAmount","openInNewTab","QuickViewFunctionalComponent","quickView","quickViewButton","isModalOpen","isMobileDevice","isUserAuth","isProductDiscontinued","setIsProductDiscontinued","isAddToCartDisabled","setIsAddToCartDisabled","twoZeroFourProdMax","setTwoZeroFourProdMax","attributevalues","_props$productDetails","_props$productDetails2","_props$productDetails3","_props$productDetails4","_props$productDetails5","productDetails","addBundleToCartButtonLabel","addToCartbuttonLabel","_props$productDetails6","_props$productDetails7","customInput","disable","maxQuantityMessage","RenderBodyContent","_props$productDetails11","_productDetails$produ2","_cart$result4","_linkedProducts3","_linkedProducts4","_linkedProducts5","_linkedProducts6","_linkedProducts7","_props$productDetails12","_linkedProducts8","_linkedProducts9","_props$productDetails13","_props$data$customerI5","_linkedProducts10","CarouselProps","buyBoxProps","_productDetails$produ","_linkedProducts","_linkedProducts2","_cart$result","_cart$result2","_cart$result3","_CarouselProps$items$","itemNnLabel","renderItemNumber","_props$productDetails8","contactSalesOfficeMessage","quantityLabel","requestPriceLabel","cantAddContactSalesOfficeMessage","forBundleLabel","_props$attributevalue","discountedWpPrice","displayValue","_props$productDetails9","_props$productDetails10","wpPriceLabel","ppwPriceLabel","isFinite","ModalContainer","ModalHeaderContainer","ModalFooterContainer","ModalHeaderContent","ModalBodyContainer","addToWishlist","cartContainerProps","_renderAddToWishlist","_renderQuickViewPopup","_props$data$customerI6","quanATP","setQuanAtp","isLoadingAtpResponse","setIsLoadingAtpResponse","atpResponse","setAtpResponse","isCalculateBtnDisable","setIsCalculateBtnDisable","isMaxExceeded","setIsMaxExceeded","IsCalShipping","setTimeout","exceptThisSymbols","onKeyDown","handleCalculateATPDate","Qty","buttonATPCalculationDataActionCall","ATPESDMessageComponent","_atpResponse$ATPLeadT","_context$request$chan3","estShipDate","atpHighestDate","_dateFormatByLocale","_context$request$chan2","_atpResponse$ATPLeadT2","_dateFormatByLocale2","_context$request$chan4","_atpResponse$ATPLeadT3","_atpResponse$ATPLeadT4","_atpResponse$ATPLeadT5","_atpResponse$ATPLeadT6","_atpResponse$ATPLeadT7","_atpResponse$ATPLeadT8","_atpResponse$ATPLeadT9","_atpResponse$ATPLeadT10","_atpResponse$ATPLeadT11","_atpResponse$ATPLeadT12","_atpResponse$ATPLeadT13","toString","KRVATPLeadTimeChildsQuantity","_e$Product","Product","PrimaryImageUrl","trim","atpMessage","enableBadges","badges","badgeUI","badge","_badge$label","enabledForGuest","enableForGuest","background","bgColor","fontColor"],"sourceRoot":""}