WEB-639: Refactor redundant boolean comparisons (#3063)
improve improve improve improve
This commit is contained in:
@@ -154,13 +154,13 @@ export class ChargesComponent implements OnInit, AfterViewInit {
|
||||
* To show popover.
|
||||
*/
|
||||
ngAfterViewInit() {
|
||||
if (this.configurationWizardService.showChargesPage === true) {
|
||||
if (this.configurationWizardService.showChargesPage) {
|
||||
setTimeout(() => {
|
||||
this.showPopover(this.templateButtonCreateCharge, this.buttonCreateCharge.nativeElement, 'bottom', true);
|
||||
});
|
||||
}
|
||||
|
||||
if (this.configurationWizardService.showChargesList === true) {
|
||||
if (this.configurationWizardService.showChargesList) {
|
||||
setTimeout(() => {
|
||||
this.showPopover(this.templateChargesTable, this.chargesTable.nativeElement, 'top', true);
|
||||
});
|
||||
|
||||
@@ -130,7 +130,7 @@ export class FixedDepositProductsComponent implements OnInit, AfterViewInit {
|
||||
* To show popover.
|
||||
*/
|
||||
ngAfterViewInit() {
|
||||
if (this.configurationWizardService.showFixedDepositProductsPage === true) {
|
||||
if (this.configurationWizardService.showFixedDepositProductsPage) {
|
||||
setTimeout(() => {
|
||||
this.showPopover(
|
||||
this.templateButtonCreateFixedProduct,
|
||||
@@ -141,7 +141,7 @@ export class FixedDepositProductsComponent implements OnInit, AfterViewInit {
|
||||
});
|
||||
}
|
||||
|
||||
if (this.configurationWizardService.showFixedDepositProductsList === true) {
|
||||
if (this.configurationWizardService.showFixedDepositProductsList) {
|
||||
setTimeout(() => {
|
||||
this.showPopover(this.templateFixedProductsTable, this.fixedProductsTable.nativeElement, 'top', true);
|
||||
});
|
||||
|
||||
@@ -339,7 +339,7 @@ export class EditLoanProductComponent implements OnInit {
|
||||
|
||||
submit() {
|
||||
const loanProduct = this.loanProducts.buildPayload(this.loanProduct, this.itemsByDefault);
|
||||
if (loanProduct['useDueForRepaymentsConfigurations'] === true) {
|
||||
if (loanProduct['useDueForRepaymentsConfigurations']) {
|
||||
loanProduct['dueDaysForRepaymentEvent'] = null;
|
||||
loanProduct['overDueDaysForRepaymentEvent'] = null;
|
||||
}
|
||||
|
||||
@@ -125,7 +125,7 @@ export class LoanProductsComponent implements OnInit, AfterViewInit {
|
||||
* To show popover.
|
||||
*/
|
||||
ngAfterViewInit() {
|
||||
if (this.configurationWizardService.showLoanProductsPage === true) {
|
||||
if (this.configurationWizardService.showLoanProductsPage) {
|
||||
setTimeout(() => {
|
||||
this.showPopover(
|
||||
this.templateButtonCreateLoanProduct,
|
||||
@@ -136,7 +136,7 @@ export class LoanProductsComponent implements OnInit, AfterViewInit {
|
||||
});
|
||||
}
|
||||
|
||||
if (this.configurationWizardService.showLoanProductsList === true) {
|
||||
if (this.configurationWizardService.showLoanProductsList) {
|
||||
setTimeout(() => {
|
||||
this.showPopover(this.templateLoanProductsTable, this.loanProductsTable.nativeElement, 'top', true);
|
||||
});
|
||||
|
||||
@@ -71,32 +71,32 @@ export class ProductsComponent implements AfterViewInit {
|
||||
* To show popover.
|
||||
*/
|
||||
ngAfterViewInit() {
|
||||
if (this.configurationWizardService.showCharges === true) {
|
||||
if (this.configurationWizardService.showCharges) {
|
||||
setTimeout(() => {
|
||||
this.showPopover(this.templateCharges, this.charges.nativeElement, 'bottom', true);
|
||||
});
|
||||
}
|
||||
if (this.configurationWizardService.showLoanProducts === true) {
|
||||
if (this.configurationWizardService.showLoanProducts) {
|
||||
setTimeout(() => {
|
||||
this.showPopover(this.templateLoanProducts, this.loanProducts.nativeElement, 'bottom', true);
|
||||
});
|
||||
}
|
||||
if (this.configurationWizardService.showSavingsProducts === true) {
|
||||
if (this.configurationWizardService.showSavingsProducts) {
|
||||
setTimeout(() => {
|
||||
this.showPopover(this.templateSavingsProducts, this.savingsProducts.nativeElement, 'bottom', true);
|
||||
});
|
||||
}
|
||||
if (this.configurationWizardService.showShareProducts === true) {
|
||||
if (this.configurationWizardService.showShareProducts) {
|
||||
setTimeout(() => {
|
||||
this.showPopover(this.templateShareProducts, this.shareProducts.nativeElement, 'bottom', true);
|
||||
});
|
||||
}
|
||||
if (this.configurationWizardService.showFixedDepositProducts === true) {
|
||||
if (this.configurationWizardService.showFixedDepositProducts) {
|
||||
setTimeout(() => {
|
||||
this.showPopover(this.templateFixedDepositProducts, this.fixedDepositProducts.nativeElement, 'bottom', true);
|
||||
});
|
||||
}
|
||||
if (this.configurationWizardService.showRecurringDepositProducts === true) {
|
||||
if (this.configurationWizardService.showRecurringDepositProducts) {
|
||||
setTimeout(() => {
|
||||
this.showPopover(
|
||||
this.templateRecurringDepositProducts,
|
||||
|
||||
@@ -137,7 +137,7 @@ export class RecurringDepositProductsComponent implements OnInit, AfterViewInit
|
||||
* To show popover.
|
||||
*/
|
||||
ngAfterViewInit() {
|
||||
if (this.configurationWizardService.showRecurringDepositProductsPage === true) {
|
||||
if (this.configurationWizardService.showRecurringDepositProductsPage) {
|
||||
setTimeout(() => {
|
||||
this.showPopover(
|
||||
this.templateButtonCreateRecurringProduct,
|
||||
@@ -148,7 +148,7 @@ export class RecurringDepositProductsComponent implements OnInit, AfterViewInit
|
||||
});
|
||||
}
|
||||
|
||||
if (this.configurationWizardService.showRecurringDepositProductsList === true) {
|
||||
if (this.configurationWizardService.showRecurringDepositProductsList) {
|
||||
setTimeout(() => {
|
||||
this.showPopover(this.templateRecurringProductsTable, this.recurringProductsTable.nativeElement, 'top', true);
|
||||
});
|
||||
|
||||
@@ -104,13 +104,13 @@ export class SavingProductsComponent implements OnInit, AfterViewInit {
|
||||
* To show popover.
|
||||
*/
|
||||
ngAfterViewInit() {
|
||||
if (this.configurationWizardService.showSavingsProductsPage === true) {
|
||||
if (this.configurationWizardService.showSavingsProductsPage) {
|
||||
setTimeout(() => {
|
||||
this.showPopover(this.templateButtonSavingProduct, this.buttonSavingProduct.nativeElement, 'bottom', true);
|
||||
});
|
||||
}
|
||||
|
||||
if (this.configurationWizardService.showSavingsProductsList === true) {
|
||||
if (this.configurationWizardService.showSavingsProductsList) {
|
||||
setTimeout(() => {
|
||||
this.showPopover(this.templateSavingProductTable, this.savingProductTable.nativeElement, 'top', true);
|
||||
});
|
||||
|
||||
@@ -105,7 +105,7 @@ export class ShareProductsComponent implements OnInit, AfterViewInit {
|
||||
* To show popover.
|
||||
*/
|
||||
ngAfterViewInit() {
|
||||
if (this.configurationWizardService.showShareProductsPage === true) {
|
||||
if (this.configurationWizardService.showShareProductsPage) {
|
||||
setTimeout(() => {
|
||||
this.showPopover(
|
||||
this.templateButtonCreateShareProduct,
|
||||
@@ -116,7 +116,7 @@ export class ShareProductsComponent implements OnInit, AfterViewInit {
|
||||
});
|
||||
}
|
||||
|
||||
if (this.configurationWizardService.showShareProductsList === true) {
|
||||
if (this.configurationWizardService.showShareProductsList) {
|
||||
setTimeout(() => {
|
||||
this.showPopover(this.templateShareProductsTable, this.shareProductsTable.nativeElement, 'top', true);
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user