You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
21 lines
798 B
21 lines
798 B
import { NgModule } from '@angular/core'; |
|
import { RouterModule, Routes } from '@angular/router'; |
|
import { AuthGuard } from './auth.guard'; |
|
import { LoginComponent } from './pages/login/login.component'; |
|
import { NavigationComponent } from './system-management/navigation/navigation.component'; |
|
|
|
const routes: Routes = [ |
|
{ path: '', redirectTo: '/login', pathMatch: 'full' }, |
|
{ path: 'login', component: LoginComponent, }, |
|
{ |
|
path: '', component: NavigationComponent, canActivate: [AuthGuard], children: [ |
|
{ path: 'system', loadChildren: () => import('./system-management/system-management.module').then(m => m.SystemManagementModule) } |
|
] |
|
}//系统管理 |
|
]; |
|
|
|
@NgModule({ |
|
imports: [RouterModule.forRoot(routes)], |
|
exports: [RouterModule] |
|
}) |
|
export class AppRoutingModule { }
|
|
|