Hello All,
I'm trying to make an ObjectStatus item clickable. It seems to me that this should be easily done as there is a property to ObjectStatus of 'active' and the documentation says of it..."[this] Indicates if the ObjectStatus text and icon can be clicked/tapped by the user."
However, I've tried many ways to get this to work and it doesn't. I can do the same to ObjectAttribute and it works, but not ObjectStatus. Below is my code.
Note: The 'active' in the attributes is for illustration only. Also, you may ask if I can use something other than ObjectList. If you have a recommendation, please let me know. I'm using the Object List because of the nice 'favorite' ObjectMarker that I can easily employ.
_accountArea: function(sItemPath) {
var masterList = this.getView().byId("masterList");
var that = this;
var itemTemplate = new sap.m.ObjectListItem({
title: "{fullName}",
type: "Active",
press: [this.GoToDetail, this],
showMarkers: true,
firstStatus: new sap.m.ObjectStatus({
text: "{MainAddress/phone}",
this doesn't work-> active: true,
icon: "sap-icon://call",
press: that.handleTelPress
}),
secondStatus: new sap.m.ObjectStatus({
text: "{MainAddress/email}",
this doesn't work-> active: "true",
icon: "sap-icon://email",
press: that.handleEmailPress
}),
attributes: [new sap.m.ObjectAttribute({
text: "{roleDescription}",
this works -> active: true,
press: that.handleTelPress
}), new sap.m.ObjectAttribute({
text: "{MainAddress/street}"
}), new sap.m.ObjectAttribute({
text: "{MainAddress/city},
{MainAddress/regionID}
{MainAddress/postcode}"
})
],
markers: [new sap.m.ObjectMarker({
type: {
path: "favorite",
formatter: that.formatter.favorite
}
})]
});
}
Here is what it looks like. The Attribute is clickable (Sold-To Party), the Status is not (telephone and email).

Thanks for any insight, I really appreciate it. When you work on this stuff alone, sometimes the obvious is not so obvious.
Greg