Modify Product definitions templates

Abstract

You can modify Product definition templates to suit your business needs.

There are 4 product definitions: CommerceProductMasterKit, CommerceProductMaster, CommerceProductKit, and CommerceProduct. They can be used for any channel.

Users can control the default channel by modifying the product definitions template, located at C:\inetpub\AXRefStorefront\Website\Templates\Render_DynamicsProductDefinitions.cshtml.. If you are running Synchronization from the SDK, the template should also be updated in the SDK location.

  1. All properties that are not listed in a product definition will be exposed in the property bags: DynamicsProductProperties, DynamicsVariantProperties in the following format: name1=value1|name2=value2|etc. All values in property bags are XML encoded.

  2. To add a base property, which is a separate property outside of the property bag, the follwing lines needs to be added to a product definition:

    1. For a product property: <DefProperty axName="AXPropertyName">CSPropertyName</DefProperty>.

    2. For a variant property: <DefVariantProperty axName="AXPropertyName">CSPropertyName</DefVariantProperty>.

    You can omit the axName attribute if AXPropertyName and CSPropertyName are the same. The CS product property should match an Dynamics AX product master property, and the CS variant property should be defined in a product in Dynamics AX.

    Note

    • Keep the cases as the following: DefProperty and DefVariantProperty. The Catalog import is case-sensitive, and those properties will be ignored if cases are different.

    • Do not remove or rename existing properties, as that could break the solution. If needed, you can rename axName.

    • If you have a previous catalog synchronized during a previous release, during the first new synchronization, you must run a full synchronization. After that synchronization is completed, reset all caches, delete and update the data templates, and refresh the caches again before publishing and indexing the site.