merge aircox and aircox_instance
This commit is contained in:
@ -0,0 +1,8 @@
|
||||
<section class="section_item {{ self.css_class }} {{ self.snake_name }}">
|
||||
{% block title %}
|
||||
{% if self.show_title %}<h2>{{ self.title }}</h2>{% endif %}
|
||||
{% endblock %}
|
||||
{% block content %}{{ content|safe }}{% endblock %}
|
||||
</section>
|
||||
|
||||
|
13
aircox_cms/templates/aircox_cms/sections/section_link.html
Normal file
13
aircox_cms/templates/aircox_cms/sections/section_link.html
Normal file
@ -0,0 +1,13 @@
|
||||
{% extends "aircox_cms/sections/section_item.html" %}
|
||||
{% load wagtailimages_tags %}
|
||||
|
||||
{% block content %}
|
||||
{% with link=self.as_dict %}
|
||||
<a href="{{ link.url }}">
|
||||
{% if link.icon %}{% image link.icon fill-32x32 class="icon link_icon" height='' width='' %}{% endif %}
|
||||
{{ link.text }}
|
||||
</a>
|
||||
{% endwith %}
|
||||
{% endblock %}
|
||||
|
||||
|
@ -0,0 +1,16 @@
|
||||
{% extends "aircox_cms/sections/section_item.html" %}
|
||||
{% load wagtailimages_tags %}
|
||||
|
||||
{% block content %}
|
||||
{% for item in object_list %}
|
||||
{% with link=item.as_dict %}
|
||||
<a href="{{ link.url }}"
|
||||
{% if item.css_class %}class="{{ item.css_class }}"{% endif %}>
|
||||
{% if link.icon %}{% image link.icon fill-24x24 class="icon" %}{% endif %}
|
||||
{{ link.text }}
|
||||
</a>
|
||||
{% endwith %}
|
||||
{% endfor %}
|
||||
{% endblock %}
|
||||
|
||||
|
16
aircox_cms/templates/aircox_cms/sections/section_list.html
Normal file
16
aircox_cms/templates/aircox_cms/sections/section_list.html
Normal file
@ -0,0 +1,16 @@
|
||||
{% extends "aircox_cms/sections/section_item.html" %}
|
||||
|
||||
{% block content %}
|
||||
{% if focus %}
|
||||
{% with item=focus item_big_cover=True %}
|
||||
{% include "aircox_cms/snippets/list_item.html" %}
|
||||
{% endwith %}
|
||||
{% endif %}
|
||||
|
||||
{% with url=url url_text=self.url_text %}
|
||||
{% include "aircox_cms/snippets/list.html" %}
|
||||
{% endwith %}
|
||||
|
||||
{% endblock %}
|
||||
|
||||
|
@ -0,0 +1,10 @@
|
||||
{% extends "aircox_cms/sections/section_item.html" %}
|
||||
|
||||
{% block content %}
|
||||
{% with item_date_format="H:i" list_css_class="date_list" list_no_cover=True %}
|
||||
{% for item in object_list %}
|
||||
{% include "aircox_cms/snippets/date_list_item.html" %}
|
||||
{% endfor %}
|
||||
{% endwith %}
|
||||
{% endblock %}
|
||||
|
27
aircox_cms/templates/aircox_cms/sections/section_player.html
Normal file
27
aircox_cms/templates/aircox_cms/sections/section_player.html
Normal file
@ -0,0 +1,27 @@
|
||||
{% extends 'aircox_cms/sections/section_item.html' %}
|
||||
|
||||
|
||||
{% block content %}
|
||||
<div id="player" class="player">
|
||||
{% include "aircox_cms/snippets/player.html" %}
|
||||
</div>
|
||||
|
||||
<script>
|
||||
var player = new Player('player', '{% url 'aircox.on_air' %}');
|
||||
var sound = player.playlist.add(
|
||||
new Sound(
|
||||
'{{ self.live_title }}',
|
||||
'', undefined,
|
||||
streams=[ {% for stream in streams %}'{{ stream }}',{% endfor %} ],
|
||||
cover = undefined,
|
||||
on_air = true
|
||||
)
|
||||
);
|
||||
sound.item.className += ' live';
|
||||
player.playlist.select(sound, false);
|
||||
|
||||
</script>
|
||||
{% endblock %}
|
||||
|
||||
|
||||
|
@ -0,0 +1,60 @@
|
||||
{% extends "aircox_cms/sections/section_item.html" %}
|
||||
{% load i18n %}
|
||||
{% load static %}
|
||||
|
||||
{% load wagtailsettings_tags %}
|
||||
|
||||
{% block content %}
|
||||
<div class="meta">
|
||||
<div class="author">
|
||||
{% if page.publish_as %}
|
||||
{% with item=page.publish_as item_date_format='' %}
|
||||
{% include "aircox_cms/snippets/list_item.html" %}
|
||||
{% endwith %}
|
||||
{% elif page.owner %}
|
||||
{% trans "Published by" %}
|
||||
{{ page.owner }}
|
||||
{% endif %}
|
||||
</div>
|
||||
{% with page_date=page.specific.date %}
|
||||
{% if page_date %}
|
||||
<time datetime="{{ page_date }}">
|
||||
<b>{% trans "Published on " %}</b>
|
||||
{{ page_date|date:'l d F, H:i' }}
|
||||
</time>
|
||||
{% endif %}
|
||||
{% endwith %}
|
||||
|
||||
{% with list_page=settings.cms.WebsiteSettings.list_page %}
|
||||
{% if list_page and page.tags.count %}
|
||||
<div class="tags"><b>{% trans "Tags" %}</b>
|
||||
{% for tag in page.tags.all %}
|
||||
<a href="{{ list_page }}?tag={{ tag }}">{{ tag }}</a>
|
||||
{% endfor %}
|
||||
</div>
|
||||
{% endif %}
|
||||
{% endwith %}
|
||||
|
||||
<div class="share">
|
||||
<img src="{% static "aircox_cms/images/share.png" %}" alt="{% trans "Share" %}"
|
||||
class="small_icon">
|
||||
<a href="mailto:?&body={{ page.full_url|urlencode }}"
|
||||
target="new">
|
||||
<img src="{% static "aircox_cms/images/mail.png" %}" alt="Mail" class="small_icon">
|
||||
</a>
|
||||
<a href="https://www.facebook.com/sharer/sharer.php?u={{ page.full_url|urlencode }}"
|
||||
target="new">
|
||||
<img src="{% static "aircox_cms/images/facebook.png" %}" alt="Facebook" class="small_icon">
|
||||
</a>
|
||||
<a href="https://twitter.com/intent/tweet?text={{ page.full_url|urlencode }}"
|
||||
target="new">
|
||||
<img src="{% static "aircox_cms/images/twitter.png" %}" alt="Twitter" class="small_icon">
|
||||
</a>
|
||||
<a href="https://plus.google.com/share?url={{ page.full_url|urlencode }}"
|
||||
target="new">
|
||||
<img src="{% static "aircox_cms/images/gplus.png" %}" alt="Google Plus" class="small_icon">
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
{% endblock %}
|
||||
|
@ -0,0 +1,16 @@
|
||||
{% extends "aircox_cms/sections/section_item.html" %}
|
||||
{% load i18n %}
|
||||
{% load static %}
|
||||
|
||||
{% load wagtailsettings_tags %}
|
||||
|
||||
{% block content %}
|
||||
{% with list_page=settings.cms.WebsiteSettings.list_page %}
|
||||
<form action="{{ list_page.url }}" method="GET">
|
||||
<img src="{% static "aircox_cms/images/search.png" %}" class="icon"/>
|
||||
<input type="text" name="search" placeholder="{{ self.default_text }}">
|
||||
<input type="submit" style="display: none;">
|
||||
</form>
|
||||
{% endwith %}
|
||||
{% endblock %}
|
||||
|
@ -0,0 +1,6 @@
|
||||
{% extends "aircox_cms/sections/section_item.html" %}
|
||||
|
||||
{% block content %}
|
||||
{% include "aircox_cms/snippets/date_list.html" %}
|
||||
{% endblock %}
|
||||
|
Reference in New Issue
Block a user