templates/uniqskills/catalogue/landing_new/landing_partials/courseProgram.html.twig line 1

Open in your IDE?
  1. <section class="rowCourseProgram">
  2.     {% set showCourseProgram = module.showCourseProgram is defined and module.showCourseProgram == true %}
  3.     <a name="{{ module.type }}-{{ module.id }}"></a>
  4.     <div class="container">
  5.         <div class="row">
  6.             <div class="col rowCourseProgram__header">
  7.                 <h2>{% if module.titleName is defined and module.titleName is not empty %}{{ module.titleName|raw }}{% else %}{{ 'uniqskills.landing.nl.courseProgram'|trans }}{% endif %}</h2>
  8.             </div>
  9.         </div>
  10.         {% for key, item in module.json %}
  11.             <div class="row rowCourseProgram__module" style="position: relative; overflow: hidden;">
  12.                 <div class="col">
  13.                     {% if item.list[0] is defined %}
  14.                         {% set isFree = false %}
  15.                         {% for point in item.list[0].list %}
  16.                             {% if point.free is defined and point.free %}
  17.                                 {% set isFree = true %}
  18.                             {% endif %}
  19.                         {% endfor %}
  20.                         {% if isFree == true %}
  21.                             <img class="imgForFree" src="{{ asset('uniqskills/new_landing/images/free.png') }}"/>
  22.                         {% endif %}
  23.                     {% endif %}
  24.                     {% if item.moduleTitle is defined and item.moduleTitle is not null %}
  25.                         {% if item.list is defined %}
  26.                             {% set isPointsEmpty = item.list|filter(v => v.list is not empty) is empty %}
  27.                         {% else %}
  28.                             {% set isPointsEmpty = true %}
  29.                         {% endif %}
  30.                         <div class="row accordionTab"{% if showCourseProgram or isPointsEmpty %} style="cursor: default;" data-no-slide="1"{% endif %}>
  31.                             <div class="col-10">
  32.                                 <div class="rowCourseProgram__module__title">{{ item.moduleTitle|raw }}</div>
  33.                             </div>
  34.                             {% if not (showCourseProgram or isPointsEmpty) %}
  35.                                 <div class="col-2 text-center">
  36.                                     <span class="rowCourseProgram__module__more" data-id="mod-{{ loop.index }}">+</span>
  37.                                 </div>
  38.                             {% endif %}
  39.                         </div>
  40.                     {% endif %}
  41.                     {% if item.list is defined %}
  42.                         {% for list in item.list %}
  43.                             {% if list.title is not null  %}
  44.                                 {% if item.moduleTitle is null and loop.first %}
  45.                                     <div class="row accordionTab"{% if showCourseProgram or list.list is empty %} style="cursor: default;" data-no-slide="1"{% endif %}>
  46.                                 {% else %}
  47.                                     <div class="row accordionChild"{% if showCourseProgram or list.list is empty %} style="cursor: default;" data-no-slide="1"{% endif %}>
  48.                                 {% endif %}
  49.                                     <div class="col-10">
  50.                                         <div class="rowCourseProgram__module__description">
  51.                                             {% if item.list|length > 1 %}
  52.                                                 ✔
  53.                                             {%  endif %}
  54.                                             {{ list.title|raw }}
  55.                                         </div>
  56.                                     </div>
  57.                                     {% if item.moduleTitle is not null and loop.first %}
  58.                                         <div class="col-2 text-center">
  59.                                             <span class="rowCourseProgram__module__more" data-id="mod-{{ loop.parent.loop.index }}">+</span>
  60.                                         </div>
  61.                                     {% endif %}
  62.                                 </div>
  63.                             {% endif %}
  64.                             <div class="rowCourseProgram__module__elements" id="mod-{{ loop.parent.loop.index }}"
  65.                                  {% if showCourseProgram %}style="display: block;"{% endif %}
  66.                             >
  67.                                 {% if item.list is defined %}
  68.                                     {% for point in list.list %}
  69.                                         <div class="row">
  70.                                             <div class="col-12 col-md-10 rowCourseProgram__module__elements__vertical">
  71.                                                 <div class="bgs2-rowCourseProgram_elementIcon"></div>
  72.                                                 <div>
  73.                                                     {{ point.title|raw }}
  74.                                                 </div>
  75.                                             </div>
  76.                                             <div class="col-12 col-md-2 text-md-center mt-2 mt-md-0 mb-4 mb-md-0 ml-4 pl-4 ml-md-0 pl-md-0">
  77.                                                 {% if point.free is defined and point.free %}
  78.                                                     <a data-login={{ path('uniqskills_login') }} data-temporary="{{ temporaryUserLogin }}"
  79.                                                        class="rowCourseProgram__module__elements__check{% if 'vimeo.com' in point.free or 'bbvms.com' in point.free %} showFreeLessonVimeo{% else %} sm-download{% endif %}"
  80.                                                        {% if 'vimeo.com' in point.free or 'bbvms.com' in point.free %}
  81.                                                            data-vimeoUrl="{{ point.free }}"
  82.                                                        {% else %}
  83.                                                            href="{{ point.free }}" target="_blank"
  84.                                                        {% endif %}
  85.                                                     >
  86.                                                         <i style="font-style: normal;" class="fas fa-play"></i>{{ 'uniqskills.landing.nl.freematerials'|trans }}
  87.                                                     </a>
  88.                                                 {% endif %}
  89.                                             </div>
  90.                                         </div>
  91.                                     {% endfor %}
  92.                                 {% endif %}
  93.                             </div>
  94.                         {% endfor %}
  95.                     {% endif %}
  96.                 </div>
  97.             </div>
  98.         {% endfor %}
  99.     </div>
  100.     <!-- Modal -->
  101.     <div class="modal fade" id="vimeoVideoModal" tabindex="-1" role="dialog" aria-labelledby="exampleModalLabel" aria-hidden="true">
  102.         <div class="modal-dialog" role="document">
  103.             <div class="modal-content">
  104.                 <div class="modal-header">
  105.                     {#<h5 class="modal-title" id="exampleModalLabel">Modal title</h5>#}
  106.                     <button type="button" class="close" data-dismiss="modal" aria-label="Close">
  107.                         <span aria-hidden="true">&times;</span>
  108.                     </button>
  109.                 </div>
  110.                 <div class="modal-body">
  111.                     <iframe id="vimeoVideoModalIframe" src="https://player.vimeo.com/video/76979871"
  112.                             width="640" height="460" frameborder="0" allowfullscreen
  113.                             style="display: block; margin: 0 auto;"
  114.                     ></iframe>
  115.                 </div>
  116.                 {#<div class="modal-footer">#}
  117.                 {#<button type="button" class="btn btn-secondary" data-dismiss="modal">Close</button>#}
  118.                 {#<button type="button" class="btn btn-primary">Save changes</button>#}
  119.                 {#</div>#}
  120.             </div>
  121.         </div>
  122.     </div>
  123. </section>