title: Angular-toggle-switch how to detect change/click?
body: <p>I am a Angular newbee trying to use the Angular-toggle-switch designd by CGARVIS: <a href="http://cgarvis.github.io/angular-toggle-switch" rel="noreferrer">http://cgarvis.github.io/angular-toggle-switch</a>. Unfortunately there is not a lot of documentation and the "normal" Angular option like ng-click etc wont work.</p>
  
  <p>I've managed tot set the initial value of the toggle button based on if a certain value is present in a JSON object:</p>
  
  <pre><code>    &lt;div ng-repeat="agendapunt in aktieveVergadering.Agendapunten | orderBy:'VolgNr'" ng-init="search(agendapunt.AgendapuntCollegelid)"&gt;
          &lt;ul class="list-group"&gt;
              &lt;li class="list-group-item"&gt;
  
                  &lt;table class="table-condensed apunttable"&gt;
                      &lt;tr&gt;
                          &lt;td class="apuntvolgnr"&gt;&lt;span class="badge pull-left"&gt;{{agendapunt.VolgNr}}&lt;/span&gt;&lt;/td&gt;
                          &lt;td class="apuntomschrijving"&gt;{{agendapunt.Omschrijving}}&lt;/td&gt;
                          &lt;td class="apuntkeuze"&gt;&lt;toggle-switch model="Bespreken" on-label="Ja" off-label="Nee"  /&gt;&lt;/td&gt;
                      &lt;/tr&gt;
                  &lt;/table&gt;
              &lt;/li&gt;
          &lt;/ul&gt;
      &lt;/div&gt;
  </code></pre>
  
  <p>The setting of the initial true/false is done by this function:</p>
  
  <pre><code>$scope.search = function (array) {
      this.Bespreken = false;
      for (var i = 0; i &lt; array.length; i++) {
          if (array[i].Volledigenaam == $scope.VolledigeNaam)
              this.Bespreken = true;
              return;
      }
      return;
  };
  </code></pre>
  
  <p>For now this gives me a page with listitems , each with a togglebutton set to the right initial value. BUT:</p>
  
  <p>-How can i detect change ( or click event) of each seperate button?</p>
  
  <p>-Why can't i reference the "Bespreken" value in a Angular way like $scope.Bespreken?</p>
  
  <ul>
  <li>where can i find more info/examples about using the Angular-toggle-switch?</li>
  </ul>