Loading
Visual Studio Code Based Modeler for Consumer Goods Cloud
Table of Contents
Select Filters

          No results
          No results
          Here are some search tips

          Check the spelling of your keywords.
          Use more general search terms.
          Select fewer filters to broaden your search.

          Search all of Salesforce Help
          Domain Contract

          Domain Contract

          A domain represents the data type used in the Consumer Goods Cloud offline mobile app. When you create a picklist in an org for use in the offline mobile app, create a domain representing this picklist in the Domain Contract. Configure the picklist mapping between the picklist and the Domain in the Salesforce org. The data types are transformed to domain records after the sync with the offline mobile app.

          Required Editions

          Available in: Enterprise, Performance, and Unlimited Editions

          The Domain contract contains information about the domains used in the CG Cloud offline mobile app. Use the domain information to define the simple properties in business objects and list objects, and in declarations in processes. The Domains.xml file resides in $workspace/contracts/SharedWebData.

          There are several predefined domains available in Domains.xml that you can use when customizing contracts. For example: DomText, DomLanguage, DomBpaCustomerNumber, DomPKey, and DomBool. You can even reuse domains, for example - use of customer number (string) for an account and an order. Create domains to suit the requirements of your business.

          Use the DomainRepository root to define the details of a domain in the Domain contract. This table lists the elements of DomainRepository.

          Attribute Description Value/Pattern Required
          name Specifies the unique name of the domain. Uses the prefix Dom in the name. For example, DomText. String Yes
          baseType Specifies the data type of the domain. For information about the data types supported in the Consumer Goods Cloud offline mobile app, see Create Data Type.
          • Toggle. Toggle is shown as a list of values.
          • String
          • Boolean
          • Decimal
          Yes
          length Specifies the data column length. The maximum length of the toggle code that is saved to the database is 16. Integer Yes
          Initializer Use Initializer to define the default value for the domain or empty value. String Yes

          Sample XML code:

          <DomainRepository>
            <Domain name="DomAgrAgreementType" baseType="Toggle" length="16">
              <Initializer>
                <Default value="'Basic'" />
                <Empty value="" />
              </Initializer>
            </Domain>
          </DomainRepository>
          
           
          Loading
          Salesforce Help | Article