Skip to content
Zotonic
  • Start
  • Guides
  • Reference
  • Releases

Live search

Search across all Zotonic content

Type at least two characters

Results are matched against titles, summaries and topics as you type.

Notifications
  • Reference
  • Backend developer
  • Search and discovery
  • Notification
  • Index

observe_pivot_fields/3

Foldr to change or add pivot fields for the main pivot table. The rsc contains all rsc properties for this resource, including pivot properties. Fold with a map containing the pivot fields.

Type:

foldl

Return:

#pivot_fields{} properties:

  • id: m_rsc:resource_id()
  • raw_props: m_rsc:props()

Edit on GitHub

Related documentation

Notifications

observe_custom_pivot/2

Add custom pivot fields to a resource’s search index (map) Result is a single tuple or list of tuples {pivotname, props} , where…

Notifications

observe_pivot_rsc_data/3

Fold over the resource props map to extend/remove data to be pivoted

Notifications

observe_rsc_pivot_done/2

Signal that a resource pivot has been done.

Notifications

observe_pivot_update/3

Pivot just before a m_rsc_update update. Used to pivot fields before the pivot itself.

Notifications

observe_search_query_normalize_value/2

Normalize a search value for queries and indexing. An example is the normalization of texts by transliteration and removal of accents.

Notifications

observe_search_query/2

Map a custom search term to a #search_sql_term{} record.

Notifications

observe_rsc_query_item/2

Send a notification that the resource ‘id’ is added to the query query_id.

Notifications

observe_search_query_term/2

Map a custom search term to a #search_sql_term{} record.

Notifications

observe_development_make/2

Runs the development make process and reloads newly compiled BEAM files after a manual request.

GitHub © 2026 Zotonic