blank model fields

This commit is contained in:
Sam
2021-03-08 10:50:39 +00:00
parent 4316ab6f2b
commit 44294223ed
2 changed files with 3 additions and 3 deletions

View File

@@ -69,8 +69,8 @@ class Product(models.Model):
# internal
created = models.DateTimeField('date of creation', auto_now_add=True)
updated = models.DateTimeField('date last update', auto_now=True)
creator = models.ForeignKey('core.CustomUser', on_delete=models.SET_NULL, null=True, related_name='product')
history = models.ForeignKey('history.HistorySync', on_delete=models.SET_NULL, null=True, related_name='product')
creator = models.ForeignKey('core.CustomUser', on_delete=models.SET_NULL, null=True, blank=True, related_name='product')
history = models.ForeignKey('history.HistorySync', on_delete=models.SET_NULL, null=True, blank=True, related_name='product')
def __str__(self):
return f"{self.name} / {self.sku}"