question about Child rows field visualization
question about Child rows field visualization
Gargiucn
Posts: 109Questions: 30Answers: 0
I'm working with the example:
https://datatables.net/examples/api/row_details.html.
I should display an array field that comes from a mjoin relationship:
{
data: "tags",
render: "[, ].tag_descr"
},
I would like to know how to display the tags field correctly in the function:
/* Formatting function for row details - modify as you need */
function format ( d ) {
// `d` is the original data object for the row
return '<table cellpadding="5" cellspacing="0" border="0" style="padding-left:50px;">'+
'<tr>'+
'<td>List of tags:</td>'+
'<td>'+d.<<<tags>>>+'</td>'+
'</tr>'+
'</table>';
}
to get the same view I get with render.
Thanks for your help,
Giuseppe
This question has an accepted answers - jump to answer
This discussion has been closed.
Answers
Maybe the Javascript join() method would work.
Kevin
I tried with:
inserendolo nella funzione:
I tried to get a result similar to what I used to view pdf files attached and this works great:
but I always get the same result...
[object Object],[object Object],[object Object]
Giuseppe
will give you the comma / space separated string.
Allan
OK! modified just a little for my function works perfectly!
Thanks for your help,
Giuseppe