shannah / xataface

Framework for building data-driven web applications in PHP and MySQL
http://xataface.com
GNU General Public License v2.0
138 stars 58 forks source link

Bug on render_cell function in related list view #100

Open Pierrick-R opened 6 years ago

Pierrick-R commented 6 years ago

there is a bug on the render_cell function for the related list view.

Let's take an example

function Field2_link__renderCell( &$record ){

 if ($record->strval('Field2_link')) return  '<a href='.$record->strval('Field2_link').' target="_blank"> Link </a>';

 }

If I go to the list view => Field2 display is correct this means "Link" appears and works (since I put noLinkFromListView=1 in the fields.ini)

If I access the same table (the one which includes "Field2"), but as related list view => Field2 display is no longer correct its appears with the "[...]", this means "Link[...]"

when I clic on "Link" => the hyperlink works when I clic on [...] => it displays the complete hyperlink


To fix the bug => fix the handling of the $fulltext variable around this line https://github.com/shannah/xataface/blob/768eac8f8be472a9632972bc288a7e5d99cb652a/Dataface/RelatedList.php#L546

Thanks