Skip to content

07. Backdrop Layouts and OG

Alejandro Cremaschi edited this page May 28, 2022 · 3 revisions

Backdrop's version of Drupal's Panels is called Layouts, and it's part of core.

Like Panels, Layouts allow you to place blocks in different regions of the screen. Organic Groups provides the following Layouts plugins:

  • "Content Create Links" block. This is parallel to D7 OG's "Content Create Links" for Panels. When placed in a layout region, this block will create a link to the node/add form appropriate for the OG group being viewed. Important: in order to get the full functionality of this block, you must enable Entity Reference Prepopulate. See this video tutorial.
  • The following "visibility conditions" for layouts are available (similar to Panels' "selection rules"):
    • OG: Node is a an OG group: allows you to show a layout only if the content being viewed is an OG group
    • OG: Node is a an OG group content: allows you to show a layout only if the content being viewed is an OG group content
    • OG: User permission in group: allows you to show a layout only if the logged in user has specific permissions in an OG group
    • OG: User membership in group: allows you to show a layout only if the logged in user is (or is not) a member of the group being shown
  • The following block is available when enabling OG UI
    • OG: Membership links: displays a subscribe/unsubscribe link when viewing a group

Not yet ported

  • OG membership from a group node and user: this relationship plugin will allow you to get an OG membership entity based on the group being viewed and logged in user.