Hy, I have a variable bound to my scope,
$scope.isSuccess = {
invalidPhone : false
}
And I am using a span to display a message when the variable gets true ...
<form name = "myForm">
<span ng-if="isSuccess.invalidPhone && myForm.$submitted">
Please enter valid phone no.
</span>
</form>
Now I am calling a Js method when the form gets submitted..which validates the phone number and set
$scope.isSuccess.invalidPhone = true
Only if it is incorrect.
Now I want to reset the value of this variable to false when my span gets executed. How to do it ? Thank you