sync-all-wp_button.html.twig 593 Bytes
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12
{% if admin.hasRoute('sync-all-wp') %}
    {% set confirmPhrase = 'confirm_phrase_sync-all-wp'|trans({}, 'SonataAdminBundle') %}
    {% set promptText = 'confirm_sync-all-wp'|trans({'%phrase%': confirmPhrase}, 'SonataAdminBundle') %}
    <li>
        <a class="sonata-action-element danger" href="{{ admin.generateUrl('sync-all-wp') }}"
           onclick="return '{{-confirmPhrase-}}' == prompt('{{ promptText }}')"
        >
            <i class="fa fa-refresh" aria-hidden="true"></i>
            {{ 'action_sync-all-wp'|trans({}, 'SonataAdminBundle') }}
        </a>
    </li>
{% endif %}