Skip to Content
0
Sep 20, 2012 at 09:45 PM

Bug report data binding DropDownBox v1.6.3

18 Views

Hello. I don't know where to report bugs other than here so I apologize if this is the wrong place to do it.

In SAPUI5 version 1.6.3 with eclipse Juno the code example for data binding DropDownBox does not work. In fact no data binding works for DropDownBox in this version of SAPUI5. In version 1.4.2 it works flawlessly so it seems like a regression to me.

Could someone in the development team please take a look?

Example code as in documentation:

// Create JSON data model
jQuery.sap.require("sap.ui.model.json.JSONModel");
var oModel = new sap.ui.model.json.JSONModel();
oModel.setData({
hardware:[
{device:"PC", enabled:true}],
editable: true,
tooltip: "Device"});
sap.ui.getCore().setModel(oModel);

// Create a DropdownBox
var oDropdownBox3 = new sap.ui.commons.DropdownBox("DropdownBox3");
oDropdownBox3.bindProperty("tooltip", "tooltip");
oDropdownBox3.bindProperty("editable", "editable");
oDropdownBox3.setModel(oModel);
var oItemTemplate1 = new sap.ui.core.ListItem();
oItemTemplate1.bindProperty("text", "device");
oItemTemplate1.bindProperty("enabled", "enabled");
oDropdownBox3.bindItems("hardware", oItemTemplate1);

// Attach the DropdownBox to the page
oDropdownBox3.placeAt("sample3");

Problem is that the data does not get bound and the dropdown box is empty. Again please note this only concerns version 1.6.3

Cheers

Martin