-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Rewroke route parameters to have unique route
- Loading branch information
Showing
4 changed files
with
69 additions
and
37 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
10 changes: 6 additions & 4 deletions
10
packages/sonata-extra-bundle/Resources/views/Action/action.html.twig
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,10 @@ | ||
{% for action in item.action.actions %} | ||
<li> | ||
<a class="sonata-action-element" href="{{ item.action.generateUrl(admin, object) }}"> | ||
{% if item.action.icon %} | ||
<i class="{{ item.action.icon }}" aria-hidden="true"></i> | ||
<a class="sonata-action-element" href="{{ action.generateUrl(admin, object) }}"> | ||
{% if action.icon %} | ||
<i class="{{ action.icon }}" aria-hidden="true"></i> | ||
{% endif %} | ||
{{ item.action|translate_label }} | ||
{{ action|translate_label }} | ||
</a> | ||
</li> | ||
{% endfor %} |
14 changes: 8 additions & 6 deletions
14
packages/sonata-extra-bundle/Resources/views/Action/list_action.html.twig
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,10 @@ | ||
{% if admin.hasAccess(actions.action.name, object) %} | ||
<a class="btn btn-sm btn-default" href="{{ actions.action.generateUrl(admin, object) }}"> | ||
{% if actions.action.icon %} | ||
<i class="{{ actions.action.icon }}" aria-hidden="true"></i> | ||
{% endif %} | ||
{{ actions.action|translate_label }} | ||
</a> | ||
{% for action in actions.action.actions %} | ||
<a class="btn btn-sm btn-default" href="{{ action.generateUrl(admin, object) }}"> | ||
{% if action.icon %} | ||
<i class="{{ action.icon }}" aria-hidden="true"></i> | ||
{% endif %} | ||
{{ action|translate_label }} | ||
</a> | ||
{% endfor %} | ||
{% endif %} |