import { Component, AfterViewInit, OnInit } from '@angular/core'; import { Router } from '@angular/router'; import { ApplicationService } from '../services/application.service'; import {AddUser} from '../model/add-user.interface'; import {UserType} from '../model/db-tables'; import {PasswordValidation} from '../components/shared/password-validation'; declare var jQuery: any; @Component({ templateUrl: '../components/add-user.component.html' }) export class AddUserComponent implements AfterViewInit, OnInit { adduser: AddUser = { userName: '', password: '', emailId: '', confirmPassword: '', firstName: '', lastName: '', accountNumber: '', userType: '', productEdition: '' } constructor(private application: ApplicationService, private router: Router) { } ngAfterViewInit(): void { this.initializeUIElements(); } initializeUIElements(): void { } ngOnInit(): void { /*if (this.application.currentUser == null) { this.router.navigate(['/login']); }*/ } showAlert(id: string): void { jQuery('#' + id).modal('show'); } //addUser(model: AddUser, isValid: boolean) { // // call API to save customer // console.log(model, isValid); //} }