PDA

View Full Version : Itemselector - override onAddbuttonClick



hieu79vn
29 Jul 2012, 1:38 PM
Hi

Do you know how can I override the onAddButtonClick in itemselector?

Thank you

scottmartin
29 Jul 2012, 9:53 PM
You should be able to call it as such:



Ext.override(Ext.ux.form.ItemSelector, {
// add you override code to function
onAddBtnClick : function() {
var me = this,
selected = me.getSelections(me.fromField.boundList);

me.moveRec(true, selected);
me.toField.boundList.getSelectionModel().select(selected);
}

});


Scott.

hieu79vn
31 Jul 2012, 12:29 AM
Thank you Scott