Hi Omri,
Try to move the formatter function next to path inside parts definition. That should fix it.
bindProperty("value", {
parts: [
{path : "tblModel>anotherText",
formatter : function(anotherText) {
if ((anotherText!=null) && (anotherText.trim().length>0)) {
return "X" + anotherText;
} else {
return anotherText;
}
}}
],
// What is wrong with the formatter?
/*formatter : function(anotherText) {
if ((anotherText!=null) && (anotherText.trim().length>0)) {
return "X" + anotherText;
} else {
return anotherText;
}
}*/
Here's the jsbin: http://jsbin.com/gikoxejagidu/1/edit
Regards,
Kimmo