src/WebBundle/Resources/views/Catalog/factory-header.html.twig line 1

Open in your IDE?
  1. {% apply spaceless %}
  2.     {% set name = typeKey | trans %}
  3.     {% if factory.getLogoWeb %}
  4.         {% set name = name | replace({'%factory%': ''}) %}
  5.     {% else %}
  6.         {% set name = name | replace({'%factory%': factory.name}) %}
  7.     {% endif %}
  8.     {{ name | raw }}
  9.     {% if factory.getLogoWeb %}
  10.         <img src="{{ factory.getLogoWeb }}" alt="{{ factory.name }}" style="height: 24px; vertical-align: baseline; margin: 10px 10px 0;" />
  11.     {% endif %}
  12.     {% if factory.getLogoUrl %}
  13.         <a href="{{ factory.getLogoUrl }}" target="_blank" class="link-url" > {{ factory.getLogoUrl }} </a>
  14.     {% endif %}
  15.     {% if is_granted('ROLE_ADMIN') and editLink  is defined and editLink != null %}
  16.         <sup>
  17.         <span class="link-edit">
  18.             <a href="{{ editLink }}" target="_blank" rel="noopener">edit ADM</a>
  19.             {% if biLink  is defined and biLink != null %}
  20.                 <span> / </span>
  21.                 <a href="{{ biLink }}" target="_blank" rel="noopener">edit BI</a>
  22.             {% endif %}
  23.         </span>
  24.         </sup>
  25.     {% endif %}
  26.     {% set src = import.pathSoundGenerator('factory-sound-site', factory) %}
  27.     {% if src | length > 0 %}
  28.         <a href="#"
  29.            data-src="{{ src }}"
  30.            class="js-audio-btn-play material-icons volume-high help-tooltip tooltip-autoclose"
  31.            title="{{ 'collection_sound_name_factories' | trans }}">&#xE050;</a>
  32.     {% endif %}
  33.     {% if factory.country != null %}
  34.         <a class="flag flag-{{ factory.country.code | lower }} help-tooltip"
  35.            href="{{ path('app_catalog', {'key': factory.country.slug}) }}"
  36.            title="{{ factory.country.name | replace({'"': '\''}) | raw }}"
  37.         ></a>
  38.     {% endif %}
  39. {% endapply %}