title: Angularjs getting the button value
body: <p>I need to get the button <code>id</code> value using angularjs.I have written the code but i am getting the value as <code>"undefined"</code>.So please suggest me the code which i need to use.</p>
  
  <p>My code is:</p>
  
  <pre><code> &lt;button type="button"  class="btn btn-primary ole" data-toggle="tooltip"  id="buttonvalue" name="rdoResult"  value="SUN" ng-click="addvalue()"  ng-model="testDate23"  data-placement="left" data-original-title="this is a left tooltip"&gt;
        SUN
  &lt;/button&gt;
  
  &lt;button type="button"  ng-value="2"  class="btn btn-primary ole two" data-toggle="tooltip"  ng-click="addvalue()" 
   ng-model="testDate23" value="MON"  id="buttonvalue" data-placement="top" data-original-title="this is a top tooltip"&gt;
        MON
  &lt;/button&gt;
  </code></pre>
  
  <p>Script code:</p>
  
  <pre><code>$scope.addvalue = function() {
      var datevaluee=$scope.testDate23;
  }
  </code></pre>