I’m using PURE from BeeBole for filling some HTML templates with JSON, everything works perfect except that I can’t find how to pass a default value when a missing property, and I wanted to do this from this side since from the server there is nothing I can do. So for example I have this JSON object:
var example = {records: [ {id: ‘1’, name: ‘Bill’, nick: ‘B’}, {id: ‘2’, name: ‘Amy’} ]}
When I render this in a table, on the directive when I ask for ‘nick’ I get ‘B’ for the first and nothing for the second, but for this case I would like to set a default value such as ‘-‘ when the property is not found.
Is this possible?
Thank you
A bit late on this one.
If you want to show the
nickin aSPAN, it should look something like:instead of:
You would probably get a quicker answer on the forum