How to add "Not set" if value in row is empty
How to add "Not set" if value in row is empty

Hi guys, I can't add a default value for empty data, like "Not set" if empty value in the row
This question has an accepted answers - jump to answer
This discussion has been closed.
Answers
Hi @inajaf ,
Have a look at the
columns.renderdocumentation, I think it should provide what you are looking for.If you can't get it to work, could you please link to a test case. Information on how to create a test case (if you aren't able to link to the page you are working on) is available here.
Thanks,
Sandy
Hi @sandy,
I found the parameter for the default value https://datatables.net/reference/option/columns.defaultContent, but I have some issues for applying it to my current code, I need to add some fields in options that could be empty or null and set the default value: "Not set".
Here is a link to my current js file live.datatables.net/zecewuhi/1/
I need for Example "Additional phone number, Trailer Number" that could be null or empty and set them to "Not Set".
As Sandy said, use
columns.render, see "Ashton Cox" in this example,Colin