Hello, khoomy!
Please look to the attached patch for 7.x-1.x-dev which is a new version of the module. Here are the major changes:
- Added "rotate images" permission to limit access to the feature.
- Added possibility to rotate images in user profiles including Profile2 module image fields.
- Added support to any field names not only 'field_image'
- Rotated images are renamed by adding _r[number] suffix and therefore no need to flush image cache and clear caches.
- hook_entity_update and hook_entity_insert are replaced with hook_entity_presave.
Hope the patch is good enough to include in the module.
| Comment | File | Size | Author |
|---|---|---|---|
| #6 | new-features.patch | 14.72 KB | khoomy |
| #5 | update-1-2.patch | 31.96 KB | martynov |
| update-1-1.patch | 28.98 KB | martynov |
Comments
Comment #2
martynov commentedComment #3
martynov commentedComment #4
khoomy commentedHi martynov
Thanks for your contribution with some extra features. I tried to patch but found some issues as:
While creating new node and before saving if we upload image and rotate it always rotates 180 degree but this can be fixed if use existing condition in javascript file as
But when we save node then it does not update image with proper rotated value.
If we rotate image in existing node then it works fine but still need existing condition as mentioned above.
Please look your code again and provide proper patch with above fix, I will apply path in new version and will definitely give you credits in commit :)
Good work
Khoomy
Comment #5
martynov commentedHello, Khoomy!
I corrected the mentioned issue and added the README.txt file in the new patch. Please take a look.
Comment #6
khoomy commentedHi martynov
We have only one issue left that while creating node, if upload image and rotate image to 90 degree then after save image was actually rotated to 180 degree instead of 90
Thanks
Khoomy
Comment #7
martynov commentedThis is probably a browser cache issue. I cannot reproduce it. In my local environment the module rotates images on new nodes correctly. Please, check the javascript aggregation and caching settings, refresh your browser with F5 and repeat the whole operation.
Comment #8
martynov commentedHi Khoomy!
Did you see my previous post? I am looking forward for your reply.
Comment #10
khoomy commentedHi martynov
New release 7.x-2.0 has been committed and live now
https://www.drupal.org/project/simple_image_rotate
Your work much appreciated :)
Thanks
Khoomy
Comment #12
martynov commentedThanks for reply and new release!
Comment #13
khoomy commented