Skip to content

Commit

Permalink
Merge pull request #952 from LoicGoyet/improvement/translator-init-on…
Browse files Browse the repository at this point in the history
…-head

Improvement/translator init on head
  • Loading branch information
paulandrieux authored Jul 7, 2017
2 parents 0d443c2 + 55a560d commit 56b545c
Showing 1 changed file with 11 additions and 10 deletions.
21 changes: 11 additions & 10 deletions Bundle/CoreBundle/Resources/views/Layout/layout.html.twig
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,17 @@
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.12.4/jquery.min.js"></script>
<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.5.6/angular.min.js"></script>
{% endif %}

{% block trans_script %}
{% if victoire_i18n_available_locales|default([])|length > 1 or is_granted('ROLE_VICTOIRE') %}
{% javascripts
"@BazingaJsTranslationBundle/Resources/public/js/translator.min.js"
"js/translations/config.js"
%}
<script type="text/javascript" src="{{ asset_url }}"></script>
{% endjavascripts %}
{% endif %}
{% endblock trans_script %}
{% endblock head_script %}

{% block head_style %}
Expand Down Expand Up @@ -77,16 +88,6 @@

{% block foot_script %}
<!-- Script foot includes -->
{% if victoire_i18n_available_locales|default([])|length > 1 or is_granted('ROLE_VICTOIRE') %}
{% javascripts
"@BazingaJsTranslationBundle/Resources/public/js/translator.min.js"
"js/translations/config.js" %}
<script type="text/javascript" src="{{ asset_url }}"></script>
{% endjavascripts %}
{% endif %}

<!-- ==================== -->

{% block foot_script__view %}
{% block foot_script__view_bootstrap %}
{% if app.debug %}
Expand Down

0 comments on commit 56b545c

Please sign in to comment.