From 51502b3a51b8a244149e5e94dcb2229bbcec1e69 Mon Sep 17 00:00:00 2001 From: Radek Czajka Date: Thu, 26 Nov 2020 13:14:30 +0100 Subject: [PATCH] Forgotten migrations. --- .../migrations/0024_auto_20201126_1250.py | 33 +++++++++++++++++++ .../migrations/0025_auto_20201126_1250.py | 18 ++++++++++ src/club/models.py | 2 +- .../migrations/0006_auto_20201126_1242.py | 22 +++++++++++++ 4 files changed, 74 insertions(+), 1 deletion(-) create mode 100644 src/club/migrations/0024_auto_20201126_1250.py create mode 100644 src/club/migrations/0025_auto_20201126_1250.py create mode 100644 src/messaging/migrations/0006_auto_20201126_1242.py diff --git a/src/club/migrations/0024_auto_20201126_1250.py b/src/club/migrations/0024_auto_20201126_1250.py new file mode 100644 index 000000000..2b4996385 --- /dev/null +++ b/src/club/migrations/0024_auto_20201126_1250.py @@ -0,0 +1,33 @@ +# Generated by Django 2.2.16 on 2020-11-26 11:50 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('club', '0023_completed_at'), + ] + + operations = [ + migrations.RenameField( + model_name='membership', + old_name='honorary', + new_name='manual', + ), + migrations.AddField( + model_name='membership', + name='notes', + field=models.CharField(blank=True, max_length=2048, verbose_name='notes'), + ), + migrations.AddField( + model_name='membership', + name='updated_at', + field=models.DateField(auto_now=True, verbose_name='updated at'), + ), + migrations.AlterField( + model_name='membership', + name='name', + field=models.CharField(blank=True, max_length=255, verbose_name='name'), + ), + ] diff --git a/src/club/migrations/0025_auto_20201126_1250.py b/src/club/migrations/0025_auto_20201126_1250.py new file mode 100644 index 000000000..7954afe5b --- /dev/null +++ b/src/club/migrations/0025_auto_20201126_1250.py @@ -0,0 +1,18 @@ +# Generated by Django 2.2.16 on 2020-11-26 11:50 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('club', '0024_auto_20201126_1250'), + ] + + operations = [ + migrations.AlterField( + model_name='membership', + name='manual', + field=models.BooleanField(default=False, verbose_name='manual'), + ), + ] diff --git a/src/club/models.py b/src/club/models.py index 7147d474c..665f5ba61 100644 --- a/src/club/models.py +++ b/src/club/models.py @@ -167,7 +167,7 @@ class Membership(models.Model): membership = user.membership except cls.DoesNotExist: return False - if membership.honorary: + if membership.manual: return True return Schedule.objects.filter( expires_at__gt=now(), diff --git a/src/messaging/migrations/0006_auto_20201126_1242.py b/src/messaging/migrations/0006_auto_20201126_1242.py new file mode 100644 index 000000000..2b8865810 --- /dev/null +++ b/src/messaging/migrations/0006_auto_20201126_1242.py @@ -0,0 +1,22 @@ +# Generated by Django 2.2.16 on 2020-11-26 11:42 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('messaging', '0005_auto_20200129_1309'), + ] + + operations = [ + migrations.AlterModelOptions( + name='contact', + options={'verbose_name': 'contact', 'verbose_name_plural': 'contacts'}, + ), + migrations.AlterField( + model_name='contact', + name='level', + field=models.PositiveSmallIntegerField(choices=[(10, 'Cold'), (20, 'Would-be donor'), (30, 'One-time donor'), (40, 'Recurring donor'), (45, 'Manually set as member'), (50, 'Opt out')]), + ), + ] -- 2.20.1