-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #212 from ottemo/awk_password-field-bug
[#109488236 deliver] password field rendering bug
- Loading branch information
Showing
3 changed files
with
8 additions
and
31 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,47 +1,23 @@ | ||
<ng-form name="passwordForm" novalidate> | ||
<div class="form-group" | ||
ng-class="{ 'has-error' : passwordForm.password.$invalid && passwordForm.password.$dirty}"> | ||
<label class="control-label"> | ||
Password* | ||
<label class="control-label" for="inp_{{attribute.Attribute}}"> | ||
{{attribute.Label}} | ||
<span ng-show="attribute.IsRequired">*</span> | ||
</label> | ||
|
||
<input type="password" | ||
id="inp_{{attribute.Attribute}}" | ||
class="form-control" | ||
name="password" | ||
ng-model="item.password" | ||
ot-password | ||
required | ||
ng-model="item[attribute.Attribute]" | ||
ng-required="attribute.IsRequired" | ||
autocomplete="off"> | ||
|
||
<div class="help-block" | ||
ng-show="passwordForm.password.$dirty"> | ||
<span ng-show="passwordForm.password.$error.required">This field is required.</span> | ||
<span ng-show="passwordForm.password.$error['ot-password']">{{passwordForm.password.message}}</span> | ||
</div> | ||
</div> | ||
|
||
<div class="form-group" | ||
ng-class="{ 'has-error' : passwordForm.confirm_password.$invalid && passwordForm.confirm_password.$dirty}"> | ||
<label class="control-label"> | ||
Confirm* | ||
</label> | ||
|
||
<!-- NOTE: intentionally not bound to the model, because we send the whole model to the server | ||
and the server will error out if there are any extra fields present --> | ||
<input type="password" | ||
class="form-control" | ||
name="confirm_password" | ||
ng-model="confirm_password" | ||
ot-match="item.password" | ||
required | ||
autocomplete="off"> | ||
|
||
<div class="help-block" | ||
ng-show="passwordForm.$submitted || passwordForm.confirm_password.$dirty"> | ||
<span ng-show="passwordForm.confirm_password.$error.required">This field is required.</span> | ||
<span ng-show="passwordForm.confirm_password.$error.match">The two passwords don't match</span> | ||
</div> | ||
</div> | ||
|
||
</ng-form> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters