mirror of
https://github.com/akveo/ngx-admin.git
synced 2025-12-18 08:20:13 +01:00
feat(sidebar): add menu sidebar updating (#548)
* feat(sidebar): add menu sidebar updating Relates to issue #236 * refactor(sidebar): move menu initialization into app component Also fix BaMenuService provider (move it into module providers from component providers) * refactor(sidebar): move baMenuService to services directory
This commit is contained in:
parent
b78e72dde9
commit
05e17d24df
9 changed files with 42 additions and 19 deletions
|
|
@ -1,10 +1,14 @@
|
|||
import { Routes } from '@angular/router';
|
||||
import './app.loader.ts';
|
||||
import { Component, ViewEncapsulation, ViewContainerRef } from '@angular/core';
|
||||
import { GlobalState } from './global.state';
|
||||
import { BaImageLoaderService, BaThemePreloader, BaThemeSpinner } from './theme/services';
|
||||
import { layoutPaths } from './theme/theme.constants';
|
||||
import { BaThemeConfig } from './theme/theme.config';
|
||||
import { BaMenuService } from './theme';
|
||||
import {ComponentsHelper } from 'ng2-bootstrap';
|
||||
|
||||
import { MENU } from './app.menu';
|
||||
/*
|
||||
* App Component
|
||||
* Top Level Component
|
||||
|
|
@ -28,8 +32,11 @@ export class App {
|
|||
private _imageLoader: BaImageLoaderService,
|
||||
private _spinner: BaThemeSpinner,
|
||||
private _config: BaThemeConfig,
|
||||
private _menuService: BaMenuService,
|
||||
private viewContainerRef: ViewContainerRef) {
|
||||
|
||||
this._menuService.updateMenuByRoutes(<Routes>MENU);
|
||||
|
||||
this._fixModals();
|
||||
|
||||
this._loadImages();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue