From deaf7344888df5848396b4d874474063edd2252c Mon Sep 17 00:00:00 2001 From: Lauryn Menard Date: Thu, 14 Dec 2023 19:47:40 +0100 Subject: [PATCH] corporate: Add minimum_licenses field to Customer model. --- .../0032_customer_minimum_licenses.py | 17 +++++++++++++++++ corporate/models.py | 1 + 2 files changed, 18 insertions(+) create mode 100644 corporate/migrations/0032_customer_minimum_licenses.py diff --git a/corporate/migrations/0032_customer_minimum_licenses.py b/corporate/migrations/0032_customer_minimum_licenses.py new file mode 100644 index 0000000000..0c765b540c --- /dev/null +++ b/corporate/migrations/0032_customer_minimum_licenses.py @@ -0,0 +1,17 @@ +# Generated by Django 4.2.8 on 2023-12-14 13:27 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + dependencies = [ + ("corporate", "0031_customer_flat_discount_and_more"), + ] + + operations = [ + migrations.AddField( + model_name="customer", + name="minimum_licenses", + field=models.PositiveIntegerField(null=True), + ), + ] diff --git a/corporate/models.py b/corporate/models.py index b0c1381190..7f933164c9 100644 --- a/corporate/models.py +++ b/corporate/models.py @@ -28,6 +28,7 @@ class Customer(models.Model): sponsorship_pending = models.BooleanField(default=False) # A percentage, like 85. default_discount = models.DecimalField(decimal_places=4, max_digits=7, null=True) + minimum_licenses = models.PositiveIntegerField(null=True) # Some non-profit organizations on manual license management pay # only for their paid employees. We don't prevent these # organizations from adding more users than the number of licenses