Hi All,
I am facing problem while showing suggested values to sap.m.input control. Here is my logic
View
<Input id="ddlCustomer" type="Text"
placeholder="Enter Customer ..."
showSuggestion="true"
StartSuggestion="3"
suggest="handleSuggest_Customer"
suggestionItems="{/Customers}">
<suggestionItems>
<core:Item
key="{CustomerId}"
text="{parts:[{path: 'CustomerId' },{path: 'Name' }],
formatter: 'sap.ui.demo.myFiori.util.Formatter.CustomerInfo'}"
/>
</suggestionItems>
</Input>
Formatter Function
CustomerInfo : function(val1, val2) {
debugger;
if (val1 != "undefined" && val2 != "undefined") {
// return val2 + " | " + val1;
return val1;
}
Controller