Skip to main content

Overview

Every Store component reads its configuration from one Store Settings (FS_PORTAL_Store_Settings__mdt) record. Rather than repeating page paths and business rules on each component, you fill them in once here and each component names the record it should use. You can keep more than one record — one per storefront — and point different pages at different records.
The package does not ship a Store Settings record. Create one before you place any Store component, or every component reports that it cannot resolve its settings. Components default their Store Settings property to Default, so naming your first record Default means you can leave that property alone.

Create the Record

1

Open the custom metadata type

From Setup, go to Custom Code > Custom Metadata Types, find FS Portal Store Settings, and click Manage Records.
2

Create a new record

Click New. Set Label and FS Portal Store Settings Name — the name is what a component’s Store Settings property refers to, so Default is the convenient choice for your first record.
3

Fill in the page URLs

These five are required, and each has a sensible default. Set them to your real page paths.
Each URL takes either a path beginning with / for a page in this portal, or a full https:// URL for a page outside it. External URLs let a shopper move between the Store and a CMS site.
4

Choose how the cart opens

Set Show Cart As (FS_PORTAL_Show_Cart_As__c):
  • Drawer — clicking the Cart Indicator slides the cart in over the current page.
  • Page — clicking the Cart Indicator navigates to the Cart page.
5

Save

Click Save. Two validation rules run here, so a record that would break at runtime is rejected at save time — see Validation Rules below.

Which Products the Store Shows

Product Business Unit Ids (FS_PORTAL_Product_Business_Unit_Ids__c) takes a comma-separated list of Business Unit Ids. Only products belonging to those business units appear in this storefront. Leave it blank to show products from every business unit.

Which Business Unit the Order Gets

Every cart becomes an Order, and every Order needs a Business Unit. Cart Business Unit Logic (FS_PORTAL_Cart_Business_Unit_Logic__c) decides which one:
From First Added Product re-resolves if the shopper empties the cart and starts again — it is not permanently pinned by the very first product they ever added.

Currency

Currency ISO Codes (FS_PORTAL_Currency_Iso_Codes__c) is a comma-separated list, for example USD,EUR,GBP. The Store shows a currency picker offering exactly these, and the first code in the list is the fallback when the shopper’s own currency is not among them. The setting applies only to multi-currency orgs. In a single-currency org the Store uses the org currency and hides the picker.
Prices, and which products appear at all, depend on the selected currency — a product needs a price book entry in that currency to be shown. Switching currency with items already in the cart clears the cart, after warning the shopper.

Guest Checkout

These fields only matter when you let shoppers buy without an account. See Guest Checkout for the full picture.

Extension Points

Two fields let you replace built-in behavior with your own Apex. Leave both blank for the shipped behavior.

Validation Rules

Three validation rules protect combinations that would otherwise fail silently at runtime.

Pointing a Component at a Record

Every Store component has a Store Settings property holding the record’s name, defaulting to Default. To run two storefronts, create a second Store Settings record and set that name on the components of the second storefront’s pages.
A component pointed at a record that does not exist cannot resolve its settings and reports an error instead of rendering. Check for typos in the name, and remember it is the record’s name, not its label.

Limitations and Common Pitfalls with Store Settings

  • No record ships with the package. Create one first. Naming it Default saves setting the property on every component.
  • The five page URLs are required for a reason. A missing Checkout Page URL, for instance, leaves the shopper’s Continue click reporting that the checkout page is not configured.
  • Business unit fields do two different jobs. Product Business Unit Ids filters what the Store shows; Cart Business Unit Logic decides what the Order gets. Setting one does not set the other.
  • Currency ISO Codes is ignored in single-currency orgs, so a picker you expected will not appear.
  • The record’s name, not its label, is what components reference. Renaming the label is safe; renaming the name breaks every component pointing at it.