Custom action in Pages actionbar

173 views
Skip to first unread message

Heike Franosch

unread,
Dec 9, 2021, 6:12:18 AM12/9/21
to Magnolia User Mailing List
Hi all,

I have to migrate my custom action configured in the pages app.
In 5.7. it was configured within admincentral, in 6.2 the pages
configuration seems to be read from pages-app.yaml.

Is it possible to insert a custom action in the pages detail actionbar?

Thanks for any help,
Heike

Roman Kovařík

unread,
Dec 9, 2021, 6:22:54 AM12/9/21
to Magnolia User Mailing List, hfgm...@gmail.com
Hey Heike,

by clicking on "Show definition decorators" in the Definitions app you can see that the pages app is decorated by various modules, e.g. personalization.

Hope that helps
Roman

Heike Franosch

unread,
Dec 10, 2021, 12:19:36 PM12/10/21
to Magnolia User Mailing List, roman....@magnolia-cms.com, Heike Franosch
Hi Roman,

thanks for your answer, it helped to start with decorations.
I experimented a lot, but my action does not show up in the pages app.
I can easily add my action to the dam app. So, the config should be fine.
Is there something special about the pages app?

I have:
my-module/decorations/pages/apps/pages/pages.subApps.detail.actionbar.sections.pagePreviewActions.groups.myaction.yaml:
items:
  - name: myaction

my-module/decorations/pages/apps/pages/pages.subApps.detail.actions.myaction.yaml
class: com.xxx.MyActionDefinition
icon: 'icon-edit'
label: 'do something'
dialogId:my-module:pages/myDialog

MyActionDefinition extends OpenDialogActionDefinition

The definition app shows my action, so it is found and configured.
But the action is never shown. I tried setting the availabilty explicit, but it did not help.

Thanks, Heike

Roman Kovařík

unread,
Dec 13, 2021, 2:05:15 AM12/13/21
to Magnolia User Mailing List, hfgm...@gmail.com, Roman Kovařík
There is still the compatibility pages app which is actually hidden in the app launcher by default.
The new framework pages app decorator location would be my-module/decorations/pages-app/apps/pages-app.subApps.detail.actions.myaction.yaml.

Heike Franosch

unread,
Dec 13, 2021, 3:25:08 AM12/13/21
to Magnolia User Mailing List, roman....@magnolia-cms.com, Heike Franosch
Hi Roman,

thanks, that's it.
It's tricky because the config in admincentral was in pages. What's the difference between pages and pages-app?
Both stil exist and influence the system.

Thanks so much, it helped a lot :-)
Heike

Roman Kovařík

unread,
Dec 13, 2021, 3:38:13 AM12/13/21
to Magnolia User Mailing List, hfgm...@gmail.com, Roman Kovařík
 What's the difference between pages and pages-app?

Pages-app runs in the new framework
  • It's able to convert old framework dialog config at runtime
  • It's not able convert custom fields (e.g. custom impl in java)
Pages runs in the old framework, so it can be used 
  • till your custom fields are migrated to the new framework
  • if you have any, not yet migrated, customization of the app
  • any other old apps linking to pages need this app to create the chooser

Thanks so much, it helped a lot :-)
 
You're welcome :-)

Roman
Reply all
Reply to author
Forward
0 new messages