{{{
class MyModal(models.Model):
key = models.CharField(max_length=20, blank=False, null=False)
created_at = models.DateTimeField(blank=False, null=False,
auto_now_add=True)
}}}
When loading the data via the fixtures and ''omitting'' the created_at
field, I would assume created_at will be set to ''now''
I'm getting a error:
{{{
Could not load app.MyModal(pk=None): (1048, "Column 'created_at' cannot be
null")
}}}
YAML:
{{{
- model: app.mymodal
fields:
key: some text value
}}}
--
Ticket URL: <https://code.djangoproject.com/ticket/34114>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.