templates/sp/detail.html.twig line 1

Open in your IDE?
  1. {% extends 'layouts/layout.html.twig' %}
  2. {% block content %}
  3.     <main class="pullc">
  4.         <div class="container-xl">
  5.             <div class="row">
  6.                 <div class="col-lg-3 leftpull section-pillar d-none d-lg-block" {% if pillar_background %} style="background-image: url({{ pillar_background.thumbnail('pillar') }})" {% endif %}>
  7.                     <div class="section-title px-3 px-lg-3 ps-lg-0 d-flex flex-column">
  8.                     <h1 class="mb-lg-5 pt-1 pe-lg-4 mt-5 text-lg-end">{{ section_title }}
  9.                         </h1>
  10.                     </div>
  11.                     {% if not document.getProperty('hide_subnav') and document.getProperty('subnav_doc')%}
  12.                         <div class="d-flex justify-content-end">
  13.                             {% set nav = pimcore_build_nav({active: document, root: document.getProperty('subnav_doc')}) %}
  14.                             {{ pimcore_render_nav(nav, 'menu', 'renderMenu', {
  15.             maxDepth: 2,
  16.             ulClass: {
  17.                 0: 'sidenav list-unstyled justify-content-end align-self-end',
  18.                  1: 'list-unstyled subnav',
  19.                  2: 'list-unstyled subnav'
  20.             },
  21.             expandSiblingNodesOfActiveBranch: true
  22.         }) }}
  23.                         </div>
  24.                     {% endif %}
  25.                             {% if document.getProperty('pillar_background') %}
  26.                         {% if document.getProperty('pillar_background').getMetadata('Credit') %}
  27.                             <div class="pillar-credit">
  28.                                 Image:
  29.                                 {{ document.getProperty('pillar_background').getMetadata('Credit') }}
  30.                             </div>
  31.                         {% endif %}
  32.                     {% endif %}
  33.                 </div>
  34.                 <div class="col-lg-9 ps-lg-5 pe-lg-5 pb-4">
  35.                     {% if showBreadcrumbs %}
  36.                         {% set mainNavStartNode = document.getProperty('navigation_root') %}
  37.                         {% if mainNavStartNode is empty %}
  38.                             {% set mainNavStartNode = pimcore_document(1) %}
  39.                         {% endif %}
  40.                         {% set breadbrumbs = pimcore_build_nav({
  41.                                     active: document,
  42.                                     root: mainNavStartNode
  43.                                 }) %}
  44.                         {% do app_navigation_enrich_breadcrumbs(breadbrumbs) %}
  45.                         {% do pimcore_nav_renderer('breadcrumbs').setMinDepth(null) %}
  46.                         <div class="breadcrumbs mt-3">
  47.                             <a href="/">Home</a>
  48.                             /
  49.                             {{ pimcore_render_nav(breadbrumbs, 'breadcrumbs')|replace({'&gt;':' / '})|raw }}
  50.                         </div>
  51.                     {% endif %}
  52.                     <div class="content-body">
  53.                         <h1 class="mt-3 purpleline">{{ sp.parent.key }}
  54.                             ({{ sp.parent.parent.key|slice(0,sp.parent.parent.key|length-1)|lower }})</h1>
  55.                         
  56.                         {% if sp.image %}
  57.                             {{ sp.image.thumbnail('serviceprovider').html({'imgAttributes': {
  58.                                             'class': 'spimage my-3',
  59.                                             'alt': sp.title,
  60.                                            },}) | raw }}
  61.                         {% endif %}
  62. <h2 class="mt-3">{{ sp.title }}    {% if sp.acronym %}
  63.                                                         - {{ sp.acronym }}
  64.                                                     {% endif %}</h2>
  65.                         {% if sp.website %}
  66.                             <p>
  67.                                 <a href="{{ sp.website }}" target="_blank">Visit website</a>
  68.                             </p>
  69.                         {% endif %}
  70.                         {{ sp.body | raw }}
  71.                     </div>
  72.                 </div>
  73.             </div>
  74.         </div>
  75.     </main>
  76. {% endblock %}