Broadleaf Microservices
  • v1.0.0-latest-prod

Content Services Data Model

Data Diagram

The Content Services data model stores the content zones, models, items and associated data along with any defined theme fields.

Content Services Data Model
Figure 1. Content and Theme Entities Data Model

Content Model

A Content Model provides a way to define various types of content. A model consists of a set of field definitions used to create structured content. It can also provide a base URI for retrieving associated content items

BLC_CONTENT_MODEL

Field Description

ID

Unique row ID

CONTEXT_ID

Logical ID. Allows for sandbox versions.

NAME

A unique name for the content model, used for retrieval.

ADDRESSABLE_BY_URI

Whether all Content Items of this model can be retrieved by navigating to a uri from a storefront app

URI

SEO-friendly URI to identify Content Items of this model.

FIELDS

The list of fields that make up this content model

BLC_CONTENT_FIELD

Note
Introduced in Content 1.1.0, Release Train 2.0.0

Represents meta-info about fields defined for a ContentModel. Values are stored by FieldData.

Field Description

ID

Unique row ID

CONTEXT_ID

Logical ID. Allows for sandbox versions.

CONTENT_MODEL_CONTEXT_ID

The id of the parent model.

NAME

A name used to reference the field in the business logic. This should be unique per model and is referenced by BLC_FIELD_DATA to map values to meta-info.

LABEL

A display label

TYPE

The field type such as STRING, HTML, DATE.

REFERENCE_TYPE

If TYPE is REFERENCE then this field indicates what kind of reference, PRODUCT, CATEGORY, or CONTENT for another content item.

ALLOWED_MODELS

When the referenceType is CONTENT, this field holds allowed content models. If empty, allows all.

COLLECTION

Whether this field represents a collection.

REQUIRED

Whether the field is required.

HELP_TEXT

Help text to display in the Admin.

HINT

Hint to display in the admin.

DISPLAY_ORDER

Relative display order compared to other fields of the same model.

TRANSLATABLE

Whether the field is translatable.

ATTRIBUTES

Additional arbitrary attributes.

Content Item

Content Items represent structured content created by admin users. This content’s fields are defined by its associated Content Model.

BLC_CONTENT_ITEM

Field Description

ID

Unique row ID

CONTEXT_ID

Logical ID. Allows for sandbox versions.

NAME

A unique name for the content item, used for retrieval.

URI

SEO-friendly URI to identify this content item.

ACTIVE_START_DATE

Defines the beginning time for which this content item is active.

ACTIVE_END_DATE

Defines the ending time for which this content item is active.

MODEL_CONTEXT_ID

The content model for this content.

LAST_UPDATED

The date this content item was last updated.

MODEL_NAME

The name of the content model for this content.

Field Data

The Field Data contain the actual user configured data for individual content items.

BLC_CONTENT_FIELD_DATA

Field Description

ID

Unique row ID

CONTEXT_ID

Logical ID. Allows for sandbox versions.

CONTENT_ITEM_ID

The content item this field belongs to

FIELD_NAME

The content field’s name

FIELD_VALUE

The field’s value

Content Zone

Content Zones represent logical groupings of content that are requested by the frontend. Zones consist of a set of default content items as well as any number of alternate sets of items.

BLC_CONTENT_ZONE

Field Description

ID

Unique row ID

CONTEXT_ID

Logical ID. Allows for sandbox versions.

NAME

A unique name for the content zone, used for retrieval.

ALLOWED_MODELS

A list of all the allowed content models that this zone accepts.

DEFAULT_ITEMS

The list of default content zone items that are displayed if no alternate sets match their display rules.

ALTERNATE_ITEM_SETS

A list of content zone item lists, one of which may be active instead of the default depending on its display rules.

Theme Field Group

A Theme Field Group is simply a grouping of theme fields that give the API response a predictable structure.

BLC_THEME_FIELD_GROUP

Field Description

ID

Unique row ID

CONTEXT_ID

Logical ID. Allows for sandbox versions.

LABEL

The friendly display label for this field

GROUP_NAME

A unique name for the field, used for retrieval

Theme Field

Theme Fields hold the actual field name and value. A field must be part of a theme field group.

BLC_THEME_FIELD

Field Description

ID

Unique row ID

CONTEXT_ID

Logical ID. Allows for sandbox versions.

LABEL

The friendly display label for this field

FIELD_NAME

A unique name for the field, used for retrieval

FIELD_TYPE

The type of this content field

FIELD_VALUE

The field’s value

Content Foldering

Content Folders are used to organize content items into a hierarchy. A folder can contain any number of content items and other folders.

Note
Introduced in Content Services 1.1.2

BLC_CONTENT_FOLDER

Field Description

ID

Unique row ID

CONTEXT_ID

Logical ID. Allows for sandbox versions.

NAME

The name of the folder

PARENT_FOLDER_CONTEXT_ID

This folder’s parent folder if it exists

ATTRIBUTES

Additional arbitrary attributes.

BLC_CONTENT_FOLDER_ITEM

Field Description

ID

Unique row ID

CONTEXT_ID

Logical ID. Allows for sandbox versions.

FOLDER_CONTEXT_ID

The folder this item belongs to

CONTENT_ITEM_CONTEXT_ID

The content item that has been added to the folder

BLC_STARRED_ITEM

Starred Items are used to track which content items a user has starred.

Field Description

ID

Unique row ID

CONTEXT_ID

Logical ID. Allows for sandbox versions.

USER_ID

The user that has starred the content item

CONTENT_ITEM_ID

The content item that has been marked as starred

Broadleaf Common Data Features

Content Zone, Content Item, Field Data, Theme Field Group and Theme Field are Catalog Trackable, which includes Sandbox Trackable behavior.

Content Model is Catalog Trackable but NOT Sandbox Trackable.