-
Notifications
You must be signed in to change notification settings - Fork 2.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cannot add image to Grid in 8.12 #9982
Comments
Can reproduce, seems to be an issue not only on upgraded projects but also on new ones. |
Can reproduce! Existential error on a new project. Problems got to do with the focalPoint: |
I've just noticed this as well 😱 We'll look into it! |
As a workaround for now, you can update the function updateControlValue(selectedImage) {
// const doGetThumbnail = $scope.control.value.focalPoint !== selectedImage.focalPoint
// || $scope.control.value.image !== selectedImage.image;
// we could apply selectedImage directly to $scope.control.value,
// but this allows excluding fields in future if needed
$scope.control.value = {
focalPoint: selectedImage.focalPoint,
coordinates: selectedImage.coordinates,
id: selectedImage.id,
udi: selectedImage.udi,
image: selectedImage.image,
caption: selectedImage.caption,
altText: selectedImage.altText
};
// if (doGetThumbnail) {
$scope.thumbnailUrl = getThumbnailUrl();
//}
} This method was added in @nathanwoulfe 's PR https://github.com/umbraco/Umbraco-CMS/pull/9681/files#diff-16bf5e50f31cc4c3ef3f2af6bf0a399b98e5e2e926e793184cffdc9d0f0ecbcdR105 I don't know how this was supposed to work, since |
@nul800sebastiaan PR to fix is in #9987 - shouldn't have been attempting to access control values until they'd been set. |
That was fast @nathanwoulfe! Thanks! Will have a look tomorrow! |
Fixed in #9987 for the upcoming 8.12.2. |
Thanks for the prompt fix, looking forward to 8.12.2 |
After upgrading a site from 8.11.1 to 8.12, I can no longer add an image to a Grid editor using the standard "Image" grid control.
Umbraco version
Reproduction
Specifics
After selecting an image, another infinity editor opens "Edit selected media".
Clicking Submit causes a JS error in
umbraco.controllers.js
function updateControlValue(selectedImage)
on line 18732 in 8.12.1:Error: "$scope.control.value is null"
Steps to reproduce
Image
controlExpected result
Image added to the grid
Actual result
Image isn't selected, I can only "Close" the dialog
The text was updated successfully, but these errors were encountered: