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,gCAlC4BC,EAACC,EAAqBC,KAUlD,GADAjB,EAAQE,YAAYc,GAAuBC,GACtCjB,EAAQE,YAAYc,GAAqBE,QAC1C,MAAM,IAAIC,MAAM,oBAAsBH,EAAsB,mCAEhEhB,EAAQE,YAAYc,GAAqBE,QAAQE,UAAUC,eAAiBL,EACxEhB,EAAQE,YAAYc,GAAqBE,QAAQE,UAAUE,KAC3DtB,EAAQE,YAAYF,EAAQE,YAAYc,GAAqBE,QAAQE,UAAUE,IAAMN,IA0BzFD,CAF4B,kEACXX,EAAQ,KAMjC7F,OAAOgH,aAAehH,OAAOgH,cAAgB,GAC7ChH,OAAOgH,aAAatB,QAAOrE,EAAAA,EAAA,GACpBrB,OAAOgH,aAAatB,SAAW,IAC/BD,EAAQC,SAGX1F,OAAOgH,aAAarB,YAAWtE,EAAAA,EAAA,GAC5BrB,OAAOgH,aAAarB,aAAe,IACnCF,EAAQE,aAEY,MAAMsB,EAAiB,GAC9BA,EAAe,iEAAmE,CAC1FrB,EAAGA,IAAMC,EAAQ,MACjBqB,GAAI,wCAEpBlH,OAAOgH,aAAehH,OAAOgH,cAAgB,GAC7ChH,OAAOgH,aAAaC,eAAc5F,EAAAA,EAAA,GACPrB,OAAOgH,aAAaC,gBAAkB,IACtCA,UCnF3BE,EAAOC,QAAUjJ,cCAjBgJ,EAAOC,QAAUC","sources":["webpack://Msdyn365.Commerce.Online/./src/actions/DataServiceEntities.g.ts?6c17","webpack://Msdyn365.Commerce.Online/./src/actions/DataActionExtension.g.ts?ff78","webpack://Msdyn365.Commerce.Online/./src/modules/britax-subscribe/mocks/utils/britax-onlick-arrow.tsx?1afd","webpack://Msdyn365.Commerce.Online/./src/modules/britax-subscribe/britax-subscribe.tsx?0519","webpack://Msdyn365.Commerce.Online/./src/modules/britax-subscribe/britax-subscribe.view.tsx?baab","webpack://Msdyn365.Commerce.Online/./lib/britax-subscribe/module-registration.js?b5c5","webpack://Msdyn365.Commerce.Online/external var \"React\"?0d3b","webpack://Msdyn365.Commerce.Online/external var \"ReactDOM\"?853b"],"sourcesContent":["// @ts-ignore -- Unused import\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// @ts-ignore -- Unused import\r\nimport { jsonLightReadStringPropertyValue } from '@msdyn365-commerce/retail-proxy/dist/externals';\r\n\r\n/**\r\n * FUSCustomEntity entity interface.\r\n */\r\nexport interface IFUSCustomEntity {\r\n RequestId: string;\r\n ExtensionProperties?: Entities.CommerceProperty[];\r\n}\r\n\r\n/**\r\n * RegistratonDataEntity entity interface.\r\n */\r\nexport interface IRegistratonDataEntity {\r\n ID: number;\r\n FName?: string;\r\n LName?: string;\r\n Email?: string;\r\n Phone?: string;\r\n ProductType?: string;\r\n ProductName?: string;\r\n StoreName?: string;\r\n PurchDate?: string;\r\n MDate?: string;\r\n ItemId?: string;\r\n CustAccount?: string;\r\n BatchId?: string;\r\n SerialId?: string;\r\n ReOrderCode?: string;\r\n Send: boolean;\r\n DataAreaId?: string;\r\n ExtensionProperties?: Entities.CommerceProperty[];\r\n}\r\n\r\n/**\r\n * SubscriptionDataEntity entity interface.\r\n */\r\nexport interface ISubscriptionDataEntity {\r\n ID: number;\r\n Email?: string;\r\n CustAccount?: string;\r\n Send: boolean;\r\n DataAreaId?: string;\r\n ExtensionProperties?: Entities.CommerceProperty[];\r\n}\r\n\r\n/**\r\n * FUSCustomEntity entity class.\r\n */\r\nexport class FUSCustomEntityExtensionClass implements IFUSCustomEntity {\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n public RequestId: 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.RequestId = odataObject.RequestId;\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[i]) {\r\n if (odataObject.ExtensionProperties[i]['@odata.type']) {\r\n var className: string = odataObject.ExtensionProperties[i]['@odata.type'];\r\n className = className.substr(className.lastIndexOf('.') + 1).concat('Class');\r\n if (EntityClasses[className]) {\r\n this.ExtensionProperties[i] = new EntityClasses[className](odataObject.ExtensionProperties[i]);\r\n }\r\n } else {\r\n this.ExtensionProperties[i] = new EntityClasses.CommercePropertyClass(odataObject.ExtensionProperties[i]);\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[i] = undefined;\r\n }\r\n }\r\n }\r\n }\r\n}\r\n\r\n/**\r\n * RegistratonDataEntity entity class.\r\n */\r\nexport class RegistratonDataEntityExtensionClass implements IRegistratonDataEntity {\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 FName: 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 LName: 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 Email: 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 Phone: 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 ProductType: 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 ProductName: 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 StoreName: 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 PurchDate: 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 MDate: 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 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 CustAccount: 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 BatchId: 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 SerialId: 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 ReOrderCode: 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 Send: boolean;\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 DataAreaId: 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;\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.FName = odataObject.FName;\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.LName = odataObject.LName;\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.Email = odataObject.Email;\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.Phone = odataObject.Phone;\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.ProductType = odataObject.ProductType;\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.ProductName = odataObject.ProductName;\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.StoreName = odataObject.StoreName;\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.PurchDate = odataObject.PurchDate;\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.MDate = odataObject.MDate;\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.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.CustAccount = odataObject.CustAccount;\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.BatchId = odataObject.BatchId;\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.SerialId = odataObject.SerialId;\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.ReOrderCode = odataObject.ReOrderCode;\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.Send = odataObject.Send;\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.DataAreaId = odataObject.DataAreaId;\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[i]) {\r\n if (odataObject.ExtensionProperties[i]['@odata.type']) {\r\n var className: string = odataObject.ExtensionProperties[i]['@odata.type'];\r\n className = className.substr(className.lastIndexOf('.') + 1).concat('Class');\r\n if (EntityClasses[className]) {\r\n this.ExtensionProperties[i] = new EntityClasses[className](odataObject.ExtensionProperties[i]);\r\n }\r\n } else {\r\n this.ExtensionProperties[i] = new EntityClasses.CommercePropertyClass(odataObject.ExtensionProperties[i]);\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[i] = undefined;\r\n }\r\n }\r\n }\r\n }\r\n}\r\n\r\n/**\r\n * SubscriptionDataEntity entity class.\r\n */\r\nexport class SubscriptionDataEntityExtensionClass implements ISubscriptionDataEntity {\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 Email: 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 CustAccount: 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 Send: boolean;\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 DataAreaId: 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;\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.Email = odataObject.Email;\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.CustAccount = odataObject.CustAccount;\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.Send = odataObject.Send;\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.DataAreaId = odataObject.DataAreaId;\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[i]) {\r\n if (odataObject.ExtensionProperties[i]['@odata.type']) {\r\n var className: string = odataObject.ExtensionProperties[i]['@odata.type'];\r\n className = className.substr(className.lastIndexOf('.') + 1).concat('Class');\r\n if (EntityClasses[className]) {\r\n this.ExtensionProperties[i] = new EntityClasses[className](odataObject.ExtensionProperties[i]);\r\n }\r\n } else {\r\n this.ExtensionProperties[i] = new EntityClasses.CommercePropertyClass(odataObject.ExtensionProperties[i]);\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[i] = undefined;\r\n }\r\n }\r\n }\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\nimport {\r\n AsyncResult,\r\n callActionOrExecute,\r\n DataServiceQuery,\r\n IContext,\r\n IDataServiceRequest,\r\n IQueryResultSettings,\r\n // @ts-ignore -- Unused import\r\n NullResult\r\n} from '@msdyn365-commerce/retail-proxy';\r\n// @ts-ignore -- Unused import\r\nimport * as EntityClasses from '@msdyn365-commerce/retail-proxy/dist/Entities/CommerceModels.g';\r\n// @ts-ignore -- Unused import\r\nimport * as Entities from '@msdyn365-commerce/retail-proxy/dist/Entities/CommerceTypes.g';\r\nimport * as DataServiceEntities from './DataServiceEntities.g';\r\n\r\n// @ts-ignore\r\nfunction customControllerQuery(requestId?: string): DataServiceQuery {\r\n const key = requestId ? { RequestId: requestId } : null;\r\n return new DataServiceQuery('CustomController', 'FUSCustomEntity', DataServiceEntities.FUSCustomEntityExtensionClass, key);\r\n}\r\n\r\nexport function createSendRegistratonDataInput(\r\n fName: string,\r\n lName: string,\r\n email: string,\r\n phone: string,\r\n productType: string,\r\n productName: string,\r\n storeName: string,\r\n purchDate: string,\r\n mDate: string,\r\n itemId: string,\r\n batchId: string,\r\n serialId: string,\r\n reOrderCode: string,\r\n custAccount: string\r\n): IDataServiceRequest {\r\n const query = customControllerQuery();\r\n return query.createDataServiceRequestForOperation(\r\n 'SendRegistratonData',\r\n true,\r\n '',\r\n 'false',\r\n { bypassCache: 'get', returnEntity: '' },\r\n {\r\n FName: fName,\r\n LName: lName,\r\n Email: email,\r\n Phone: phone,\r\n ProductType: productType,\r\n ProductName: productName,\r\n StoreName: storeName,\r\n PurchDate: purchDate,\r\n MDate: mDate,\r\n ItemId: itemId,\r\n BatchId: batchId,\r\n SerialId: serialId,\r\n ReOrderCode: reOrderCode,\r\n CustAccount: custAccount\r\n }\r\n );\r\n}\r\n\r\nexport function sendRegistratonDataAsync(\r\n context: IContext,\r\n fName: string,\r\n lName: string,\r\n email: string,\r\n phone: string,\r\n productType: string,\r\n productName: string,\r\n storeName: string,\r\n purchDate: string,\r\n mDate: string,\r\n itemId: string,\r\n batchId: string,\r\n serialId: string,\r\n reOrderCode: string,\r\n custAccount: string\r\n): AsyncResult {\r\n const request = createSendRegistratonDataInput(\r\n fName,\r\n lName,\r\n email,\r\n phone,\r\n productType,\r\n productName,\r\n storeName,\r\n purchDate,\r\n mDate,\r\n itemId,\r\n batchId,\r\n serialId,\r\n reOrderCode,\r\n custAccount\r\n );\r\n return callActionOrExecute(request, context.callerContext);\r\n}\r\n\r\nexport function createGetRegistratonDataInput(\r\n queryResultSettings: IQueryResultSettings,\r\n id: number,\r\n singleRecord: boolean\r\n): IDataServiceRequest {\r\n const query = customControllerQuery().resultSettings(queryResultSettings);\r\n return query.createDataServiceRequestForOperation(\r\n 'GetRegistratonData',\r\n true,\r\n DataServiceEntities.RegistratonDataEntityExtensionClass,\r\n 'true',\r\n { bypassCache: 'none', returnEntity: 'DataServiceEntities.IRegistratonDataEntity' },\r\n { Id: id, SingleRecord: singleRecord }\r\n );\r\n}\r\n\r\nexport function getRegistratonDataAsync(\r\n context: IContext,\r\n id: number,\r\n singleRecord: boolean\r\n): AsyncResult {\r\n const request = createGetRegistratonDataInput(context.queryResultSettings || {}, id, singleRecord);\r\n return callActionOrExecute(request, context.callerContext);\r\n}\r\n\r\nexport function createSendSubscriptionEmailInput(email: string, custAccount: string): IDataServiceRequest {\r\n const query = customControllerQuery();\r\n return query.createDataServiceRequestForOperation(\r\n 'SendSubscriptionEmail',\r\n true,\r\n '',\r\n 'false',\r\n { bypassCache: 'get', returnEntity: '' },\r\n { Email: email, CustAccount: custAccount }\r\n );\r\n}\r\n\r\nexport function sendSubscriptionEmailAsync(context: IContext, email: string, custAccount: string): AsyncResult {\r\n const request = createSendSubscriptionEmailInput(email, custAccount);\r\n return callActionOrExecute(request, context.callerContext);\r\n}\r\n\r\nexport function createGetSubscriptionDataInput(\r\n queryResultSettings: IQueryResultSettings,\r\n id: number,\r\n singleRecord: boolean\r\n): IDataServiceRequest {\r\n const query = customControllerQuery().resultSettings(queryResultSettings);\r\n return query.createDataServiceRequestForOperation(\r\n 'GetSubscriptionData',\r\n true,\r\n DataServiceEntities.SubscriptionDataEntityExtensionClass,\r\n 'true',\r\n { bypassCache: 'none', returnEntity: 'DataServiceEntities.ISubscriptionDataEntity' },\r\n { Id: id, SingleRecord: singleRecord }\r\n );\r\n}\r\n\r\nexport function getSubscriptionDataAsync(\r\n context: IContext,\r\n id: number,\r\n singleRecord: boolean\r\n): AsyncResult {\r\n const request = createGetSubscriptionDataInput(context.queryResultSettings || {}, id, singleRecord);\r\n return callActionOrExecute(request, context.callerContext);\r\n}\r\n","import React from 'react';\r\n\r\nconst ArrowIcon = ({ onClickArrow, iconClassnames }: { onClickArrow: () => void; iconClassnames: string }) => {\r\n return

;\r\n};\r\n\r\nexport { ArrowIcon };\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 * as Msdyn365 from '@msdyn365-commerce/core';\r\nimport { Button, IModuleProps, INodeProps, isMobile, VariantType, addThrottledEvent } from '@msdyn365-commerce-modules/utilities';\r\nimport * as React from 'react';\r\n\r\nimport { IBritaxSubscribeProps } from './britax-subscribe.props.autogenerated';\r\nimport { ArrowIcon } from './mocks/utils/britax-onlick-arrow';\r\nimport * as DataActionExtension from '../../actions/DataActionExtension.g';\r\nimport { IBritaxSubscribeData } from './britax-subscribe.data';\r\nimport { computed } from 'mobx';\r\ninterface errorState {\r\n email?: string | undefined;\r\n iconClassnames: string;\r\n message: string;\r\n isOnlyMobile: boolean;\r\n}\r\n\r\n/**\r\n * Subscribe view props.\r\n */\r\nexport interface ISubscribeViewProps extends IBritaxSubscribeProps {\r\n subscribe: IModuleProps;\r\n subscribeContainer: INodeProps;\r\n inputContainer: INodeProps;\r\n heading: React.ReactNode;\r\n text: React.ReactNode;\r\n submitButton?: INodeProps;\r\n submitButtonLabelText?: string;\r\n subscribeForm?: INodeProps;\r\n emailInput?: INodeProps;\r\n handleText(): void;\r\n ArrowIcon?: React.ReactNode;\r\n errorMessageNode?: React.ReactNode;\r\n isOnlyMobile: boolean;\r\n}\r\nexport interface ISubscribeViewPropsExtended extends IBritaxSubscribeProps {}\r\n\r\n/**\r\n * Subscribe component.\r\n * @extends {React.PureComponent>}\r\n */\r\nexport class Subscribe extends React.PureComponent, errorState> {\r\n private readonly _emailAddressInputRef: React.RefObject;\r\n private customResizeThrottledEventHandler?: (event: Event) => void;\r\n @computed public get isOnlyMobile(): boolean {\r\n return isMobile({ variant: VariantType.Browser, context: this.props.context.request }) === 'xs';\r\n }\r\n public componentDidMount(): void {\r\n this.customResizeThrottledEventHandler = addThrottledEvent(window, 'resize', this._customUpdateViewport as EventListener);\r\n this._customUpdateViewport();\r\n window.addEventListener('hashchange', this._handleHashChange);\r\n }\r\n public componentWillUnmount(): void {\r\n window.removeEventListener('resize', this.customResizeThrottledEventHandler!, false);\r\n window.removeEventListener('hashchange', this._handleHashChange);\r\n }\r\n public constructor(props: ISubscribeViewPropsExtended) {\r\n super(props);\r\n this._emailAddressInputRef = React.createRef();\r\n this._handleHashChange = this._handleHashChange.bind(this);\r\n this.state = {\r\n iconClassnames: 'default',\r\n email: '',\r\n message: '',\r\n isOnlyMobile: false\r\n };\r\n }\r\n\r\n public render(): JSX.Element | null {\r\n const { heading, paragraph } = this.props.config;\r\n const {\r\n subscribeValidErrorMessage,\r\n subscribeEmptyErrorMessage,\r\n subscribeGenericErrorMessage,\r\n subscribeSuccessMessage\r\n } = this.props.resources;\r\n const { message, iconClassnames, isOnlyMobile } = this.state;\r\n const moduleClassName = 'ms-subscribe';\r\n\r\n const subscribeParagraph = paragraph && (\r\n \r\n );\r\n const onClickHandler = (): void => {\r\n const email = this._emailAddressInputRef.current?.value;\r\n const cutsAccount = (this.props.data.accountInformation && this.props.data.accountInformation.result?.AccountNumber) ?? '';\r\n if (!email) {\r\n this.setState({ message: subscribeEmptyErrorMessage, iconClassnames: 'error' });\r\n } else if (validateEmail(email)) {\r\n const sendDataPromise = new Promise((resolve, reject) => {\r\n DataActionExtension.sendSubscriptionEmailAsync({ callerContext: this.props.context.actionContext }, email, cutsAccount)\r\n .then(response => {\r\n resolve(response);\r\n })\r\n .catch(error => {\r\n reject(error);\r\n });\r\n });\r\n sendDataPromise\r\n .then(response => {\r\n this.setState({ message: subscribeSuccessMessage, iconClassnames: 'success' });\r\n })\r\n .catch(error => {\r\n this.setState({ message: subscribeGenericErrorMessage, iconClassnames: 'error' });\r\n });\r\n } else {\r\n this.setState({ message: subscribeValidErrorMessage, iconClassnames: 'error' });\r\n }\r\n };\r\n\r\n const validateEmail = (email: string) => {\r\n const emailRegex = /^[^\\s@]+@[^\\s@]+\\.[^\\s@]+$/;\r\n return emailRegex.test(email);\r\n };\r\n\r\n const subscribeHeading = heading && (\r\n \r\n );\r\n const onChangeHandler = (e: React.ChangeEvent): void => {\r\n this.setState({ email: e.target.value });\r\n };\r\n //console.log(isOnlyMobile);\r\n const viewProps = {\r\n ...this.props,\r\n handleText: this.handleTextChange,\r\n subscribe: {\r\n moduleProps: this.props,\r\n className: moduleClassName\r\n },\r\n subscribeContainer: {\r\n className: 'ms-subscribe__details'\r\n },\r\n inputContainer: {\r\n className: 'ms-subscribe__input__container'\r\n },\r\n heading: subscribeHeading,\r\n text: subscribeParagraph,\r\n subscribeForm: {\r\n className: 'ms-subscribe__details__form',\r\n tag: 'form',\r\n 'aria-label': this.props.resources.subscribeFormAriaLabel,\r\n name: 'subscribeForm',\r\n role: 'form',\r\n autoComplete: 'off'\r\n },\r\n emailInput: {\r\n className: 'ms-subscribe__details__form__email',\r\n tag: 'input',\r\n ref: this._emailAddressInputRef,\r\n type: 'email',\r\n 'aria-label': this.props.resources.subscribeFormEmailAriaLabel,\r\n placeholder: this.props.resources.subscribeEmailPlaceholderText,\r\n onchange: { onChangeHandler }\r\n },\r\n submitButton: {\r\n className: 'ms-subscribe__details__form__submit',\r\n tag: Button,\r\n 'aria-label': this.props.resources.subscribeFormSubmitAriaLabel,\r\n type: 'submit',\r\n title: this.props.resources.subscribeButtonLabel\r\n },\r\n isOnlyMobile: isOnlyMobile,\r\n submitButtonLabelText: this.props.resources.subscribeButtonLabel,\r\n ArrowIcon: ,\r\n errorMessageNode:
{message}
\r\n };\r\n\r\n return this.props.renderView(viewProps);\r\n }\r\n\r\n /**\r\n * Handle text change.\r\n * @param event - The dialog that is allowed to remain open.\r\n */\r\n public handleTextChange = (event: Msdyn365.ContentEditableEvent): void => {\r\n this.props.config.heading!.text = event.target.value;\r\n };\r\n\r\n /**\r\n * Handle paragraph change.\r\n * @param event - The dialog that is allowed to remain open.\r\n */\r\n public handleParagraphChange = (event: Msdyn365.ContentEditableEvent): void => {\r\n this.props.config.paragraph = event.target.value;\r\n };\r\n /**\r\n * Custom update viewport.\r\n */\r\n private readonly _customUpdateViewport = (): void => {\r\n this.setState({ isOnlyMobile: this.isOnlyMobile });\r\n };\r\n\r\n /**\r\n * Handle hash change.\r\n */\r\n private _handleHashChange(): void {\r\n if (window.location.hash === '#subscribe') {\r\n this._emailAddressInputRef.current?.focus();\r\n // It just for trigger event on mobile.\r\n this._emailAddressInputRef.current?.setAttribute('class', 'nothing');\r\n this._emailAddressInputRef.current?.setAttribute('id', 'subscribe');\r\n }\r\n }\r\n}\r\n\r\nexport default Subscribe;\r\n","/* eslint-disable prettier/prettier */\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 { ISubscribeViewProps } from './britax-subscribe';\r\n\r\n/**\r\n * Override form action and button action below.\r\n * @param event - The form event.\r\n */\r\nconst onSubmit = (event: React.FormEvent): void => {\r\n event.preventDefault();\r\n};\r\n\r\n/**\r\n * View component.\r\n * @param props - The view properties.\r\n * @returns - Returns nothing.\r\n */\r\nexport const subscribeView: React.FC = props => {\r\n const {\r\n subscribe,\r\n subscribeContainer,\r\n heading,\r\n text,\r\n subscribeForm,\r\n emailInput,\r\n submitButton,\r\n ArrowIcon,\r\n errorMessageNode,\r\n inputContainer,\r\n isOnlyMobile\r\n } = props;\r\n return (\r\n \r\n \r\n {heading}\r\n {text}\r\n {isOnlyMobile && \r\n \r\n {isOnlyMobile && }\r\n {ArrowIcon}\r\n \r\n {errorMessageNode}\r\n\r\n \r\n {props.submitButtonLabelText}\r\n \r\n \r\n }\r\n {!isOnlyMobile && \r\n \r\n {!isOnlyMobile && }\r\n {ArrowIcon}\r\n \r\n {errorMessageNode}\r\n\r\n \r\n {props.submitButtonLabelText}\r\n \r\n \r\n }\r\n \r\n \r\n );\r\n};\r\n\r\nexport default subscribeView;\r\n","const binding = { modules: {}, dataActions: {} };\n\n const registerActionId = (actionPath) => {\n if (binding.dataActions[actionPath] &&\n binding.dataActions[actionPath].default &&\n binding.dataActions[actionPath].default.prototype &&\n binding.dataActions[actionPath].default.prototype.id) {\n binding.dataActions[binding.dataActions[actionPath].default.prototype.id] = binding.dataActions[actionPath];\n } else {\n Object.keys(binding.dataActions[actionPath] || {}).forEach(exportName => {\n if (binding.dataActions[actionPath][exportName] &&\n binding.dataActions[actionPath][exportName].prototype &&\n binding.dataActions[actionPath][exportName].prototype.Action) {\n binding.dataActions[binding.dataActions[actionPath][exportName].prototype.id] = binding.dataActions[actionPath][exportName];\n }\n })\n }\n };\n\n const registerSanitizedActionPath = (sanitizedActionPath, dataAction) => {\n if (process.env.NODE_ENV === 'development') {\n if (!dataAction.default) {\n throw new Error('Data action path does not have a default export');\n }\n if (!(dataAction.default.prototype.id && binding.dataActions[dataAction.default.prototype.id]) || !binding.dataActions[sanitizedActionPath]) {\n binding.dataActions[sanitizedActionPath] = dataAction;\n }\n } else {\n binding.dataActions[sanitizedActionPath] = dataAction;\n if (!binding.dataActions[sanitizedActionPath].default) {\n throw new Error('Data action path ' + sanitizedActionPath + ' does not have a default export');\n }\n binding.dataActions[sanitizedActionPath].default.prototype.RegistrationId = sanitizedActionPath;\n if (binding.dataActions[sanitizedActionPath].default.prototype.id) {\n binding.dataActions[binding.dataActions[sanitizedActionPath].default.prototype.id] = sanitizedActionPath;\n }\n }\n };\n \n\n (binding.modules['britax-subscribe'] = {\n c: () => require('partner/modules/britax-subscribe/britax-subscribe.tsx'),\n $type: 'contentModule',\n da: [{name:'accountInformation', path:'@msdyn365-commerce-modules/retail-actions/dist/lib/get-customer', runOn: 0}],\n \n iNM: false,\n ns: '__local__',\n n: 'britax-subscribe',\n p: '__local__',\n \n pdp: '',\n \n \n md: 'src/modules/britax-subscribe'\n });\n \n\n {\n const sanitizedActionPath = '@msdyn365-commerce-modules/retail-actions/dist/lib/get-customer';\n let dataAction = require('@msdyn365-commerce-modules/retail-actions/dist/lib/get-customer');\n registerSanitizedActionPath(sanitizedActionPath, dataAction);\n }\n \n\n \n window.__bindings__ = window.__bindings__ || {};\n window.__bindings__.modules = {\n ...window.__bindings__.modules || {},\n ...binding.modules\n };\n \n window.__bindings__.dataActions = {\n ...window.__bindings__.dataActions || {},\n ...binding.dataActions\n };\n export const viewDictionary = {};\n viewDictionary['__local__|__local__|modules|britax-subscribe|britax-subscribe'] = {\n c: () => require('partner/modules/britax-subscribe/britax-subscribe.view.tsx'),\n cn: '__local__-__local__-britax-subscribe'\n };\nwindow.__bindings__ = window.__bindings__ || {};\nwindow.__bindings__.viewDictionary = {\n ...window.__bindings__.viewDictionary || {},\n ...viewDictionary\n };","module.exports = React;","module.exports = ReactDOM;"],"names":["FUSCustomEntityExtensionClass","constructor","odataObject","this","RequestId","ExtensionProperties","undefined","i","length","className","substr","lastIndexOf","concat","EntityClasses","customControllerQuery","requestId","key","DataServiceQuery","DataServiceEntities","sendRegistratonDataAsync","context","fName","lName","email","phone","productType","productName","storeName","purchDate","mDate","itemId","batchId","serialId","reOrderCode","custAccount","request","createDataServiceRequestForOperation","bypassCache","returnEntity","FName","LName","Email","Phone","ProductType","ProductName","StoreName","PurchDate","MDate","ItemId","BatchId","SerialId","ReOrderCode","CustAccount","createSendRegistratonDataInput","callActionOrExecute","callerContext","sendSubscriptionEmailAsync","createSendSubscriptionEmailInput","ArrowIcon","_ref","onClickArrow","iconClassnames","React","onClick","Subscribe","props","super","handleTextChange","event","config","heading","text","target","value","handleParagraphChange","paragraph","_customUpdateViewport","setState","isOnlyMobile","_emailAddressInputRef","_handleHashChange","bind","state","message","isMobile","variant","VariantType","Browser","componentDidMount","customResizeThrottledEventHandler","addThrottledEvent","window","addEventListener","componentWillUnmount","removeEventListener","render","_heading$tag","subscribeValidErrorMessage","subscribeEmptyErrorMessage","subscribeGenericErrorMessage","subscribeSuccessMessage","resources","subscribeParagraph","Msdyn365","editProps","onEdit","requestContext","validateEmail","test","subscribeHeading","tag","viewProps","_objectSpread","handleText","subscribe","moduleProps","subscribeContainer","inputContainer","subscribeForm","subscribeFormAriaLabel","name","role","autoComplete","emailInput","ref","type","subscribeFormEmailAriaLabel","placeholder","subscribeEmailPlaceholderText","onchange","onChangeHandler","e","submitButton","Button","subscribeFormSubmitAriaLabel","title","subscribeButtonLabel","submitButtonLabelText","onClickHandler","_this$_emailAddressIn","_this$props$data$acco","current","cutsAccount","data","accountInformation","result","AccountNumber","Promise","resolve","reject","DataActionExtension","actionContext","then","response","catch","error","errorMessageNode","renderView","_this$_emailAddressIn2","_this$_emailAddressIn3","_this$_emailAddressIn4","location","hash","focus","setAttribute","__decorate","computed","onSubmit","preventDefault","subscribeView","_subscribeForm$classN","_emailInput$className","_submitButton$classNa","_subscribeForm$classN2","_emailInput$className2","_submitButton$classNa2","Module","Object","assign","Node","binding","modules","dataActions","c","require","$type","da","path","runOn","iNM","ns","n","p","pdp","md","registerSanitizedActionPath","sanitizedActionPath","dataAction","default","Error","prototype","RegistrationId","id","__bindings__","viewDictionary","cn","module","exports","ReactDOM"],"sourceRoot":""}