From 25717f6a7996825355e24e24659d398c422366ce Mon Sep 17 00:00:00 2001 From: vabene1111 Date: Wed, 24 Mar 2021 00:06:34 +0100 Subject: [PATCH] space max --- cookbook/migrations/0117_space_max_recipes.py | 18 ++++++++++++++++++ cookbook/models.py | 1 + 2 files changed, 19 insertions(+) create mode 100644 cookbook/migrations/0117_space_max_recipes.py diff --git a/cookbook/migrations/0117_space_max_recipes.py b/cookbook/migrations/0117_space_max_recipes.py new file mode 100644 index 000000000..41f271aee --- /dev/null +++ b/cookbook/migrations/0117_space_max_recipes.py @@ -0,0 +1,18 @@ +# Generated by Django 3.1.7 on 2021-03-23 21:50 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('cookbook', '0116_auto_20210319_0012'), + ] + + operations = [ + migrations.AddField( + model_name='space', + name='max_recipes', + field=models.IntegerField(default=0), + ), + ] diff --git a/cookbook/models.py b/cookbook/models.py index d1668bacb..75d624b2f 100644 --- a/cookbook/models.py +++ b/cookbook/models.py @@ -61,6 +61,7 @@ class Space(models.Model): name = models.CharField(max_length=128, default='Default') created_by = models.ForeignKey(User, on_delete=models.PROTECT, null=True) message = models.CharField(max_length=512, default='', blank=True) + max_recipes = models.IntegerField(default=0) def __str__(self): return self.name