I have multiple toggles on a screen and one master toggle. What I want is as soon as I switch on the master toggle, all other toggles are automatically switched on and disabled.
I know I can do something like this:
var toggle =Ext.getCmp('toggleId1');
toggle.setValue(1);
toggle.disable();
where toggleId1 is the id of first toggle.
But I don't want to rewrite this piece of code for every toggle. Instead I wish if I could get hold of all the toggles somehow (maybe by cls) and then switch on all of them.
I tried naming the ids of all the toggles to same name but that does not seem to work (it did not allow me to tap on any toggle which was strange).