title: In AngularJS how to uncheck a radio button to make all objects become false
body: <p>I have an array with many "contact" objects inside. Only one contact can be the primary contact (primary: true).</p>
  
  <p>I also have a radio button to select which contact is the primary.</p>
  
  <p>Q: How can I make one contact primary and deactivate all of the others (primary: false)? so only one object have the property (primary: true) and the rest false?</p>
  
  <p>My example: <a href="http://plnkr.co/edit/Y3as4SXv2ZGQSF39W8O6?p=preview" rel="nofollow">http://plnkr.co/edit/Y3as4SXv2ZGQSF39W8O6?p=preview</a></p>
  
  <pre><code>.controller('ExampleController', ['$scope',
          function($scope) {
          $scope.addContList = [
              {
                  email: "q@q.com",
                  jobTitle: "clerk",
                  name: "nico2",
                  phone: "1",
                  primary: true
              },
              {
                  email: "a@a.com",
                  jobTitle: "director",
                  name: "david",
                  phone: "1",
                  primary: false
              }
          ];
            $scope.$watch('addContList', function() {
              console.log('changed', JSON.stringify($scope.addContList, null, 2))
            }, true)
  
          }
        ]);
  </code></pre>
  
  <p>Here is the view</p>
  
  <pre><code>&lt;tr ng-repeat="contact in addContList"&gt;
            &lt;td&gt;
              &lt;label class="radio-inline"&gt;
                &lt;input type="radio" value="" name="ui_cont" ng-model="contact.primary" ng-value="true"&gt;
              &lt;/label&gt;
            &lt;/td&gt;
            &lt;td&gt;{{ contact.name }} value = {{contact.primary}} &lt;/td&gt;
            &lt;td&gt;Edit&lt;/td&gt;
            &lt;td&gt;Delete&lt;/td&gt;
          &lt;/tr&gt;
  </code></pre>