Set

From The Smartest Wiki
Jump to: navigation, search

Sets are an important feature in Smartest that allow you create groups of your Items that are more semantically meaningful than the entire list of all items of a given model. Sets are always model-specific, and listing items in a template can normally only be done from a set.

There are two types of set that function differently: Normal "static" sets, and saved "dynamic" queries. Normal, or 'static' sets essentially behave like folders, and the user manually puts items into the folder, and controls their order. Dynamic sets are saved queries that include or exclude items depending on a set of rules that are applied to the items' properties.

The two types of set are interchangeable externally - that is, one can be substituted for the other without any other adjustments needing to be made.

Sets are represented by class SmartestCmsItemSet and in the database by table Sets.