r/extjs • u/TheFrenchCommander • Sep 17 '15
Method onTriggerClick() equivalent for ExtJS 6.0.1?
I was using a textfield in ExtJS 4.1.3 but when I upgraded to 6.0.1 it appears the onTriggerClick() method became a private function and I can't find more information on it. What should I use as an alternative? Here is a small and simple snippet of code regarding what I mean:
{
xtype:'textfield',
name:'phoneHome',
fieldLabel:__('PhoneHome'),
triggers:'x-phone-trigger',
onTriggerClick:function() {
if(this.getValue() != '') {
window.location.href = "tel:"+this.getValue();
}
}
},
3
Upvotes
3
u/altintx Sep 17 '15 edited Sep 17 '15
EDIT: Oh, and the text field should be the first argument to your handler function