WEB-639: Refactor redundant boolean comparisons (#3063)
improve improve improve improve
This commit is contained in:
@@ -142,7 +142,7 @@ export class CreateEmployeeComponent implements OnInit, AfterViewInit {
|
||||
locale
|
||||
};
|
||||
this.organizationService.createEmployee(data).subscribe((response: any) => {
|
||||
if (this.configurationWizardService.showEmployeeForm === true) {
|
||||
if (this.configurationWizardService.showEmployeeForm) {
|
||||
this.configurationWizardService.showEmployeeForm = false;
|
||||
this.openDialog();
|
||||
} else {
|
||||
@@ -171,7 +171,7 @@ export class CreateEmployeeComponent implements OnInit, AfterViewInit {
|
||||
* To show popover.
|
||||
*/
|
||||
ngAfterViewInit() {
|
||||
if (this.configurationWizardService.showEmployeeForm === true) {
|
||||
if (this.configurationWizardService.showEmployeeForm) {
|
||||
setTimeout(() => {
|
||||
this.showPopover(this.templateCreateEmployeeForm, this.createEmployeeFormRef.nativeElement, 'right', true);
|
||||
});
|
||||
|
||||
@@ -151,12 +151,12 @@ export class EmployeesComponent implements OnInit, AfterViewInit {
|
||||
* To show popover.
|
||||
*/
|
||||
ngAfterViewInit() {
|
||||
if (this.configurationWizardService.showEmployeeList === true) {
|
||||
if (this.configurationWizardService.showEmployeeList) {
|
||||
setTimeout(() => {
|
||||
this.showPopover(this.templateButtonImportEmployees, this.buttonImportEmployees.nativeElement, 'bottom', true);
|
||||
});
|
||||
}
|
||||
if (this.configurationWizardService.showEmployeeTable === true) {
|
||||
if (this.configurationWizardService.showEmployeeTable) {
|
||||
setTimeout(() => {
|
||||
this.showPopover(this.templateTableEmployees, this.tableEmployees.nativeElement, 'top', true);
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user