Skip to content

Commit

Permalink
Merge branch 'develop' of git://github.com/divio/django-cms into develop
Browse files Browse the repository at this point in the history
  • Loading branch information
kezabelle committed Aug 25, 2011
2 parents ff78478 + 8cd05ad commit ccd790c
Show file tree
Hide file tree
Showing 35 changed files with 228 additions and 112 deletions.
1 change: 1 addition & 0 deletions AUTHORS
Expand Up @@ -82,6 +82,7 @@ Contributors (in alphabetical order):
* Jorge Vargas (elpargo)
* kar1m
* Keryn Knight
* Kim Blomqvist
* kochin
* Krzysztof Bandurski
* kunitoki
Expand Down
7 changes: 6 additions & 1 deletion cms/api.py
Expand Up @@ -11,6 +11,7 @@
from django.conf import settings
from django.contrib.auth.models import User
from django.contrib.sites.models import Site
from django.db.models import Max
from django.template.defaultfilters import slugify
from menus.menu_pool import menu_pool

Expand Down Expand Up @@ -266,10 +267,14 @@ def add_plugin(placeholder, plugin_type, language, position='last-child',
# validate and normalize plugin type
plugin_model, plugin_type = _verify_plugin_type(plugin_type)


max_pos = CMSPlugin.objects.filter(language=language,
placeholder=placeholder).aggregate(Max('position'))['position__max'] or 0

plugin_base = CMSPlugin(
plugin_type=plugin_type,
placeholder=placeholder,
position=1,
position=max_pos + 1,
language=language
)
plugin_base.insert_at(target, position=position, save=False)
Expand Down
Binary file modified cms/locale/bn/LC_MESSAGES/django.mo
Binary file not shown.
34 changes: 24 additions & 10 deletions cms/locale/bn/LC_MESSAGES/django.po
@@ -1,19 +1,19 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the PACKAGE package.
#
#
msgid ""
msgstr ""
"Project-Id-Version: django-cms\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2011-08-14 09:48-0500\n"
"PO-Revision-Date: 2011-08-14 14:43+0000\n"
"Report-Msgid-Bugs-To: https://github.com/divio/django-cms/issues\n"
"POT-Creation-Date: 2011-08-14 09:47-0500\n"
"PO-Revision-Date: 2011-08-25 19:27+0000\n"
"Last-Translator: Benjamin Wohlwend <piquadrat@gmail.com>\n"
"Language-Team: divio.ch <developers@divio.ch>\n"
"Language: bn\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: bn\n"
"Plural-Forms: nplurals=2; plural=(n != 1)\n"
"X-Poedit-Country: SWITZERLAND\n"
"X-Poedit-Language: English\n"
Expand Down Expand Up @@ -125,7 +125,8 @@ msgid "Page Title"
msgstr ""

#: admin/forms.py:138
msgid "Overwrites what is displayed at the top of your browser or in bookmarks"
msgid ""
"Overwrites what is displayed at the top of your browser or in bookmarks"
msgstr ""

#: admin/forms.py:139
Expand Down Expand Up @@ -1247,8 +1248,8 @@ msgstr ""

#: plugins/video/models.py:10
msgid ""
"vimeo or youtube video url. Example: http://www.youtube.com/watch?v=-"
"iJ7bs4mTUY"
"vimeo or youtube video url. Example: "
"http://www.youtube.com/watch?v=-iJ7bs4mTUY"
msgstr ""

#: plugins/video/models.py:11
Expand Down Expand Up @@ -1794,8 +1795,7 @@ msgstr ""
#: templatetags/cms_tags.py:79
#, python-format
msgid ""
"A template tag couldn't find the page with lookup arguments `"
"%(page_lookup)s\n"
"A template tag couldn't find the page with lookup arguments `%(page_lookup)s\n"
"`. The URL of the request was: http://%(host)s%(path)s"
msgstr ""

Expand All @@ -1819,3 +1819,17 @@ msgstr ""
#, python-format
msgid "CMS - Page %s requires approvement."
msgstr ""

#~ msgid "move"
#~ msgstr "move request"

#~ msgid "sidebar column"
#~ msgstr "background color"

#~ msgid "fgcolor"
#~ msgstr "foreground color"

#~ msgid "Wanted language has not been translated yet."
#~ msgstr "Requested language has not been translated yet."


Binary file modified cms/locale/bn/LC_MESSAGES/djangojs.mo
Binary file not shown.
12 changes: 7 additions & 5 deletions cms/locale/bn/LC_MESSAGES/djangojs.po
@@ -1,19 +1,19 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the PACKAGE package.
#
#
msgid ""
msgstr ""
"Project-Id-Version: django-cms\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2011-08-14 09:45-0500\n"
"PO-Revision-Date: 2011-08-14 14:43+0000\n"
"Report-Msgid-Bugs-To: https://github.com/divio/django-cms/issues\n"
"POT-Creation-Date: 2011-08-14 09:44-0500\n"
"PO-Revision-Date: 2011-08-25 19:27+0000\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
"Language: bn\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: bn\n"
"Plural-Forms: nplurals=2; plural=(n != 1)\n"

#: static/cms/js/change_form.js:31
Expand All @@ -35,3 +35,5 @@ msgstr ""
#: static/cms/js/plugin_editor.js:132
msgid "Are you sure you want to delete this plugin?"
msgstr ""


Binary file modified cms/locale/cy/LC_MESSAGES/django.mo
Binary file not shown.
35 changes: 24 additions & 11 deletions cms/locale/cy/LC_MESSAGES/django.po
@@ -1,21 +1,20 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the PACKAGE package.
#
#
msgid ""
msgstr ""
"Project-Id-Version: django-cms\n"
"Report-Msgid-Bugs-To: \n"
"Report-Msgid-Bugs-To: https://github.com/divio/django-cms/issues\n"
"POT-Creation-Date: 2011-08-14 09:47-0500\n"
"PO-Revision-Date: 2011-08-14 14:43+0000\n"
"PO-Revision-Date: 2011-08-25 19:27+0000\n"
"Last-Translator: Benjamin Wohlwend <piquadrat@gmail.com>\n"
"Language-Team: divio.ch <developers@divio.ch>\n"
"Language: cy\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=4; plural=(n==1) ? 0 : (n==2) ? 1 : (n != 8 && n != "
"11) ? 2 : 3\n"
"Language: cy\n"
"Plural-Forms: nplurals=4; plural=(n==1) ? 0 : (n==2) ? 1 : (n != 8 && n != 11) ? 2 : 3\n"
"X-Poedit-Country: SWITZERLAND\n"
"X-Poedit-Language: English\n"
"X-Poedit-SourceCharset: utf-8\n"
Expand Down Expand Up @@ -126,7 +125,8 @@ msgid "Page Title"
msgstr ""

#: admin/forms.py:138
msgid "Overwrites what is displayed at the top of your browser or in bookmarks"
msgid ""
"Overwrites what is displayed at the top of your browser or in bookmarks"
msgstr ""

#: admin/forms.py:139
Expand Down Expand Up @@ -1248,8 +1248,8 @@ msgstr ""

#: plugins/video/models.py:10
msgid ""
"vimeo or youtube video url. Example: http://www.youtube.com/watch?v=-"
"iJ7bs4mTUY"
"vimeo or youtube video url. Example: "
"http://www.youtube.com/watch?v=-iJ7bs4mTUY"
msgstr ""

#: plugins/video/models.py:11
Expand Down Expand Up @@ -1797,8 +1797,7 @@ msgstr ""
#: templatetags/cms_tags.py:79
#, python-format
msgid ""
"A template tag couldn't find the page with lookup arguments `"
"%(page_lookup)s\n"
"A template tag couldn't find the page with lookup arguments `%(page_lookup)s\n"
"`. The URL of the request was: http://%(host)s%(path)s"
msgstr ""

Expand All @@ -1822,3 +1821,17 @@ msgstr ""
#, python-format
msgid "CMS - Page %s requires approvement."
msgstr ""

#~ msgid "move"
#~ msgstr "move request"

#~ msgid "sidebar column"
#~ msgstr "background color"

#~ msgid "fgcolor"
#~ msgstr "foreground color"

#~ msgid "Wanted language has not been translated yet."
#~ msgstr "Requested language has not been translated yet."


Binary file modified cms/locale/cy/LC_MESSAGES/djangojs.mo
Binary file not shown.
13 changes: 7 additions & 6 deletions cms/locale/cy/LC_MESSAGES/djangojs.po
@@ -1,21 +1,20 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the PACKAGE package.
#
#
msgid ""
msgstr ""
"Project-Id-Version: django-cms\n"
"Report-Msgid-Bugs-To: \n"
"Report-Msgid-Bugs-To: https://github.com/divio/django-cms/issues\n"
"POT-Creation-Date: 2011-08-14 09:44-0500\n"
"PO-Revision-Date: 2011-08-14 14:42+0000\n"
"PO-Revision-Date: 2011-08-25 19:27+0000\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
"Language: cy\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=4; plural=(n==1) ? 0 : (n==2) ? 1 : (n != 8 && n != "
"11) ? 2 : 3\n"
"Language: cy\n"
"Plural-Forms: nplurals=4; plural=(n==1) ? 0 : (n==2) ? 1 : (n != 8 && n != 11) ? 2 : 3\n"

#: static/cms/js/change_form.js:31
msgid ""
Expand All @@ -36,3 +35,5 @@ msgstr ""
#: static/cms/js/plugin_editor.js:132
msgid "Are you sure you want to delete this plugin?"
msgstr ""


Binary file modified cms/locale/es_AR/LC_MESSAGES/djangojs.mo
Binary file not shown.
12 changes: 7 additions & 5 deletions cms/locale/es_AR/LC_MESSAGES/djangojs.po
@@ -1,19 +1,19 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the PACKAGE package.
#
#
msgid ""
msgstr ""
"Project-Id-Version: django-cms\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2011-08-14 09:45-0500\n"
"PO-Revision-Date: 2011-08-14 14:43+0000\n"
"Report-Msgid-Bugs-To: https://github.com/divio/django-cms/issues\n"
"POT-Creation-Date: 2011-08-14 09:44-0500\n"
"PO-Revision-Date: 2011-08-25 19:27+0000\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
"Language: es_AR\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: es_AR\n"
"Plural-Forms: nplurals=2; plural=(n != 1)\n"

#: static/cms/js/change_form.js:31
Expand All @@ -35,3 +35,5 @@ msgstr ""
#: static/cms/js/plugin_editor.js:132
msgid "Are you sure you want to delete this plugin?"
msgstr ""


Binary file modified cms/locale/et/LC_MESSAGES/djangojs.mo
Binary file not shown.
12 changes: 7 additions & 5 deletions cms/locale/et/LC_MESSAGES/djangojs.po
@@ -1,19 +1,19 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the PACKAGE package.
#
#
msgid ""
msgstr ""
"Project-Id-Version: django-cms\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2011-08-14 09:45-0500\n"
"PO-Revision-Date: 2011-08-14 14:42+0000\n"
"Report-Msgid-Bugs-To: https://github.com/divio/django-cms/issues\n"
"POT-Creation-Date: 2011-08-14 09:44-0500\n"
"PO-Revision-Date: 2011-08-25 19:27+0000\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
"Language: et\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: et\n"
"Plural-Forms: nplurals=2; plural=(n != 1)\n"

#: static/cms/js/change_form.js:31
Expand All @@ -35,3 +35,5 @@ msgstr ""
#: static/cms/js/plugin_editor.js:132
msgid "Are you sure you want to delete this plugin?"
msgstr ""


Binary file modified cms/locale/eu/LC_MESSAGES/django.mo
Binary file not shown.
34 changes: 24 additions & 10 deletions cms/locale/eu/LC_MESSAGES/django.po
@@ -1,19 +1,19 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the PACKAGE package.
#
#
msgid ""
msgstr ""
"Project-Id-Version: django-cms\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2011-08-14 09:48-0500\n"
"PO-Revision-Date: 2011-08-14 14:43+0000\n"
"Report-Msgid-Bugs-To: https://github.com/divio/django-cms/issues\n"
"POT-Creation-Date: 2011-08-14 09:47-0500\n"
"PO-Revision-Date: 2011-08-25 19:27+0000\n"
"Last-Translator: Benjamin Wohlwend <piquadrat@gmail.com>\n"
"Language-Team: divio.ch <developers@divio.ch>\n"
"Language: eu\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: eu\n"
"Plural-Forms: nplurals=2; plural=(n != 1)\n"
"X-Poedit-Country: SWITZERLAND\n"
"X-Poedit-Language: English\n"
Expand Down Expand Up @@ -125,7 +125,8 @@ msgid "Page Title"
msgstr ""

#: admin/forms.py:138
msgid "Overwrites what is displayed at the top of your browser or in bookmarks"
msgid ""
"Overwrites what is displayed at the top of your browser or in bookmarks"
msgstr ""

#: admin/forms.py:139
Expand Down Expand Up @@ -1247,8 +1248,8 @@ msgstr ""

#: plugins/video/models.py:10
msgid ""
"vimeo or youtube video url. Example: http://www.youtube.com/watch?v=-"
"iJ7bs4mTUY"
"vimeo or youtube video url. Example: "
"http://www.youtube.com/watch?v=-iJ7bs4mTUY"
msgstr ""

#: plugins/video/models.py:11
Expand Down Expand Up @@ -1794,8 +1795,7 @@ msgstr ""
#: templatetags/cms_tags.py:79
#, python-format
msgid ""
"A template tag couldn't find the page with lookup arguments `"
"%(page_lookup)s\n"
"A template tag couldn't find the page with lookup arguments `%(page_lookup)s\n"
"`. The URL of the request was: http://%(host)s%(path)s"
msgstr ""

Expand All @@ -1819,3 +1819,17 @@ msgstr ""
#, python-format
msgid "CMS - Page %s requires approvement."
msgstr ""

#~ msgid "move"
#~ msgstr "move request"

#~ msgid "sidebar column"
#~ msgstr "background color"

#~ msgid "fgcolor"
#~ msgstr "foreground color"

#~ msgid "Wanted language has not been translated yet."
#~ msgstr "Requested language has not been translated yet."


Binary file modified cms/locale/eu/LC_MESSAGES/djangojs.mo
Binary file not shown.

0 comments on commit ccd790c

Please sign in to comment.