src/app/modules/profile/profile.routing.module.ts
import { RouterModule, Routes } from '@angular/router';
import { NgModule } from '@angular/core';
import { ProfileComponent } from './profile.component';
import { ProfileHomeComponent } from './home/home';
import { ProfileBupComponent } from './bup/bup';
import { ProfileRupComponent } from './rup/rup';
import { ProfileTrajectoryComponent } from './trajectory/trajectory';
import { ProfileMarksComponent } from './marks/marks';
import { ProfileRecordBookComponent } from './recordBook/recordBook';
import { ProfileStipendComponent } from './stipend/stipend';
import { ProfileContractsComponent } from './contracts/contracts';
import { ProfileOrdersComponent } from './orders/orders';
import { ProfileContractsSimpleComponent } from './contracts.simple/contracts';
import { ProfileContractsDetailComponent } from './contracts.detail/contracts';
const PROFILE_ROUTES: Routes = [
{
path: '', component: ProfileComponent,
children: [
{path: '', redirectTo: 'home'},
{path: 'home', component: ProfileHomeComponent},
{path: 'bup', component: ProfileBupComponent},
{path: 'rup', component: ProfileRupComponent},
{path: 'trajectory', component: ProfileTrajectoryComponent},
{path: 'marksold', component: ProfileMarksComponent},
{path: 'marks', component: ProfileRecordBookComponent},
{path: 'stipend', component: ProfileStipendComponent},
{path: 'contractsold', component: ProfileContractsComponent},
{path: 'contracts', component: ProfileContractsSimpleComponent},
{path: 'contracts/:id', component: ProfileContractsDetailComponent},
{path: 'orders', component: ProfileOrdersComponent},
]
},
];
@NgModule({
imports: [
RouterModule.forChild(PROFILE_ROUTES)
],
exports: [RouterModule]
})
export class ProfileRoutingModule {
}