Does anyone have experience using ImageKit to manage thumbnails?
I currently have the following in my models.py:
class Item(models.Model):
id = models.AutoField(primary_key=True)
owner = models.ForeignKey(
get_user_model(),
on_delete=models.SET_NULL,
null=True,
blank=True
)
image = ProcessedImageField(
upload_to=image_upload,
blank=True,
validators=[validate_image],
format='JPEG',
help_text="Max file size is 3 MB."
)
image_thumbnail = ImageSpecField(
source='image',
processors=[ResizeToFill(50, 50)],
format='JPEG',
options={'quality': 60}
)
I'd like to rename the thumbnail and store it in a particular folder (not the CACHE/images/ folder that ImageKit defaults to), but can't figure out how to do that (and adding an "upload_to" to the thumbnail gives me an error). All help greatly appreciated! Thank you!