Stylesheets werden nur mit Less erzeugt. Damit können sie gleich

optimiert werden.
jQuery wurde entfernt.
Übersetzungen wurden korrigiert.
Neue sync.sh Datei, welche änderungen mit rsync auf den Server spielt
und das neuladen erzwingt.
This commit is contained in:
Christian Berg
2014-12-14 23:57:40 +01:00
parent 711c303f9a
commit 9c2413a794
76 changed files with 2514 additions and 1884 deletions

View File

@@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: kasu.content\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2014-12-09 20:35+0100\n"
"POT-Creation-Date: 2014-12-14 01:12+0100\n"
"PO-Revision-Date: 2014-12-08 16:15+0100\n"
"Last-Translator: Christian Berg <xeniac.at@gmail.com>\n"
"Language-Team: Kasu <verein@kasu.at>\n"
@@ -135,12 +135,21 @@ msgstr "Kategorien"
msgid "This Category does not exist."
msgstr "Diese Kategorie existiert nicht."
#: views.py:152
#: views.py:93 templates/content/article_detail.html:52
#: templates/content/article_form.html:17
msgid "Edit Article"
msgstr "Artikel bearbeiten"
#: views.py:95 templates/content/article_form.html:17
msgid "Create Article"
msgstr "Artikel erstellen"
#: views.py:160
#, python-format
msgid "No Page found matching the Path %s"
msgstr "Keine Seite unter dem Pfad %s gefunden"
#: views.py:166
#: views.py:174
#, python-format
msgid "No PDF Document found matching the Path %s"
msgstr "Kein PDF Dokument unter dem Pfad %s gefunden."
@@ -205,39 +214,24 @@ msgstr "Auf Twitter teilen"
msgid "Share on Facebook"
msgstr "Auf Facebook teilen"
#: templates/content/article_detail.html:52
#: templates/content/article_form.html:5
#: templates/content/article_form.html:21
msgid "Edit Article"
msgstr "Artikel bearbeiten"
#: templates/content/article_form.html:5
#: templates/content/article_form.html:21
msgid "Create Article"
msgstr "Artikel erstellen"
#: templates/content/article_form.html:26 templates/content/page_form.html:29
#: templates/content/article_form.html:22 templates/content/page_form.html:29
#: templates/content/page_form.html:35
msgid "German"
msgstr "Deutsch"
#: templates/content/article_form.html:27 templates/content/page_form.html:30
#: templates/content/article_form.html:23 templates/content/page_form.html:30
#: templates/content/page_form.html:39
msgid "English"
msgstr "Englisch"
#: templates/content/article_form.html:40 templates/content/page_form.html:50
#: templates/content/article_form.html:36 templates/content/page_form.html:50
msgid "reset"
msgstr "Zurücksetzen"
#: templates/content/article_form.html:41 templates/content/page_form.html:51
#: templates/content/article_form.html:37 templates/content/page_form.html:51
msgid "save"
msgstr "Speichern"
#: templates/content/page.html:23
msgid "Subpages"
msgstr "Unterseiten"
#: templates/content/page_form.html:4 templates/content/page_form.html:24
msgid "Edit Page"
msgstr "Seite bearbeiten"
@@ -249,3 +243,6 @@ msgstr "Seite hinzufügen"
#: templates/content/page_form.html:45
msgid "HTML Specific"
msgstr "HTML spezifisch"
#~ msgid "Subpages"
#~ msgstr "Unterseiten"

View File

@@ -1,10 +1,6 @@
{% extends "base.html" %}
{% load i18n fieldset_extras %}
{% block title %}
{% if object.pk %}{% trans "Edit Article" %}{% else %}{% trans "Create Article" %}{% endif %}
{% endblock %}
{% block extra_head %}
<script type="text/javascript" src="{{ STATIC_URL }}js/jquery-1.6.2.min.js"></script>
<script type="text/javascript" src="{{ STATIC_URL }}js/language_tabs.js" ></script>

View File

@@ -14,18 +14,20 @@
{% endblock %}
{% block content %}
<h2>{{ page.title }}</h2>
{{ page.content }}
{{ page.content }}
{% endblock %}
{% block sidebar %}
{% if current_top_page.subpages %}
<h2>{% trans "Subpages" %}</h2>
{% for subpage in current_top_page.subpages.all %}
<h3><a href="{{ subpage.get_absolute_url }}">{{subpage.menu_name}}</a></h3>
<ul class="list">
{% for subpage in subpage.subpages.all %}<li class="{{subpage.css_class}}"><a href="{{ subpage.get_absolute_url }}">{{ subpage.menu_name }}</a></li>{% endfor %}
</ul>
{% if subpage.content_type > 0 %}
<h2><a href="{{ subpage.get_absolute_url }}">{{subpage.menu_name}}</a></h2>
<ul class="list">
{% for subpage in subpage.subpages.all %}
<li class="{{subpage.css_class}}"><a href="{{ subpage.get_absolute_url }}">{{ subpage.menu_name }}</a></li>
{% endfor %}
</ul>
{% endif %}
{% endfor %}
{% endif %}
{% endblock %}

View File

@@ -87,6 +87,14 @@ class ArticleForm(PermissionRequiredMixin, generic.UpdateView):
form_class = forms.ArticleForm
permission_required = 'content.change_article'
def get_context_data(self, **kwargs):
context = super(ArticleForm, self).get_context_data(**kwargs)
if self.kwargs.get('pk'):
context['title'] = _("Edit Article")
else:
context['title'] = _("Create Article")
return context
def get_object(self, **kwargs):
if self.kwargs.get('pk', None):
return models.Article.objects.get(pk=self.kwargs['pk'])