1👍
✅
You can set editable=False
[Django-doc] to prevent the field to show up in ModelForm
s, ModelAdmin
, etc.:
from datetime import datetime
class Source(Model):
# …
updated = models.DateTimeField(editable=False, default=datetime(2000, 1, 1), help_text="Most recent time this source has been updated")
Source:stackexchange.com