Added strings fro wagtailsnippets

pull/76/head
Serafeim Papastefanos 2014-02-19 21:03:08 +02:00
rodzic 8cea752893
commit a93c8e8187
13 zmienionych plików z 204 dodań i 58 usunięć

Wyświetl plik

@ -1,6 +1,12 @@
[main]
host = https://www.transifex.com
[wagtail.wagtailsnippets]
file_filter = wagtail/wagtailsnippets/locale/<lang>/LC_MESSAGES/django.po
source_file = wagtail/wagtailsnippets/locale/en/LC_MESSAGES/django.po
source_lang = en
type = PO
[wagtail.wagtailusers]
file_filter = wagtail/wagtailusers/locale/<lang>/LC_MESSAGES/django.po
source_file = wagtail/wagtailusers/locale/en/LC_MESSAGES/django.po

Wyświetl plik

@ -0,0 +1,123 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the PACKAGE package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2014-02-19 20:59+0200\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
#: .\templates\wagtailsnippets\chooser\choose.html:2
msgid "Choose"
msgstr ""
#: .\templates\wagtailsnippets\edit_handlers\snippet_chooser_panel.html:10
#, python-format
msgid "Choose another %(snippet_type_name)s"
msgstr ""
#: .\templates\wagtailsnippets\edit_handlers\snippet_chooser_panel.html:11
#, python-format
msgid "Choose %(snippet_type_name)s"
msgstr ""
#: .\templates\wagtailsnippets\snippets\confirm_delete.html:3
#, python-format
msgid "Delete %(snippet_type_name)s - %(instance)s"
msgstr ""
#: .\templates\wagtailsnippets\snippets\confirm_delete.html:6
#: .\templates\wagtailsnippets\snippets\edit.html:20
msgid "Delete"
msgstr ""
#: .\templates\wagtailsnippets\snippets\confirm_delete.html:10
#, python-format
msgid "Are you sure you want to delete this %(snippet_type_name)s?"
msgstr ""
#: .\templates\wagtailsnippets\snippets\confirm_delete.html:13
msgid "Yes, delete"
msgstr ""
#: .\templates\wagtailsnippets\snippets\create.html:3
#, python-format
msgid "New %(snippet_type_name)s"
msgstr ""
#: .\templates\wagtailsnippets\snippets\create.html:6
msgid "New"
msgstr ""
#: .\templates\wagtailsnippets\snippets\create.html:17
#: .\templates\wagtailsnippets\snippets\edit.html:17
msgid "Save"
msgstr ""
#: .\templates\wagtailsnippets\snippets\edit.html:3
#, python-format
msgid "Editing %(snippet_type_name)s - %(instance)s"
msgstr ""
#: .\templates\wagtailsnippets\snippets\edit.html:6
msgid "Editing"
msgstr ""
#: .\templates\wagtailsnippets\snippets\index.html:3
msgid "Snippets"
msgstr ""
#: .\templates\wagtailsnippets\snippets\list.html:8
msgid "Title"
msgstr ""
#: .\templates\wagtailsnippets\snippets\type_index.html:3
#, python-format
msgid "Snippets %(snippet_type_name_plural|capfirst)s"
msgstr ""
#: .\templates\wagtailsnippets\snippets\type_index.html:10
#, python-format
msgid "Snippets <span>%(snippet_type_name_plural|capfirst)s</span>"
msgstr ""
#: .\templates\wagtailsnippets\snippets\type_index.html:13
#, python-format
msgid "Add %(snippet_type_name)s"
msgstr ""
#: .\templates\wagtailsnippets\snippets\type_index.html:23
#, python-format
msgid ""
"No %(snippet_type_name_plural)s have been created. Why not <a href=\"%"
"(wagtailsnippets_create_url)s\">add one</a>?"
msgstr ""
#: .\views\snippets.py:127
msgid "{snippet_type} '{instance}' created."
msgstr ""
#: .\views\snippets.py:134
msgid "The snippet could not be created due to errors."
msgstr ""
#: .\views\snippets.py:168
msgid "{snippet_type} '{instance}' updated."
msgstr ""
#: .\views\snippets.py:175
msgid "The snippet could not be saved due to errors."
msgstr ""
#: .\views\snippets.py:204
msgid "{snippet_type} '{instance}' deleted."
msgstr ""

Wyświetl plik

@ -1,4 +1,6 @@
{% include "wagtailadmin/shared/header.html" with title="Choose" subtitle=snippet_type_name %}
{% load i18n %}
{% trans "Choose" as choose_str %}
{% include "wagtailadmin/shared/header.html" with title=choose_str subtitle=snippet_type_name %}
<div class="nice-padding">
{% include "wagtailsnippets/snippets/list.html" with choosing=1 %}

Wyświetl plik

@ -1,4 +1,5 @@
{% extends "wagtailadmin/edit_handlers/chooser_panel.html" %}
{% load i18n %}
{% block chooser_class %}snippet-chooser{% endblock %}
@ -6,5 +7,5 @@
<span class="title">{% if is_chosen %}{{ item }}{% endif %}</span>
{% endblock %}
{% block choose_another_button_label %}Choose another {{ snippet_type_name }}{% endblock %}
{% block choose_button_label %}Choose {{ snippet_type_name }}{% endblock %}
{% block choose_another_button_label %}{% blocktrans %}Choose another {{ snippet_type_name }}{% endblocktrans %}{% endblock %}
{% block choose_button_label %}{% blocktrans %}Choose {{ snippet_type_name }}{% endblocktrans %}{% endblock %}

Wyświetl plik

@ -1,15 +1,16 @@
{% extends "wagtailadmin/base.html" %}
{% block titletag %}Delete {{ snippet_type_name}} - {{ instance }}{% endblock %}
{% load i18n %}
{% block titletag %}{% blocktrans %}Delete {{ snippet_type_name}} - {{ instance }}{% endblocktrans %}{% endblock %}
{% block bodyclass %}menu-snippets{% endblock %}
{% block content %}
{% include "wagtailadmin/shared/header.html" with title="Delete" subtitle=instance %}
{% trans "Delete" as delete_str %}
{% include "wagtailadmin/shared/header.html" with title=delete_str subtitle=instance %}
<div class="nice-padding">
<p>Are you sure you want to delete this {{ snippet_type_name }}?</p>
<p>{% blocktrans %}Are you sure you want to delete this {{ snippet_type_name }}?{% endblocktrans %}</p>
<form action="{% url 'wagtailsnippets_delete' content_type.app_label content_type.model instance.id %}" method="POST">
{% csrf_token %}
<input type="submit" value="Yes, delete" class="serious" />
<input type="submit" value="{% trans 'Yes, delete' %}" class="serious" />
</form>
</div>

Wyświetl plik

@ -1,9 +1,10 @@
{% extends "wagtailadmin/base.html" %}
{% block titletag %}New {{ snippet_type_name}}{% endblock %}
{% load i18n %}
{% block titletag %}{% blocktrans %}New {{ snippet_type_name}}{% endblocktrans %}{% endblock %}
{% block bodyclass %}menu-snippets{% endblock %}
{% block content %}
{% include "wagtailadmin/shared/header.html" with title="New" subtitle=snippet_type_name %}
{% trans "New" as new_str %}
{% include "wagtailadmin/shared/header.html" with title=new_str subtitle=snippet_type_name %}
<form action="{% url 'wagtailsnippets_create' content_type.app_label content_type.model %}" method="POST">
{% csrf_token %}
@ -13,7 +14,7 @@
<ul>
<li class="actions">
<div class="dropdown dropup match-width">
<div><input type="submit" value="Save" /></div>
<div><input type="submit" value="{% trans 'Save' %}" /></div>
</div>
</li>
</ul>

Wyświetl plik

@ -1,9 +1,10 @@
{% extends "wagtailadmin/base.html" %}
{% block titletag %}Editing {{ snippet_type_name}} - {{ instance }}{% endblock %}
{% load i18n %}
{% block titletag %}{% blocktrans %}Editing {{ snippet_type_name}} - {{ instance }}{% endblocktrans %}{% endblock %}
{% block bodyclass %}menu-snippets{% endblock %}
{% block content %}
{% include "wagtailadmin/shared/header.html" with title="Editing" subtitle=instance %}
{% trans "Editing" as editing_str %}
{% include "wagtailadmin/shared/header.html" with title=editing_str subtitle=instance %}
<form action="{% url 'wagtailsnippets_edit' content_type.app_label content_type.model instance.id %}" method="POST">
{% csrf_token %}
@ -13,10 +14,10 @@
<ul>
<li class="actions">
<div class="dropdown dropup match-width">
<input type="submit" value="Save" class="button" />
<input type="submit" value="{% trans 'Save' %}" class="button" />
<div class="dropdown-toggle icon icon-arrow-up"></div>
<ul role="menu">
<li><a href="{% url 'wagtailsnippets_delete' content_type.app_label content_type.model instance.id %}" class="shortcut">Delete</a></li>
<li><a href="{% url 'wagtailsnippets_delete' content_type.app_label content_type.model instance.id %}" class="shortcut">{% trans "Delete" %}</a></li>
</ul>
</div>
</li>

Wyświetl plik

@ -1,6 +1,6 @@
{% extends "wagtailadmin/base.html" %}
{% block titletag %}Snippets{% endblock %}
{% load i18n %}
{% block titletag %}{% trans "Snippets" %}{% endblock %}
{% block bodyclass %}menu-snippets{% endblock %}
{% block content %}

Wyświetl plik

@ -1,10 +1,11 @@
{% load i18n %}
<table class="listing">
<col />
<col />
<col width="16%" />
<thead>
<tr class="table-headers">
<th>Title</th>
<th>{% trans "Title" %}</th>
</tr>
</thead>
<tbody>

Wyświetl plik

@ -1,15 +1,16 @@
{% extends "wagtailadmin/base.html" %}
{% block titletag %}Snippets {{ snippet_type_name_plural|capfirst }}{% endblock %}
{% load i18n %}
{% block titletag %}{% blocktrans %}Snippets {{ snippet_type_name_plural|capfirst }}{% endblocktrans %}{% endblock %}
{% block bodyclass %}menu-snippets{% endblock %}
{% block content %}
<header class="nice-padding">
<div class="row row-flush">
<div class="left col9">
<h1>Snippets <span>{{ snippet_type_name_plural|capfirst }}</span></h1>
<h1>{% blocktrans %}Snippets <span>{{ snippet_type_name_plural|capfirst }}</span>{% endblocktrans %}</h1>
</div>
<div class="right col3">
<a href="{% url 'wagtailsnippets_create' content_type.app_label content_type.model %}" class="button bicolor icon icon-plus">Add {{ snippet_type_name }}</a>
<a href="{% url 'wagtailsnippets_create' content_type.app_label content_type.model %}" class="button bicolor icon icon-plus">{% blocktrans %}Add {{ snippet_type_name }}{% endblocktrans %}</a>
{# TODO: figure out a way of saying "Add a/an [foo]" #}
</div>
</div>
@ -18,7 +19,8 @@
{% if items %}
{% include "wagtailsnippets/snippets/list.html" %}
{% else %}
<p class="no-results-message">No {{ snippet_type_name_plural }} have been created. Why not <a href="{% url 'wagtailsnippets_create' content_type.app_label content_type.model %}">add one</a>?</p>
{% url 'wagtailsnippets_create' content_type.app_label content_type.model as wagtailsnippets_create_url %}
<p class="no-results-message">{% blocktrans %}No {{ snippet_type_name_plural }} have been created. Why not <a href="{{ wagtailsnippets_create_url }}">add one</a>?{% endblocktrans %}</p>
{% endif %}
</div>
{% endblock %}

Wyświetl plik

@ -6,6 +6,7 @@ from django.contrib.contenttypes.models import ContentType
from django.contrib import messages
from django.contrib.auth.decorators import login_required
from django.core.exceptions import PermissionDenied
from django.utils.translation import ugettext as _
from wagtail.wagtailadmin.edit_handlers import ObjectList, extract_panel_definitions_from_model_class
@ -123,11 +124,14 @@ def create(request, content_type_app_name, content_type_model_name):
messages.success(
request,
"%s '%s' created." % (capfirst(get_snippet_type_name(content_type)[0]), instance)
_("{snippet_type} '{instance}' created.").format(
snippet_type=capfirst(get_snippet_type_name(content_type)[0]),
instance=instance
)
)
return redirect('wagtailsnippets_list', content_type.app_label, content_type.model)
else:
messages.error(request, "The snippet could not be created due to errors.")
messages.error(request, _("The snippet could not be created due to errors."))
edit_handler = edit_handler_class(instance=instance, form=form)
else:
form = form_class(instance=instance)
@ -161,11 +165,14 @@ def edit(request, content_type_app_name, content_type_model_name, id):
messages.success(
request,
"%s '%s' updated." % (capfirst(snippet_type_name), instance)
_("{snippet_type} '{instance}' updated.").format(
snippet_type=capfirst(snippet_type_name),
instance=instance
)
)
return redirect('wagtailsnippets_list', content_type.app_label, content_type.model)
else:
messages.error(request, "The snippet could not be saved due to errors.")
messages.error(request, _("The snippet could not be saved due to errors."))
edit_handler = edit_handler_class(instance=instance, form=form)
else:
form = form_class(instance=instance)
@ -194,7 +201,10 @@ def delete(request, content_type_app_name, content_type_model_name, id):
instance.delete()
messages.success(
request,
"%s '%s' deleted." % (capfirst(snippet_type_name), instance)
_("{snippet_type} '{instance}' deleted.").format(
snippet_type=capfirst(snippet_type_name),
instance=instance
)
)
return redirect('wagtailsnippets_list', content_type.app_label, content_type.model)

Wyświetl plik

@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2014-02-19 14:35+0200\n"
"POT-Creation-Date: 2014-02-19 20:59+0200\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
@ -44,7 +44,7 @@ msgstr ""
msgid "The two password fields didn't match."
msgstr ""
#: .\forms.py:50 .\templates\wagtailusers\list.html.py:15
#: .\forms.py:50 .\templates\wagtailusers\list.html:15
msgid "Username"
msgstr ""
@ -76,70 +76,70 @@ msgstr ""
msgid "Administrators have the ability to manage user accounts."
msgstr ""
#: .\templates\wagtailusers\create.html.py:8
#: .\templates\wagtailusers\create.html.py:35
#: .\templates\wagtailusers\create.html:4
#: .\templates\wagtailusers\create.html:8
#: .\templates\wagtailusers\create.html:35
msgid "Add user"
msgstr ""
#: .\templates\wagtailusers\create.html.py:12
#: .\templates\wagtailusers\edit.html.py:12
#: .\templates\wagtailusers\create.html:12
#: .\templates\wagtailusers\edit.html:12
msgid "Account"
msgstr ""
#: .\templates\wagtailusers\create.html.py:13
#: .\templates\wagtailusers\create.html.py:28
#: .\templates\wagtailusers\edit.html.py:13
#: .\templates\wagtailusers\create.html:13
#: .\templates\wagtailusers\create.html:28
#: .\templates\wagtailusers\edit.html:13
msgid "Roles"
msgstr ""
#: .\templates\wagtailusers\edit.html.py:4
#: .\templates\wagtailusers\edit.html.py:8
#: .\templates\wagtailusers\edit.html:4 .\templates\wagtailusers\edit.html:8
msgid "Editing"
msgstr ""
#: .\templates\wagtailusers\edit.html.py:37
#: .\templates\wagtailusers\edit.html:30 .\templates\wagtailusers\edit.html:37
msgid "Save"
msgstr ""
#: .\templates\wagtailusers\index.html.py:4
#: .\templates\wagtailusers\index.html.py:17
#: .\templates\wagtailusers\index.html:4
#: .\templates\wagtailusers\index.html:17
msgid "Users"
msgstr ""
#: .\templates\wagtailusers\index.html.py:18
#: .\templates\wagtailusers\index.html:18
msgid "Add a user"
msgstr ""
#: .\templates\wagtailusers\list.html.py:7
#: .\templates\wagtailusers\list.html:7
msgid "Name"
msgstr ""
#: .\templates\wagtailusers\list.html.py:22
#: .\templates\wagtailusers\list.html:22
msgid "Level"
msgstr ""
#: .\templates\wagtailusers\list.html.py:23
#: .\templates\wagtailusers\list.html:23
msgid "Status"
msgstr ""
#: .\templates\wagtailusers\list.html.py:36
#: .\templates\wagtailusers\list.html:36
msgid "Admin"
msgstr ""
#: .\templates\wagtailusers\list.html.py:37
#: .\templates\wagtailusers\list.html:37
msgid "Active"
msgstr ""
#: .\templates\wagtailusers\list.html.py:37
#: .\templates\wagtailusers\list.html:37
msgid "Inactive"
msgstr ""
#: .\templates\wagtailusers\results.html.py:12
#: .\templates\wagtailusers\results.html:12
#, python-format
msgid "Sorry, no users match \"<em>%(search_query)s</em>\""
msgstr ""
#: .\templates\wagtailusers\results.html.py:15
#: .\templates\wagtailusers\results.html:15
#, python-format
msgid ""
"There are no users configured. Why not <a href=\"%(wagtailusers_create_url)s"
@ -147,8 +147,7 @@ msgid ""
msgstr ""
#: .\views\users.py:75
#, python-format
msgid "User '%s' created."
msgid "User '{0}' created."
msgstr ""
#: .\views\users.py:78
@ -156,8 +155,7 @@ msgid "The user could not be created due to errors."
msgstr ""
#: .\views\users.py:94
#, python-format
msgid "User '%s' updated."
msgid "User '{0}' updated."
msgstr ""
#: .\views\users.py:97

Wyświetl plik

@ -72,7 +72,7 @@ def create(request):
form = UserCreationForm(request.POST)
if form.is_valid():
user = form.save()
messages.success(request, _("User '%s' created.").format(user))
messages.success(request, _("User '{0}' created.").format(user))
return redirect('wagtailusers_index')
else:
messages.error(request, _("The user could not be created due to errors.") )
@ -91,7 +91,7 @@ def edit(request, user_id):
form = UserEditForm(request.POST, instance=user)
if form.is_valid():
user = form.save()
messages.success(request, _("User '%s' updated.").format(user))
messages.success(request, _("User '{0}' updated.").format(user))
return redirect('wagtailusers_index')
else:
messages.error(request, _("The user could not be saved due to errors."))