-
☆ A M B ☆
- 24,524 Posts
Looking at what gets put into the modx_site_tmplvar_contentvalues table for such a MIGx TV, it gets this for the image data:
image":"{\n \"sourceImg\": {\n \"src\": \"assets/images/coming/baker.jpg\",\n \"width\": 2197,\n \"height\": 1465,\n \"source\": 1\n },\n \"crop\": {\n \"width\": 250,\n \"height\": 250,\n \"x\": 0,\n \"y\": 0\n },\n \"targetWidth\": 250,\n \"targetHeight\": 250,\n \"altTag\": false\n}"
and MIGx doesn't know what to do with that, it's expecting a simple path.
-
☆ A M B ☆
- 24,524 Posts
Ok, there is some documentation here
https://github.com/alanpich/tvImagePlus/issues/15
I've added a bug report as far as it not rendering properly as an Image+ type TV. Not much point in getting MIGx into the mix until that's fixed. I don't know if it's being actively developed any more, though.
It works great, but it doesn't respect the "media source" set for specific contexts.
When editing the tv under the "media sources" tab I specify a "media source" for different contexts for the imageplus tv.
This doens't work.
This works when I use the default MODX image input type.
Can this be fixed?
I would really appreciate it!
-
☆ A M B ☆
- 24,524 Posts
That's tricky for add-on developers. Technically you're working in the 'mgr' context when you're working in the Manager, while the resources involved are in their own contexts. So you have to be able to get the resource's context's settings, not the current working 'mgr' context. But when displaying the TV value on the front-end, it needs to use the current working context.
-
☆ A M B ☆
- 1,031 Posts
$this->tv->get('source')) contains the current mediasource during editing the resource. The value depends on the context of the resource.
-
☆ A M B ☆
- 24,524 Posts
The MODX repository is still providing a much earlier version for download; it doesn't display properly in Revo 2.3.3