Skip to main content
Skip table of contents

Allowed and available components

During the configuration process, each component may be one of the several states:

  • Not allowed

  • Allowed but not available

  • Allowed and available

These states can be summarized:

State

Description

Not allowed

A component is blocked by one or more rules.

Typical handling in the user experience:

  • A component is likely to be hidden from view since it is not currently valid or selectable

Allowed but not available

A component is generally allowed however it is not in stock, does not have inventory, or otherwise purchaseable.

Typical handling in the user experience:

  • Depending on the use case, the component may be displayed, but in a non-selectable state. The component may have additional badges or status information, for example, Backorder. UX may provide additional actions, such as back-in-stock notifications.

Allowed and available

A component can be selected

Typical handling in the user experience:

  • A component is shown in the selectable state

Controller handling

When using the Javascript API, the controller class automatically performs state and availability calculations. Developers can enhance the out of the box functionality by handling events:

  • isAllowed — perform additional component validations. Note that the standard functionality, such as rules calculations, always apply and cannot be disabled

  • isAvailable — perform component inventory or stock validation. If the event handler returns true, the out of the box inventory validation still will apply.

  • getInventory — return an available inventory for a component.

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.