From 332a74b4e80d806b5eebdb34538e7d7ca73aa674 Mon Sep 17 00:00:00 2001 From: Nicola Lanzilotto Date: Tue, 3 Oct 2023 15:01:32 +0200 Subject: [PATCH] Fixes the bug: "Knowledge Base" menu item does not change background when active --- .../settings-sidebar.component.ts | 20 +++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) diff --git a/src/app/components/settings-sidebar/settings-sidebar.component.ts b/src/app/components/settings-sidebar/settings-sidebar.component.ts index ee568382e807..cbdc2c4cefc8 100755 --- a/src/app/components/settings-sidebar/settings-sidebar.component.ts +++ b/src/app/components/settings-sidebar/settings-sidebar.component.ts @@ -545,18 +545,22 @@ export class SettingsSidebarComponent implements OnInit { if (this.route.indexOf('/hours') !== -1) { this.OPERATING_HOURS_ROUTE_IS_ACTIVE = true - this.logger.log( - '[SETTING-SIDEBAR] - OPERATING_HOURS_ROUTE_IS_ACTIVE ', - this.OPERATING_HOURS_ROUTE_IS_ACTIVE, - ) + this.logger.log('[SETTING-SIDEBAR] - OPERATING_HOURS_ROUTE_IS_ACTIVE ',this.OPERATING_HOURS_ROUTE_IS_ACTIVE) } else { this.OPERATING_HOURS_ROUTE_IS_ACTIVE = false - this.logger.log( - '[SETTING-SIDEBAR] - OPERATING_HOURS_ROUTE_IS_ACTIVE ', - this.OPERATING_HOURS_ROUTE_IS_ACTIVE, - ) + this.logger.log('[SETTING-SIDEBAR] - OPERATING_HOURS_ROUTE_IS_ACTIVE ',this.OPERATING_HOURS_ROUTE_IS_ACTIVE) } + if (this.route.indexOf('/knowledge-bases') !== -1) { + this.KNOWLEDGE_BASES_ROUTE_IS_ACTIVE = true + this.logger.log('[SETTING-SIDEBAR] - KNOWLEDGE_BASES_ROUTE_IS_ACTIVE ',this.KNOWLEDGE_BASES_ROUTE_IS_ACTIVE) + } else { + this.KNOWLEDGE_BASES_ROUTE_IS_ACTIVE = false + this.logger.log('[SETTING-SIDEBAR] - KNOWLEDGE_BASES_ROUTE_IS_ACTIVE ',this.KNOWLEDGE_BASES_ROUTE_IS_ACTIVE) + } + + + if (this.route.indexOf('/project-settings/') !== -1) { this.PROJECT_SETTINGS_ROUTE_IS_ACTIVE = true this.logger.log(