Skip to main content
1 of 2

CSR Coloured Colum

I've created a document library with some folders in it and I have added a new Column "Permission" to this Library. So now I want to color the cell or the entire row when e.g. the value "Owner" appears in this row. For this I found a little JS file:

$(document).ready(function () { colorCellsByStatus(); }); var colorCellsByStatus = function() { $Text = $("td.ms-cellstyle.ms-vb2:contains('Owner')"); $Text.parent().css("background-color", "#01DF3A"); }

So When I put this in a script editor it colors the whole row when the value is inserted. But when i have more rows and I want to filter the library this coloring does not appear. Is there any possibility to rerender or call the script when a filter is created? Many thanks. BR Michael