Move dashboard redirect into dashboard routing module

This commit is contained in:
Tom Bloor 2017-08-16 15:54:36 +01:00
parent cec88d1cb5
commit e0c976c8cf
2 changed files with 2 additions and 1 deletions

View file

@ -5,7 +5,6 @@ import { P404Component } from './pages/404.component';
import { P500Component } from './pages/500.component'; import { P500Component } from './pages/500.component';
export const routes: Routes = [ export const routes: Routes = [
{ path: '', redirectTo: '/dashboard', pathMatch: 'full' },
{ path: '404', component: P404Component }, { path: '404', component: P404Component },
{ path: '500', component: P500Component }, { path: '500', component: P500Component },
{ path: '**', redirectTo: '/404' }, { path: '**', redirectTo: '/404' },

View file

@ -1,5 +1,6 @@
import { NgModule } from '@angular/core'; import { NgModule } from '@angular/core';
import { Routes, RouterModule } from '@angular/router'; import { Routes, RouterModule } from '@angular/router';
import { AuthGuard } from '../_guards/auth.guard'; import { AuthGuard } from '../_guards/auth.guard';
import { DashboardComponent } from './dashboard.component'; import { DashboardComponent } from './dashboard.component';
@ -10,6 +11,7 @@ import { AddDataComponent } from './add-data.component';
// Using child path to allow for FullLayout theming // Using child path to allow for FullLayout theming
const routes: Routes = [ const routes: Routes = [
{ path: '', redirectTo: '/dashboard', pathMatch: 'full' },
{ {
path: '', path: '',
component: FullLayoutComponent, component: FullLayoutComponent,