Changeset View
Changeset View
Standalone View
Standalone View
training/templates/training/flatpage.html
| {% extends 'training/base_training.html' %} | {% extends 'training/base_training.html' %} | ||||
| {% load common_extras %} | {% load common_extras %} | ||||
| {% load pipeline %} | {% load pipeline %} | ||||
| {% block title_append %} - {{ training.title }} {{ flatpage.title }}{% endblock title_append %} | {% block title_append %} - {{ training.title }} {{ flatpage.title }}{% endblock title_append %} | ||||
| {% block meta %} | {% block meta %} | ||||
| {% firstof flatpage.title as title %} | {% firstof flatpage.title as title %} | ||||
| {% firstof flatpage.thumbnail_m_url training.thumbnail_m_url as image_url %} | {% firstof flatpage.thumbnail_m_url training.thumbnail_m_url as image_url %} | ||||
| {% with description=flatpage.content|truncatewords:25 %} | {% with description=flatpage.content|truncatewords:25 %} | ||||
| {% include 'common/components/meta.html' %} | {% include 'common/components/meta.html' %} | ||||
| {% endwith %} | {% endwith %} | ||||
| {% endblock %} | {% endblock %} | ||||
| {% block content %} | {% block content %} | ||||
| {% if flatpage.header %} | {% if flatpage.header %} | ||||
| <div class="jumbotron jumbotron-fluid jumbotron-blog jumbotron-overlay overlay-blog mb-3"> | <div class="jumbotron jumbotron-fluid jumbotron-blog jumbotron-overlay overlay-blog mb-3"> | ||||
| <div class="container py-5 px-5"> | <div class="container py-5 px-5"> | ||||
| <div class="row"> | <div class="row"> | ||||
| <div class="col-md-5"> | <div class="col-md-5"> | ||||
| <p class="subtitle">{{ training.title }}</p> | <p class="subtitle">{{ training.title }}</p> | ||||
| <h1 class="display-3 text-uppercase font-weight-bold">{{ flatpage.title }}</h1> | <h1 class="display-3 text-uppercase font-weight-bold">{{ flatpage.title }}</h1> | ||||
| </div> | </div> | ||||
| </div> | </div> | ||||
| </div> | </div> | ||||
| <div class="jumbotron-bg-wrapper"> | <div class="jumbotron-bg-wrapper"> | ||||
| {% include "common/components/helpers/image_set.html" with alt=asset.name classes="jumbotron-bg" img_source=flatpage.header xsmall_width="600" small_width="800" medium_width="1000" large_width="1200" xlarge_width="1920" %} | {% include "common/components/helpers/image_set.html" with alt=asset.name classes="jumbotron-bg" img_source=flatpage.header xsmall_width="600" small_width="800" medium_width="1000" large_width="1200" xlarge_width="1920" %} | ||||
| </div> | </div> | ||||
| </div> | </div> | ||||
| {% endif %} | {% endif %} | ||||
| <div class="container-fluid pt-4"> | <div class="container-fluid pt-4"> | ||||
| <section class="flat-page-content editorial-text-area mb-4"> | <section class="flat-page-content editorial-text-area mb-4"> | ||||
| {% if user_can_edit_flatpage %} | {% if user_can_edit_flatpage %} | ||||
| <div class="admin-button"> | <div class="admin-button"> | ||||
| <a href="{{ flatpage.admin_url }}" class="btn btn-sm btn-secondary btn-icon btn-float"> | <a href="{{ flatpage.admin_url }}" class="btn btn-sm btn-secondary btn-icon btn-float"> | ||||
| <i class="material-icons">create</i> | <i class="material-icons">create</i> | ||||
| </a> | </a> | ||||
| </div> | </div> | ||||
| {% endif %} | {% endif %} | ||||
| {% if not flatpage.header %} | {% if not flatpage.header %} | ||||
| <div class="text-center mb-3"> | <div class="text-center mb-3"> | ||||
| <p class="subtitle">{{ training.title }}</p> | <p class="subtitle">{{ training.title }}</p> | ||||
| <h1 class="mb-0">{{ flatpage.title }}</h1> | <h1 class="mb-0">{{ flatpage.title }}</h1> | ||||
| </div> | </div> | ||||
| {% endif %} | {% endif %} | ||||
| <div>{% with_shortcodes flatpage.html_content %}</div> | <div>{% with_shortcodes flatpage.html_content %}</div> | ||||
| </section> | </section> | ||||
| </div> | </div> | ||||
| {% endblock content %} | {% endblock content %} | ||||
| {% block scripts %} | {% block scripts %} | ||||
| {% javascript 'training' %} | {% javascript 'training' %} | ||||
| {% endblock scripts %} | {% endblock scripts %} | ||||