2019-08-09 13:57:37 +00:00
|
|
|
{% extends "puput/base.html" %}
|
2020-01-16 10:34:10 +00:00
|
|
|
{% load i18n wagtailcore_tags wagtailimages_tags puput_tags wagtailroutablepage_tags social_share %}
|
2017-03-13 16:56:47 +00:00
|
|
|
|
2019-08-09 13:57:37 +00:00
|
|
|
{% block title %}
|
|
|
|
{{ self.title }} | {{ blog_page.title }}
|
|
|
|
{% endblock title %}
|
|
|
|
|
|
|
|
{% block meta_title %}
|
|
|
|
{% if self.seo_title %}
|
|
|
|
{{ self.seo_title }}
|
|
|
|
{% else %}
|
|
|
|
{{ self.title }}
|
|
|
|
{% endif %}
|
|
|
|
{% endblock meta_title %}
|
|
|
|
|
|
|
|
{% block meta_description %}
|
|
|
|
{% if self.search_description %}
|
|
|
|
{{ self.search_description }}
|
|
|
|
{% else %}
|
|
|
|
{{ self.body|striptags|truncatewords:20 }}
|
|
|
|
{% endif %}
|
|
|
|
{% endblock meta_description %}
|
|
|
|
|
|
|
|
{% block canonical %}
|
|
|
|
{% canonical_url entry=self %}
|
|
|
|
{% endblock canonical %}
|
2017-03-13 16:56:47 +00:00
|
|
|
|
|
|
|
{% block social_share %}
|
|
|
|
{% image self.header_image fill-800x450 as share_image %}
|
|
|
|
<meta property="og:title" content="{{ self.title }}" />
|
|
|
|
<meta property="og:description" content="{% if self.excerpt %}{{ self.excerpt|striptags }}{% else %}{{ self.body|striptags|truncatewords:20 }}{% endif %}" />
|
|
|
|
<meta property="og:url" content="{% canonical_url entry=self %}" />
|
|
|
|
{% if self.header_image %}
|
2019-08-09 13:57:37 +00:00
|
|
|
<meta property="og:image" content="{% image_url share_image.url %}" />
|
|
|
|
<meta property="og:image:width" content="800" />
|
|
|
|
<meta property="og:image:height" content="450" />
|
|
|
|
<meta name="twitter:image" content="{% image_url share_image.url %}" />
|
2017-03-13 16:56:47 +00:00
|
|
|
{% endif %}
|
|
|
|
<meta name="twitter:card" content="summary_large_image" />
|
|
|
|
<meta name="twitter:title" content="{{ self.title }}" />
|
|
|
|
<meta name="twitter:description" content="{% if self.excerpt %}{{ self.excerpt|striptags }}{% else %}{{ self.body|striptags|truncatewords:20 }}{% endif %}" />
|
|
|
|
{% endblock social_share %}
|
|
|
|
|
2019-08-09 13:57:37 +00:00
|
|
|
{% block blog_content %}
|
2019-08-12 15:28:31 +00:00
|
|
|
|
2020-02-18 16:50:56 +00:00
|
|
|
{% if self.categories.count > 0 %}
|
2020-01-16 10:34:10 +00:00
|
|
|
<div class="entry-categories">
|
|
|
|
{% categories_list self.categories %}
|
|
|
|
</div>
|
2020-02-18 16:50:56 +00:00
|
|
|
{% endif %}
|
2020-01-16 10:34:10 +00:00
|
|
|
|
|
|
|
<h1 class="title">{{ self.title }}</h1>
|
|
|
|
|
|
|
|
<ul class="links">
|
|
|
|
<li>
|
|
|
|
{{ self.date|date:"d.m.Y" }}
|
|
|
|
</li>
|
|
|
|
{% if self.tags.count > 0 %}
|
|
|
|
<li>
|
|
|
|
<i class="fa fa-tag"></i>
|
|
|
|
{% tags_list blog_page.num_tags_entry_header self.tags %}
|
|
|
|
</li>
|
|
|
|
{% endif %}
|
|
|
|
{% if blog_page.display_comments %}
|
|
|
|
<li>
|
|
|
|
<i class="fa fa-comments"></i>
|
|
|
|
{{ self.num_comments }}
|
|
|
|
</li>
|
|
|
|
{% endif %}
|
|
|
|
</ul>
|
|
|
|
|
|
|
|
<p class="excerpt">
|
|
|
|
{{ self.excerpt|safe }}
|
|
|
|
</p>
|
|
|
|
|
2019-08-12 15:28:31 +00:00
|
|
|
{% if self.header_image %}
|
|
|
|
<div class="image">
|
|
|
|
{% image self.header_image fill-940x400 class="img-responsive" %}
|
|
|
|
</div>
|
|
|
|
{% endif %}
|
|
|
|
|
2020-01-16 10:34:10 +00:00
|
|
|
<article class="box page-content"
|
|
|
|
{% if self.id %}data-entry-page-update-comments-url="{% url 'entry_page_update_comments' self.id %}{% endif %}">
|
|
|
|
<section>
|
|
|
|
{{ self.body|richtext}}
|
2020-02-18 16:50:56 +00:00
|
|
|
</section>
|
|
|
|
<div class="row">
|
|
|
|
<div class="col-md-2">
|
|
|
|
<a href="{% pageurl blog_page %}" class="blog_btn back hidden">
|
|
|
|
<i class="fa fa-home"></i>
|
|
|
|
</a>
|
2020-01-16 10:34:10 +00:00
|
|
|
{% entry_url self blog_page as post_url %}
|
|
|
|
</div>
|
2020-02-18 16:50:56 +00:00
|
|
|
<ul class="social-share-all text-right col-md-10">
|
|
|
|
<li class="social-item">
|
|
|
|
{% post_to_facebook post_url '<span><i class="fa fa-facebook"></i></span>' %}
|
|
|
|
</li>
|
|
|
|
<li class="social-item">
|
|
|
|
{% post_to_twitter self.title post_url '<span><i class="fa fa-twitter"></i></span>' %}
|
|
|
|
</li>
|
|
|
|
<li class="social-item">
|
|
|
|
{% post_to_linkendin post_url '<span><i class="fa fa-linkedin"></i></span>' %}
|
|
|
|
</li>
|
|
|
|
</ul>
|
|
|
|
</div>
|
2020-01-16 10:34:10 +00:00
|
|
|
{% show_comments %}
|
|
|
|
</article>
|
2019-08-09 13:57:37 +00:00
|
|
|
{% endblock blog_content %}
|
2017-03-13 16:56:47 +00:00
|
|
|
|
|
|
|
{% block extra_content %}
|
|
|
|
{% if self.has_related %}
|
|
|
|
{% include 'puput/related_entries.html' with entry=self %}
|
|
|
|
{% endif %}
|
|
|
|
{% endblock extra_content %}
|