mirror of
https://dev.azure.com/hugendubel/ISA/_git/ISA-Frontend
synced 2025-12-28 22:42:11 +01:00
Refacrored layouts to components
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
import { NgModule } from '@angular/core';
|
||||
import { Routes, RouterModule } from '@angular/router';
|
||||
import { DashboardComponent } from './layouts/dashboard/dashboard.component';
|
||||
import { ArticleSearchComponent } from './layouts/article-search/article-search.component';
|
||||
import { DashboardComponent } from './components/dashboard/dashboard.component';
|
||||
import { ArticleSearchComponent } from './components/article-search/article-search.component';
|
||||
|
||||
const routes: Routes = [
|
||||
{path: '', redirectTo: '/dashboard', pathMatch: 'full'},
|
||||
|
||||
@@ -3,8 +3,7 @@ import { NgModule } from '@angular/core';
|
||||
|
||||
import { AppRoutingModule } from './app-routing.module';
|
||||
import { AppComponent } from './app.component';
|
||||
import { LayoutsModule } from './modules/layouts/layouts.module';
|
||||
import { MenuComponent } from './layouts/menu/menu.component';
|
||||
import { ComponentsModule } from './modules/components.module';
|
||||
import { processReducer } from './core/reducers/process.reducer';
|
||||
import { StoreModule } from '@ngrx/store';
|
||||
|
||||
@@ -14,13 +13,12 @@ const rootReducer = {
|
||||
|
||||
@NgModule({
|
||||
declarations: [
|
||||
AppComponent,
|
||||
MenuComponent
|
||||
AppComponent
|
||||
],
|
||||
imports: [
|
||||
BrowserModule,
|
||||
AppRoutingModule,
|
||||
LayoutsModule,
|
||||
ComponentsModule,
|
||||
StoreModule.forRoot(rootReducer)
|
||||
],
|
||||
providers: [],
|
||||
|
||||
36
src/app/modules/components.module.ts
Normal file
36
src/app/modules/components.module.ts
Normal file
@@ -0,0 +1,36 @@
|
||||
import { NgModule } from '@angular/core';
|
||||
import { HeaderComponent } from 'src/app/components/header/header.component';
|
||||
import { ProcessHeaderComponent } from 'src/app/components/process-header/process-header.component';
|
||||
import { ProcessTabComponent } from 'src/app/components/process-tab/process-tab.component';
|
||||
import { CommonModule } from '@angular/common';
|
||||
import { ContentComponent } from 'src/app/components/content/content.component';
|
||||
import { ArticleSearchComponent } from 'src/app/components/article-search/article-search.component';
|
||||
import { DashboardComponent } from 'src/app/components/dashboard/dashboard.component';
|
||||
import { AppRoutingModule } from 'src/app/app-routing.module';
|
||||
import { MenuComponent } from '../components/menu/menu.component';
|
||||
|
||||
@NgModule({
|
||||
declarations: [
|
||||
HeaderComponent,
|
||||
ProcessHeaderComponent,
|
||||
ProcessTabComponent,
|
||||
ContentComponent,
|
||||
ArticleSearchComponent,
|
||||
DashboardComponent,
|
||||
MenuComponent
|
||||
],
|
||||
imports: [
|
||||
CommonModule,
|
||||
AppRoutingModule
|
||||
],
|
||||
exports: [
|
||||
HeaderComponent,
|
||||
ProcessHeaderComponent,
|
||||
ProcessTabComponent,
|
||||
ContentComponent,
|
||||
ArticleSearchComponent,
|
||||
DashboardComponent,
|
||||
MenuComponent
|
||||
]
|
||||
})
|
||||
export class ComponentsModule { }
|
||||
@@ -1,33 +0,0 @@
|
||||
import { NgModule } from '@angular/core';
|
||||
import { HeaderComponent } from 'src/app/layouts/header/header.component';
|
||||
import { ProcessHeaderComponent } from 'src/app/layouts/process-header/process-header.component';
|
||||
import { ProcessTabComponent } from 'src/app/layouts/process-tab/process-tab.component';
|
||||
import { CommonModule } from '@angular/common';
|
||||
import { ContentComponent } from 'src/app/layouts/content/content.component';
|
||||
import { ArticleSearchComponent } from 'src/app/layouts/article-search/article-search.component';
|
||||
import { DashboardComponent } from 'src/app/layouts/dashboard/dashboard.component';
|
||||
import { AppRoutingModule } from 'src/app/app-routing.module';
|
||||
|
||||
@NgModule({
|
||||
declarations: [
|
||||
HeaderComponent,
|
||||
ProcessHeaderComponent,
|
||||
ProcessTabComponent,
|
||||
ContentComponent,
|
||||
ArticleSearchComponent,
|
||||
DashboardComponent
|
||||
],
|
||||
imports: [
|
||||
CommonModule,
|
||||
AppRoutingModule
|
||||
],
|
||||
exports: [
|
||||
HeaderComponent,
|
||||
ProcessHeaderComponent,
|
||||
ProcessTabComponent,
|
||||
ContentComponent,
|
||||
ArticleSearchComponent,
|
||||
DashboardComponent
|
||||
]
|
||||
})
|
||||
export class LayoutsModule { }
|
||||
Reference in New Issue
Block a user