I am using CSR against two columns, both of which I need to hide from the list view.
I have used this example to successfully hide one:
function hideFields(ctx)
{
var cell = $("div [name='myField']").closest('th');
var cellIndex = cell[0].cellIndex + 1;
$('td:nth-child(' + cellIndex + ')').hide();
$('th:nth-child(' + cellIndex + ')').hide();
}
but I also need to hide another column and am struggling to do so - I've tried writing a separate function with new variable names but this doesn't work. Can I add a further column into the existing hideFields function ?