diff --git a/scipost_django/production/migrations/0010_alter_productionstream_opened.py b/scipost_django/production/migrations/0010_alter_productionstream_opened.py new file mode 100644 index 0000000000000000000000000000000000000000..1bf0c8b869394d12f4794fea200381597df0491d --- /dev/null +++ b/scipost_django/production/migrations/0010_alter_productionstream_opened.py @@ -0,0 +1,19 @@ +# Generated by Django 3.2.18 on 2023-10-06 15:27 + +from django.db import migrations, models +import django.utils.timezone + + +class Migration(migrations.Migration): + + dependencies = [ + ('production', '0009_productionstream_on_hold'), + ] + + operations = [ + migrations.AlterField( + model_name='productionstream', + name='opened', + field=models.DateTimeField(default=django.utils.timezone.now), + ), + ] diff --git a/scipost_django/production/models.py b/scipost_django/production/models.py index b3fbdb7ce05cd559a31867eb8871620802f43630..f8f283eea4122d458c9f788efab39093f0e7df4b 100644 --- a/scipost_django/production/models.py +++ b/scipost_django/production/models.py @@ -73,7 +73,7 @@ class ProductionStream(models.Model): on_delete=models.CASCADE, related_name="production_stream", ) - opened = models.DateTimeField(auto_now_add=True) + opened = models.DateTimeField(default=timezone.now) closed = models.DateTimeField(default=timezone.now) status = models.CharField( max_length=32,