AnsweredAssumed Answered

HTML field contents not showing in ListView

Question asked by derrickoltmann derrickoltmann on Jan 13, 2015
I'm having an issue with URLs and changing the link name to something manageable...

My first attempt was to use a URL field thats default was set to "http://.../{id}"; so it would create the appropriate link. I then used customCode to alter the rather lengthly url to display as "Preview Document." This worked fine for the DetailView, but was unsuccessful for the listview(search), subpanel and dashlet views and the full url continued to be displayed.

My second attempt was to alter the link within the get_list_view_data() function in the modules module.php file, as I have used that to alter other fields in this module. This was successful for the listview(search) and dashlet but still no luck on the subpanel. Oddly enough, the alterations made to other fields in this function do apply properly in the subpanel, just not the url field change.

My third attempt was to just use an HTML field, which should require no alteration of the contents and thus would be better all around. Created HTML field with studio, added the appropriate code to the field, and it works well... in detailview only. The contents of the HTML field are not returned in any other view.

Is there something that must be done to display the content of an HTML field in listview/other views beside detail? I believe this to be the simplest (and therefore best) solution to this, but am open to suggestion.

Sidenote: Sugar is a nice platform, but it seems like every time you turn around there's a big gotcha that really keeps the project from moving forward.

Outcomes