You can use property bags to persist any key-value pairs in order to store settings for
a CHIP instance.
Using property bags, you can persist page settings in the following scopes:
- Personalization: User-specific settings (These settings supersede Customizing
and Configuration settings.)
- Customizing: Client-specific settings (These settings supersede
Configuration settings, but can be superseded by Personalization
settings.)
- Configuration: System-wide settings (These settings can be superseded by
Customizing and Personalization settings.)
As a prerequisite, you have to consume the bag contract in the CHIP definition
XML.
The bag property is then available in the CHIP API object.
Note CHIPs are not the
only objects that can store properties in bags. Property bags may also be created by a
client-side page builder.
Example:
Code Example
var oChipApi = this.getView().getViewData().chip,
aBagIds = oChipApi.bag.getBagIds();
oBag = oChipApi.bag.getBag("sample_bag");