I wrote a small app based on the example (below) from sapui5.hana.ondemand.com.
My question pertains to anyone else that has data binding working and has tried to do something like the text in red.
When stringing together "variables" like the ones highlighted in below ... if I do something similar all I get on the screen is the actual text, ie {Width} instead of the value that should replace that. If I get rid of the extra text and just have the variable in " " I get the correct value displayed for the "variable"
Anyone else ran across this?
-Mike
var header = new sap.m.ObjectHeader({
title : "{Name}",
number : "{Price}",
numberUnit : "{CurrencyCode}",
statuses : [
new sap.m.ObjectStatus({
text : "Some Damaged",
state : "Error"
}),
new sap.m.ObjectStatus({
text : "In Stock",
state : "Success"
})
],
attributes : [
new sap.m.ObjectAttribute({
text : "{WeightMeasure} {WeightUnit}"
}),
new sap.m.ObjectAttribute({
text : "{Width} x {Depth} X {Height} {DimUnit}"
}),
new sap.m.ObjectAttribute({
text : "{Description}"
}),
new sap.m.ObjectAttribute({
text : "www.sap.com",
active : true,
press : function () {
sap.m.URLHelper.redirect("http://www.sap.com", true);
}
})
]
});