How can I generate link to another module in Symfony admin generator Yaml?
I am trying to link from sfGuardUser module (user list) to profile/viewProfilesDetails but it always points to sfGuardUser/viewProfilesDetails
My generator.yml :
(...)
list:
title: Użytkownicy
display: [=username, _name, created_at, last_login]
actions: {}
batch_actions: {}
object_actions:
_edit: ~
signIn:
label: Zaloguj jako
action: signIn
viewProfiles:
label: Profile
module: profiles
action: viewProfilesDetails
(...)
I don’t think you can specify a module in this configuration, but only an action from the same module.
I personnaly do this in this way.
generator.yml:Then in the same module for the
generator.yml, I create an action:It generates a link called View items, like
/blog/158/viewItemswhich redirect to the/items(which is the route@items).Edit:
In fact, you can’t specify an other module.
The template
_list_td_actions.phpdisplaylist.object_actions. Here is the interesting part:It calls the
getLinkToActionwhich use the current module by using$this->getModuleName():