Fix account form submit on enter.

This commit is contained in:
Alexis Lahouze 2017-07-04 21:53:32 +02:00
parent a3e9ba02ac
commit fe2355a405

View File

@ -19,8 +19,8 @@
<h3 class="modal-title" id="modal-title">{{ $ctrl.title() }}</h3> <h3 class="modal-title" id="modal-title">{{ $ctrl.title() }}</h3>
</div> </div>
<form class="form-horizontal simple-form" novalidate ng-submit="$ctrl.ok()">
<div class="modal-body" id="modal-body"> <div class="modal-body" id="modal-body">
<form class="form-horizontal simple-form" novalidate>
<div class="form-group" ng-class="{ 'has-error' : form.name.$invalid && !form.name.$pristine }"> <div class="form-group" ng-class="{ 'has-error' : form.name.$invalid && !form.name.$pristine }">
<label class="col-sm-4 control-label" for="name">Account name</label> <label class="col-sm-4 control-label" for="name">Account name</label>
<div class="col-sm-8"> <div class="col-sm-8">
@ -53,14 +53,12 @@
</div> </div>
</div> </div>
</div> </div>
</form>
</div> </div>
<div class="modal-footer"> <div class="modal-footer">
<button class="btn btn-primary" type="button" ng-click="$ctrl.ok()"> <input class="btn btn-primary" type="submit" ng-click="$ctrl.ok()"/>
OK
</button>
<button class="btn btn-default" type="button" ng-click="$ctrl.cancel()"> <button class="btn btn-default" type="button" ng-click="$ctrl.cancel()">
Annuler Annuler
</button> </button>
</div> </div>
</form>