|
@@ -1,10 +1,61 @@
|
|
|
-import { Component } from '@angular/core';
|
|
|
+import { Component, OnInit } from '@angular/core';
|
|
|
+import { ActivatedRoute } from '@angular/router';
|
|
|
+import { ComponentBase } from '@core/base/common-base';
|
|
|
+import { takeUntil } from 'rxjs';
|
|
|
+import { BaseForm } from '@core/base/base-form';
|
|
|
+import {
|
|
|
+ FormGroup,
|
|
|
+ UntypedFormControl,
|
|
|
+ UntypedFormGroup,
|
|
|
+ Validators,
|
|
|
+} from '@angular/forms';
|
|
|
|
|
|
@Component({
|
|
|
selector: 'app-signup-employee',
|
|
|
templateUrl: './signup-employee.component.html',
|
|
|
- styleUrls: ['./signup-employee.component.scss']
|
|
|
+ styleUrls: ['./signup-employee.component.scss'],
|
|
|
})
|
|
|
-export class SignupEmployeeComponent {
|
|
|
+export class SignupEmployeeComponent
|
|
|
+ extends ComponentBase
|
|
|
+ implements OnInit, BaseForm
|
|
|
+{
|
|
|
+ form!: FormGroup;
|
|
|
|
|
|
+ constructor(private readonly route: ActivatedRoute) {
|
|
|
+ super();
|
|
|
+ }
|
|
|
+
|
|
|
+ ngOnInit(): void {
|
|
|
+ this.initForm();
|
|
|
+ this.route.queryParams.pipe(takeUntil(this.destroy$)).subscribe((res) => {
|
|
|
+ console.log(res);
|
|
|
+ });
|
|
|
+ }
|
|
|
+
|
|
|
+ initForm(): void {
|
|
|
+ this.form = new UntypedFormGroup({
|
|
|
+ firstName: new UntypedFormControl(null, [Validators.required]),
|
|
|
+ lastName: new UntypedFormControl(null, [Validators.required]),
|
|
|
+ email: new UntypedFormControl(null, [
|
|
|
+ Validators.required,
|
|
|
+ Validators.email,
|
|
|
+ ]),
|
|
|
+ phoneNumber: new UntypedFormControl(null, [Validators.required]),
|
|
|
+ linkedInLink: new UntypedFormControl(null, [Validators.required]),
|
|
|
+ userType: new UntypedFormControl(null, [Validators.required]),
|
|
|
+ userName: new UntypedFormControl(null, [Validators.required]),
|
|
|
+ password: new UntypedFormControl(null, [Validators.required]),
|
|
|
+ favoriteName: new UntypedFormControl(null, [Validators.required]),
|
|
|
+ passportNumber: new UntypedFormControl(null, [Validators.required]),
|
|
|
+ qualificationId: new UntypedFormControl(null, [Validators.required]),
|
|
|
+ universityId: new UntypedFormControl(null, [Validators.required]),
|
|
|
+ jobTitleId: new UntypedFormControl(null, [Validators.required]),
|
|
|
+ industryId: new UntypedFormControl(null, [Validators.required]),
|
|
|
+ countryId: new UntypedFormControl(null, [Validators.required]),
|
|
|
+ taxNumber: new UntypedFormControl(null, [Validators.required]),
|
|
|
+ incomeTaxValue: new UntypedFormControl(null, Validators.required),
|
|
|
+ });
|
|
|
+ }
|
|
|
+
|
|
|
+ onSubmit(): void {}
|
|
|
}
|