mirror of
https://github.com/jazzband/django-dbtemplates.git
synced 2026-03-16 22:20:28 +00:00
Add explicit id field to avoid creating migration with DEFAULT_AUTO_FIELD set to BigAutoField (#142)
Co-authored-by: blag <blag@users.noreply.github.com>
This commit is contained in:
parent
7f1c6701c1
commit
64d112cc4f
1 changed files with 2 additions and 0 deletions
|
|
@ -18,6 +18,8 @@ class Template(models.Model):
|
||||||
Defines a template model for use with the database template loader.
|
Defines a template model for use with the database template loader.
|
||||||
The field ``name`` is the equivalent to the filename of a static template.
|
The field ``name`` is the equivalent to the filename of a static template.
|
||||||
"""
|
"""
|
||||||
|
id = models.AutoField(primary_key=True, verbose_name=_('ID'),
|
||||||
|
serialize=False, auto_created=True)
|
||||||
name = models.CharField(_('name'), max_length=100,
|
name = models.CharField(_('name'), max_length=100,
|
||||||
help_text=_("Example: 'flatpages/default.html'"))
|
help_text=_("Example: 'flatpages/default.html'"))
|
||||||
content = models.TextField(_('content'), blank=True)
|
content = models.TextField(_('content'), blank=True)
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue