EasyUI Forum

General Category => EasyUI for jQuery => Topic started by: Stefan B. on August 15, 2014, 02:11:56 AM



Title: How to dynamic change of datagrid title
Post by: Stefan B. on August 15, 2014, 02:11:56 AM
I would change a datagrid title dynamic. How can i do this?

The following code is not working:

Code:
$('#cb1').combobox({  
...
   onSelect: function(row) {
consoleLog(row);
var dgPanel = $('#dg').datagrid('getPanel');
dgPanel.panel('options').title = row.text;
    }
});


Title: Re: How to dynamic change of datagrid title
Post by: Stefan B. on August 15, 2014, 02:17:39 AM
I found the solution:

Code:
   var dgPanel = $('#dg').datagrid('getPanel');
  dgPanel.panel('setTitle', row.text);