title: How to set required field to not required in angular controller after the form passed to controller
body: <p>I have set <code>ng-required="valid"</code> to <code>true</code> in controller and In html after passing  form from the click event (ex :saveData(form)) in the <code>saveData()</code> method based on condition i set <code>$scope.valid= false</code> and need to check the <code>form.$valid</code>.</p>
  
  <p>However setting <code>$scope.valid = false</code>, does not modify the form <code>ng-required</code> attributes i have settled to  <code>true</code> initially.</p>
  
  <pre><code>&lt;form name="customForm" noValidate&gt;
      &lt;input type="text" ng-required="valid"/&gt;
      &lt;button ng-click ="saveData(customForm)"&gt;&lt;/button&gt;
  &lt;/form&gt;
  </code></pre>
  
  <h2>in Controller</h2>
  
  <pre><code>$scope.valid = true;
  
  $scope.saveData = function(form){
    $scope.valid = false;
    if(form.$valid){
     // ng-required values set to false and take action
    }
  }
  </code></pre>