1
Good morning. I have been trying for a while to validate my form, disabling the Button
when it is invalid. I have tried several ways, including searching here and following as it was said. But it has not worked yet.
<button type="button" class="btn btn-primary" ng-disabled="!myForm.timeUpdateModel" data-ng-click="salvar();">Pesquisar</button>
I’ve tried using timeUpdateModel.$invalid
, timeUpdateModel.$pristine
, I tried to get the name of input
timeUpdate.$invalid
and yet none of them work. Someone can help me?
hello, try myForm. $invalid and put ng-required="true" in your input if you don’t have.
– FelipeM
@Felipem o ng-required ja tem no input. I tried to use the way Oce said. However it still didn’t work :(
– Aleff Rodrigues