bundles/AppBundle/Resources/views/Areas/radiostatistik/view.html.twig line 1

Open in your IDE?
  1. {% set block = pimcore_block('stats') %}
  2. {% set bgColor = pimcore_select('bgColor').getValue() %}
  3. {% set bgColorHex = pimcore_input('bgColorHex').getValue() %}
  4. {% set paddingTop = pimcore_select('paddingTop').getValue() %}
  5. {% set paddingTop = paddingTop == '' ? '10' : paddingTop %}
  6. {% set paddingBottom = pimcore_select('paddingBottom').getValue() %}
  7. {% set paddingBottom = paddingBottom == '' ? '10' : paddingBottom %}
  8. {% set count = block.getCount() %}
  9. {% set cols = count > 4 ? 4 : (count > 0 ? count : 1) %}
  10. {% set mobileCols = 1 %}
  11. {% set delays = ['', 'delay-100', 'delay-200', 'delay-300'] %}
  12. <div class="module-container my-10 radiostatistik-module-container {% if not bgColorHex %} {{ bgColor }} {% endif %} {{ pimcore_input('classes').data }}" style="{% if bgColorHex %}background: {{ bgColorHex }};{% endif %}">
  13.     <section class="{{ editmode ? '' : 'module-section radiostatistik-module' }}">
  14.         {% if editmode %}
  15.             <div class="container">
  16.                 <div class="bg-white p-5 mb-10">
  17.                     <div class="mb-5">Intro Text</div>
  18.                     {{ pimcore_wysiwyg('intro') }}
  19.                 </div>
  20.                 <div class="bg-white shadow-lg my-10">
  21.                     <div class="px-5 py-2 bg-gray-800 text-white">
  22.                         {{ 'Modul - Radiostatistik' | trans }}
  23.                     </div>
  24.                     <div class="p-5 text-black">
  25.                         {% for j in pimcore_iterate_block(block) %}
  26.                             <div class="mb-5 p-3 bg-neutral-100">
  27.                                 <div class="grid grid-cols-3 gap-5">
  28.                                     <div>
  29.                                         <div class="text-xs">Title</div>
  30.                                         <div class="bg-gray-200">{{ pimcore_input('title') }}</div>
  31.                                     </div>
  32.                                     <div>
  33.                                         <div class="text-xs">Beschriftung (z.B. Bayerische Oberlandapp)</div>
  34.                                         <div class="bg-gray-200">{{ pimcore_input('label') }}</div>
  35.                                     </div>
  36.                                     <div>
  37.                                         <div class="text-xs">Wert Approximationen (z.B. über, etwa, nahezu)</div>
  38.                                         <div class="bg-gray-200">{{ pimcore_input('approx') }}</div>
  39.                                     </div>
  40.                                     <div>
  41.                                         <div class="text-xs">Wert (z.B. 120000)</div>
  42.                                         <div class="bg-gray-200">{{ pimcore_input('value') }}</div>
  43.                                     </div>
  44.                                     <div>
  45.                                         <div class="text-xs">Text (optional)</div>
  46.                                         <div class="bg-gray-200">{{ pimcore_wysiwyg('text') }}</div>
  47.                                     </div>
  48.                                 </div>
  49.                             </div>
  50.                         {% endfor %}
  51.                     </div>
  52.                 </div>
  53.                 <div class="bg-white p-5 mb-10 grid grid-cols-3 gap-5">
  54.                     <div class="col-span-2">
  55.                         <div class="mb-5">Outro Subtitle</div>
  56.                         <div class="mb-5">{{ pimcore_input('outroSubtitle') }}</div>
  57.                         <div class="mb-5">Outro Text</div>
  58.                         <div class="mb-5">{{ pimcore_wysiwyg('outro') }}</div>
  59.                     </div>
  60.                     <div>
  61.                         <div class="mb-5">{{ pimcore_image('outroBackground') }}</div>
  62.                         {{ pimcore_link('outroLink') }}
  63.                     </div>
  64.                 </div>
  65.             </div>
  66.         {% else %}
  67.             <div class="container px-5 pt-{{ paddingTop }} pb-{{ paddingBottom }}">
  68.                 {% set intro = pimcore_wysiwyg('intro') %}
  69.                 {% if intro %}
  70.                     <div class="prose colored text-balance text-sm mb-20 md:pt-10">{{ intro | raw }}</div>
  71.                 {% endif %}
  72.                 <div class="grid grid-cols-{{ mobileCols }} md:grid-cols-{{ cols }} gap-10 md:gap-16">
  73.                     {% for j in pimcore_iterate_block(block) %}
  74.                         {% set value = pimcore_input('value').getValue() %}
  75.                         {% set title = pimcore_input('title').getValue() %}
  76.                         {% set label = pimcore_input('label').getValue() %}
  77.                         {% set approx = pimcore_input('approx').getValue() %}
  78.                         {% set text = pimcore_wysiwyg('text').getValue() %}
  79.                         {% if value or label or text %}
  80.                             <div>
  81.                                 <div class="font-mont-heavy md:text-[18px]">{{ title }}</div>
  82.                                 {% if label %}
  83.                                     <div class="text-sm">{{ label }}</div>
  84.                                 {% endif %}
  85.                                 <div class="flex justify-between border-b-2 border-blue-light items-end mt-3 mb-2">
  86.                                     <div class="text-sm pb-4">{{ approx }}</div>
  87.                                     <div class="font-mont-heavy text-4xl md:text-5xl text-blue-light vue-app"><number :value="{{ value }}" :from="0" :duration="2.5"></number></div>
  88.                                 </div>
  89.                                 {% if text %}
  90.                                     <div class="prose colored text-balance text-sm pt-3">{{ text | raw }}</div>
  91.                                 {% endif %}
  92.                             </div>
  93.                         {% endif %}
  94.                     {% endfor %}
  95.                 </div>
  96.                 {% set outro = pimcore_wysiwyg('outro') %}
  97.                 {% set outroLink = pimcore_link('outroLink', { class: 'btn btn-blue' }) %}
  98.                 {% set outroSubtitle = pimcore_input('outroSubtitle') %}
  99.                 {% set outroImage = pimcore_image('outroBackground') %}
  100.                 {% if outro | length %}
  101.                     <div class="bg-white shadow-card mt-10 md:mt-20 p-5 md:p-10 lg:p-20 mb-5 md:mb-10 lg:mb-20 grid lg:grid-cols-2 gap-10"
  102.                          style="{% if outroImage and outroImage.image %}background-image: url('{{ outroImage.image.fullpath }}'); background-size: auto 100%; background-repeat: no-repeat; background-position: right;{% endif %}">
  103.                         <div>
  104.                             {% if outroSubtitle %}
  105.                                 <div class="font-mont-heavy mb-5 md:mb-10">{{ outroSubtitle | raw }}</div>
  106.                             {% endif %}
  107.                             <div class="prose colored text-balance">
  108.                                 {{ outro | raw }}
  109.                             </div>
  110.                         </div>
  111.                         {% if outroLink %}
  112.                             <div class="md:self-end text-center">
  113.                                 {{ outroLink | raw }}
  114.                             </div>
  115.                         {% endif %}
  116.                     </div>
  117.                 {% endif %}
  118.             </div>
  119.         {% endif %}
  120.     </section>
  121. </div>