mirror of
https://github.com/jwinterm/modoboa.git
synced 2026-10-17 05:41:25 +02:00
fix: the untildate field is not mandatory!
This commit is contained in:
@@ -46,6 +46,34 @@ First, decompress the new tarball at the same location than your
|
||||
current installation. Then, check if the new version you're installing
|
||||
requires a migration::
|
||||
|
||||
0.8 -> 0.8.1 : project renamed.
|
||||
|
||||
* First, rename your mailng folder to modoboa and copy all the
|
||||
content from modoboa-0.8.1 to modoboa.
|
||||
|
||||
* Edit your settings.py and replace all occurences of mailng by
|
||||
modoboa. Make sure you don't modify the DATABASE section as you're
|
||||
not going to rename your database.
|
||||
|
||||
* Rename the MAILNG_DIR variable to MODOBOA_DIR.
|
||||
|
||||
* Add 'django.contrib.messages.middleware.MessageMiddleware' to
|
||||
MIDDLEWARE_CLASSES and 'django.contrib.messages' to
|
||||
INSTALLED_APPS. Save your modifications.
|
||||
|
||||
* Run the following command::
|
||||
|
||||
# python manage.py syncdb
|
||||
|
||||
* For all activated extensions, run the following command::
|
||||
|
||||
# export PYTHONPATH=<modoboa_dir>/..
|
||||
# DJANGO_SETTINGS_MODULE=modoboa.settings \
|
||||
<modoboa_dir>/scripts/extension.py <extension> on
|
||||
|
||||
* Update your webserver configuration and restart it.
|
||||
|
||||
|
||||
0.7 -> 0.8 : SQL migration needed.
|
||||
|
||||
Before you start migration, make sure you have updated your
|
||||
|
||||
@@ -4,9 +4,12 @@ from django.utils.translation import ugettext as _
|
||||
import datetime
|
||||
|
||||
class ARmessageForm(forms.ModelForm):
|
||||
untildate = forms.DateField(label=_('Until'), required=False,
|
||||
help_text=_("Activate your auto reply until this date"))
|
||||
|
||||
class Meta:
|
||||
model = ARmessage
|
||||
fields = ('subject', 'content', 'enabled', 'untildate')
|
||||
fields = ('subject', 'content', 'enabled')
|
||||
|
||||
def __init__(self, *args, **kwargs):
|
||||
super(ARmessageForm, self).__init__(*args, **kwargs)
|
||||
@@ -14,6 +17,7 @@ class ARmessageForm(forms.ModelForm):
|
||||
self.fields['content'].widget.attrs['cols'] = 50
|
||||
|
||||
def clean_untildate(self):
|
||||
if self.cleaned_data["untildate"] < datetime.date.today():
|
||||
raise forms.ValidationError(_("This date is over"))
|
||||
if self.cleaned_data["untildate"] is not None:
|
||||
if self.cleaned_data["untildate"] < datetime.date.today():
|
||||
raise forms.ValidationError(_("This date is over"))
|
||||
return self.cleaned_data['untildate']
|
||||
|
||||
@@ -55,7 +55,7 @@ def menu(**kwargs):
|
||||
"url" : reverse(views.autoreply),
|
||||
"img" : "/static/pics/auto-reply.png",
|
||||
"class" : "boxed",
|
||||
"rel" : "{handler:'iframe',size:{x:440,y:370}}",
|
||||
"rel" : "{handler:'iframe',size:{x:440,y:400}}",
|
||||
"label" : _("Auto-reply message")}
|
||||
]
|
||||
|
||||
|
||||
@@ -18,8 +18,7 @@ class ARmessage(models.Model):
|
||||
help_text=_("The content that will appear in sended emails"))
|
||||
enabled = models.BooleanField(_('enabled'),
|
||||
help_text=_("Activate/Deactivate your auto reply"))
|
||||
untildate = models.DateField(_('until'),
|
||||
help_text=_("Activate your auto reply until this date"))
|
||||
untildate = models.DateField()
|
||||
|
||||
class ARhistoric(models.Model):
|
||||
armessage = models.ForeignKey(ARmessage)
|
||||
|
||||
@@ -29,6 +29,7 @@ def autoreply(request):
|
||||
from modoboa import userprefs
|
||||
|
||||
arm = form.save(commit=False)
|
||||
arm.untildate = form.cleaned_data["untildate"]
|
||||
arm.mbox = mb
|
||||
arm.save()
|
||||
messages.info(request, _("Auto reply message updated successfully."),
|
||||
@@ -42,6 +43,7 @@ def autoreply(request):
|
||||
mimetype="application/json")
|
||||
|
||||
form = ARmessageForm(instance=arm)
|
||||
form.fields['untildate'].initial = arm.untildate
|
||||
return _render(request, "postfix_autoreply/autoreply.html", {
|
||||
"form" : form
|
||||
})
|
||||
|
||||
@@ -43,7 +43,7 @@ def display_messages(msgs):
|
||||
<script type="text/javascript">
|
||||
window.addEvent("domready", function() {
|
||||
infobox.%s("%s");
|
||||
infobox.hide(3);
|
||||
infobox.hide(2);
|
||||
});
|
||||
</script>
|
||||
""" % (level, text)
|
||||
|
||||
@@ -7,7 +7,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: PACKAGE VERSION\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2010-07-23 16:23+0200\n"
|
||||
"POT-Creation-Date: 2010-07-27 15:29+0200\n"
|
||||
"PO-Revision-Date: 2010-07-25 21:39+0200\n"
|
||||
"Last-Translator: Patrick Ben Koetter <p@state-of-mind.de>\n"
|
||||
"Language-Team: DE <p@state-of-mind.de>\n"
|
||||
@@ -170,45 +170,45 @@ msgstr "Mailbox auf den dieser Alias verweist"
|
||||
msgid "Check to activate this alias"
|
||||
msgstr "Auswählen um den Alias zu aktivieren"
|
||||
|
||||
#: admin/views.py:27
|
||||
#: admin/views.py:29
|
||||
msgid "Permission denied."
|
||||
msgstr "Zugriff verweigert."
|
||||
|
||||
#: admin/views.py:73 admin/views.py:103
|
||||
#: admin/views.py:75 admin/views.py:105
|
||||
msgid "Domain with this name already defined"
|
||||
msgstr "Es existiert bereits eine Domain mit diesem Namen"
|
||||
|
||||
#: admin/views.py:82
|
||||
#: admin/views.py:84
|
||||
msgid "Failed to initialise domain, check permissions"
|
||||
msgstr ""
|
||||
"Domäne konnte nicht initialisiert werden. Prüfen Sie die Berechtigungen."
|
||||
|
||||
#: admin/views.py:106
|
||||
#: admin/views.py:108
|
||||
msgid "Failed to rename domain, check permissions"
|
||||
msgstr "Domäne konnte nicht umbenannt werden. Prüfen Sie die Berechtigungen."
|
||||
|
||||
#: admin/views.py:160 admin/views.py:222
|
||||
#: admin/views.py:162 admin/views.py:225
|
||||
msgid "Mailbox with this address already exists"
|
||||
msgstr "Eine Mailbox mit diesem Namen existiert bereits."
|
||||
|
||||
#: admin/views.py:194
|
||||
#: admin/views.py:196
|
||||
msgid "Mailbox created."
|
||||
msgstr "Mailbox erstellt."
|
||||
|
||||
#: admin/views.py:198
|
||||
#: admin/views.py:201
|
||||
msgid "Failed to initialise mailbox, check permissions"
|
||||
msgstr ""
|
||||
"Mailbox konnte nicht initialisiert werden. Prüfen Sie die Berechtigungen."
|
||||
|
||||
#: admin/views.py:225
|
||||
#: admin/views.py:228
|
||||
msgid "Failed to rename mailbox, check permissions"
|
||||
msgstr "Mailbox konnte nicht umbenannt werden. Prüfen Sie die Berechtigungen."
|
||||
|
||||
#: admin/views.py:296 admin/views.py:326
|
||||
#: admin/views.py:299 admin/views.py:329
|
||||
msgid "Alias with this name already exists"
|
||||
msgstr "Ein Alias mit dieser Adresse existiert bereits"
|
||||
|
||||
#: admin/views.py:401
|
||||
#: admin/views.py:404
|
||||
msgid "admin is intouchable!!"
|
||||
msgstr "admin ist unantastbar!!"
|
||||
|
||||
@@ -435,7 +435,15 @@ msgstr "Nachrichten-Header"
|
||||
msgid "Bad MIME"
|
||||
msgstr "Schlechtes MIME"
|
||||
|
||||
#: extensions/postfix_autoreply/forms.py:18
|
||||
#: extensions/postfix_autoreply/forms.py:7
|
||||
msgid "Until"
|
||||
msgstr "Bis"
|
||||
|
||||
#: extensions/postfix_autoreply/forms.py:8
|
||||
msgid "Activate your auto reply until this date"
|
||||
msgstr "Aktivieren Sie ihre automatisierte Antwort bis zu diesem Datum"
|
||||
|
||||
#: extensions/postfix_autoreply/forms.py:22
|
||||
msgid "This date is over"
|
||||
msgstr "Das Datum ist vorbei"
|
||||
|
||||
@@ -470,14 +478,6 @@ msgstr "Der Inhalt, der in den versendeten Nachrichten verwendet wird"
|
||||
msgid "Activate/Deactivate your auto reply"
|
||||
msgstr "Aktivieren/Deaktivieren Sie die automatisierte Antwort"
|
||||
|
||||
#: extensions/postfix_autoreply/models.py:21
|
||||
msgid "until"
|
||||
msgstr "bis"
|
||||
|
||||
#: extensions/postfix_autoreply/models.py:22
|
||||
msgid "Activate your auto reply until this date"
|
||||
msgstr "Aktivieren Sie ihre automatisierte Antwort bis zu diesem Datum"
|
||||
|
||||
#: extensions/postfix_autoreply/views.py:34
|
||||
msgid "Auto reply message updated successfully."
|
||||
msgstr "Automatische Antwort erfolgreich aktualisiert."
|
||||
@@ -681,7 +681,7 @@ msgstr "Benutzerdefinierte Signatur der E-Mail"
|
||||
msgid "Simple IMAP webmail"
|
||||
msgstr "Einfaches IMAP-Webmail"
|
||||
|
||||
#: extensions/webmail/main.py:67 extensions/webmail/templates/index.html:309
|
||||
#: extensions/webmail/main.py:67 extensions/webmail/templates/index.html:313
|
||||
msgid "Webmail"
|
||||
msgstr "Webmail"
|
||||
|
||||
@@ -705,15 +705,15 @@ msgstr "Ordner"
|
||||
msgid "Attachments"
|
||||
msgstr "Dateianhänge"
|
||||
|
||||
#: extensions/webmail/templates/index.html:120
|
||||
#: extensions/webmail/templates/index.html:125
|
||||
msgid "Reloading..."
|
||||
msgstr "Aktualisiere..."
|
||||
|
||||
#: extensions/webmail/templates/index.html:127
|
||||
#: extensions/webmail/templates/index.html:132
|
||||
msgid "Done"
|
||||
msgstr "Abgeschlossen"
|
||||
|
||||
#: extensions/webmail/templates/index.html:315
|
||||
#: extensions/webmail/templates/index.html:319
|
||||
msgid "Mailbox quota"
|
||||
msgstr "Mailbox Quota"
|
||||
|
||||
@@ -958,7 +958,7 @@ msgstr "Passwort ändern"
|
||||
msgid "Do not delete mailbox directory"
|
||||
msgstr "Mailbox-Verzeichnis nicht löschen"
|
||||
|
||||
#: templates/userprefs/preferences.html:7
|
||||
#: templates/userprefs/preferences.html:6
|
||||
#: userprefs/templatetags/uprefs_extras.py:26
|
||||
msgid "Preferences"
|
||||
msgstr "Einstellungen"
|
||||
|
||||
@@ -1,17 +1,17 @@
|
||||
# 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.
|
||||
# Antoine Nguyen <tonio@ngyn.org>, 2010.
|
||||
#
|
||||
#, fuzzy
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: PACKAGE VERSION\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2010-07-23 16:23+0200\n"
|
||||
"POT-Creation-Date: 2010-07-27 15:29+0200\n"
|
||||
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
||||
"Last-Translator: Antoine Nguyen <tonio@ngyn.org>\n"
|
||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||
"Language-Team: Antoine Nguyen <tonio@ngyn.org>\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
@@ -173,44 +173,44 @@ msgstr "Les boites aux lettres sur lesquelles pointe cet alias"
|
||||
msgid "Check to activate this alias"
|
||||
msgstr "Cocher pour activer cet alias"
|
||||
|
||||
#: admin/views.py:27
|
||||
#: admin/views.py:29
|
||||
msgid "Permission denied."
|
||||
msgstr "Permission refusée."
|
||||
|
||||
#: admin/views.py:73 admin/views.py:103
|
||||
#: admin/views.py:75 admin/views.py:105
|
||||
msgid "Domain with this name already defined"
|
||||
msgstr "Un domaine avec ce nom existe déjà"
|
||||
|
||||
#: admin/views.py:82
|
||||
#: admin/views.py:84
|
||||
msgid "Failed to initialise domain, check permissions"
|
||||
msgstr "Impossible d'initialiser le domaine, vérifier les permissions"
|
||||
|
||||
#: admin/views.py:106
|
||||
#: admin/views.py:108
|
||||
msgid "Failed to rename domain, check permissions"
|
||||
msgstr "Impossible de renommer le domaine, vérifier les permissions"
|
||||
|
||||
#: admin/views.py:160 admin/views.py:222
|
||||
#: admin/views.py:162 admin/views.py:225
|
||||
msgid "Mailbox with this address already exists"
|
||||
msgstr "Une boite aux lettres pour cette adresse existe déjà"
|
||||
|
||||
#: admin/views.py:194
|
||||
#: admin/views.py:196
|
||||
msgid "Mailbox created."
|
||||
msgstr "Boite aux lettres créé."
|
||||
|
||||
#: admin/views.py:198
|
||||
#: admin/views.py:201
|
||||
msgid "Failed to initialise mailbox, check permissions"
|
||||
msgstr ""
|
||||
"Impossible d'initialiser la boite aux lettres, vérifier les permissions"
|
||||
|
||||
#: admin/views.py:225
|
||||
#: admin/views.py:228
|
||||
msgid "Failed to rename mailbox, check permissions"
|
||||
msgstr "Impossible de renommer la boite aux lettres, vérifier les permissions."
|
||||
|
||||
#: admin/views.py:296 admin/views.py:326
|
||||
#: admin/views.py:299 admin/views.py:329
|
||||
msgid "Alias with this name already exists"
|
||||
msgstr "Un alias avec ce nom existe déjà"
|
||||
|
||||
#: admin/views.py:401
|
||||
#: admin/views.py:404
|
||||
msgid "admin is intouchable!!"
|
||||
msgstr "admin est intouchable!!"
|
||||
|
||||
@@ -435,7 +435,15 @@ msgstr "Mauvais entête"
|
||||
msgid "Bad MIME"
|
||||
msgstr "Mauvais type MIME"
|
||||
|
||||
#: extensions/postfix_autoreply/forms.py:18
|
||||
#: extensions/postfix_autoreply/forms.py:7
|
||||
msgid "Until"
|
||||
msgstr "Jusqu'à"
|
||||
|
||||
#: extensions/postfix_autoreply/forms.py:8
|
||||
msgid "Activate your auto reply until this date"
|
||||
msgstr "Activer votre réponse automatique jusqu'à cette date"
|
||||
|
||||
#: extensions/postfix_autoreply/forms.py:22
|
||||
msgid "This date is over"
|
||||
msgstr "Cette date est dépassée"
|
||||
|
||||
@@ -470,14 +478,6 @@ msgstr "Le contenu qui apparaitra dans les emails envoyés"
|
||||
msgid "Activate/Deactivate your auto reply"
|
||||
msgstr "Activer/Désactiver votre réponse automatique"
|
||||
|
||||
#: extensions/postfix_autoreply/models.py:21
|
||||
msgid "until"
|
||||
msgstr "jusqu'à"
|
||||
|
||||
#: extensions/postfix_autoreply/models.py:22
|
||||
msgid "Activate your auto reply until this date"
|
||||
msgstr "Activer votre réponse automatique jusqu'à cette date"
|
||||
|
||||
#: extensions/postfix_autoreply/views.py:34
|
||||
msgid "Auto reply message updated successfully."
|
||||
msgstr "Message de réponse auto. mis à jour."
|
||||
@@ -680,7 +680,7 @@ msgstr ""
|
||||
msgid "Simple IMAP webmail"
|
||||
msgstr ""
|
||||
|
||||
#: extensions/webmail/main.py:67 extensions/webmail/templates/index.html:309
|
||||
#: extensions/webmail/main.py:67 extensions/webmail/templates/index.html:313
|
||||
msgid "Webmail"
|
||||
msgstr ""
|
||||
|
||||
@@ -704,15 +704,15 @@ msgstr "Dossiers"
|
||||
msgid "Attachments"
|
||||
msgstr "Pièces jointes"
|
||||
|
||||
#: extensions/webmail/templates/index.html:120
|
||||
#: extensions/webmail/templates/index.html:125
|
||||
msgid "Reloading..."
|
||||
msgstr "Rechargement..."
|
||||
|
||||
#: extensions/webmail/templates/index.html:127
|
||||
#: extensions/webmail/templates/index.html:132
|
||||
msgid "Done"
|
||||
msgstr "Effectué"
|
||||
|
||||
#: extensions/webmail/templates/index.html:315
|
||||
#: extensions/webmail/templates/index.html:319
|
||||
msgid "Mailbox quota"
|
||||
msgstr "Quota de la boite aux lettres"
|
||||
|
||||
@@ -957,7 +957,7 @@ msgstr "Changer de mot de passe"
|
||||
msgid "Do not delete mailbox directory"
|
||||
msgstr "Ne pas supprimer le répertoire de la boite aux lettres"
|
||||
|
||||
#: templates/userprefs/preferences.html:7
|
||||
#: templates/userprefs/preferences.html:6
|
||||
#: userprefs/templatetags/uprefs_extras.py:26
|
||||
msgid "Preferences"
|
||||
msgstr "Préférences"
|
||||
|
||||
+9
-3
@@ -1,6 +1,6 @@
|
||||
body {
|
||||
font-family: arial, helvetica, verdana, tahoma, sans-serif;
|
||||
font-size: small;
|
||||
font-size: 0.9em;
|
||||
margin: 0 auto;
|
||||
padding: 0;
|
||||
}
|
||||
@@ -14,14 +14,12 @@ div.row {
|
||||
div.row label {
|
||||
float: left;
|
||||
width: 120px;
|
||||
font-size: small;
|
||||
padding: 3px 0;
|
||||
}
|
||||
|
||||
input {
|
||||
border: 1px solid #cccccc;
|
||||
color: inherit;
|
||||
/*background-color: #e9e9e9;*/
|
||||
background-color: #eee;
|
||||
padding: 2px;
|
||||
}
|
||||
@@ -35,6 +33,14 @@ input:hover {
|
||||
background-color: #ffffcc;
|
||||
}
|
||||
|
||||
textarea {
|
||||
border: 1px solid #cccccc;
|
||||
background-color: #eee;
|
||||
width: 300px;
|
||||
font-family: inherit;
|
||||
font-size: inherit;
|
||||
}
|
||||
|
||||
select {
|
||||
width: 135px;
|
||||
background-color: #eee;
|
||||
|
||||
@@ -24,8 +24,8 @@ button.calendar{
|
||||
padding:0px;
|
||||
margin-right:3px;
|
||||
cursor:pointer;
|
||||
width:16px;
|
||||
height:16px;
|
||||
width:20px;
|
||||
height:20px;
|
||||
}
|
||||
input.calendar{
|
||||
cursor:pointer;
|
||||
|
||||
Reference in New Issue
Block a user