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QAAU/B,2BCAjB8B,EAAOC,QAAUC","sources":["webpack://Msdyn365.Commerce.Online/./src/actions/get-product-active-prices.action.ts?7ea5","webpack://Msdyn365.Commerce.Online/./src/actions/payment-state-share.action.ts?5a06","webpack://Msdyn365.Commerce.Online/./src/themes/bluecrest/bluecrest.tsx?789c","webpack://Msdyn365.Commerce.Online/./lib/bluecrest/module-registration.js?6aa6","webpack://Msdyn365.Commerce.Online/external var \"React\"?0d3b","webpack://Msdyn365.Commerce.Online/external var \"ReactDOM\"?853b"],"sourcesContent":["/*!\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 * as Msdyn365 from '@msdyn365-commerce/core';\r\nimport { getCatalogId } from '@msdyn365-commerce/core';\r\nimport { ProductPrice } from '@msdyn365-commerce/retail-proxy';\r\nimport { getActivePricesAsync } from '@msdyn365-commerce/retail-proxy/dist/DataActions/ProductsDataActions.g';\r\n\r\n/**\r\n * GetProductActivePrices Input Action\r\n */\r\nexport class GetProductActivePricesInput implements Msdyn365.IActionInput {\r\n // TODO: Construct the input needed to run the action\r\n public productIDs: number[];\r\n constructor(productIDs: number[]) {\r\n this.productIDs = productIDs;\r\n }\r\n\r\n // TODO: Determine if the results of this get action should cache the results and if so provide\r\n // a cache object type and an appropriate cache key\r\n public getCacheKey = () => `GetActivePrices`;\r\n public getCacheObjectType = () => 'GetActivePrices';\r\n public dataCacheType = (): Msdyn365.CacheType => 'none';\r\n}\r\n\r\n// TODO: Create a data model here or import one to capture the response of the action\r\nexport interface IGetProductActivePricesData {\r\n activePrices: ProductPrice[];\r\n}\r\n\r\n/**\r\n * TODO: Use this function to call your action and process the results as needed\r\n */\r\nasync function getActivePricesAction(\r\n input: GetProductActivePricesInput,\r\n ctx: Msdyn365.IActionContext\r\n): Promise {\r\n const catalogId = getCatalogId(ctx.requestContext);\r\n const projectDomain = {\r\n ChannelId: +ctx.requestContext.apiSettings.channelId,\r\n CatalogId: catalogId\r\n };\r\n const activePricesResponse = await getActivePricesAsync(\r\n { callerContext: ctx },\r\n projectDomain,\r\n input.productIDs,\r\n new Date(),\r\n null,\r\n null,\r\n true,\r\n null,\r\n true\r\n ).then(productPrices => {\r\n return productPrices;\r\n });\r\n return { activePrices: activePricesResponse };\r\n}\r\n\r\nexport default Msdyn365.createObservableDataAction({\r\n action: >getActivePricesAction,\r\n id: 'GetProductActivePrices'\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 */\r\n\r\nimport * as Msdyn365 from '@msdyn365-commerce/core';\r\n\r\n/**\r\n * PaymentStateShare Input Action\r\n */\r\nexport class PaymentStateShareInput implements Msdyn365.IActionInput {\r\n // TODO: Construct the input needed to run the action\r\n constructor() {}\r\n\r\n // TODO: Determine if the results of this get action should cache the results and if so provide\r\n // a cache object type and an appropriate cache key\r\n public getCacheKey = () => `payment-state-share`;\r\n public getCacheObjectType = () => 'payment-state-share';\r\n public dataCacheType = (): Msdyn365.CacheType => 'application';\r\n}\r\n\r\n// TODO: Create a data model here or import one to capture the response of the action\r\nexport interface IPaymentStateShareData {\r\n isAccountPaymentSelected: boolean;\r\n isCreditCardSelected: boolean;\r\n shouldApplyOnAccountPayment: boolean;\r\n}\r\n\r\n/**\r\n * TODO: Use this function to create the input required to make the action call\r\n */\r\nconst createInput = (args: Msdyn365.ICreateActionContext): Msdyn365.IActionInput => {\r\n return new PaymentStateShareInput();\r\n};\r\n\r\n/**\r\n * TODO: Use this function to call your action and process the results as needed\r\n */\r\nasync function action(input: PaymentStateShareInput, ctx: Msdyn365.IActionContext): Promise {\r\n // const apiSettings = Msdyn365.msdyn365Commerce.apiSettings;\r\n\r\n // TODO: Uncomment the below line to get the value from a service\r\n // const response = await Msdyn365.sendRequest('/get/example/id/1', 'get');\r\n return { isAccountPaymentSelected: true, isCreditCardSelected: false, shouldApplyOnAccountPayment: false };\r\n}\r\n\r\nexport default Msdyn365.createObservableDataAction({\r\n action: >action,\r\n // TODO: Give your data action a unique id\r\n id: 'PaymentStateShare',\r\n input: createInput\r\n // TODO: Uncomment the below line if this is a meant to be a batched data action\r\n // isBatched: true\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 */\r\n\r\nimport * as React from 'react';\r\n\r\n// TODO: Current build require at least one tsx file\r\nexport default () =>
;\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['bluecrest'] = {\n c: () => require('partner/themes/bluecrest/bluecrest.tsx'),\n $type: 'themeModule',\n da: [{name:'checkout', path:'@msdyn365-commerce/global-state/dist/lib/data-actions/checkout-state-data-action', moduleName: 'checkout-payment-instrument',runOn: 1},{name:'checkout', path:'@msdyn365-commerce/global-state/dist/lib/data-actions/checkout-state-data-action', moduleName: 'checkout-customer-account-payment',runOn: 1},{name:'customerInformation', path:'@msdyn365-commerce-modules/retail-actions/dist/lib/get-customer', moduleName: 'checkout-payment-instrument',runOn: 0},{name:'getActivePricesPLP', path:'actions/get-product-active-prices.action', moduleName: 'search-result-container',runOn: 1},{name:'getPaymentState', path:'actions/payment-state-share.action', moduleName: 'checkout-delivery-options',runOn: 1},{name:'getPaymentState', path:'actions/payment-state-share.action', moduleName: 'checkout-payment-instrument',runOn: 1},{name:'getPaymentState', path:'actions/payment-state-share.action', moduleName: 'checkout-customer-account-payment',runOn: 0}],\n definitionExtensions: ['active-image','b2b-requests-status','business-organization-list','buybox','cart-icon','checkout-customer-account-payment','checkout-delivery-options','checkout-payment-instrument','checkout','content-block','header','image-list','navigation-menu','order-confirmation','order-template-list','promo-banner','quickview','ratings-histogram','reviews-list','search-result-container','search','sign-in','store-selector','text-block','write-review'],\n iNM: false,\n ns: '__local__',\n n: 'bluecrest',\n p: '__local__',\n \n pdp: '',\n \n themeSettings: 'bluecrest.theme.settings.json',\n md: 'src/themes/bluecrest'\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 const sanitizedActionPath = '@msdyn365-commerce/global-state/dist/lib/data-actions/checkout-state-data-action';\n let dataAction = require('@msdyn365-commerce/global-state/dist/lib/data-actions/checkout-state-data-action');\n registerSanitizedActionPath(sanitizedActionPath, dataAction);\n }\n \n\n {\n const sanitizedActionPath = '@msdyn365-commerce/global-state/dist/lib/data-actions/checkout-state-data-action';\n let dataAction = require('@msdyn365-commerce/global-state/dist/lib/data-actions/checkout-state-data-action');\n registerSanitizedActionPath(sanitizedActionPath, dataAction);\n }\n \n\n {\n const sanitizedActionPath = 'actions/get-product-active-prices.action';\n let dataAction = require('partner/actions/get-product-active-prices.action');\n registerSanitizedActionPath(sanitizedActionPath, dataAction);\n }\n \n\n {\n const sanitizedActionPath = 'actions/payment-state-share.action';\n let dataAction = require('partner/actions/payment-state-share.action');\n registerSanitizedActionPath(sanitizedActionPath, dataAction);\n }\n \n\n {\n const sanitizedActionPath = 'actions/payment-state-share.action';\n let dataAction = require('partner/actions/payment-state-share.action');\n registerSanitizedActionPath(sanitizedActionPath, dataAction);\n }\n \n\n {\n const sanitizedActionPath = 'actions/payment-state-share.action';\n let dataAction = require('partner/actions/payment-state-share.action');\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 };","module.exports = React;","module.exports = ReactDOM;"],"names":["GetProductActivePricesInput","constructor","productIDs","getCacheKey","getCacheObjectType","dataCacheType","this","Msdyn365","action","async","input","ctx","catalogId","getCatalogId","requestContext","projectDomain","ChannelId","apiSettings","channelId","CatalogId","activePrices","getActivePricesAsync","callerContext","Date","then","productPrices","id","PaymentStateShareInput","isAccountPaymentSelected","isCreditCardSelected","shouldApplyOnAccountPayment","args","React","binding","modules","dataActions","registerSanitizedActionPath","sanitizedActionPath","dataAction","default","Error","prototype","RegistrationId","c","require","$type","da","name","path","moduleName","runOn","definitionExtensions","iNM","ns","n","p","pdp","themeSettings","md","window","__bindings__","_objectSpread","module","exports","ReactDOM"],"sourceRoot":""}