Tuesday, August 18, 2020

Checkbox Click Event Sencha Ext JS

{

                        xtype: 'checkboxfield',

                        boxLabel: 'All Municipal',

                        name: 'AllMunicipal',

                        margin: '0 0 0 0',

                        listeners: {

                              change: function (checkbox, newVal, oldVal) {

                                  if (newVal == '1' && oldVal == '0') {

                                      var allCheckBoxes = checkbox.up('checkboxgroup').items.items;

                                      for (var i = 0; i < allCheckBoxes.length; i++) {

                                          allCheckBoxes[i].setValue('1');

                                      }

                                  }

                              }

                          }

                    }

 

 

https://forum.sencha.com/forum/showthread.php?137463-Checkbox-Click-Event

 



No comments: