日期:2014-05-16 浏览次数:20519 次
onEditComplete : function(ed, value, startValue) {
var me = this,
grid = me.grid,
activeColumn = me.getActiveColumn(),
sm = grid.getSelectionModel(),
record;
if (activeColumn) {
record = me.context.record;
me.setActiveEditor(null);
me.setActiveColumn(null);
me.setActiveRecord(null);
if (!me.validateEdit()) {
return;
}
if (!record.isEqual(value, startValue)) {
record.set(activeColumn.dataIndex, value);
}
if (sm.setCurrentPosition) {
sm.setCurrentPosition(sm.getCurrentPosition());
}
grid.getView().getEl(activeColumn).focus();
me.context.value = value;
me.fireEvent('edit', me, me.context);
}
},