aviary in bird model

This commit is contained in:
gw3000 2023-06-28 22:19:08 +02:00
parent 6af0a15f9e
commit 96dc7ed688
6 changed files with 381 additions and 6 deletions

View file

@ -0,0 +1,31 @@
# Generated by Django 4.2.2 on 2023-06-28 20:12
from django.db import migrations, models
import uuid
class Migration(migrations.Migration):
initial = True
dependencies = []
operations = [
migrations.CreateModel(
name="Aviary",
fields=[
(
"id",
models.UUIDField(
default=uuid.uuid4,
editable=False,
primary_key=True,
serialize=False,
),
),
("description", models.CharField(max_length=256)),
("condition", models.CharField(max_length=256)),
("last_ward_round", models.DateField()),
],
),
]

View file

@ -6,7 +6,7 @@ class Aviary(models.Model):
id = models.UUIDField(primary_key=True, default=uuid4, editable=False)
description = models.CharField(max_length=256)
condition = models.CharField(max_length=256)
last_ward_round = models.DateTimeField(auto_now_add=True)
last_ward_round = models.DateField()
def __str__(self):
return self.description