From 8d9b008e173de86f1f6ef2f04b2369c5667a9917 Mon Sep 17 00:00:00 2001 From: jedi Date: Mon, 9 Nov 2020 16:06:26 +0100 Subject: [PATCH] cleanup --- backend/multimail/forms.py | 4 +--- .../migrations/0002_auto_20201109_1505.py | 17 +++++++++++++++++ update.sh | 3 ++- 3 files changed, 20 insertions(+), 4 deletions(-) create mode 100644 backend/multimail/migrations/0002_auto_20201109_1505.py diff --git a/backend/multimail/forms.py b/backend/multimail/forms.py index 8c9d70d..fe0650b 100644 --- a/backend/multimail/forms.py +++ b/backend/multimail/forms.py @@ -12,15 +12,13 @@ class DomainForm(ModelForm): class Meta: model = Domain fields = '__all__' - # fields = ['domain'] class MailboxForm(ModelForm): plain_password = CharField(label='Password', required=False, widget=PasswordInput()) class Meta: model = Mailbox - # fields = '__all__' - fields = ['domain', 'username', 'plain_password', 'sendonly', 'enabled'] + fields = ['domain', 'username', 'plain_password', 'quota', 'sendonly', 'enabled'] def save(self, commit=True): mailbox = super(MailboxForm, self).save(commit=False) diff --git a/backend/multimail/migrations/0002_auto_20201109_1505.py b/backend/multimail/migrations/0002_auto_20201109_1505.py new file mode 100644 index 0000000..e550f22 --- /dev/null +++ b/backend/multimail/migrations/0002_auto_20201109_1505.py @@ -0,0 +1,17 @@ +# Generated by Django 3.1.3 on 2020-11-09 15:05 + +from django.db import migrations + + +class Migration(migrations.Migration): + + dependencies = [ + ('multimail', '0001_initial'), + ] + + operations = [ + migrations.AlterUniqueTogether( + name='domainowner', + unique_together={('domain', 'admin', 'source')}, + ), + ] diff --git a/update.sh b/update.sh index ec3866b..b206172 100755 --- a/update.sh +++ b/update.sh @@ -14,7 +14,8 @@ function run_update(){ echo run autoupdate in $(pwd) git pull cd backend - python3 manage.py migrate + python3 manage.py migrate + python3 manage.py collectstatic --noinput } run_update | prefix_date >> $DIR/update.log