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GAML,KAAA/E,YAAc,IAAM,eACpB,KAAAC,mBAAqB,IAAM,eAC3B,KAAAC,cAAgB,IAA0B,OAP7CC,KAAK4E,QAAUA,GAahB3E,eAAe0F,EAAmBxF,EAA6BC,GAClE,GAAID,EAAQyE,QACR,IACI,MAAMvE,QAAewE,EAAAA,EAAAA,IAAkB,CAAEtE,cAAeH,GAAOD,EAAQyE,SACvE,GAAIvE,EACA,OAAOA,EAEb,MAAOG,GACLC,QAAQC,IAAI,QAASF,GAG7B,OAAO,KAGX,QAAeG,EAAAA,GAAoC,CAC/CC,OAAgD+E,EAEhD9E,GAAI","sources":["webpack://Msdyn365.Commerce.Online/./src/actions/GetCustomerAddress.action.ts?d507","webpack://Msdyn365.Commerce.Online/./src/actions/SearchItemsDataServiceEntities.g.ts?d72b","webpack://Msdyn365.Commerce.Online/./src/actions/SearchItemsDataActionExtension.g.ts?347d","webpack://Msdyn365.Commerce.Online/./src/actions/getStateCity.action.ts?af75"],"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 { getCustomerAddressAsync } from './SearchItemsDataActionExtension.g';\r\nimport { IITSCustomerAddressResponse } from './SearchItemsDataServiceEntities.g';\r\n\r\n/**\r\n * Getaddresses Input Action\r\n */\r\n\r\nexport interface IITSCutomerAddressInput extends Msdyn365.IActionInput {\r\n customerAccount: string;\r\n}\r\nexport class GetaddressesInput implements Msdyn365.IActionInput {\r\n public customerAccount: string;\r\n // TODO: Construct the input needed to run the action\r\n constructor(customerAccount: string) {\r\n this.customerAccount = customerAccount;\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 = () => `GetCustomerAddress`;\r\n public getCacheObjectType = () => 'GetCustomerAddress';\r\n public dataCacheType = (): Msdyn365.CacheType => 'none';\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\nexport async function getCustomerAddressesAction(\r\n request: IITSCutomerAddressInput,\r\n ctx: Msdyn365.IActionContext\r\n): Promise {\r\n if (request.customerAccount) {\r\n try {\r\n const result = await getCustomerAddressAsync({ callerContext: ctx }, request.customerAccount);\r\n if (result) {\r\n return result;\r\n }\r\n } catch (error) {\r\n console.log('Error', error);\r\n }\r\n }\r\n return null;\r\n}\r\n\r\nexport default Msdyn365.createObservableDataAction({\r\n action: >getCustomerAddressesAction,\r\n // TODO: Give your data action a unique id\r\n id: `GetCustomerAddress`\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","/* eslint-disable security/detect-object-injection */\r\n// @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 * ExampleEntity entity interface.\r\n */\r\nexport interface IExampleEntity {\r\n IntData: number;\r\n StringData?: string;\r\n UnusualEntityId: number;\r\n ExtensionProperties?: Entities.CommerceProperty[];\r\n}\r\n\r\n/**\r\n * StatesEntity entity interface.\r\n */\r\nexport interface IStatesEntity {\r\n State?: string;\r\n City?: string;\r\n ExtensionProperties?: Entities.CommerceProperty[];\r\n}\r\n\r\n/**\r\n * ProductEntity entity interface.\r\n */\r\nexport interface IProductEntity {\r\n RecId: number;\r\n ProductNumber?: string;\r\n AltItemId?: string;\r\n Attributes?: IProductAttributeParameter[];\r\n UseAltItemId: number;\r\n AltItemRecId: number;\r\n ProductSuperseded?: string;\r\n AlternativeText?: string;\r\n ExtensionProperties?: Entities.CommerceProperty[];\r\n}\r\n\r\n/**\r\n * AddressEntity entity interface.\r\n */\r\nexport interface IAddressEntity {\r\n CustomerAccountNumber?: string;\r\n Description?: string;\r\n Purpose?: string;\r\n State?: string;\r\n Street?: string;\r\n City?: string;\r\n Phone?: string;\r\n FullAddress?: string;\r\n ThreeLetterISORegionName?: string;\r\n ZipCode?: string;\r\n LogisticsLocationRecordId: number;\r\n RecordId: number;\r\n LogisticsLocationId?: string;\r\n AddressTypeValue: number;\r\n ExtensionProperties?: Entities.CommerceProperty[];\r\n}\r\n\r\n/**\r\n * ProductAttributeParameter entity interface.\r\n */\r\nexport interface IProductAttributeParameter {\r\n Name?: string;\r\n DataTypeValue: number;\r\n TextValue?: string;\r\n BooleanValue: boolean;\r\n AttributeValueId: number;\r\n RecordId: number;\r\n}\r\n\r\n/**\r\n * ITSSearchItemPartResponse entity interface.\r\n */\r\nexport interface IITSSearchItemPartResponse {\r\n FoundProducts?: IProductEntity[];\r\n NotFoundItems?: string[];\r\n}\r\n\r\n/**\r\n * ITSCustomerAddressResponse entity interface.\r\n */\r\nexport interface IITSCustomerAddressResponse {\r\n Addresses?: IAddressEntity[];\r\n}\r\n\r\n/**\r\n * ITSInvoiceSearchResponse entity interface.\r\n */\r\nexport interface IITSInvoiceSearchResponse {\r\n Invoices?: Entities.OrderInvoice[];\r\n}\r\n\r\n/**\r\n * ITSInvoiceSearchResponse entity class.\r\n */\r\nexport class ITSInvoiceSearchResponseExtensionClass implements IITSInvoiceSearchResponse {\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n public Invoices: Entities.OrderInvoice[];\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.Invoices = undefined;\r\n if (odataObject.Invoices) {\r\n this.Invoices = [];\r\n for (var i = 0; i < odataObject.Invoices.length; i++) {\r\n if (odataObject.Invoices[i]) {\r\n if (odataObject.Invoices[i]['@odata.type']) {\r\n var className: string = odataObject.Invoices[i]['@odata.type'];\r\n className = className.substr(className.lastIndexOf('.') + 1).concat('Class');\r\n // @ts-ignore\r\n if (EntityClasses[className]) {\r\n // @ts-ignore\r\n this.Invoices[i] = new EntityClasses[className](odataObject.Invoices[i]);\r\n }\r\n } else {\r\n this.Invoices[i] = new EntityClasses.OrderInvoiceClass(odataObject.Invoices[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.Invoices[i] = undefined;\r\n }\r\n }\r\n }\r\n }\r\n}\r\n\r\n/**\r\n * ExampleEntity entity class.\r\n */\r\nexport class ExampleEntityExtensionClass implements IExampleEntity {\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n public IntData: 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 StringData: 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 UnusualEntityId: 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.IntData = odataObject.IntData;\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.StringData = odataObject.StringData;\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.UnusualEntityId = odataObject.UnusualEntityId ? parseInt(odataObject.UnusualEntityId, 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.ExtensionProperties = undefined;\r\n if (odataObject.ExtensionProperties) {\r\n this.ExtensionProperties = [];\r\n for (let i = 0; i < odataObject.ExtensionProperties.length; i++) {\r\n if (odataObject.ExtensionProperties[i]) {\r\n if (odataObject.ExtensionProperties[i]['@odata.type']) {\r\n let className: string = odataObject.ExtensionProperties[i]['@odata.type'];\r\n className = className.substr(className.lastIndexOf('.') + 1).concat('Class');\r\n // @ts-ignore\r\n if (EntityClasses[className]) {\r\n // @ts-ignore\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 * StatesEntity entity class.\r\n */\r\nexport class StatesEntityExtensionClass implements IStatesEntity {\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n public State: 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 City: 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.State = odataObject.State;\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.City = odataObject.City;\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 (let i = 0; i < odataObject.ExtensionProperties.length; i++) {\r\n if (odataObject.ExtensionProperties[i]) {\r\n if (odataObject.ExtensionProperties[i]['@odata.type']) {\r\n let className: string = odataObject.ExtensionProperties[i]['@odata.type'];\r\n className = className.substr(className.lastIndexOf('.') + 1).concat('Class');\r\n // @ts-ignore\r\n if (EntityClasses[className]) {\r\n // @ts-ignore\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 * ProductEntity entity class.\r\n */\r\nexport class ProductEntityExtensionClass implements IProductEntity {\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n public RecId: 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 ProductNumber: 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 AltItemId: 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 Attributes: IProductAttributeParameter[];\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 UseAltItemId: 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 AltItemRecId: 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 ProductSuperseded: 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 AlternativeText: 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.RecId = odataObject.RecId ? parseInt(odataObject.RecId, 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.ProductNumber = odataObject.ProductNumber;\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.AltItemId = odataObject.AltItemId;\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.Attributes = undefined;\r\n if (odataObject.Attributes) {\r\n this.Attributes = [];\r\n for (let i = 0; i < odataObject.Attributes.length; i++) {\r\n if (odataObject.Attributes[i]) {\r\n if (odataObject.Attributes[i]['@odata.type']) {\r\n let className: string = odataObject.Attributes[i]['@odata.type'];\r\n className = className.substr(className.lastIndexOf('.') + 1).concat('Class');\r\n // @ts-ignore\r\n if (EntityClasses[className]) {\r\n // @ts-ignore\r\n this.Attributes[i] = new EntityClasses[className](odataObject.Attributes[i]);\r\n }\r\n } else {\r\n this.Attributes[i] = new ProductAttributeParameterExtensionClass(odataObject.Attributes[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.Attributes[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.UseAltItemId = odataObject.UseAltItemId;\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.AltItemRecId = odataObject.AltItemRecId ? parseInt(odataObject.AltItemRecId, 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.ProductSuperseded = odataObject.ProductSuperseded;\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.AlternativeText = odataObject.AlternativeText;\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 (let i = 0; i < odataObject.ExtensionProperties.length; i++) {\r\n if (odataObject.ExtensionProperties[i]) {\r\n if (odataObject.ExtensionProperties[i]['@odata.type']) {\r\n let className: string = odataObject.ExtensionProperties[i]['@odata.type'];\r\n className = className.substr(className.lastIndexOf('.') + 1).concat('Class');\r\n // @ts-ignore\r\n if (EntityClasses[className]) {\r\n // @ts-ignore\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 * AddressEntity entity class.\r\n */\r\nexport class AddressEntityExtensionClass implements IAddressEntity {\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n public CustomerAccountNumber: 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 Description: 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 Purpose: 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 State: 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 Street: 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 City: 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 FullAddress: 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 ThreeLetterISORegionName: 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 ZipCode: 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 LogisticsLocationRecordId: 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 LogisticsLocationId: 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 AddressTypeValue: 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 // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n public RecordId: number;\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.CustomerAccountNumber = odataObject.CustomerAccountNumber;\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.Description = odataObject.Description;\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.Purpose = odataObject.Purpose;\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.State = odataObject.State;\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.Street = odataObject.Street;\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.City = odataObject.City;\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.FullAddress = odataObject.FullAddress;\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.ThreeLetterISORegionName = odataObject.ThreeLetterISORegionName;\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.ZipCode = odataObject.ZipCode;\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.LogisticsLocationRecordId = odataObject.LogisticsLocationRecordId ? parseInt(odataObject.LogisticsLocationRecordId, 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.LogisticsLocationId = odataObject.LogisticsLocationId;\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.AddressTypeValue = odataObject.AddressTypeValue;\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n this.RecordId = odataObject.RecordId;\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 (let i = 0; i < odataObject.ExtensionProperties.length; i++) {\r\n if (odataObject.ExtensionProperties[i]) {\r\n if (odataObject.ExtensionProperties[i]['@odata.type']) {\r\n let className: string = odataObject.ExtensionProperties[i]['@odata.type'];\r\n className = className.substr(className.lastIndexOf('.') + 1).concat('Class');\r\n // @ts-ignore\r\n if (EntityClasses[className]) {\r\n // @ts-ignore\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 * ProductAttributeParameter entity class.\r\n */\r\nexport class ProductAttributeParameterExtensionClass implements IProductAttributeParameter {\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n public Name: 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 DataTypeValue: 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 TextValue: 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 BooleanValue: 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 AttributeValueId: 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 RecordId: number;\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.Name = odataObject.Name;\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.DataTypeValue = odataObject.DataTypeValue;\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.TextValue = odataObject.TextValue;\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.BooleanValue = odataObject.BooleanValue;\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.AttributeValueId = odataObject.AttributeValueId ? parseInt(odataObject.AttributeValueId, 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.RecordId = odataObject.RecordId ? parseInt(odataObject.RecordId, 10) : 0;\r\n }\r\n}\r\n\r\n/**\r\n * ITSSearchItemPartResponse entity class.\r\n */\r\nexport class ITSSearchItemPartResponseExtensionClass implements IITSSearchItemPartResponse {\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n public FoundProducts: IProductEntity[];\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 NotFoundItems: 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.FoundProducts = undefined;\r\n if (odataObject.FoundProducts) {\r\n this.FoundProducts = [];\r\n for (let i = 0; i < odataObject.FoundProducts.length; i++) {\r\n if (odataObject.FoundProducts[i]) {\r\n if (odataObject.FoundProducts[i]['@odata.type']) {\r\n let className: string = odataObject.FoundProducts[i]['@odata.type'];\r\n className = className.substr(className.lastIndexOf('.') + 1).concat('Class');\r\n // @ts-ignore\r\n if (EntityClasses[className]) {\r\n // @ts-ignore\r\n this.FoundProducts[i] = new EntityClasses[className](odataObject.FoundProducts[i]);\r\n }\r\n } else {\r\n this.FoundProducts[i] = new ProductEntityExtensionClass(odataObject.FoundProducts[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.FoundProducts[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.NotFoundItems = undefined;\r\n if (odataObject.NotFoundItems) {\r\n this.NotFoundItems = [];\r\n for (let i = 0; i < odataObject.NotFoundItems.length; i++) {\r\n if (odataObject.NotFoundItems[i]) {\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n this.NotFoundItems[i] = odataObject.NotFoundItems[i];\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.NotFoundItems[i] = undefined;\r\n }\r\n }\r\n }\r\n }\r\n}\r\n\r\n/**\r\n * ITSCustomerAddressResponse entity class.\r\n */\r\nexport class ITSCustomerAddressResponseExtensionClass implements IITSCustomerAddressResponse {\r\n // @ts-ignore - TODO bug fix #23427261 - remove ts-ignore - https://microsoft.visualstudio.com/DefaultCollection/OSGS/_workitems/edit/23427261/\r\n public Addresses: IAddressEntity[];\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.Addresses = undefined;\r\n if (odataObject.Addresses) {\r\n this.Addresses = [];\r\n for (let i = 0; i < odataObject.Addresses.length; i++) {\r\n if (odataObject.Addresses[i]) {\r\n if (odataObject.Addresses[i]['@odata.type']) {\r\n let className: string = odataObject.Addresses[i]['@odata.type'];\r\n className = className.substr(className.lastIndexOf('.') + 1).concat('Class');\r\n // @ts-ignore\r\n if (EntityClasses[className]) {\r\n // @ts-ignore\r\n this.Addresses[i] = new EntityClasses[className](odataObject.Addresses[i]);\r\n }\r\n } else {\r\n this.Addresses[i] = new AddressEntityExtensionClass(odataObject.Addresses[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.Addresses[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 './SearchItemsDataServiceEntities.g';\r\n\r\nfunction getSortedInvoicesQuery(): DataServiceQuery {\r\n return new DataServiceQuery();\r\n}\r\n\r\nexport function getSortedInvoicesInput(\r\n invoiceSearchCriteria: Entities.InvoiceSearchCriteria,\r\n top: number,\r\n skip: number\r\n): IDataServiceRequest {\r\n const query = getSortedInvoicesQuery();\r\n return query.createDataServiceRequestForOperation(\r\n 'GetSortedInvoices',\r\n true,\r\n DataServiceEntities.ITSInvoiceSearchResponseExtensionClass,\r\n 'false',\r\n {\r\n bypassCache: 'get',\r\n returnEntity: 'DataServiceEntities.IITSInvoiceSearchResponse'\r\n },\r\n {\r\n invoiceSearchCriteria: invoiceSearchCriteria,\r\n top: top,\r\n skip: skip\r\n }\r\n );\r\n}\r\n\r\nexport function getSortedInvoicesAsync(\r\n context: IContext,\r\n invoiceSearchCriteria: Entities.InvoiceSearchCriteria,\r\n top: number,\r\n skip: number\r\n): AsyncResult {\r\n const request = getSortedInvoicesInput(invoiceSearchCriteria, top, skip);\r\n return callActionOrExecute(request, context.callerContext);\r\n}\r\n\r\nfunction getStateCityQuery(): DataServiceQuery {\r\n return new DataServiceQuery();\r\n}\r\n\r\nexport function getStateCityInput(zipCode: string): IDataServiceRequest {\r\n const query = getStateCityQuery();\r\n return query.createDataServiceRequestForOperation(\r\n 'GetStateCity',\r\n false,\r\n DataServiceEntities.StatesEntityExtensionClass,\r\n 'false',\r\n { bypassCache: 'get', returnEntity: 'DataServiceEntities.IStatesEntity' },\r\n {\r\n zipCode: zipCode\r\n }\r\n );\r\n}\r\n\r\nexport function getStateCityAsync(context: IContext, zipCode: string): AsyncResult {\r\n const request = getStateCityInput(zipCode);\r\n return callActionOrExecute(request, context.callerContext);\r\n}\r\n\r\nfunction getProductsByItemPartNumberQuery(): DataServiceQuery {\r\n return new DataServiceQuery();\r\n}\r\n\r\nexport function getProductsByItemPartNumberInput(itemPartNumber: string, strictSearch: boolean): IDataServiceRequest {\r\n const query = getProductsByItemPartNumberQuery();\r\n return query.createDataServiceRequestForOperation(\r\n 'GetProductsByItemPartNumber',\r\n false,\r\n DataServiceEntities.ITSSearchItemPartResponseExtensionClass,\r\n 'false',\r\n { bypassCache: 'get', returnEntity: 'DataServiceEntities.IITSSearchItemPartResponse' },\r\n {\r\n itemPartNumber: itemPartNumber,\r\n StrictSearch: strictSearch\r\n }\r\n );\r\n}\r\n\r\nexport function getProductsByItemPartNumberAsync(\r\n context: IContext,\r\n itemPartNumber: string,\r\n strictSearch: boolean\r\n): AsyncResult {\r\n const request = getProductsByItemPartNumberInput(itemPartNumber, strictSearch);\r\n return callActionOrExecute(request, context.callerContext);\r\n}\r\n\r\nfunction getCustomerAddressQuery(): DataServiceQuery {\r\n return new DataServiceQuery();\r\n}\r\n\r\nexport function getCustomerAddressInput(customerAccount: string): IDataServiceRequest {\r\n const query = getCustomerAddressQuery();\r\n return query.createDataServiceRequestForOperation(\r\n 'GetCustomerAddress',\r\n false,\r\n DataServiceEntities.ITSCustomerAddressResponseExtensionClass,\r\n 'false',\r\n { bypassCache: 'get', returnEntity: 'DataServiceEntities.IITSCustomerAddressResponse' },\r\n {\r\n customerAccount: customerAccount\r\n }\r\n );\r\n}\r\n\r\nexport function getCustomerAddressAsync(\r\n context: IContext,\r\n customerAccount: string\r\n): AsyncResult {\r\n const request = getCustomerAddressInput(customerAccount);\r\n return callActionOrExecute(request, context.callerContext);\r\n}\r\n\r\nfunction getOrderHistoryByPONumberQuery(): DataServiceQuery {\r\n return new DataServiceQuery();\r\n}\r\n\r\nexport function getOrderHistoryByPONumberInput(\r\n queryResultSettings: IQueryResultSettings,\r\n pONumber: string,\r\n customerAccount: string,\r\n businessPartnerId: string\r\n): IDataServiceRequest {\r\n const query = getOrderHistoryByPONumberQuery().resultSettings(queryResultSettings);\r\n return query.createDataServiceRequestForOperation(\r\n 'GetOrderHistoryByPONumber',\r\n false,\r\n EntityClasses.SalesOrderClass,\r\n 'true',\r\n { bypassCache: 'get', returnEntity: 'Entities.SalesOrder' },\r\n {\r\n pONumber: pONumber,\r\n customerAccount: customerAccount,\r\n businessPartnerId: businessPartnerId\r\n }\r\n );\r\n}\r\n\r\nexport function getOrderHistoryByPONumberAsync(\r\n context: IContext,\r\n pONumber: string,\r\n customerAccount: string,\r\n businessPartnerId: string\r\n): AsyncResult {\r\n const request = getOrderHistoryByPONumberInput(context.queryResultSettings || {}, pONumber, customerAccount, businessPartnerId);\r\n return callActionOrExecute(request, context.callerContext);\r\n}\r\n\r\nfunction simplePingPostQuery(): DataServiceQuery {\r\n return new DataServiceQuery();\r\n}\r\n\r\nexport function simplePingPostInput(): IDataServiceRequest {\r\n const query = simplePingPostQuery();\r\n return query.createDataServiceRequestForOperation('SimplePingPost', true, '', 'false', { bypassCache: 'get', returnEntity: '' }, {});\r\n}\r\n\r\nexport function simplePingPostAsync(context: IContext): AsyncResult {\r\n const request = simplePingPostInput();\r\n return callActionOrExecute(request, context.callerContext);\r\n}\r\n\r\nfunction simplePingGetQuery(): DataServiceQuery {\r\n return new DataServiceQuery();\r\n}\r\n\r\nexport function simplePingGetInput(): IDataServiceRequest {\r\n const query = simplePingGetQuery();\r\n return query.createDataServiceRequestForOperation('SimplePingGet', false, '', 'false', { bypassCache: 'get', returnEntity: '' }, {});\r\n}\r\n\r\nexport function simplePingGetAsync(context: IContext): AsyncResult {\r\n const request = simplePingGetInput();\r\n return callActionOrExecute(request, context.callerContext);\r\n}\r\n\r\n// @ts-ignore\r\nfunction boundControllerQuery(unusualEntityId?: number): DataServiceQuery {\r\n const key = unusualEntityId ? { UnusualEntityId: unusualEntityId } : null;\r\n return new DataServiceQuery('BoundController', 'ExampleEntity', DataServiceEntities.ExampleEntityExtensionClass, key);\r\n}\r\n\r\nexport function createCreateExampleEntityInput(entityData: DataServiceEntities.IExampleEntity): IDataServiceRequest {\r\n const query = boundControllerQuery();\r\n return query.createDataServiceRequestForOperation(\r\n 'CreateExampleEntity',\r\n true,\r\n '',\r\n 'false',\r\n { bypassCache: 'get', returnEntity: '' },\r\n { entityData: entityData }\r\n );\r\n}\r\n\r\nexport function createExampleEntityAsync(context: IContext, entityData: DataServiceEntities.IExampleEntity): AsyncResult {\r\n const request = createCreateExampleEntityInput(entityData);\r\n return callActionOrExecute(request, context.callerContext);\r\n}\r\n\r\nexport function createUpdateExampleEntityInput(\r\n unusualEntityId: number,\r\n updatedEntity: DataServiceEntities.IExampleEntity\r\n): IDataServiceRequest {\r\n const query = boundControllerQuery(unusualEntityId);\r\n return query.createDataServiceRequestForOperation(\r\n 'UpdateExampleEntity',\r\n true,\r\n '',\r\n 'false',\r\n { bypassCache: 'get', returnEntity: '' },\r\n { updatedEntity: updatedEntity }\r\n );\r\n}\r\n\r\nexport function updateExampleEntityAsync(\r\n context: IContext,\r\n unusualEntityId: number,\r\n updatedEntity: DataServiceEntities.IExampleEntity\r\n): AsyncResult {\r\n const request = createUpdateExampleEntityInput(unusualEntityId, updatedEntity);\r\n return callActionOrExecute(request, context.callerContext);\r\n}\r\n\r\nexport function createDeleteExampleEntityInput(unusualEntityId: number): IDataServiceRequest {\r\n const query = boundControllerQuery(unusualEntityId);\r\n return query.createDataServiceRequestForOperation(\r\n 'DeleteExampleEntity',\r\n true,\r\n '',\r\n 'false',\r\n { bypassCache: 'get', returnEntity: '' },\r\n {}\r\n );\r\n}\r\n\r\nexport function deleteExampleEntityAsync(context: IContext, unusualEntityId: number): AsyncResult {\r\n const request = createDeleteExampleEntityInput(unusualEntityId);\r\n return callActionOrExecute(request, context.callerContext);\r\n}\r\n\r\nexport function createGetAllExampleEntitiesInput(queryResultSettings: IQueryResultSettings): IDataServiceRequest {\r\n const query = boundControllerQuery().resultSettings(queryResultSettings);\r\n return query.createDataServiceRequestForOperation(\r\n 'GetAllExampleEntities',\r\n false,\r\n DataServiceEntities.ExampleEntityExtensionClass,\r\n 'true',\r\n { bypassCache: 'none', returnEntity: 'DataServiceEntities.IExampleEntity' },\r\n {}\r\n );\r\n}\r\n\r\nexport function getAllExampleEntitiesAsync(context: IContext): AsyncResult {\r\n const request = createGetAllExampleEntitiesInput(context.queryResultSettings || {});\r\n return callActionOrExecute(request, context.callerContext);\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\nimport { getStateCityAsync } from './SearchItemsDataActionExtension.g';\r\nimport { IStatesEntity } from './SearchItemsDataServiceEntities.g';\r\n\r\n/**\r\n * Getaddresses Input Action\r\n */\r\n\r\nexport interface IITSStateCityInput extends Msdyn365.IActionInput {\r\n zipCode: string;\r\n}\r\nexport class GetZipCodeInput implements Msdyn365.IActionInput {\r\n public zipCode: string;\r\n // TODO: Construct the input needed to run the action\r\n constructor(zipCode: string) {\r\n this.zipCode = zipCode;\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 = () => `getStateCity`;\r\n public getCacheObjectType = () => 'getStateCity';\r\n public dataCacheType = (): Msdyn365.CacheType => 'none';\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\nexport async function getStateCityAction(request: IITSStateCityInput, ctx: Msdyn365.IActionContext): Promise {\r\n if (request.zipCode) {\r\n try {\r\n const result = await getStateCityAsync({ callerContext: ctx }, request.zipCode); //calling getStateCityAsync API\r\n if (result) {\r\n return result;\r\n }\r\n } catch (error) {\r\n console.log('Error', error);\r\n }\r\n }\r\n return null;\r\n}\r\n\r\nexport default Msdyn365.createObservableDataAction({\r\n action: >getStateCityAction,\r\n // TODO: Give your data action a unique id\r\n id: `getStateCity`\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"],"names":["GetaddressesInput","constructor","customerAccount","getCacheKey","getCacheObjectType","dataCacheType","this","async","getCustomerAddressesAction","request","ctx","result","getCustomerAddressAsync","callerContext","error","console","log","Msdyn365","action","id","ITSInvoiceSearchResponseExtensionClass","odataObject","Invoices","undefined","i","length","className","substr","lastIndexOf","concat","EntityClasses","StatesEntityExtensionClass","State","City","ExtensionProperties","ProductEntityExtensionClass","RecId","parseInt","ProductNumber","AltItemId","Attributes","ProductAttributeParameterExtensionClass","UseAltItemId","AltItemRecId","ProductSuperseded","AlternativeText","AddressEntityExtensionClass","CustomerAccountNumber","Description","Purpose","Street","Phone","FullAddress","ThreeLetterISORegionName","ZipCode","LogisticsLocationRecordId","LogisticsLocationId","AddressTypeValue","RecordId","Name","DataTypeValue","TextValue","BooleanValue","AttributeValueId","ITSSearchItemPartResponseExtensionClass","FoundProducts","NotFoundItems","ITSCustomerAddressResponseExtensionClass","Addresses","getSortedInvoicesInput","invoiceSearchCriteria","top","skip","DataServiceQuery","createDataServiceRequestForOperation","DataServiceEntities","bypassCache","returnEntity","getSortedInvoicesAsync","context","callActionOrExecute","getStateCityInput","zipCode","getStateCityAsync","getProductsByItemPartNumberInput","itemPartNumber","strictSearch","StrictSearch","getProductsByItemPartNumberAsync","getCustomerAddressInput","getOrderHistoryByPONumberInput","queryResultSettings","pONumber","businessPartnerId","resultSettings","getOrderHistoryByPONumberAsync","GetZipCodeInput","getStateCityAction"],"sourceRoot":""}