Skip to content

Frontend views

A frontend view is a simplified view of a PIM entity that is intended for consumption in an external system such as a webshop.

Simplified means that it is targeted to a specific segmentation.

PIM exposes the following views:

  • Published product views
  • Product hierarchy views
  • Attribute views
  • Attribute predefined values views
  • Brand views
  • Attribute group views
  • Global list views

Requesting views

Frontend views are fetched via the api and when doing so the known segmentation dimensions must be passed in the request.

For example:

Suppose the external system is a webshop (Channel dimension) that operates in Denmark (Market dimension). The end user is using a tablet (Device dimension) and is physically located in Denmark (speaks Danish, so Translation culture dimension is da-DK).

With this information, the frontend can request a view of say a product catalogue item targeted to that specific segmentation.

This way knowledge on how to resolve segmented values is kept internally in PIM and frontend doesn't need to understand PIM's complex internal data model.

Lifecycle of views

Frontend views for some entity only exist for a specific segmentation if the segmentation has its Auto publish to frontend flag set to true. This means that if the flag is disabled, any existing views related to that segmentation will be deleted.

Under the assumption that the flag is enabled, then views are created, updated, and deleted automatically as a result of internal events in PIM.

Some views follow the lifecycle of the entities they represent, so in effect the views exist if the entities they represent exist.

Other views have additional criterias.

Published product views for example has the additional requirement that the product catalogue item they represent must have state Published. If the state is changed to Unpublished then the view will be deleted.

In general there's no need to manually manage or rebuild views, however PIM does allow rebuilding the views on demand if needed for some reason.

View maintainance

It is the responsibility of the PIM job runner to maintain frontend views via the WatchAllGeneratedViewsAndModels job.

The job is scheduled to run automatically in 1-minute intervals but may also be triggered manually if needed (under System administration → Jobs → Open Dashboard → Recurring Jobs).