var busyDialog1 = new sap.m.BusyDialog('busy1',{text:'i am soo busy doing stuff', title: 'Busy'})
var data = [ {fname : "indrajith" , lname : ""},
{fname : "fred" , lname : ""},
{fname : "den" , lname : ""},
{fname : "foo" , lname : ""},
{fname : "red" , lname : ""},
]
var oModel = sap.ui.model.json.JSONModel();
oModel.setData(data)
var oTable = new sap.m.Table({
columns: [
new sap.m.Column({
header : new sap.m.Label({
text : "First Name"
})
}),
new sap.m.Column({
header : new sap.m.Label({
text : "Last Name"
})
})
],
});
oTable.setModel(oModel)
oTable.bindAggregation("items", {
path: "/",
template: new sap.m.ColumnListItem({
cells: [new sap.m.Text({ text: "{fname}" }),
new sap.m.Button({
text : "Open the dialog",
press : function(e)
{
var id = e.getSource().sId;
var index = id.substr(-1);
console.log(index)
var oDialog = new sap.m.Dialog();
var oText = new sap.m.Input({value: ""});
oDialog.addContent(oText);
oDialog.addContent(new sap.m.Button({text : "OK",
press : function()
{
/*
var m = oTable.getModel();
var data = m.getData();
var val = oText.getValue();
data[index].fname =...
Please Whitelist JSFiddle in your content blocker.
Help keep JSFiddle free for always by one of two ways:
Whitelist JSFiddle in your content blocker (two clicks)
Go PRO and get access to additional PRO features →
Join the 4+ million users, and keep the JSFiddle dream alive.
Ad-free
All ads in the editor and listing pages are turned completely off.
Use pre-released features
You get to try and use features (like the Palette Color Generator) months before everyone else.
Fiddle collections
Sort and categorize your Fiddles into multiple collections.
Private collections and fiddles
You can make as many Private Fiddles, and Private Collections as you wish!
Console
Debug your Fiddle with a minimal built-in JavaScript console.