.
This commit is contained in:
+3
-1
@@ -32,6 +32,8 @@ from generic.models import Examination, Condition, Sign, ExamBase
|
||||
from easy_thumbnails.files import get_thumbnailer
|
||||
from easy_thumbnails.exceptions import InvalidImageFormatError
|
||||
|
||||
|
||||
|
||||
image_storage = FileSystemStorage(
|
||||
# Physical file location ROOT
|
||||
location=u"{0}longs/".format(settings.MEDIA_ROOT),
|
||||
@@ -147,7 +149,7 @@ def test_image_validator(file):
|
||||
pass
|
||||
|
||||
class LongSeriesImage(models.Model):
|
||||
image = models.FileField(upload_to=image_directory_path, storage=image_storage)
|
||||
image = models.FileField(upload_to=image_directory_path)
|
||||
position = models.IntegerField(default=0)
|
||||
series = models.ForeignKey(
|
||||
"LongSeries", related_name="images", on_delete=models.SET_NULL, null=True
|
||||
|
||||
Reference in New Issue
Block a user