Update regexp pour le mot de passe
This commit is contained in:
@@ -41,7 +41,7 @@
|
|||||||
<input matInput type="password" formControlName="password"
|
<input matInput type="password" formControlName="password"
|
||||||
[ngClass]="{ 'is-invalid': submitted && formCtrls.password.errors }" tabindex="5" />
|
[ngClass]="{ 'is-invalid': submitted && formCtrls.password.errors }" tabindex="5" />
|
||||||
<mat-error *ngIf="formCtrls.password.hasError('required')">Password is required</mat-error>
|
<mat-error *ngIf="formCtrls.password.hasError('required')">Password is required</mat-error>
|
||||||
<mat-error *ngIf="formCtrls.password.hasError('pattern')">The pattern of the password ([A-Za-z0-9_-]
|
<mat-error *ngIf="formCtrls.password.hasError('pattern')">The pattern of the password ([A-Za-z0-9_-|/]
|
||||||
{{ '{' }}8,15{{ '}' }})</mat-error>
|
{{ '{' }}8,15{{ '}' }})</mat-error>
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
</p>
|
</p>
|
||||||
|
|||||||
@@ -37,7 +37,7 @@ export class CreateUserComponent implements OnInit {
|
|||||||
username: ["", [Validators.required, Validators.minLength(3)]],
|
username: ["", [Validators.required, Validators.minLength(3)]],
|
||||||
password: [
|
password: [
|
||||||
"",
|
"",
|
||||||
[Validators.required, Validators.pattern("^[A-Za-z0-9_-]{8,15}$")]
|
[Validators.required, Validators.pattern("^[A-Za-z0-9_-|/]{8,15}$")]
|
||||||
],
|
],
|
||||||
firstname: ["", [Validators.required, Validators.minLength(3)]],
|
firstname: ["", [Validators.required, Validators.minLength(3)]],
|
||||||
lastname: ["", [Validators.required, Validators.minLength(3)]],
|
lastname: ["", [Validators.required, Validators.minLength(3)]],
|
||||||
|
|||||||
Reference in New Issue
Block a user