In my JSP code, I try to use ng-submit on a form.
The problem is that there are many validations for the textboxes of that form which are implemented using ng-disabled in Submit button.
Now if I click enter key on a textbox then those validations will not be implemented and the form will be submitted.
How can I add the conditions here?
The only option I could think is to move all the conditions of ng-disabled to Javascript function.
<form name="customersForm" ng-submit="findCustomers(custName, custCity)">
<button type=submit **ng-disabled="validateInputs(custName,custCity)"**
id="listButton" ng-click="findCustomers(custName,custCity)"><span>Find </span></button>