prevent invalid entity create form submission using enter key

This commit is contained in:
alecmerdler 2017-06-23 15:12:52 -07:00
parent 606222f32e
commit 74ebf2a94b

View file

@ -29,7 +29,7 @@
ng-if="entity"></div>
</div>
<div class="modal-body" ng-show="view == 'enterName'">
<form name="enterNameForm" ng-submit="createEntity()">
<form name="enterNameForm" ng-submit="enterNameForm.$valid && createEntity()">
<label>Provide a name for your new {{ entityTitle }}:</label>
<input type="text" class="form-control" ng-model="entityName" ng-pattern="entityNameRegexObj" required>
<div class="help-text">