0
我有TreeGrid多列,我使用RowEditing插件来保存数据。当“价格”变化时,我想动态改变“总计”的价值。我做了以下,但它不起作用。 当我看到“Total”对象时,我发现它的值已更改,但在编辑时和更新之前无法在RowEditing插件中看到此内容。ExtJS 4基于另一个Ext.grid.plugin.RowEditing更改单元格值
{
text: 'price',
dataIndex: 'price',
editor: {
xtype: 'textfield',
listeners: {
change: function (field, newValue, oldValue, eOpts) {
var selectedModel = MyTree.getSelectionModel().getSelection()[0];
selectedModel.set('total', 'Total sum is' + field.value);
}
}
}
},
{
text: 'total',
dataIndex: 'total',
editor: {
xtype: 'textfield'
}
}
它不工作太:( – vuzh