From 1c3bda32c05c2f074a3737a7b8485315ced5fff8 Mon Sep 17 00:00:00 2001 From: AmarHakim Date: Mon, 18 Oct 2021 19:40:50 -0400 Subject: [PATCH 1/3] Added a CANCELLED status for events --- .../migrations/0014_alter_newsitem_status.py | 18 ++++++++++++++++++ api/community/models.py | 1 + 2 files changed, 19 insertions(+) create mode 100644 api/community/migrations/0014_alter_newsitem_status.py diff --git a/api/community/migrations/0014_alter_newsitem_status.py b/api/community/migrations/0014_alter_newsitem_status.py new file mode 100644 index 0000000..d15ae6b --- /dev/null +++ b/api/community/migrations/0014_alter_newsitem_status.py @@ -0,0 +1,18 @@ +# Generated by Django 3.2 on 2021-10-12 15:06 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('community', '0013_newsitem_categories'), + ] + + operations = [ + migrations.AlterField( + model_name='newsitem', + name='status', + field=models.CharField(choices=[('draft', 'DRAFT'), ('public', 'PUBLIC'), ('cancelled', 'CANCELLED')], default='public', max_length=12), + ), + ] diff --git a/api/community/models.py b/api/community/models.py index d415406..4efd1d3 100644 --- a/api/community/models.py +++ b/api/community/models.py @@ -10,6 +10,7 @@ STATUS_CHOICES = ( ("draft", "DRAFT"), ("public", "PUBLIC"), + ("cancelled", "CANCELLED") ) From 5214a40b3a85fd2fd0bce28adf2a3bdaa2cbbd43 Mon Sep 17 00:00:00 2001 From: Hakim <56102253+AmarHakim@users.noreply.github.com> Date: Mon, 18 Oct 2021 19:51:56 -0400 Subject: [PATCH 2/3] Delete 0014_alter_newsitem_status.py --- .../migrations/0014_alter_newsitem_status.py | 18 ------------------ 1 file changed, 18 deletions(-) delete mode 100644 api/community/migrations/0014_alter_newsitem_status.py diff --git a/api/community/migrations/0014_alter_newsitem_status.py b/api/community/migrations/0014_alter_newsitem_status.py deleted file mode 100644 index d15ae6b..0000000 --- a/api/community/migrations/0014_alter_newsitem_status.py +++ /dev/null @@ -1,18 +0,0 @@ -# Generated by Django 3.2 on 2021-10-12 15:06 - -from django.db import migrations, models - - -class Migration(migrations.Migration): - - dependencies = [ - ('community', '0013_newsitem_categories'), - ] - - operations = [ - migrations.AlterField( - model_name='newsitem', - name='status', - field=models.CharField(choices=[('draft', 'DRAFT'), ('public', 'PUBLIC'), ('cancelled', 'CANCELLED')], default='public', max_length=12), - ), - ] From 0e434517ffff5947b953781734086c763ec9c921 Mon Sep 17 00:00:00 2001 From: Hakim <56102253+AmarHakim@users.noreply.github.com> Date: Mon, 18 Oct 2021 20:02:53 -0400 Subject: [PATCH 3/3] Update models.py --- api/community/models.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/api/community/models.py b/api/community/models.py index 4efd1d3..89d0456 100644 --- a/api/community/models.py +++ b/api/community/models.py @@ -10,7 +10,7 @@ STATUS_CHOICES = ( ("draft", "DRAFT"), ("public", "PUBLIC"), - ("cancelled", "CANCELLED") + ("cancelled", "CANCELLED"), )