update du code
This commit is contained in:
@@ -1,15 +1,39 @@
|
||||
import { Component, OnInit } from '@angular/core';
|
||||
import { FormBuilder, FormGroup, Validators, ValidatorFn, ValidationErrors, AbstractControl } from '@angular/forms';
|
||||
import { Router } from '@angular/router';
|
||||
import { BackendService } from '../../../../services/backend/backend.service';
|
||||
import { ToastrService } from 'ngx-toastr';
|
||||
|
||||
@Component({
|
||||
selector: 'app-parametres',
|
||||
templateUrl: './parametres.component.html',
|
||||
styleUrls: ['./parametres.component.css']
|
||||
selector: 'app-parametres',
|
||||
templateUrl: './parametres.component.html',
|
||||
styleUrls: ['./parametres.component.css']
|
||||
})
|
||||
export class ParametresComponent implements OnInit {
|
||||
paramsFG:FormGroup;
|
||||
submitted:boolean=false;
|
||||
Pw:number = 10;
|
||||
|
||||
constructor() { }
|
||||
constructor(private fb:FormBuilder,
|
||||
private bs:BackendService,
|
||||
private router:Router,
|
||||
private toast:ToastrService) { }
|
||||
|
||||
ngOnInit(): void {
|
||||
}
|
||||
ngOnInit(): void {
|
||||
this.paramsFG=this.fb.group({
|
||||
pin:["", [
|
||||
Validators.required,
|
||||
Validators.pattern('(?=\\D*\\d)(?=[^a-z])(?=[^A-Z]*[A-Z]).{' + this.Pw + '}')
|
||||
]],
|
||||
num_accepted:["", [
|
||||
Validators.required,
|
||||
Validators.pattern('(?=\\D*\\d)(?=[^a-z])(?=[^A-Z]*[A-Z]).{' + this.Pw + '}'),
|
||||
]],
|
||||
});
|
||||
}
|
||||
|
||||
onUpdate(): void {
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user