Closed (works as designed)
Project:
DrupalGap
Version:
7.x-1.16
Component:
Mobile Application Development Kit Code
Priority:
Normal
Category:
Support request
Assigned:
Unassigned
Reporter:
Created:
22 Oct 2016 at 02:34 UTC
Updated:
28 Oct 2016 at 16:12 UTC
Jump to comment: Most recent
Comments
Comment #2
billycheuk commentedComment #3
billycheuk commentedNow that I have worked out the other way in which the image field output is now changed to a link, by configuring Views. Views JSON renders a url, which works fine, suggesting not necessarily deploying the Image Link Formatter module.
Still unable to get the link done on the app, having referenced Drupalgap 7 Docs - Views - Displaying Images with links.
Comment #4
tyler.frankenstein commentedWhen using Views JSON it has nothing to do with any other contrib module, as the row_callback function is in charge of displaying the row as you wish. DrupalGap does not having support for the Image Link Formatter module, but I'm open to patches/pull-requests to help.
Comment #5
billycheuk commentedComment #6
billycheuk commentedHi there
Could the row_callback function calls and displays a viewspage other than a node (nid or uid), given that a viewspage is not a node (so having no nid)?
Sampling the http://tylerfrankenstein.com/code/build-mobile-app-sell-products-with-dr...
In my case, I wanted the listed fields (an image field) of a views (configured in ViewsJSON) to link (when clicked) to other views corresponding to the fields. In the default display (configured in Views), it works quite well while the field can rewrite and output to a url so that it can be linked (when clicked) to the other Views' url.
In other words, how could the row_callback function calls a custom module (which is actually a viewspage)?
Comment #7
tyler.frankenstein commentedIf I understand correctly, in your
row_callback, I think you could do something like this:Comment #8
billycheuk commentedHi Tyler
Thank you for your reply but so sorry to bother you again as I still don't know how to merge the codes.
What I wish is:
View A ->
image field 1 -> View B
image field 2 -> View C
image field 3 -> View D
image field 4 -> View E
In Views JSON of View A, I now rewrite and output a variable (exactly names of View B, View C, View D, View E) intended as path name to link (onclick) to the corresponding views.
Comment #9
billycheuk commentedI think I now get it done:
where link is the exact name of the the other view as a path variable.
Thanks Tyler for reminding me of the path variable.
Comment #10
tyler.frankenstein commentedNo problem, thank you for reporting back.