RUN apt-get update &&\
apt-get -y install locales netcat && \
+ apt-get install -y --force-yes netcat && \
echo fr_FR.UTF-8 UTF-8 >> /etc/locale.gen &&\
locale-gen
# waiting for other services
sh $app/deploy/wait.sh
-if [ ! -f $app/.init ]; then
- python $manage makemigrations --noinput
- touch $app/.init
-fi
-
# django init
python $manage syncdb --noinput
python $manage migrate --noinput
#!/bin/sh
-# apt-get install -y --force-yes netcat
-
set -e
host=$(env | grep _TCP_ADDR | cut -d = -f 2)
--- /dev/null
+{% extends "base.html" %}
+{% load i18n mezzanine_tags %}
+
+{% block meta_title %}{{ title }}{% endblock %}
+{% block title %}{{ title }}{% endblock %}
+{% block body_id %}account{% endblock %}
+
+{% block breadcrumb_menu %}
+{{ block.super }}
+<li>{{ title }}</li>
+{% endblock %}
+
+{% block main %}
+
+{% errors_for form %}
+
+<form method="post"{% if form.is_multipart %} enctype="multipart/form-data"{% endif %}>
+ <fieldset>
+ <legend>{{ title }}</legend>
+ {% fields_for form %}
+ <div class="form-actions">
+ {% block account_form_actions %}
+ <input class="btn btn-primary btn-lg pull-right" type="submit" value="{{ title }}">
+ {% endblock %}
+ </div>
+ </fieldset>
+</form>
+{% endblock %}
--- /dev/null
+{% extends "accounts/account_form.html" %}
+{% load i18n %}
+
+{% block main %}
+
+{% if request.user.is_authenticated %}
+ <p>{% trans "You're already logged in. If you'd like to log in as a different user, you'll need to log out first." %}</p>
+{% else %}
+ {{ block.super }}
+ {% url "signup" as signup_url %}
+ <p>{% blocktrans with request.GET.next as next %}If you don't have an account you can <a href="{{ signup_url }}?next={{ next }}">sign up</a> for one now.{% endblocktrans %}</p>
+ {% url "mezzanine_password_reset" as password_reset_url %}
+ {% url "profile_update" as profile_update_url %}
+ {% blocktrans %}<p>You can also <a href="{{ password_reset_url }}?next={{ profile_update_url }}">reset your password</a> if you've forgotten it.</p>{% endblocktrans %}</p>
+{% endif %}
+
+{% endblock %}
--- /dev/null
+{% extends "accounts/account_form.html" %}
+{% load i18n %}
+
+{% block main %}
+{{ block.super }}
+<p>{% trans "Enter your username or email address and you'll receive an email with a link you need to click, in order to log in and change your password." %}</p>
+{% endblock %}
--- /dev/null
+{% extends "base.html" %}
+{% load i18n mezzanine_tags accounts_tags %}
+
+{% block meta_title %}{{ profile_user|username_or:"get_full_name" }}{% endblock %}
+{% block title %}{{ profile_user|username_or:"get_full_name" }}{% endblock %}
+{% block body_id %}account{% endblock %}
+
+{% block breadcrumb_menu %}
+{{ block.super }}
+<li>{{ profile_user|username_or:"get_full_name" }}</li>
+{% endblock %}
+
+{% block main %}
+<div class="row">
+<div class="profile-image col-md-3">
+ <img class="img-thumbnail" src="{% gravatar_url profile_user.email 128 %}">
+ {% if profile_user == request.user %}
+ <br><a class="btn btn-primary" href="{% url "profile_update" %}">{% trans "Update profile" %}</a>
+ {% endif %}
+</div>
+<div class="profile-content col-md-9">
+ <h2>{{ profile_user.get_full_name }}</h2>
+ {% for field, value in profile_user|profile_fields %}
+ <h3>{{ field }}</h3>
+ <p>{{ value|linebreaksbr }}</p>
+ {% endfor %}
+</div>
+</div>
+{% endblock %}
--- /dev/null
+{% extends "accounts/account_form.html" %}
--- /dev/null
+{% extends "accounts/account_form.html" %}
+{% load i18n %}
+
+{% block main %}
+
+{% if request.user.is_authenticated %}
+ <p>{% trans "You're already logged in. If you'd like to create a new account, you'll need to log out first." %}</p>
+{% else %}
+ {{ block.super }}
+ {% if settings.ACCOUNTS_APPROVAL_REQUIRED %}
+ <p>{% trans "After signing up, your account will be reviewed for approval. You'll receive an email when your account is activated." %}</p>
+ {% elif settings.ACCOUNTS_VERIFICATION_REQUIRED %}
+ <p>{% trans "After signing up, you'll receive an email with a link you need to click, in order to activate your account." %}</p>
+ {% endif %}
+{% endif %}
+
+{% endblock %}
--- /dev/null
+{% load i18n mezzanine_tags accounts_tags %}
+
+{% if request.user.is_authenticated %}
+ <p>
+ {% trans "Logged in as: " %}
+ {% url "profile" request.user.username as profile_url %}
+ {% if profile_url %}
+ <a href="{{ profile_url }}">{{ request.user|username_or:"email" }}</a>
+ </p>
+ <a href="{% url "profile_update" %}" class="btn btn-default btn-sm btn-account">
+ <span class="glyphicon glyphicon-edit"></span> {% trans "Update profile" %}</a>
+ {% else %}
+ <a href="{% url "profile_update" %}">{{ request.user|username_or:"email" }}</a>
+ </p>
+ {% endif %}
+ <a href="{% url "logout" %}?next={{ request.path }}" class="btn btn-sm btn-danger btn-account">
+ <span class="glyphicon glyphicon-log-out"></span> {% trans "Log out" %}</a>
+{% else %}
+ <a href="{% url "login" %}?next={{ request.path }}" class="btn btn-default btn-sm btn-account">
+ <span class="glyphicon glyphicon-log-in"></span> {% trans "Log in" %}</a>
+ {% trans "or" %}
+ <a href="{% url "signup" %}?next={{ request.path }}" class="btn btn-default btn-sm btn-account">
+ <span class="glyphicon glyphicon-edit"></span> {% trans "Sign up" %}</a>
+{% endif %}
--- /dev/null
+{% load i18n mezzanine_tags accounts_tags %}
+
+<div class="navbar-right navbar-account-controls">
+ {% if request.user.is_authenticated %}
+ {% url "profile" request.user.username as profile_url %}
+ {% if not profile_url %}{% url "profile_update" as profile_url %}{% endif %}
+ <p class="navbar-text">
+ <a class="navbar-link" href="{{ profile_url }}">
+ <span class="glyphicon glyphicon-user"></span> {{ request.user|username_or:"email" }}</a></p>
+ <a href="{% url "logout" %}?next={{ request.path }}" class="btn btn-default navbar-btn">
+ <span class="glyphicon glyphicon-log-out"></span> {% trans "Log out" %}</a>
+ {% else %}
+ <a href="{% url "login" %}?next={{ request.path }}" class="btn btn-default navbar-btn">
+ <span class="glyphicon glyphicon-log-in"></span> {% trans "Log in" %}</a>
+ <a href="{% url "signup" %}?next={{ request.path }}" class="btn btn-default navbar-btn">
+ <span class="glyphicon glyphicon-edit"></span> {% trans "Sign up" %}</a>
+ {% endif %}
+</div>
+
--- /dev/null
+<!doctype html>
+<html lang="{{ LANGUAGE_CODE }}"{% if LANGUAGE_BIDI %} dir="rtl"{% endif %}>
+{% load pages_tags mezzanine_tags i18n staticfiles %}
+
+<head>
+<meta http-equiv="Content-type" content="text/html; charset=utf-8">
+<meta name="viewport" content="width=device-width, initial-scale=1.0">
+<meta name="keywords" content="{% block meta_keywords %}{% endblock %}">
+<meta name="description" content="{% block meta_description %}{% endblock %}">
+<title>{% block meta_title %}{% endblock %}{% if settings.SITE_TITLE %} | {{ settings.SITE_TITLE }}{% endif %}</title>
+<link rel="shortcut icon" href="{% static "img/favicon.ico" %}">
+
+{% ifinstalled mezzanine.blog %}
+<link rel="alternate" type="application/rss+xml" title="RSS" href="{% url "blog_post_feed" "rss" %}">
+<link rel="alternate" type="application/atom+xml" title="Atom" href="{% url "blog_post_feed" "atom" %}">
+{% endifinstalled %}
+
+{% compress css %}
+<link rel="stylesheet" href="{% static "css/bootstrap.css" %}">
+<link rel="stylesheet" href="{% static "css/mezzanine.css" %}">
+<link rel="stylesheet" href="{% static "css/bootstrap-theme.css" %}">
+{% if LANGUAGE_BIDI %}
+<link rel="stylesheet" href="{% static "css/bootstrap-rtl.css" %}">
+{% endif %}
+{% ifinstalled cartridge.shop %}
+<link rel="stylesheet" href="{% static "css/cartridge.css" %}">
+{% if LANGUAGE_BIDI %}
+<link rel="stylesheet" href="{% static "css/cartridge.rtl.css" %}">
+{% endif %}
+{% endifinstalled %}
+{% block extra_css %}{% endblock %}
+{% endcompress %}
+
+{% compress js %}
+<script src="{% static "mezzanine/js/"|add:settings.JQUERY_FILENAME %}"></script>
+<script src="{% static "js/bootstrap.js" %}"></script>
+<script src="{% static "js/bootstrap-extras.js" %}"></script>
+{% block extra_js %}{% endblock %}
+{% endcompress %}
+
+<!--[if lt IE 9]>
+<script src="{% static "js/html5shiv.js" %}"></script>
+<script src="{% static "js/respond.min.js" %}"></script>
+<![endif]-->
+
+{% block extra_head %}{% endblock %}
+</head>
+
+<body id="{% block body_id %}body{% endblock %}">
+
+<div class="navbar navbar-default navbar-fixed-top" role="navigation">
+<div class="container">
+<div class="navbar-header">
+ <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
+ <span class="sr-only">{% trans "Toggle Navigation" %}</span>
+ <span class="icon-bar"></span>
+ <span class="icon-bar"></span>
+ <span class="icon-bar"></span>
+ </button>
+ {% if settings.SITE_TITLE %}<a class="navbar-brand" href="/">{{ settings.SITE_TITLE }}</a>{% endif %}
+ {% if settings.SITE_TAGLINE %}<p class="navbar-text visible-lg">{{ settings.SITE_TAGLINE }}</p>{% endif %}
+</div>
+<div class="navbar-collapse collapse">
+ {% search_form "all" %}
+ {% page_menu "pages/menus/dropdown.html" %}
+</div>
+</div>
+</div>
+
+<div class="container">
+
+{% nevercache %}
+{% if messages %}
+<div class="messages">
+{% for message in messages %}
+<div class="alert alert-dismissable alert-{{ message.tags }}" data-alert="alert">
+ <button type="button" class="close" data-dismiss="alert" aria-hidden="true">×</button>
+ {{ message }}
+</div>
+{% endfor %}
+</div>
+{% endif %}
+{% endnevercache %}
+
+<h1>{% block title %}{% endblock %}</h1>
+
+<ul class="breadcrumb">
+{% spaceless %}
+{% block breadcrumb_menu %}{% page_menu "pages/menus/breadcrumb.html" %}{% endblock %}
+{% endspaceless %}
+</ul>
+
+</div>
+
+<div class="container">
+<div class="row">
+
+<div class="col-md-2 left">
+ {% block left_panel %}
+ <div class="panel panel-default tree">{% page_menu "pages/menus/tree.html" %}</div>
+ {% endblock %}
+</div>
+
+<div class="col-md-7 middle">
+ {% block main %}{% endblock %}
+</div>
+
+<div class="col-md-3 right">
+ {% nevercache %}
+ {% include "includes/language_selector.html" %}
+ {% include "includes/user_panel.html" %}
+ {% endnevercache %}
+ <div class="panel panel-default">
+ <div class="panel-body">
+ {% block right_panel %}
+ {% ifinstalled mezzanine.twitter %}
+ {% include "twitter/tweets.html" %}
+ {% endifinstalled %}
+ {% endblock %}
+ </div>
+ </div>
+</div>
+
+</div>
+</div>
+
+<footer>
+<div class="container">
+{% page_menu "pages/menus/footer.html" %}
+
+<div class="row">
+<p class="site-info text-center">
+ {% trans "Powered by" %}
+ <a href="http://mezzanine.jupo.org">Mezzanine</a>{% ifinstalled cartridge.shop %},
+ <a href="http://cartridge.jupo.org">Cartridge</a>{% endifinstalled %}
+ {% trans "and" %}
+ <a href="http://www.djangoproject.com">Django</a>
+ <span class="separator">|</span>
+ {% trans "Theme by" %} <a target="_blank" href="http://getbootstrap.com">Bootstrap</a>
+ {% ifinstalled mezzanine.mobile %}
+ <span class="separator">|</span>
+ <a href="{% url "set_device" "mobile" %}?next={{ request.path }}">{% trans "View Mobile Site" %}</a>
+ {% endifinstalled %}
+</p>
+</div>
+</div>
+</footer>
+
+{% include "includes/footer_scripts.html" %}
+
+</body>
+</html>
--- /dev/null
+{% extends "blog/blog_post_list.html" %}
+{% load mezzanine_tags comment_tags keyword_tags rating_tags i18n disqus_tags %}
+
+{% block meta_title %}{{ blog_post.meta_title }}{% endblock %}
+
+{% block meta_keywords %}{% metablock %}
+{% keywords_for blog_post as tags %}
+{% for tag in tags %}{% if not forloop.first %}, {% endif %}{{ tag }}{% endfor %}
+{% endmetablock %}{% endblock %}
+
+{% block meta_description %}{% metablock %}
+{{ blog_post.description }}
+{% endmetablock %}{% endblock %}
+
+{% block title %}
+{% editable blog_post.title %}{{ blog_post.title }}{% endeditable %}
+{% endblock %}
+
+{% block breadcrumb_menu %}
+{{ block.super }}
+<li class="active">{{ blog_post.title }}</li>
+{% endblock %}
+
+{% block main %}
+
+{% block blog_post_detail_postedby %}
+{% editable blog_post.publish_date %}
+<h6 class="post-meta">
+ {% trans "Posted by" %}:
+ {% with blog_post.user as author %}
+ <a href="{% url "blog_post_list_author" author %}">{{ author.get_full_name|default:author.username }}</a>
+ {% endwith %}
+ {% blocktrans with sometime=blog_post.publish_date|timesince %}{{ sometime }} ago{% endblocktrans %}
+</h6>
+{% endeditable %}
+{% endblock %}
+{% block blog_post_detail_commentlink %}
+<p>
+ {% if blog_post.allow_comments %}
+ {% if settings.COMMENTS_DISQUS_SHORTNAME %}
+ (<a href="{{ blog_post.get_absolute_url }}#disqus_thread"
+ data-disqus-identifier="{% disqus_id_for blog_post %}">{% spaceless %}
+ {% trans "Comments" %}
+ {% endspaceless %}</a>)
+ {% else %}(<a href="#comments">{% spaceless %}
+ {% blocktrans count comments_count=blog_post.comments_count %}{{ comments_count }} comment{% plural %}{{ comments_count }} comments{% endblocktrans %}
+ {% endspaceless %}</a>)
+ {% endif %}
+ {% endif %}
+</p>
+{% endblock %}
+
+{% block blog_post_detail_featured_image %}
+{% if settings.BLOG_USE_FEATURED_IMAGE and blog_post.featured_image %}
+<p><img class="img-responsive" src="{{ MEDIA_URL }}{% thumbnail blog_post.featured_image 600 0 %}"></p>
+{% endif %}
+{% endblock %}
+
+{% if settings.COMMENTS_DISQUS_SHORTNAME %}
+{% include "generic/includes/disqus_counts.html" %}
+{% endif %}
+
+{% block blog_post_detail_content %}
+{% editable blog_post.content %}
+{{ blog_post.content|richtext_filters|safe }}
+{% endeditable %}
+{% endblock %}
+
+{% block blog_post_detail_keywords %}
+{% keywords_for blog_post as tags %}
+{% if tags %}
+{% spaceless %}
+<ul class="list-inline tags">
+ <li>{% trans "Tags" %}:</li>
+ {% for tag in tags %}
+ <li><a href="{% url "blog_post_list_tag" tag.slug %}">{{ tag }}</a>{% if not forloop.last %}, {% endif %}</li>
+ {% endfor %}
+</ul>
+{% endspaceless %}
+{% endif %}
+{% endblock %}
+
+{% block blog_post_detail_rating %}
+<div class="panel panel-default rating">
+ <div class="panel-body">
+ {% rating_for blog_post %}
+ </div>
+</div>
+{% endblock %}
+
+{% block blog_post_detail_sharebuttons %}
+{% set_short_url_for blog_post %}
+<a class="btn btn-sm share-twitter" target="_blank" href="http://twitter.com/home?status={{ blog_post.short_url|urlencode }}%20{{ blog_post.title|urlencode }}">{% trans "Share on Twitter" %}</a>
+<a class="btn btn-sm share-facebook" target="_blank" href="http://facebook.com/sharer.php?u={{ request.build_absolute_uri }}&t={{ blog_post.title|urlencode }}">{% trans "Share on Facebook" %}</a>
+{% endblock %}
+
+{% block blog_post_previous_next %}
+<ul class="pager">
+{% with blog_post.get_previous_by_publish_date as previous %}
+{% if previous %}
+<li class="previous">
+ <a href="{{ previous.get_absolute_url }}">← {{ previous }}</a>
+</li>
+{% endif %}
+{% endwith %}
+{% with blog_post.get_next_by_publish_date as next %}
+{% if next %}
+<li class="next">
+ <a href="{{ next.get_absolute_url }}">{{ next }} →</a>
+</li>
+{% endif %}
+{% endwith %}
+</ul>
+{% endblock %}
+
+{% block blog_post_detail_related_posts %}
+{% if related_posts %}
+<div id="related-posts">
+<h3>{% trans 'Related posts' %}</h3>
+<ul class="list-unstyled">
+{% for post in related_posts %}
+ <li><a href="{{ post.get_absolute_url }}">{{ post.title }}</a></li>
+{% endfor %}
+</ul>
+</div>
+{% endif %}
+{% endblock %}
+
+{% block blog_post_detail_comments %}
+{% if blog_post.allow_comments %}{% comments_for blog_post %}{% endif %}
+{% endblock %}
+
+{% endblock %}
--- /dev/null
+{% extends "base.html" %}
+{% load i18n mezzanine_tags blog_tags keyword_tags disqus_tags %}
+
+{% block meta_title %}{% if page %}{{ page.meta_title }}{% else %}{% trans "Blog" %}{% endif %}{% endblock %}
+
+{% block meta_keywords %}{% metablock %}
+{% keywords_for page as keywords %}
+{% for keyword in keywords %}
+ {% if not forloop.first %}, {% endif %}
+ {{ keyword }}
+{% endfor %}
+{% endmetablock %}{% endblock %}
+
+{% block meta_description %}{% metablock %}
+{{ page.description }}
+{% endmetablock %}{% endblock %}
+
+{% block title %}
+{% if page %}
+{% editable page.title %}{{ page.title }}{% endeditable %}
+{% else %}
+{% trans "Blog" %}
+{% endif %}
+{% endblock %}
+
+{% block breadcrumb_menu %}
+{{ block.super }}
+{% if tag or category or year or month or author %}
+<li>{% spaceless %}
+{% if tag %}
+ {% trans "Tag:" %} {{ tag }}
+{% else %}{% if category %}
+ {% trans "Category:" %} {{ category }}
+{% else %}{% if year or month %}
+ {% if month %}{{ month }}, {% endif %}{{ year }}
+{% else %}{% if author %}
+ {% trans "Author:" %} {{ author.get_full_name|default:author.username }}
+{% endif %}{% endif %}{% endif %}{% endif %}
+{% endspaceless %}
+</li>
+{% endif %}
+{% endblock %}
+
+{% block main %}
+
+{% if tag or category or year or month or author %}
+ {% block blog_post_list_filterinfo %}
+ <p>
+ {% if tag %}
+ {% trans "Viewing posts tagged" %} {{ tag }}
+ {% else %}{% if category %}
+ {% trans "Viewing posts for the category" %} {{ category }}
+ {% else %}{% if year or month %}
+ {% trans "Viewing posts from" %} {% if month %}{{ month }}, {% endif %}
+ {{ year }}
+ {% else %}{% if author %}
+ {% trans "Viewing posts by" %}
+ {{ author.get_full_name|default:author.username }}
+ {% endif %}{% endif %}{% endif %}{% endif %}
+ {% endblock %}
+ </p>
+{% else %}
+ {% if page %}
+ {% block blog_post_list_pagecontent %}
+ {% if page.get_content_model.content %}
+ {% editable page.get_content_model.content %}
+ {{ page.get_content_model.content|richtext_filters|safe }}
+ {% endeditable %}
+ {% endif %}
+ {% endblock %}
+ {% endif %}
+{% endif %}
+
+{% for blog_post in blog_posts.object_list %}
+{% block blog_post_list_post_title %}
+{% editable blog_post.title %}
+<h2>
+ <a href="{{ blog_post.get_absolute_url }}">{{ blog_post.title }}</a>
+</h2>
+{% endeditable %}
+{% endblock %}
+{% block blog_post_list_post_metainfo %}
+{% editable blog_post.publish_date %}
+<h6 class="post-meta">
+ {% trans "Posted by" %}:
+ {% with blog_post.user as author %}
+ <a href="{% url "blog_post_list_author" author %}">{{ author.get_full_name|default:author.username }}</a>
+ {% endwith %}
+ {% with blog_post.categories.all as categories %}
+ {% if categories %}
+ {% trans "in" %}
+ {% for category in categories %}
+ <a href="{% url "blog_post_list_category" category.slug %}">{{ category }}</a>{% if not forloop.last %}, {% endif %}
+ {% endfor %}
+ {% endif %}
+ {% endwith %}
+ {% blocktrans with sometime=blog_post.publish_date|timesince %}{{ sometime }} ago{% endblocktrans %}
+</h6>
+{% endeditable %}
+{% endblock %}
+
+{% if settings.BLOG_USE_FEATURED_IMAGE and blog_post.featured_image %}
+{% block blog_post_list_post_featured_image %}
+<a href="{{ blog_post.get_absolute_url }}">
+ <img class="img-thumbnail pull-left" src="{{ MEDIA_URL }}{% thumbnail blog_post.featured_image 90 90 %}">
+</a>
+{% endblock %}
+{% endif %}
+
+{% block blog_post_list_post_content %}
+{% editable blog_post.content %}
+{{ blog_post.description_from_content|safe }}
+{% endeditable %}
+{% endblock %}
+
+{% block blog_post_list_post_links %}
+<div class="blog-list-detail">
+ {% keywords_for blog_post as tags %}
+ {% if tags %}
+ <ul class="list-inline tags">
+ {% trans "Tags" %}:
+ {% spaceless %}
+ {% for tag in tags %}
+ <li><a href="{% url "blog_post_list_tag" tag.slug %}" class="tag">{{ tag }}</a>{% if not forloop.last %}, {% endif %}</li>
+ {% endfor %}
+ {% endspaceless %}
+ </ul>
+ {% endif %}
+ <p>
+ <a href="{{ blog_post.get_absolute_url }}">{% trans "read more" %}</a>
+ {% if blog_post.allow_comments %}
+ /
+ {% if settings.COMMENTS_DISQUS_SHORTNAME %}
+ <a href="{{ blog_post.get_absolute_url }}#disqus_thread"
+ data-disqus-identifier="{% disqus_id_for blog_post %}">
+ {% trans "Comments" %}
+ </a>
+ {% else %}
+ <a href="{{ blog_post.get_absolute_url }}#comments">
+ {% blocktrans count comments_count=blog_post.comments_count %}{{ comments_count }} comment{% plural %}{{ comments_count }} comments{% endblocktrans %}
+ </a>
+ {% endif %}
+ {% endif %}
+ </p>
+</div>
+{% endblock %}
+{% endfor %}
+
+{% pagination_for blog_posts %}
+
+{% if settings.COMMENTS_DISQUS_SHORTNAME %}
+{% include "generic/includes/disqus_counts.html" %}
+{% endif %}
+
+{% endblock %}
+
+{% block right_panel %}
+{% include "blog/includes/filter_panel.html" %}
+{% endblock %}
--- /dev/null
+{% load blog_tags keyword_tags mezzanine_tags i18n %}
+
+{% block blog_recent_posts %}
+{% blog_recent_posts 5 as recent_posts %}
+{% if recent_posts %}
+<h3>{% trans "Recent Posts" %}</h3>
+<ul class="list-unstyled recent-posts">
+{% for recent_post in recent_posts %}
+<li>
+ {% spaceless %}
+ <a href="{{ recent_post.get_absolute_url }}">
+ {% if settings.BLOG_USE_FEATURED_IMAGE and recent_post.featured_image %}
+ <img src="{{ MEDIA_URL }}{% thumbnail recent_post.featured_image 24 24 %}">
+ {% endif %}
+ {{ recent_post.title }}
+ </a>
+ {% endspaceless %}
+</li>
+{% endfor %}
+</ul>
+{% endif %}
+{% endblock %}
+
+{% block blog_months %}
+{% blog_months as months %}
+{% if months %}
+<h3>{% trans "Archive" %}</h3>
+{% for month in months %}
+ {% ifchanged month.date.year %}
+ {% if not forloop.first %}</ul>{% endif %}
+ <h6>{{ month.date.year }}</h6><ul class="list-unstyled">
+ {% endifchanged %}
+ <li><a href="{% url "blog_post_list_month" year=month.date.year month=month.date.month %}"
+ >{{ month.date|date:"F" }}</a> ({{ month.post_count }})</li>
+{% endfor %}
+</ul>
+{% endif %}
+{% endblock %}
+
+{% block blog_categories %}
+{% blog_categories as categories %}
+{% if categories %}
+<h3>{% trans "Categories" %}</h3>
+<ul class="list-unstyled">
+{% for category in categories %}
+<li><a href="{% url "blog_post_list_category" category.slug %}"
+ >{{ category }}</a> ({{ category.post_count }})</li>
+{% endfor %}
+</ul>
+{% endif %}
+{% endblock %}
+
+{% block blog_keywords %}
+{% keywords_for blog.blogpost as tags %}
+{% if tags %}
+<h3>{% trans "Tags" %}</h3>
+<ul class="list-inline tag-cloud">
+{% for tag in tags %}
+<li>
+ <a href="{% url "blog_post_list_tag" tag.slug %}"
+ class="tag-weight-{{ tag.weight }}">{{ tag }}</a>
+ ({{ tag.item_count }})
+</li>
+{% endfor %}
+</ul>
+{% endif %}
+{% endblock %}
+
+{% block blog_authors %}
+{% blog_authors as authors %}
+{% if authors %}
+<h3>{% trans "Authors" %}</h3>
+<ul class="list-unstyled">
+{% for author in authors %}
+ <li><a href="{% url "blog_post_list_author" author.username %}"
+ >{{ author.get_full_name|default:author.username }}</a>
+ ({{ author.post_count }})</li>
+{% endfor %}
+</ul>
+{% endif %}
+{% endblock %}
+
+{% block blog_feeds %}
+<h3>{% trans "Feeds" %}</h3>
+{% if tag %}
+ <a href="{% url "blog_post_feed_tag" tag.slug "rss" %}">{% trans "RSS" %}</a> /
+ <a href="{% url "blog_post_feed_tag" tag.slug "atom" %}">{% trans "Atom" %}</a>
+{% endif %}
+{% if category %}
+ <a href="{% url "blog_post_feed_category" category.slug "rss" %}">{% trans "RSS" %}</a> /
+ <a href="{% url "blog_post_feed_category" category.slug "atom" %}">{% trans "Atom" %}</a>
+{% endif %}
+{% if author %}
+ <a href="{% url "blog_post_feed_author" author.username "rss" %}">{% trans "RSS" %}</a> /
+ <a href="{% url "blog_post_feed_author" author.username "atom" %}">{% trans "Atom" %}</a>
+{% endif %}
+{% if not tag and not category and not author %}
+ <a href="{% url "blog_post_feed" "rss" %}">{% trans "RSS" %}</a> /
+ <a href="{% url "blog_post_feed" "atom" %}">{% trans "Atom" %}</a>
+{% endif %}
+{% endblock %}
--- /dev/null
+{% load i18n accounts_tags %}
+{% block main %}
+<p>{% trans "Hey there, a new account has been created and requires activation." %}</p>
+<br>
+<p>{% trans "Name" %}: {{ user.get_full_name }}</p>
+<p>{% trans "Email" %}: {{ user.email }}</p>
+{% for field, value in user|profile_fields %}
+<p>{{ field }}: {{ value|linebreaksbr }}</p>
+{% endfor %}
+<br>
+<p>{% trans "Please use the link below to activate it." %}</p>
+<p><a href="http://{{ request.get_host }}{{ change_url }}">http://{{ request.get_host }}{{ change_url }}</a></p>
+{% endblock %}
--- /dev/null
+{% load i18n accounts_tags %}
+{% block main %}
+{% trans "Hey there, a new account has been created and requires activation." %}
+
+{% trans "Name" %}: {{ user.get_full_name }}
+{% trans "Email" %}: {{ user.email }}
+{% for field, value in user|profile_fields %}{{ field }}: {{ value|linebreaksbr }}
+{% endfor %}
+{% trans "Please use the link below to activate it." %}
+http://{{ request.get_host }}{{ change_url }}
+{% endblock %}
--- /dev/null
+{% load i18n %}
+{% trans "An account requires activation" %}
--- /dev/null
+{% load i18n %}
+{% block main %}
+<p>{% trans "Hey there, your account has been activated." %}</p>
+<p>{% trans "Please use the link below to log in." %}</p>
+<p><a href="http://{{ request.get_host }}{% url "login" %}">http://{{ request.get_host }}{% url "login" %}</a></p>
+{% endblock %}
--- /dev/null
+{% load i18n %}
+{% block main %}
+{% trans "Hey there, your account has been activated." %}
+{% trans "Please use the link below to log in." %}
+http://{{ request.get_host }}{% url "login" %}
+{% endblock %}
--- /dev/null
+{% load i18n %}
+{% trans "Your account has been activated" %}
--- /dev/null
+{% block main %}{% endblock %}
+
+<br><a href="http://{{ request.get_host }}">http://{{ request.get_host }}</a>
--- /dev/null
+{% block main %}{% endblock %}
+
+http://{{ request.get_host }}
--- /dev/null
+{% extends "email/base.html" %}
+{% load i18n %}
+
+{% block main %}
+<p>
+ {% trans "A new comment has been posted on" %}
+ <a href="http://{{ request.get_host }}{{ comment_url }}">{{ obj }}</a>
+</p>
+<p>
+ {% blocktrans with submit_date=comment.submit_date user_name=comment.user_name %}
+ At {{ submit_date }} {{ user_name }} wrote:
+ {% endblocktrans %}
+</p>
+<p>
+ {{ comment.comment|linebreaksbr|urlize }}
+</p>
+{% endblock %}
--- /dev/null
+{% extends "email/base.txt" %}
+{% load i18n %}
+
+{% block main %}
+A new comment has been posted on {{ obj }} [http://{{ request.get_host }}{{ comment_url }}]
+
+{% blocktrans with submit_date=comment.submit_date user_name=comment.user_name %}
+At {{ submit_date }} {{ user_name }} wrote:
+{% endblocktrans %}
+
+{{ comment.comment }}
+{% endblock %}
--- /dev/null
+{% extends "email/base.html" %}
+
+{% block main %}
+{% if message %}<p>{{ message }}</p>{% endif %}
+<table border="0">
+{% for field, value in fields %}
+<tr>
+ <td><b>{{ field }}:</b></td>
+ <td>{{ value|linebreaks }}</td>
+</tr>
+{% endfor %}
+</table>
+{% endblock %}
--- /dev/null
+{% extends "email/base.txt" %}
+
+{% block main %}{% if message %}
+{{ message }}
+
+{% endif %}{% for field, value in fields %}
+{{ field }}: {{ value|safe }}
+{% endfor %}
+{% endblock %}
--- /dev/null
+{% extends "email/form_response.html" %}
+
+{% block main %}
+{{ block.super }}
+{% endblock %}
--- /dev/null
+{% extends "email/form_response.txt" %}
+
+{% block main %}
+{{ block.super }}
+{% endblock %}
--- /dev/null
+{% load i18n %}
+{% block main %}
+<p>{% trans "Hey there, the password reset form was used for your account." %}</p>
+<p>{% trans "Please use the link below to log in and update your password." %}</p>
+<p><a href="http://{{ request.get_host }}{{ verify_url }}">http://{{ request.get_host }}{{ verify_url }}</a></p>
+<p>{% trans "If you didn't request for your password to be reset, please ignore this email." %}</p>
+{% endblock %}
+
--- /dev/null
+{% load i18n %}
+{% block main %}
+{% trans "Hey there, the password reset form was used for your account." %}
+{% trans "Please use the link below to log in and update your password." %}
+http://{{ request.get_host }}{{ verify_url }}
+{% trans "If you didn't request for your password to be reset, please ignore this email." %}
+{% endblock %}
--- /dev/null
+{% load i18n %}
+{% trans "Reset your password" %}
--- /dev/null
+{% load i18n %}
+{% block main %}
+<p>{% trans "Hey there, thanks for creating your account." %}</p>
+<p>{% trans "Please use the link below to activate it." %}</p>
+<p><a href="http://{{ request.get_host }}{{ verify_url }}">http://{{ request.get_host }}{{ verify_url }}</a></p>
+{% endblock %}
--- /dev/null
+{% load i18n %}
+{% block main %}
+{% trans "Hey there, thanks for creating your account." %}
+{% trans "Please use the link below to activate it." %}
+http://{{ request.get_host }}{{ verify_url }}
+{% endblock %}
--- /dev/null
+{% load i18n %}
+{% trans "Activate your account" %}
--- /dev/null
+{% extends "base.html" %}
+
+{% load i18n %}
+
+{% block meta_title %}
+{% trans "Page not found" %}
+{% endblock %}
+
+{% block title %}
+{% trans "Page not found" %}
+{% endblock %}
+
+{% block main %}
+<div class="panel panel-danger">
+ <div class="panel-heading"><h3 class="panel-title">{% trans "Page not found" %}</h3></div>
+ <div class="panel-body">{% trans "The page you requested does not exist." %}</div>
+</div>
+{% endblock %}
--- /dev/null
+{% extends "base.html" %}
+
+{% load i18n %}
+
+{% block meta_title %}
+{% trans "Error" %}
+{% endblock %}
+
+{% block title %}
+{% trans "Error" %}
+{% endblock %}
+
+{% block main %}
+<div class="panel panel-danger">
+ <div class="panel-heading"><h3 class="panel-title">{% trans "Error" %}</h3></div>
+ <div class="panel-body">{% trans "Sorry, an error occurred." %}</div>
+</div>
+{% endblock %}
--- /dev/null
+{% extends "base.html" %}
+
+{% load mezzanine_tags comment_tags keyword_tags %}
+
+{% block meta_title %}{{ obj }}{% endblock %}
+
+{% block meta_keywords %}{% metablock %}
+{% keywords_for obj as tags %}
+{% for tag in tags %}{% if not forloop.first %}, {% endif %}{{ tag }}{% endfor %}
+{% endmetablock %}{% endblock %}
+
+{% block meta_description %}{% metablock %}
+{{ obj.description }}
+{% endmetablock %}{% endblock %}
+
+{% block main %}
+{% comments_for obj %}
+{% endblock %}
--- /dev/null
+{% load i18n mezzanine_tags comment_tags rating_tags %}
+
+{% for comment in comments_for_thread %}
+
+<div id="comment-{{ comment.id }}"
+ class="comment media{% if comment.by_author %} comment-author{% endif %}">
+
+ {% editable comment.is_public comment.is_removed %}
+ {% if not comment.is_removed and comment.is_public or request.user.is_staff %}
+ {% if comment.url %}
+ <a href="{{ comment.url }}">
+ <img class="pull-left media-object" src="{% gravatar_url comment.email %}">
+ </a>
+ <div class="media-body">
+ <h4 class="media-heading"><a href="{{ comment.url }}">{{ comment.user_name }}</a>
+ {% else %}
+ <img class="pull-left media-object" src="{% gravatar_url comment.email %}">
+ <div class="media-body">
+ <h4 class="media-heading">{{ comment.user_name }}
+ {% endif %}
+ <small class="timespan">
+ {% blocktrans with sometime=comment.submit_date|timesince %}{{ sometime }} ago{% endblocktrans %}
+ </small>
+ </h4>
+ <p>{{ comment.comment|comment_filter }}</p>
+ {% endif %}
+
+ {% if not comment.is_removed and comment.is_public %}
+ <a href="{{ request.path }}#comment-{{ comment.id }}">
+ <span class="glyphicon glyphicon-link"></span> {% trans "Link" %}
+ </a> |
+ <a href="#reply-{{ comment.id }}" class="reply">
+ <span class="glyphicon glyphicon-share-alt"></span> {% trans "Reply" %}
+ </a>
+ {% if settings.COMMENTS_USE_RATINGS %}
+ <div class="rating">
+ {% rating_for comment %}
+ </div>
+ {% endif %}
+ <form class="comment-reply-form" method="post" id="reply-{{ comment.id }}"
+ action="{{ comment_url }}#reply-{{ comment.id }}"
+ {% if replied_to != comment.id %}style="display:none;"{% endif %}>
+ {% if replied_to == comment.id %}
+ {% fields_for posted_comment_form %}
+ {% else %}
+ {% fields_for unposted_comment_form %}
+ {% endif %}
+ <input type="hidden" name="replied_to" value="{{ comment.id }}">
+ <input class="btn btn-primary btn-lg" type="submit" value="{% trans "Reply" %}">
+ </form>
+
+ {% else %}
+ <p>
+ {% if comment.is_removed %}
+ <span class="glyphicon glyphicon-remove-circle"></span> {% trans "Comment deleted" %}
+ {% else %}
+ <span class="glyphicon glyphicon-warning-sign"></span> {% trans "Comment awaiting approval" %}
+ {% endif %}
+ <small class="timespan">{% blocktrans with sometime=comment.submit_date|timesince %}{{ sometime }} ago{% endblocktrans %}</small>
+ </p>
+ {% endif %}
+
+ {% comment_thread comment %}
+
+ {% if not comment.is_removed and comment.is_public or request.user.is_staff %}</div>{% endif %}
+ {% endeditable %}
+</div>
+{% endfor %}
+
+{% if no_comments %}
+<p>{% trans "There are currently no comments" %}</p>
+{% endif %}
+
--- /dev/null
+{% load i18n mezzanine_tags comment_tags %}
+<div id="comments">
+<h3>{% trans "Comments" %}</h3>
+{% if settings.COMMENTS_DISQUS_SHORTNAME %}
+{% include "generic/includes/disqus_comments.html" %}
+{% else %}
+<script>
+$(function() {
+ $('.reply').click(function() {
+ $('.comment-reply-form').hide();
+ $(this).siblings('.comment-reply-form').toggle();
+ });
+});
+</script>
+<style>.input_id_honeypot {display:none !important;}</style>
+{% comment_thread object_for_comments %}
+<h3>{% trans "New Comment" %}</h3>
+<form method="post" id="comment" action="{{ comment_url }}#comment">
+ {% if not request.POST.replied_to %}
+ {% fields_for posted_comment_form %}
+ {% else %}
+ {% fields_for unposted_comment_form %}
+ {% endif %}
+ <div class="form-actions">
+ <input class="btn btn-primary btn-lg" type="submit" value="{% trans "Comment" %}">
+ </div>
+</form>
+{% endif %}
+</div>
--- /dev/null
+{% load disqus_tags %}
+
+<div id="disqus_thread"></div>
+{% disqus_sso_script %}
+<script>
+ var disqus_developer = '{{ settings.DEV_SERVER }}' == 'True';
+ var disqus_url = 'http{% if request.is_secure %}s{% endif %}://{{ request.META.HTTP_HOST }}{{ object_for_comments.get_absolute_url }}';
+ var disqus_title = '{{ object_for_comments|escapejs }}';
+ var disqus_identifier = '{% disqus_id_for object_for_comments %}';
+ (function() {
+ var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true;
+ dsq.src = 'http{% if request.is_secure %}s{% endif %}://{{ settings.COMMENTS_DISQUS_SHORTNAME }}.disqus.com/embed.js';
+ (document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq);
+ })();
+</script>
--- /dev/null
+<script>
+/* * * CONFIGURATION VARIABLES: EDIT BEFORE PASTING INTO YOUR WEBPAGE * * */
+var disqus_shortname = '{{ settings.COMMENTS_DISQUS_SHORTNAME }}'; // required: replace example with your forum shortname
+
+/* * * DON'T EDIT BELOW THIS LINE * * */
+(function () {
+ var s = document.createElement('script'); s.async = true;
+ s.type = 'text/javascript';
+ s.src = '//' + disqus_shortname + '.disqus.com/count.js';
+ (document.getElementsByTagName('HEAD')[0] || document.getElementsByTagName('BODY')[0]).appendChild(s);
+}());
+</script>
--- /dev/null
+<script>
+var disqus_config = function () {
+ this.page.remote_auth_s3 = '{{ sso_data }}';
+ this.page.api_key = '{{ public_key }}';
+}
+</script>
--- /dev/null
+{% load mezzanine_tags rating_tags i18n %}
+
+<span id="rating-{{ rating_object.id }}">
+ {% if rating_average %}
+ {% trans "Current rating" %}: {{ rating_average|floatformat }}
+ {% else %}
+ {% trans "Currently unrated" %}
+ {% endif %}
+</span>
+
+{% if not rated or request.user.is_authenticated %}
+<form class="form-inline" role="form" method="post" action="{% url "rating" %}">
+ {% nevercache %}
+ {% csrf_token %}
+ {% endnevercache %}
+ <ul class="radio radio-inline">{{ rating_form.as_ul }}</ul>
+ <input type="submit" class="btn btn-default btn-sm" value="{% trans "Rate" %}"
+ onclick="return $(this.form).find('input:checked').length == 1;">
+</form>
+{% endif %}
--- /dev/null
+{% load i18n %}
+
+{# Edit form #}
+<form style="display:none;" class="editable-form" method="post"
+ action="{% url "edit" %}" id="{{ editable_form.uuid }}"
+ {% if editable_form.is_multipart %} enctype="multipart/form-data"{% endif %}>
+ {% csrf_token %}
+ {% for field in editable_form %}
+ <p{% if field.is_hidden %} style="display:none;"{% endif %}>
+ {{ field.label_tag }}<br />{{ field }}{{ field.errors }}
+ {% if field.help_text %}
+ <span class="helptext">{{ field.help_text }}</span>
+ {% endif %}
+ </p>
+ {% endfor %}
+ <input type="submit" value="{% trans "Save" %}" class="btn btn-primary btn-lg">
+ <input type="button" value="{% trans "Cancel" %}" class="btn btn-default btn-lg">
+</form>
+
+{# Original content wrapped in span #}
+<div class="editable-original">{{ original }}</div>
+
+{# Edit link #}
+<a style="visibility:hidden;" class="editable-link" href="#"
+ rel="#{{ editable_form.uuid }}">{% trans "Edit" %}</a>
+
+{# Edit highlight #}
+<div style="visibility:hidden;" class="editable-highlight"></div>
--- /dev/null
+{% load i18n staticfiles %}
+
+{% if has_site_permission %}
+<link rel="stylesheet" href="{% static "mezzanine/css/editable.css" %}">
+{{ richtext_media|safe }}
+<script>
+{% url "fb_browse" as fb_browse_url %}
+{% url "static_proxy" as static_proxy_url %}
+{% get_current_language as LANGUAGE_CODE %}
+window.__filebrowser_url = '{{ fb_browse_url }}';
+window.__toolbar_html = '{{ toolbar|escapejs }}';
+window.__static_proxy = '{{ static_proxy_url }}';
+window.__language_code = '{{ LANGUAGE_CODE }}';
+window.__tinymce_css = '{% static "mezzanine/css/tinymce.css" %}';
+</script>
+<script src="{% static "mezzanine/js/jquery.tools.toolbox.expose.js" %}"></script>
+<script src="{% static "mezzanine/js/jquery.tools.overlay.js" %}"></script>
+<script src="{% static "mezzanine/js/jquery.form.js" %}"></script>
+<script src="{% static "mezzanine/js/editable.js" %}"></script>
+{% endif %}
--- /dev/null
+{% load i18n staticfiles %}
+
+<div id="editable-toolbar" method="POST" action="{% url "admin:logout" %}">
+ {% url "admin:index" as admin_index_url %}
+ {% url "admin:logout" as admin_logout_url %}
+ {% url "logout" as accounts_logout_url %}
+ <a id="editable-toolbar-toggle" href="#"></a>
+ <a href="{{ editable_obj.get_admin_url|default:admin_index_url }}">{% trans "Admin" %}</a>
+ <a href="{{ accounts_logout_url|default:admin_logout_url }}?{{ REDIRECT_FIELD_NAME }}={{ request.path }}">{% trans "Log out" %}</a>
+</div>
+
+<img id="editable-loading" src="{% static "mezzanine/img/loadingAnimation.gif" %}">
+
--- /dev/null
+{% load mezzanine_tags %}
+
+{% editable_loader %}
+
+<script>
+{% if settings.GOOGLE_ANALYTICS_ID and not request.user.is_staff %}
+var _gaq = _gaq || [['_trackPageview']];
+_gaq.unshift(['_setAccount', '{{ settings.GOOGLE_ANALYTICS_ID }}']);
+(function(d, t) {
+ var g = d.createElement(t),
+ s = d.getElementsByTagName(t)[0];
+ g.async = true;
+ g.src = '//www.google-analytics.com/ga.js';
+ s.parentNode.insertBefore(g, s);
+})(document, 'script');
+{% endif %}
+</script>
--- /dev/null
+{% load i18n %}
+
+{% if form.non_field_errors or form.errors %}
+<div class="form-errors">
+ {% for error in form.non_field_errors %}
+ <div class="alert alert-danger non-field-error">{{ error }}</div>
+ {% empty %}
+ <div class="alert alert-danger field-error">{% trans "Please correct the errors below." %}</div>
+ {% endfor %}
+</div>
+{% endif %}
--- /dev/null
+{% load mezzanine_tags %}
+
+{% nevercache %}
+<input type="hidden" name="referrer" value="{{ request.META.HTTP_REFERER }}">
+{% csrf_token %}
+{% endnevercache %}
+
+{% for field in form_for_fields %}
+{% if field.is_hidden %}
+{{ field }}
+{% else %}
+<div class="form-group input_{{ field.id_for_label }} {{ field.field.type }}
+ {% if field.errors %} has-error{% endif %}">
+ {% if field.label %}<label class="control-label" for="{{ field.auto_id }}">{{ field.label }}</label>{% endif %}
+ {{ field }}
+ {% if field.errors %}
+ <p class="help-block">
+ {% for e in field.errors %}
+ {% if not forloop.first %} / {% endif %}{{ e }}
+ {% endfor %}
+ </p>
+ {% elif field.help_text %}
+ <p class="help-block">{{ field.help_text }}</p>
+ {% endif %}
+</div>
+{% endif %}
+{% endfor %}
--- /dev/null
+{% load i18n %}
+{% get_language_info_list for LANGUAGES as languages %}
+{% if settings.USE_MODELTRANSLATION and languages|length > 1 %}
+{# hide submit button if browser has javascript support and can react to onchange event #}
+<script>$(document).ready(function(){$('#language_selector_form').change(function(){this.submit();});$('#language_selector_form input').hide();});</script>
+<div>
+<form action="{% url "set_language" %}" method="post" id="language_selector_form">
+ {% csrf_token %}
+ <div class="form-group">
+ <select name="language" class="form-control">
+ {% for language in languages %}
+ <option value="{{ language.code }}"
+ {% if language.code == LANGUAGE_CODE %}selected="selected"{% endif %}>
+ {{ language.name_local }}
+ </option>
+ {% endfor %}
+ </select>
+ </div>
+ <input type="submit" class="btn btn-default" value="{% trans "Change" %}" />
+</form>
+</div>
+{% endif %}
--- /dev/null
+{% load i18n %}
+
+{% if current_page.has_previous or current_page.has_next %}
+<ul class="pagination">
+
+<li class="page-info">
+ <span>{% trans "Page" %} {{ current_page.number }} {% trans "of" %} {{ current_page.paginator.num_pages }}</span>
+</li>
+<li class="prev previous{% if not current_page.has_previous %} disabled{% endif %}">
+ <a{% if current_page.has_previous %} href="?{{ page_var }}={{ current_page.previous_page_number }}{% if querystring %}&{{ querystring }}{% endif %}"{% endif %}>←</a>
+</li>
+{% for page in current_page.visible_page_range %}
+<li{% if page == current_page.number %} class="active"{% endif %}>
+ <a href="?{{ page_var }}={{ page }}{% if querystring %}&{{ querystring }}{% endif %}">{{ page }}</a>
+</li>
+{% endfor %}
+<li class="next{% if not current_page.has_next %} disabled{% endif %}">
+ <a{% if current_page.has_next %} href="?{{ page_var }}={{ current_page.next_page_number }}{% if querystring %}&{{ querystring }}{% endif %}"{% endif %}>→</a>
+</li>
+
+</ul>
+{% endif %}
--- /dev/null
+{% load mezzanine_tags i18n %}
+<form action="{% url "search" %}" class="navbar-form navbar-right" role="search">
+
+<div class="form-group">
+ <input class="form-control" placeholder="{% trans "Search" %}" type="text" name="q" value="{{ request.REQUEST.q }}">
+</div>
+
+{% if search_model_choices %}
+ {% if search_model_choices|length == 1 %}
+ <input type="hidden" name="type" value="{{ search_model_choices.0.1 }}">
+ {% else %}
+ <div class="form-group">
+ <select class="form-control" name="type">
+ <option value="">{% trans "Everything" %}</option>
+ {% for verbose_name, model in search_model_choices %}
+ <option value="{{ model }}"
+ {% if model == request.REQUEST.type %}selected{% endif %}>
+ {{ verbose_name }}
+ </option>
+ {% endfor %}
+ </select>
+ </div>
+ {% endif %}
+{% endif %}
+
+<input type="submit" class="btn btn-default" value="{% trans "Go" %}">
+
+</form>
--- /dev/null
+{% load mezzanine_tags %}
+<div class="panel panel-default user-panel">
+<div class="panel-body">
+{% ifinstalled cartridge.shop %}
+{% include "shop/includes/user_panel.html" %}
+{% endifinstalled %}
+{% ifinstalled mezzanine.accounts %}
+{% ifinstalled cartridge.shop %}<br>{% endifinstalled %}
+{% include "accounts/includes/user_panel.html" %}
+{% endifinstalled %}
+</div>
+</div>
--- /dev/null
+{% extends "base.html" %}
+{% load i18n %}
+
+{% block meta_title %}{% trans "Home" %}{% endblock %}
+{% block title %}{% trans "Home" %}{% endblock %}
+
+{% block breadcrumb_menu %}
+<li class="active">{% trans "Home" %}</li>
+{% endblock %}
+
+{% block main %}
+{% blocktrans %}
+<h2>Congratulations!</h2>
+<p>
+ Welcome to your new Mezzanine powered website.
+ Here are some quick links to get you started:
+</p>
+<ul>
+ <li><a href="/admin/">Log in to the admin interface</a></li>
+ <li><a href="http://mezzanine.jupo.org/docs/content-architecture.html">Creating custom page types</a></li>
+ <li><a href="http://mezzanine.jupo.org/docs/frequently-asked-questions.html#templates">Modifying HTML templates</a></li>
+ <li><a href="http://mezzanine.jupo.org/docs/frequently-asked-questions.html#why-isn-t-the-homepage-a-page-object-i-can-edit-via-the-admin">Changing this homepage</a></li>
+ <li><a href="http://mezzanine.jupo.org/docs/frequently-asked-questions.html">Other frequently asked questions</a></li>
+ <li><a href="http://mezzanine.jupo.org/docs/configuration.html#default-settings">Full list of settings</a></li>
+ <li><a href="http://mezzanine.jupo.org/docs/deployment.html">Deploying to a production server</a></li>
+</ul>
+{% endblocktrans %}
+{% endblock %}
--- /dev/null
+{% extends "pages/page.html" %}
+
+{% load mezzanine_tags i18n %}
+
+{% block main %}
+{{ block.super }}
+{% if request.GET.sent %}
+ {% editable page.form.response %}
+ {{ page.form.response|richtext_filters|safe }}
+ {% endeditable %}
+{% else %}
+ {% with page.form as page_form %}
+ {% editable page_form.content %}
+ {{ page_form.content|richtext_filters|safe }}
+ {% endeditable %}
+ {% endwith %}
+
+ {% errors_for form %}
+
+ <form class="mezzanine-form" method="post"{% if form.is_multipart %} enctype="multipart/form-data"{% endif %}>
+ {% fields_for form %}
+ <div class="form-actions">
+ <input class="btn btn-primary btn-lg" type="submit"
+ value="{% if page.form.button_text %}{{ page.form.button_text }}{% else %}{% trans "Submit" %}{% endif %}">
+ </div>
+ </form>
+{% endif %}
+
+{% endblock %}
+
+
+{% block extra_js %}
+{{ block.super }}
+<script>
+$(function() {$('.mezzanine-form :input:visible:enabled:first').focus();});
+</script>
+{% endblock %}
--- /dev/null
+{% extends "pages/page.html" %}
+
+{% load mezzanine_tags staticfiles %}
+
+{% block extra_css %}
+<link rel="stylesheet" href="{% static "mezzanine/css/magnific-popup.css" %}">
+{% endblock extra_css %}
+
+{% block main %}
+{{ block.super }}
+
+{% editable page.gallery.content %}
+{{ page.gallery.content|richtext_filters|safe }}
+{% endeditable %}
+
+<div class="gallery row">
+{% with page.gallery.images.all as images %}
+{% for image in images %}
+<div class="col-xs-4 col-sm-3">
+ <a class="thumbnail" rel="#image-{{ image.id }}" title="{{ image.description }}" href="{{ image.file.url }}">
+ <img class="img-responsive" src="{{ MEDIA_URL }}{% thumbnail image.file 131 75 %}">
+ </a>
+</div>
+{% endfor %}
+{% endwith %}
+</div>
+{% endblock %}
+
+{% block extra_js %}
+{{ block.super }}
+<script src="{% static "mezzanine/js/magnific-popup.js" %}"></script>
+<script>
+$(document).ready(function() {
+ $('.gallery').magnificPopup({
+ delegate: 'a',
+ type: 'image',
+ gallery: {
+ enabled: true,
+ }
+ });
+});
+</script>
+{% endblock %}
--- /dev/null
+{% extends "pages/richtextpage.html" %}
+
+{% block main %}
+<!--
+This template is provided as a custom template for the homepage, for
+when it is configured as an editable page in the navigation tree. Feel
+free to modify it.
+-->
+{{ block.super }}
+{% endblock %}
--- /dev/null
+{% load pages_tags i18n staticfiles %}
+
+<ol>
+ {% for page in page_branch %}
+ <li id="ordering_{{ page.id }}">
+ <div class="{% cycle 'row1' 'row2' %}">
+ <a href="#" class="tree-toggle" id="page-{{ page.id }}"
+ {% if not page.has_children %}style="visibility:hidden;"{% endif %}>
+ <span class="icon open">+</span>
+ <span class="icon close">-</span>
+ </a>
+ {% set_page_permissions page %}
+ {% if page.perms.delete %}
+ <a href="{% url "admin:pages_page_delete" page.id %}?fromtree" class="delete"></a>
+ {% else %}
+ <span class="delete" style="background:none;"></span>
+ {% endif %}
+ {% if page.perms.change %}
+ <a href="{% url "admin:pages_page_change" page.id %}{% if not page.is_primary %}?parent={{ page.parent_id }}{% endif %}"
+ class="changelink">{{ page.title.strip|default:" " }}</a>
+ {% else %}
+ <span class="uneditable">{{ page.title }}</span>
+ {% endif %}
+ <span class="ordering"{% if not page.perms.change %}
+ style="visibility:hidden;"{% endif %}>
+ <img src="{% static settings.MEZZANINE_ADMIN_PREFIX|add:"img/admin/arrow-up.gif" %}">
+ <img src="{% static settings.MEZZANINE_ADMIN_PREFIX|add:"img/admin/arrow-down.gif" %}">
+ </span>
+ {% if page.perms.add %}
+ <select class="addlist" id="addlink-{{ page.id }}">
+ <option value="">{% trans "Add" %} ...</option>
+ {% for model in page_models %}
+ {% if model.perms.add %}
+ <option value="{{ model.add_url }}?parent={{ page.id }}"
+ >{{ model.meta_verbose_name|capfirst }}</option>
+ {% endif %}
+ {% endfor %}
+ </select>
+ {% endif %}
+
+ </div>
+ <br style="clear:both;">
+ {% if page.has_children %}{% page_menu page %}{% endif %}
+ </li>
+ {% endfor %}
+</ol>
--- /dev/null
+{% load i18n pages_tags %}
+
+{% if on_home %}
+<li>{% trans "Home" %}</li>
+{% else %}
+{% for page in page_branch %}
+
+ {% if not has_home and page.is_primary and forloop.first %}
+ <li id="breadcrumb-menu-home">
+ <a href="{% url "home" %}">{% trans "Home" %}</a>
+ </li>
+ {% endif %}
+
+ {% if page.is_current_or_ascendant %}
+ {% if page.is_current %}
+ <li id="breadcrumb-menu-{{ page.html_id }}"
+ class="active">{{ page.title }}</li>
+ {% else %}
+ <li id="breadcrumb-menu-{{ page.html_id }}">
+ <a href="{{ page.get_absolute_url }}">{{ page.title }}</a>
+ </li>
+ {% endif %}
+ {% if page.has_children %}{% page_menu page %}{% endif %}
+ {% endif %}
+
+{% endfor %}
+{% endif %}
--- /dev/null
+{% load i18n pages_tags %}
+{% spaceless %}
+{% if page_branch_in_menu %}
+
+{% if branch_level == 0 %}
+<ul class="nav navbar-nav">
+ {% for page in page_branch %}
+ {% if not has_home and page.is_primary and forloop.first %}
+ <li{% if on_home %} class="active"{% endif %} id="dropdown-menu-home">
+ <a href="{% url "home" %}">{% trans "Home" %}</a>
+ </li>
+ {% endif %}
+ {% if page.in_menu %}
+ <li class="{% if page.has_children_in_menu %}dropdown{% endif %}
+ {% if page.is_current_or_ascendant %}active{% endif %}"
+ id="{{ page.html_id }}">
+ <a href="{{ page.get_absolute_url }}"
+ {% if page.has_children_in_menu %}
+ class="dropdown-toggle disabled" data-toggle="dropdown"
+ {% endif %}>
+ {{ page.title }}
+ {% if page.has_children_in_menu %}<b class="caret"></b>{% endif %}
+ </a>
+ {% if page.has_children_in_menu %}{% page_menu page %}{% endif %}
+ </li>
+ {% endif %}
+ {% endfor %}
+</ul>
+
+{% else %}
+<ul class="dropdown-menu">
+ {% for page in page_branch %}
+ {% if page.in_menu %}
+ <li class="{% if page.has_children_in_menu %}dropdown-submenu{% endif %}
+ {% if page.is_current_or_ascendant %}active{% endif %}"
+ id="{{ page.html_id }}">
+ <a href="{{ page.get_absolute_url }}">{{ page.title }}</a>
+ {% if page.has_children_in_menu %}{% page_menu page %}{% endif %}
+ </li>
+ {% endif %}
+ {% endfor %}
+</ul>
+{% endif %}
+
+{% endif %}
+{% endspaceless %}
--- /dev/null
+{% load i18n pages_tags %}
+
+{% spaceless %}
+{% if page_branch_in_menu %}
+
+{% for page in page_branch %}
+ {% if page.is_primary %}
+ {% if forloop.first %}
+ <div class="nav-footer">
+ {% endif %}
+ {% if page.in_menu %}
+ <ul class="list-unstyled">
+ {% endif %}
+ {% endif %}
+
+ {% if page.in_menu %}
+ {% if forloop.first and not page.parent.in_menu and not page.is_primary %}
+ <ul class="list-unstyled">
+ {% endif %}
+ <li {% if page.is_current_or_ascendant %}class="active"{% endif %}
+ id="footer-menu-{{ page.html_id }}">
+ <a href="{{ page.get_absolute_url }}">{{ page.title }}</a></li>
+ {% endif %}
+
+ {% if page.in_menu and page.has_children_in_menu %}{% page_menu page %}{% endif %}
+
+ {% if page.in_menu %}
+ {% if forloop.first and not page.parent.in_menu and not page.is_primary %}
+ </li></ul>
+ {% endif %}
+ {% endif %}
+
+ {% if page.is_primary %}
+ {% if page.in_menu %}
+ </ul>
+ {% endif %}
+ {% if forloop.last %}
+ </div>
+ {% endif %}
+ {% endif %}
+
+{% endfor %}
+
+{% endif %}
+{% endspaceless %}
--- /dev/null
+{% load i18n pages_tags %}
+
+{% spaceless %}
+{% if page_branch_in_menu %}
+<ul class="footer-tree-menu-level-{{ branch_level }}">
+ {% for page in page_branch %}
+
+ {% if not has_home and page.is_primary and forloop.first %}
+ <li class="first{% if on_home %} active{% endif %}"
+ id="footer-tree-menu-home">
+ <a href="{% url "home" %}">{% trans "Home" %}</a>
+ </li>
+ {% endif %}
+
+ {% if page.in_menu %}
+ <li class="{% if page.is_current_or_ascendant %}active{% endif %}
+ {% if not top_level and forloop.first %} first{% endif %}
+ {% if forloop.last %} last{% endif %}"
+ id="footer-tree-menu-{{ page.html_id }}">
+ <a href="{{ page.get_absolute_url }}">{{ page.title }}</a>
+ {# remove this if tag to always show all nav items #}
+ {% if page.is_current_or_ascendant and page.has_children_in_menu %}
+ {% page_menu page %}
+ {% endif %}
+ </li>
+ {% endif %}
+
+ {% endfor %}
+</ul>
+{% endif %}
+{% endspaceless %}
--- /dev/null
+{% load i18n pages_tags %}
+
+{% spaceless %}
+{% if page_branch %}
+{% for page in page_branch %}
+
+ {% if not has_home and page.is_primary and forloop.first %}
+ <ul class="mobile-menu">
+ <li><a class="home" href="{% url "home" %}"
+ id="tree-menu-home">{% trans "Home" %}</a></li>
+ {% endif %}
+
+ {% if page.is_current_or_ascendant and not page.is_current_child %}
+ {% if page.has_children_in_menu %}{% page_menu page %}{% endif %}
+ {% endif %}
+
+ {% if page.is_current_child %}
+ <li class="
+ {% if forloop.first %} first{% endif %}
+ {% if forloop.last %} last{% endif %}"
+ id="mobile-menu-{{ page.html_id }}">
+ <a href="{{ page.get_absolute_url }}">{{ page.title }}</a>
+ </li>
+ {% endif %}
+
+ {% if page.is_primary and forloop.last %}
+ </ul>
+ {% endif %}
+
+{% endfor %}
+{% endif %}
+{% endspaceless %}
--- /dev/null
+{% load pages_tags i18n %}
+
+{% spaceless %}
+<ul id="primary-menu" class="nav pull-right">
+ {% for page in page_branch %}
+ {% if not has_home and page.is_primary and forloop.first %}
+ <li id="primary-menu-home" class="first{% if on_home %} active{% endif %}">
+ <a href="{% url "home" %}">{% trans "Home" %}</a>
+ </li>
+ {% endif %}
+ {% if page.in_menu %}
+ <li id="primary-menu-{{ page.html_id }}"
+ class="{% if page.is_current_or_ascendant %}active{% endif %}{% if forloop.last %} last{% endif %}">
+ <a href="{{ page.get_absolute_url }}">{{ page.title }}</a>
+ </li>
+ {% endif %}
+ {% endfor %}
+ <li class="divider-vertical"></li>
+</ul>
+{% endspaceless %}
--- /dev/null
+{% load i18n pages_tags %}
+
+{% spaceless %}
+{% if page_branch_in_menu %}
+<ul class="nav nav-list navlist-menu-level-{{ branch_level }}">
+ {% for page in page_branch %}
+ {% if not has_home and page.is_primary and forloop.first %}
+ <li{% if on_home %} class="active"{% endif %} id="tree-menu-home">
+ <a href="{% url "home" %}">{% trans "Home" %}</a>
+ </li>
+ {% endif %}
+ {% if page.in_menu %}
+ <li class="
+ {% if page.is_current %} active{% endif %}
+ {% if page.is_current_or_ascendant %} active-branch{% endif %}
+ " id="tree-menu-{{ page.html_id }}">
+ <a href="{{ page.get_absolute_url }}">{{ page.title }}</a>
+ {# wrap the next line with 'if page.is_current_or_ascendant' #}
+ {# to only show child pages in the menu for the current page #}
+ {% if page.has_children_in_menu %}{% page_menu page %}{% endif %}
+ </li>
+ {% endif %}
+ {% endfor %}
+</ul>
+{% endif %}
+{% endspaceless %}
--- /dev/null
+{% extends "base.html" %}
+{% load mezzanine_tags keyword_tags %}
+
+{% block meta_title %}{{ page.meta_title }}{% endblock %}
+
+{% block meta_keywords %}{% metablock %}
+{% keywords_for page as keywords %}
+{% for keyword in keywords %}
+ {% if not forloop.first %}, {% endif %}
+ {{ keyword }}
+{% endfor %}
+{% endmetablock %}{% endblock %}
+
+{% block meta_description %}{% metablock %}
+{{ page.description }}
+{% endmetablock %}{% endblock %}
+
+{% block title %}
+{% editable page.title %}{{ page.title }}{% endeditable %}
+{% endblock %}
+
+{% block main %}
+{% endblock %}
--- /dev/null
+{% extends "pages/page.html" %}
+
+{% load mezzanine_tags %}
+
+{% block main %}{{ block.super }}
+
+{% editable page.richtextpage.content %}
+{{ page.richtextpage.content|richtext_filters|safe }}
+{% endeditable %}
+
+{% endblock %}
--- /dev/null
+{% extends "base.html" %}
+
+{% load i18n mezzanine_tags %}
+
+{% block meta_title %}{% trans "Search Results" %}{% endblock %}
+{% block title %}{% trans "Search Results" %}{% endblock %}
+{% block extra_head %}
+<meta name="robots" content="noindex">
+{% endblock %}
+
+{% block breadcrumb_menu %}
+<li>
+ <a href="{% url "home" %}">{% trans "Home" %}</a>
+</li>
+<li class="active">{% trans "Search Results" %}</li>
+{% endblock %}
+
+{% block main %}
+
+<p>
+{% if results.paginator.count == 0 %}
+{% blocktrans %}
+No results were found in {{ search_type }} matching your query: {{ query }}
+{% endblocktrans %}
+{% else %}
+{% blocktrans with start=results.start_index end=results.end_index total=results.paginator.count %}
+Showing {{ start }} to {{ end }} of {{ total }} results in {{ search_type }} matching your query: {{ query }}
+{% endblocktrans %}
+{% endif %}
+</p>
+
+<div id="search-results">
+{% for result in results.object_list %}
+{% with result.get_absolute_url as result_url %}
+ <h5>
+ {{ forloop.counter0|add:results.start_index }})
+ {% if result_url %}
+ <a href="{{ result_url }}">{{ result }}</a>
+ {% else %}
+ {{ result }}
+ {% endif %}
+ </h5>
+ {% if result.description != result|stringformat:"s" %}
+ <p>{{ result.description|truncatewords_html:20|safe }}</p>
+ {% endif %}
+ {% if result_url %}
+ <a href="{{ result_url }}">{% trans "read more" %}</a>
+ {% endif %}
+{% endwith %}
+{% endfor %}
+</div>
+
+{% pagination_for results %}
+
+{% endblock %}
--- /dev/null
+
+{% load twitter_tags i18n %}
+
+{% tweets_default as tweets %}
+
+{% if tweets %}
+<h3>{% trans "Recent Tweets" %}</h3>
+<ul class="list-unstyled tweets">
+ {% for tweet in tweets %}
+ <li class="tweet">
+ <img class="pull-left tweeter-image" src="{{ tweet.profile_image_url|cut:"http:" }}" alt="{{ tweet.full_name }}">
+ <h4>{{ tweet.full_name }} <small><a href="http://twitter.com/{{ tweet.user_name }}" title="{{ tweet.full_name }}">@{{ tweet.user_name }}</a></small></h4>
+ {% if tweet.is_retweet %}
+ <h6><span class="glyphicon glyphicon-retweet"></span>
+ <a href="http://twitter.com/{{ tweet.retweeter_user_name }}" title="{{ tweet.retweeter_full_name }}">{{ tweet.retweeter_full_name }}</a></h6>
+ {% endif %}
+ <p>{{ tweet.text|safe }}<br>
+ <small class="timespan">
+ {% blocktrans with sometime=tweet.created_at|timesince %}{{ sometime }} ago{% endblocktrans %}
+ <a href="http://twitter.com/{{ tweet.user_name }}/status/{{ tweet.remote_id }}"><span class="glyphicon glyphicon-new-window"></span></a>
+ </small></p>
+ </li>
+ {% endfor %}
+</ul>
+{% endif %}