Closed AttilioGreco closed 2 years ago
Maybe a compatibility issue with jQuery versions? I did the following and it solved my issue.
IMAGE_CROPPING_JQUERY_URL = "https://code.jquery.com/jquery-3.6.0.min.js"
I've looked more into this and it isn't related to the Django version. This happens on 2.2.x and 3.2.
This issue appears due to 68ec5af . In 1bd36d2 , the variable is added back but with a blank value.
I'm unclear on the intended installation of v1.6.0 or higher. The README still states
By default the image cropping widget embeds a recent version of jQuery.
but this doesn't appear to be true anymore.
@pmyjavec 's solution does resolve the issue, but that requires the user of the library to specify their own jQuery URL by default. If this is the intention, then this should be documented in the README and it also should probably cause raise a Python error if this value is not specified.
Maybe using the jQuery version vendored with the Django admin would be a good default? I was able to use the jQuery version built in to the admin app by using
IMAGE_CROPPING_JQUERY_URL = STATIC_URL + "admin/js/vendor/jquery/jquery.min.js"
It works fine with Django 2.2.26 and 3.2.11
@agsimmons You are right, the README wasn't up to date. And thanks for tracking the issue down!
We made a new release and followed your idea to use Django's bundled jQuery as default JQUERY_URL
.
@AttilioGreco Can you confirm that the widgets work again if you use the latest version? (1.6.2
)
I have try a fast upgrade in a separated Brach Now is Working with
django-image-cropping-1.6.2
Django-3.2.11
But is conflicting with tabbed admin solved with
IMAGE_CROPPING_JQUERY_URL = None
Hi i'm having same issue using django-image-cropping. Admin is not showing copping box, with django-image-cropping==1.5.0 is working without problem
js console show this error
Regars