Merge remote-tracking branch 'origin/master'
This commit is contained in:
commit
b8c4efc9ad
2 changed files with 1 additions and 22 deletions
|
|
@ -3,15 +3,6 @@
|
||||||
|
|
||||||
<h3>Modifier</h3>
|
<h3>Modifier</h3>
|
||||||
|
|
||||||
<!-- divider -->
|
|
||||||
<br><mat-divider></mat-divider><br>
|
|
||||||
|
|
||||||
<!-- nickname -->
|
|
||||||
<mat-form-field appearance="fill">
|
|
||||||
<mat-label>Pseudo</mat-label>
|
|
||||||
<input matInput type="text" [(ngModel)]="personCopy.nickname" required>
|
|
||||||
</mat-form-field><br>
|
|
||||||
|
|
||||||
<!-- divider -->
|
<!-- divider -->
|
||||||
<mat-divider></mat-divider><br>
|
<mat-divider></mat-divider><br>
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -87,19 +87,7 @@ export class PopupUpdatePersonAdminComponent implements OnInit
|
||||||
// Check les champs saisis par l'utilisateur
|
// Check les champs saisis par l'utilisateur
|
||||||
checkField(): void
|
checkField(): void
|
||||||
{
|
{
|
||||||
if(this.personCopy.nickname.length === 0) {
|
if((this.changePassword) && (this.newPassword.length === 0)) {
|
||||||
this.errorMessage = "Veuillez remplir le champ 'pseudo'" ;
|
|
||||||
this.hasError = true;
|
|
||||||
}
|
|
||||||
else if(this.personCopy.email.length === 0) {
|
|
||||||
this.errorMessage = "Veuillez remplir le champ 'email'" ;
|
|
||||||
this.hasError = true;
|
|
||||||
}
|
|
||||||
else if(!this.checkEmailService.isValidEmail(this.personCopy.email)) {
|
|
||||||
this.errorMessage = "Email invalide" ;
|
|
||||||
this.hasError = true;
|
|
||||||
}
|
|
||||||
else if((this.changePassword) && (this.newPassword.length === 0)) {
|
|
||||||
this.errorMessage = "Veuillez remplir le champ 'mot de passe'";
|
this.errorMessage = "Veuillez remplir le champ 'mot de passe'";
|
||||||
this.hasError = true;
|
this.hasError = true;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue