From 86d954a473c4a333efb5f89df678d51f48043eca Mon Sep 17 00:00:00 2001 From: Pascal Wichmann Date: Tue, 30 Oct 2018 12:54:44 +0100 Subject: [PATCH] Allow labels to be blank (closes #113) --- label/migrations/0002_auto_20181030_1254.py | 18 ++++++++++++++++++ label/models.py | 2 +- 2 files changed, 19 insertions(+), 1 deletion(-) create mode 100644 label/migrations/0002_auto_20181030_1254.py diff --git a/label/migrations/0002_auto_20181030_1254.py b/label/migrations/0002_auto_20181030_1254.py new file mode 100644 index 0000000..c12bffe --- /dev/null +++ b/label/migrations/0002_auto_20181030_1254.py @@ -0,0 +1,18 @@ +# Generated by Django 2.1 on 2018-10-30 11:54 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('label', '0001_initial'), + ] + + operations = [ + migrations.AlterField( + model_name='label', + name='description', + field=models.TextField(blank=True, null=True), + ), + ] diff --git a/label/models.py b/label/models.py index 24bb52c..efd1a92 100644 --- a/label/models.py +++ b/label/models.py @@ -14,7 +14,7 @@ class Meta: related_name='labels') title = models.CharField(max_length=15) - description = models.TextField() + description = models.TextField(null=True, blank=True) color = models.CharField(max_length=6) def __str__(self) -> str: