Share This Post

Dynamics 365 Deployment Guidelines

This article is a Dynamics 365 Deployment guide that shows how to enable the requirements for Goods and Services Tax (GST) in the Microsoft Dynamics 365 for Retail localization for India. This sample is part of Retail software development kit (SDK). This sample consists of the extensions for the Commerce runtime (CRT). To run this sample, you must modify and build CRT projects.

We recommend that use you an unmodified Retail SDK to make the changes that are described in this article. We also recommend that you use a source control system, such as the Microsoft Visual Studio Online (VSO), where no files have been changed yet. Some steps in the procedures in this article differ, depending on the version of Microsoft Dynamics 365 for Retail that you’re using.

Dynamics 365 Deployment Prerequisites

Make sure that the Visual C++ Redistributable Packages are present on the machine you are running the Goods and Services Tax (GST) calculations on. It’s Retail server for the Cloud POS and MPOS online mode, MPOS machine itself for offline mode.

Development Environment

Follow these steps to set up the development environment so that you can test and extend the sample.

Dynamics 365 Deployment

Development Environment

The CRT extension components

The CRT extension components are included in CRT samples. To complete the following procedures, open CRT solution, CommerceRuntimeSamples.sln. You can find this solution under RetailSdk\SampleExtensions\CommerceRuntime.

Generic Tax Engine component

a. Find the Runtime.Extensions.GenericTaxEngine project, and build it.

b. Find the following files:

1. For Retail 7.3.1

  • In the Extensions.GenericTaxEngine\bin\Debug folder:

Contoso.Commerce.Runtime.Extensions.GenericTaxEngine.dll

  • In the Reference\Newtonsoft.Json\9.0.0.0 folder:

Newtonsoft.Json.dll

  • In the Reference\TaxEngine folder:
    1. Microsoft.Dynamics365.Tax.Core.dll
    2. Microsoft.Dynamics365.Tax.DataAccessor.dll
    3. Microsoft.Dynamics365.Tax.DataAccessFramework.dll
    4. Microsoft.Dynamics365.Tax.DataModel.dll
    5. Microsoft.Dynamics365.Tax.Metadata.dll
    6. Microsoft.Dynamics365.LocalizationFramework.dll
    7. Microsoft.Dynamics365.LocalizationFrameworkCore.dll
    8. Microsoft.Dynamics365.ElectronicReportingMapping.dll
    9. Microsoft.Dynamics365.XppSupportLayer.dll
  • Find the following folders in the Reference\Z3 folder: x86 and x64

2. Retail 7.3.2 and later

  • In the Extensions.GenericTaxEngine\bin\Debug folder:

Contoso.Commerce.Runtime.GenericTaxEngine.dll

  • In the References\Newtonsoft.Json.9.0.1\lib\net45 folder:

Newtonsoft.Json.dll

  • In the References\Microsoft.Dynamics.AX.TaxEngine.7.3.42\XppModule\TaxEngine\bin folder:
    1. Microsoft.Dynamics365.LocalizationFramework.dll
    2. Microsoft.Dynamics365.Tax.Core.dll
    3. Microsoft.Dynamics365.Tax.DataAccessFramework.dll
    4. Microsoft.Dynamics365.Tax.DataAccessor.dll
    5. Microsoft.Dynamics365.Tax.DataModel.dll
    6. Microsoft.Dynamics365.Tax.Metadata.dll
  • In References\Microsoft.Dynamics.AX.ElectronicReporting.7.3.42\XppModule\ElectronicReporting\bin folder:
  1. Microsoft.Dynamics365.ElectronicReportingMapping.dll
  2. Microsoft.Dynamics365.LocalizationFrameworkCore.dll
  3. Microsoft.Dynamics365.XppSupportLayer.dll
  • Find the following folders in the $(SdkReferencesPath)\Z3.4.5.0\lib\net40 folder: x86 and x64

3. Retail 8.1.3 and later

  • In the Extensions.GenericTaxEngine\bin\Debug folder:

Contoso.Commerce.Runtime.GenericTaxEngine.dll

  • In the References\Newtonsoft.Json.9.0.1\lib\net45 folder:

Newtonsoft.Json.dll

  • In the References\Microsoft.Dynamics.AX.TaxEngine.8.0.26\XppModule\TaxEngine\bin folder:
    1. Microsoft.Dynamics365.LocalizationFramework.dll
    2. Microsoft.Dynamics365.Tax.Core.dll
    3. Microsoft.Dynamics365.Tax.DataAccessFramework.dll
    4. Microsoft.Dynamics365.Tax.DataAccessor.dll
    5. Microsoft.Dynamics365.Tax.DataModel.dll
    6. Microsoft.Dynamics365.Tax.Metadata.dll
  • In References\Microsoft.Dynamics.AX.ElectronicReporting.8.0.26\XppModule\ElectronicReporting\bin folder:
    1. Microsoft.Dynamics365.ElectronicReportingMapping.dll
    2. Microsoft.Dynamics365.LocalizationFrameworkCore.dll
    3. Microsoft.Dynamics365.XppSupportLayer.dll
  • Find the following folders in the $(SdkReferencesPath)\\Z3.4.5.0\lib\net40 folder: x86 and x64

c. Copy the 11 assembly files, and both x64 and x86 folders to the CRT extensions folder:

  • Retail Server: Copy the assemblies to \bin\ext folder under the Microsoft Internet Information Services (IIS) Retail server site location.
  • Local CRT on the Modern POS: Copy the assemblies to the \ext folder under the local CRT client broker location.

d. Find the extensions configuration file for CRT:

  • Retail Server: The file is named as commerceruntime.ext.config, and it’s in the bin\ext folder under the IIS Retail server site location.
  • Local CRT on the Modern POS: The file is named CommerceRuntime.MPOSOffline.Ext.config, and it’s under the local CRT client broker location.

e. Register the CRT change in the extensions configuration file.

1. For Retail 7.3.1

<add source=”assembly” value=”Contoso.Commerce.Runtime.Extensions.GenericTaxEngine” />

2. Retail 7.3.2 and later

<add source=”assembly” value=”Contoso.Commerce.Runtime.GenericTaxEngine” />

3. Retail 8.1.3 and later

<add source=”assembly” value=”Contoso.Commerce.Runtime.GenericTaxEngine” />

Production Environment for Dynamics 365 Deployment

Follow these steps to create Microsoft Dynamics 365 Deployment packages that contain Retail components, and to apply the packages in a production environment.

  • In the commerceruntime.ext.config and the CommerceRuntime.MPOSOffline.Ext.config configuration files under the RetailSdk\Assets folder, add the following lines to the composition section.

1. For Retail 7.3.1

<add source=”assembly” value=”Contoso.Commerce.Runtime.Extensions.GenericTaxEngine” />

2. Retail 7.3.2 and later

<add source=”assembly” value=”Contoso.Commerce.Runtime.GenericTaxEngine” />

3. Retail 8.1.3 and later

<add source=”assembly” value=”Contoso.Commerce.Runtime.GenericTaxEngine” />

  • In the Customization.settings package customization configuration file under the RetailSdk\BuildTools folder, add the following lines to the ItemGroup section to include the CRT extensions in deployable packages.

1. For Retail 7.3.1

<ISV_CommerceRuntime_CustomizableFile Include=”$(SdkReferencesPath)\Contoso.Commerce.Runtime.Extensions.GenericTaxEngine.dll” />
<ISV_CommerceRuntime_CustomizableFile Include=”$(SdkReferencesPath)\TaxEngine\Microsoft.Dynamics365.Tax.Core.dll” />
<ISV_CommerceRuntime_CustomizableFile Include=”$(SdkReferencesPath)\TaxEngine\Microsoft.Dynamics365.Tax.Metadata.dll” />
<ISV_CommerceRuntime_CustomizableFile Include=”$(SdkReferencesPath)\TaxEngine\Microsoft.Dynamics365.Tax.DataAccessor.dll” />
<ISV_CommerceRuntime_CustomizableFile Include=”$(SdkReferencesPath)\TaxEngine\Microsoft.Dynamics365.Tax.DataAccessFramework.dll” />
<ISV_CommerceRuntime_CustomizableFile Include=”$(SdkReferencesPath)\TaxEngine\Microsoft.Dynamics365.Tax.DataModel.dll” />
<ISV_CommerceRuntime_CustomizableFile Include=”$(SdkReferencesPath)\TaxEngine\Microsoft.Dynamics365.LocalizationFramework.dll” />
<ISV_CommerceRuntime_CustomizableFile Include=”$(SdkReferencesPath)\TaxEngine\Microsoft.Dynamics365.LocalizationFrameworkCore.dll” />
<ISV_CommerceRuntime_CustomizableFile Include=”$(SdkReferencesPath)\TaxEngine\Microsoft.Dynamics365.ElectronicReportingMapping.dll” />
<ISV_CommerceRuntime_CustomizableFile Include=”$(SdkReferencesPath)\TaxEngine\Microsoft.Dynamics365.XppSupportLayer.dll” />
<ISV_CommerceRuntime_CustomizableFile Include=”$(SdkReferencesPath)\Newtonsoft.Json\9.0.0.0\Newtonsoft.Json.dll” />

2. Retail 7.3.2 and later

<ISV_CommerceRuntime_CustomizableFile Include=”$(SdkReferencesPath)\Contoso.Commerce.Runtime.GenericTaxEngine.dll” />
<ISV_CommerceRuntime_CustomizableFile Include=”$(SdkReferencesPath)\Microsoft.Dynamics.AX.TaxEngine.7.3.42\XppModule\TaxEngine\bin\Microsoft.Dynamics365.Tax.Core.dll” />
<ISV_CommerceRuntime_CustomizableFile Include=”$(SdkReferencesPath)\Microsoft.Dynamics.AX.TaxEngine.7.3.42\XppModule\TaxEngine\bin\Microsoft.Dynamics365.Tax.Metadata.dll” />
<ISV_CommerceRuntime_CustomizableFile Include=”$(SdkReferencesPath)\Microsoft.Dynamics.AX.TaxEngine.7.3.42\XppModule\TaxEngine\bin\Microsoft.Dynamics365.Tax.DataAccessor.dll” />
<ISV_CommerceRuntime_CustomizableFile Include=”$(SdkReferencesPath)\Microsoft.Dynamics.AX.TaxEngine.7.3.42\XppModule\TaxEngine\bin\Microsoft.Dynamics365.Tax.DataAccessFramework.dll” />
<ISV_CommerceRuntime_CustomizableFile Include=”$(SdkReferencesPath)\Microsoft.Dynamics.AX.TaxEngine.7.3.42\XppModule\TaxEngine\bin\Microsoft.Dynamics365.Tax.DataModel.dll” />
<ISV_CommerceRuntime_CustomizableFile Include=”$(SdkReferencesPath)\Microsoft.Dynamics.AX.TaxEngine.7.3.42\XppModule\TaxEngine\bin\Microsoft.Dynamics365.LocalizationFramework.dll” />
<ISV_CommerceRuntime_CustomizableFile Include=”$(SdkReferencesPath)\Microsoft.Dynamics.AX.ElectronicReporting.7.3.42\XppModule\ElectronicReporting\bin\Microsoft.Dynamics365.LocalizationFrameworkCore.dll” />
<ISV_CommerceRuntime_CustomizableFile Include=”$(SdkReferencesPath)\Microsoft.Dynamics.AX.ElectronicReporting.7.3.42\XppModule\ElectronicReporting\bin\Microsoft.Dynamics365.ElectronicReportingMapping.dll” />
<ISV_CommerceRuntime_CustomizableFile Include=”$(SdkReferencesPath)\Microsoft.Dynamics.AX.ElectronicReporting.7.3.42\XppModule\ElectronicReporting\bin\Microsoft.Dynamics365.XppSupportLayer.dll” />
<ISV_CommerceRuntime_CustomizableFile Include=”$(SdkReferencesPath)\Newtonsoft.Json.9.0.1\lib\net45\Newtonsoft.Json.dll” />

3. Retail 8.1.3 and later

<ISV_CommerceRuntime_CustomizableFile Include=”$(SdkReferencesPath)\Contoso.Commerce.Runtime.GenericTaxEngine.dll” />
<ISV_CommerceRuntime_CustomizableFile Include=”$(SdkReferencesPath)\Microsoft.Dynamics.AX.TaxEngine.8.0.26\XppModule\TaxEngine\bin\Microsoft.Dynamics365.Tax.Core.dll” />
<ISV_CommerceRuntime_CustomizableFile Include=”$(SdkReferencesPath)\Microsoft.Dynamics.AX.TaxEngine.8.0.26\XppModule\TaxEngine\bin\Microsoft.Dynamics365.Tax.Metadata.dll” />
<ISV_CommerceRuntime_CustomizableFile Include=”$(SdkReferencesPath)\Microsoft.Dynamics.AX.TaxEngine.8.0.26\XppModule\TaxEngine\bin\Microsoft.Dynamics365.Tax.DataAccessor.dll” />
<ISV_CommerceRuntime_CustomizableFile Include=”$(SdkReferencesPath)\Microsoft.Dynamics.AX.TaxEngine.8.0.26\XppModule\TaxEngine\bin\Microsoft.Dynamics365.Tax.DataAccessFramework.dll” />
<ISV_CommerceRuntime_CustomizableFile Include=”$(SdkReferencesPath)\Microsoft.Dynamics.AX.TaxEngine.8.0.26\XppModule\TaxEngine\bin\Microsoft.Dynamics365.Tax.DataModel.dll” />
<ISV_CommerceRuntime_CustomizableFile Include=”$(SdkReferencesPath)\Microsoft.Dynamics.AX.TaxEngine.8.0.26\XppModule\TaxEngine\bin\Microsoft.Dynamics365.LocalizationFramework.dll” />
<ISV_CommerceRuntime_CustomizableFile Include=”$(SdkReferencesPath)\Microsoft.Dynamics.AX.ElectronicReporting.8.0.26\XppModule\ElectronicReporting\bin\Microsoft.Dynamics365.LocalizationFrameworkCore.dll” />
<ISV_CommerceRuntime_CustomizableFile Include=”$(SdkReferencesPath)\Microsoft.Dynamics.AX.ElectronicReporting.8.0.26\XppModule\ElectronicReporting\bin\Microsoft.Dynamics365.ElectronicReportingMapping.dll” />
<ISV_CommerceRuntime_CustomizableFile Include=”$(SdkReferencesPath)\Microsoft.Dynamics.AX.ElectronicReporting.8.0.26\XppModule\ElectronicReporting\bin\Microsoft.Dynamics365.XppSupportLayer.dll” />
<ISV_CommerceRuntime_CustomizableFile Include=”$(SdkReferencesPath)\Newtonsoft.Json.9.0.1\lib\net45\Newtonsoft.Json.dll” />

  • Modify the following files to include the Z3 libraries in the deployable packages:
Deployable packages

Deployable packages

1. For Retail 7.3.1

  1. Packages\ModernPOS.Sdk\Sdk.ModernPOSSetup.csproj
  2. Packages\ModernPOSOffline.Sdk\Sdk.ModernPOSSetupOffline.csproj
  3. Packages\RetailServer\Sdk.RetailServerSetup.proj

a. Add the following lines to the ItemGroup section

<_bin_ext_Z3_x86_File Include=”..\..\References\Z3\x86\*.*” />
<_bin_ext_Z3_x64_File Include=”..\..\References\Z3\x64\*.*” />

b. For Sdk.ModernPOSSetup.csproj and Sdk.ModernPOSSetupOffline.csproj also add the following lines to the <Target Name=”CopyPackageFiles”> section

<Copy SourceFiles=”@(_bin_ext_Z3_x86_File)” DestinationFolder=”$(OutputPath)content.folder\CustomizedFiles\ClientBroker\ext\x86″ SkipUnchangedFiles=”true” />
<Copy SourceFiles=”@(_bin_ext_Z3_x64_File)” DestinationFolder=”$(OutputPath)content.folder\CustomizedFiles\ClientBroker\ext\x64″ SkipUnchangedFiles=”true” />

c. For Sdk.RetailServerSetup.proj also add the following lines to the <Target Name=”CopyPackageFiles”> section

<Copy SourceFiles=”@(_bin_ext_Z3_x86_File)” DestinationFolder=”$(OutputPath)content.folder\RetailServer\Code\bin\ext\x86″ SkipUnchangedFiles=”true” />
<Copy SourceFiles=”@(_bin_ext_Z3_x64_File)” DestinationFolder=”$(OutputPath)content.folder\RetailServer\Code\bin\ext\x64″ SkipUnchangedFiles=”true” />

2. Retail 7.3.2 and later

  1. Packages\ModernPOS.Sdk\Sdk.ModernPOSSetup.csproj
  2. Packages\ModernPOSOffline.Sdk\Sdk.ModernPOSSetupOffline.csproj
  3. Packages\RetailServer\Sdk.RetailServerSetup.proj

a. Add the following lines to the ItemGroup section

<_bin_ext_Z3_x86_File Include=”$(SdkReferencesPath)\Z3.4.5.0\lib\net40\x86\*.*” />
<_bin_ext_Z3_x64_File Include=”$(SdkReferencesPath)\Z3.4.5.0\lib\net40\x64\*.*” />

b. For Sdk.ModernPOSSetup.csproj and Sdk.ModernPOSSetupOffline.csproj also add the following lines to the <Target Name=”CopyPackageFiles”> section

<Copy SourceFiles=”@(_bin_ext_Z3_x86_File)” DestinationFolder=”$(OutputPath)content.folder\CustomizedFiles\ClientBroker\ext\x86″ SkipUnchangedFiles=”true” />
<Copy SourceFiles=”@(_bin_ext_Z3_x64_File)” DestinationFolder=”$(OutputPath)content.folder\CustomizedFiles\ClientBroker\ext\x64″ SkipUnchangedFiles=”true” />

c. For Sdk.RetailServerSetup.proj also add the following lines to the <Target Name=”CopyPackageFiles”> section

<Copy SourceFiles=”@(_bin_ext_Z3_x86_File)” DestinationFolder=”$(OutputPath)content.folder\RetailServer\Code\bin\ext\x86″ SkipUnchangedFiles=”true” />
<Copy SourceFiles=”@(_bin_ext_Z3_x64_File)” DestinationFolder=”$(OutputPath)content.folder\RetailServer\Code\bin\ext\x64″ SkipUnchangedFiles=”true” />

3. Retail 8.1.3 and later

  1. Packages\_SharedPackagingProjectComponents\Sdk.ModernPos.Shared.csproj”
  2. Packages\RetailServer\Sdk.RetailServerSetup.proj

a. Add the following lines to the ItemGroup section

<_bin_ext_Z3_x86_File Include=”$(SdkReferencesPath)\Z3.4.5.0\lib\net40\x86\*.*” />
<_bin_ext_Z3_x64_File Include=”$(SdkReferencesPath)\Z3.4.5.0\lib\net40\x64\*.*” />

b. For Sdk.ModernPos.Shared.csproj also add the following lines to the <Target Name=”CopyPackageFiles”> section

<Copy SourceFiles=”@(_bin_ext_Z3_x86_File)” DestinationFolder=”$(OutputPath)content.folder\CustomizedFiles\ClientBroker\ext\x86″ SkipUnchangedFiles=”true” />
<Copy SourceFiles=”@(_bin_ext_Z3_x64_File)” DestinationFolder=”$(OutputPath)content.folder\CustomizedFiles\ClientBroker\ext\x64″ SkipUnchangedFiles=”true” />

c. For Sdk.RetailServerSetup.proj also add the following lines to the <Target Name=”CopyPackageFiles”> section

<Copy SourceFiles=”@(_bin_ext_Z3_x86_File)” DestinationFolder=”$(OutputPath)content.folder\RetailServer\Code\bin\ext\x86″ SkipUnchangedFiles=”true” />
<Copy SourceFiles=”@(_bin_ext_Z3_x64_File)” DestinationFolder=”$(OutputPath)content.folder\RetailServer\Code\bin\ext\x64″ SkipUnchangedFiles=”true” />

  • Run msbuild for the whole Retail SDK to create the deployable packages.
  • Apply the packages via the Microsoft Dynamics Life Cycle Services (LCS) or manually.

Share This Post

Leave a Reply

avatar
  Subscribe  
Notify of
Skip to toolbar