summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPiotr Dobrowolski <admin@tastycode.pl>2017-12-13 21:30:15 +0100
committerPiotr Dobrowolski <admin@tastycode.pl>2017-12-13 21:30:15 +0100
commit7cf67e41959c1014e4f4c1d4098e37f5b1c0b330 (patch)
treea8229cc58a40e08c5ee6443dc356b4249ce5fa91
parentc1cada3de7e13d343840aa0ba1ffbe897db383dd (diff)
downloadspejstore-7cf67e41959c1014e4f4c1d4098e37f5b1c0b330.tar.gz
spejstore-7cf67e41959c1014e4f4c1d4098e37f5b1c0b330.tar.bz2
spejstore-7cf67e41959c1014e4f4c1d4098e37f5b1c0b330.zip
models: Store more sensible item image changelog
-rw-r--r--storage/models.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/storage/models.py b/storage/models.py
index edd40dc..cf1729c 100644
--- a/storage/models.py
+++ b/storage/models.py
@@ -88,6 +88,9 @@ class ItemImage(models.Model):
item = models.ForeignKey(Item, related_name='images')
image = models.ImageField()
+ def __str__(self):
+ return '{}'.format(self.image.name)
+
class Label(models.Model):
id = models.CharField(max_length=64, primary_key=True)