I am trying to display an icon in the template field base on what account it is.
In the template field I have the following html:
{{LDC__r.Name}}
Then an inline-snippet :
var params = arguments[0],
$ = skuid.$;
var uaCommod = skuid.model.getModel('UtilityAccount').getFirstRow().Commodity__r.Name;
if(uaCommod === 'Electricity'){
$('#commodIcon').addClass('fa-lightbulb-o');
}else{
$('#commodIcon').addClass('fa-fire');
}
When I load my page, it will show the right icon for a second and then it gets switched to a triangle with exclamation point in the middle. Does anyone has any ideas about what the problem maybe?