checking for non excisting items of specific like date boolean etc.

Apr 1, 2015 at 7:10 AM
Hi

I am getting the hang of this more and more but there is one thing I would like a simple solution for

I have en existing content type and template and for that I add a new content type of a specific type lets say a boolean. If I do a true false check this will only work for new items because the old items don't have this object and then i get an error, same goes for date checks

Is there an easy way to first check if an element exist for a content item before I do my functionality to check if true false or date?

On another note, A while back I asked for a best case example for a crud application and you mentioned you were working on this, did you get anywhere with this?

thanks china
Apr 1, 2015 at 10:39 AM
So checking for null should usually be done with ?? Example
if(Content.ShowDetails ?? false) { } // will not show if null
crud with angularJS - still working on it :). We're actually working on releasing 2sxc 7.0 - and there will be some minor breaking changes to the JS API, so I must delay the samples till then (otherwise it may not work after an upgrade). Sorry to keep you waiting :(