Skip to content

Commit

Permalink
Enhance create page blocks doc (#2514)
Browse files Browse the repository at this point in the history
* create_custom_page_block.md: Highlight that new block must be enabled in BO
* data_migration_actions.md: Add `add_block_to_available_blocks` example

---------

Co-authored-by: Thorsten Reiter <34274688+reithor@users.noreply.github.com>
Co-authored-by: Marek Nocoń <mnocon@users.noreply.github.com>
  • Loading branch information
3 people authored Oct 14, 2024
1 parent 0b4f8c2 commit 2a6e0f0
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@ The following migration actions are available out of the box:
- `remove_drafts` (Content type Update)
- `remove_field_by_identifier` (Content type Update)
- `unassign_content_type_group` (Content type Update)
- `add_block_to_available_blocks` (Content type Update)
- `assign_role_to_user` (Role Create / Update)
- `assign_role_to_user_group` (Role Create / Update)
- `assign_user_to_role` (User Create / Update)
Expand Down Expand Up @@ -103,6 +104,7 @@ mode: Update
- { action: unassign_content_type_group, value: 'Content' }
- { action: remove_field_by_identifier, value: 'short_title' }
- { action: remove_drafts, value: null }
- { action: add_block_to_available_blocks, fieldDefinitionIdentifier: 'page', blocks: ['event'] }
```

### Roles
Expand Down
7 changes: 5 additions & 2 deletions docs/content_management/pages/create_custom_page_block.md
Original file line number Diff line number Diff line change
Expand Up @@ -132,5 +132,8 @@ The following UDW configuration is used so only an `event` typed content item ca

For more information, see [UDW configuration](browser.md#udw-configuration).

Your custom page block is now ready.
Before you can use it in Page Builder, you must [enable it in Page field settings]([[= user_doc =]]/content_management/configure_ct_field_settings/#block-display).
Your custom page block is now registered in the system.

!!! caution

To use the new block in Page Builder, add it to the list of available blocks in a given content type's settings. This can be done manually in [Page field settings]([[= user_doc =]]/content_management/configure_ct_field_settings/#block-display) or by using the migration action [`add_block_to_available_blocks`](data_migration_actions.md#content-types).

0 comments on commit 2a6e0f0

Please sign in to comment.