Hi ,
I have added 2 buttons in one table column using layout. if the bindproperty for that column is "Approved" than that buttons set to false, if the bindproperty is "Pending" than buttons get visible. i am trying this code
oTable.addColumn(new sap.ui.table.Column({
label: new sap.ui.commons.Label({text: "Status"}),
template: new sap.ui.layout.HorizontalLayout({id:"HL",
content : [
new sap.ui.commons.Button({id:"btn1",
text: "Assign status"
}),
new sap.ui.commons.Label({}),
new sap.ui.commons.Button({id:"btn2",
text : "Deny"
})
]
})
})
).bindProperty("visible","Status",function(oEvent){
var bt = sap.ui.getCore().byId("HL");
// var bt1 = sap.ui.getCore().byId("btn2");
// var bt2 = sap.ui.getCore().byId("btn3");
if (oEvent === "Approved"){
bt.setVisible(false);
}