import { NgModule } from '@angular/core';
import { Routes, RouterModule } from '@angular/router';
import { ProbeTabPageComponent } from './probe-tab-page.component';
import { ProbeListPageComponent } from '@app/pages/probes/probe/probe-list-page.component';
import { ProbeDetailPageComponent } from '@app/pages/probes/probe/probe-detail-page.component';
import { ProbeDownloadPageComponent } from '@app/pages/probes/download/download-page.component';
import { NoAuthProbeListPageComponent } from '@app/pages/probes/noauth-probe/noauth-probe-list-page.component';
import { NoAuthProbeDetailPageComponent } from '@app/pages/probes/noauth-probe/noauth-probe-detail-page.component';

const routes: Routes = [
  {
    path: '',
    component: ProbeTabPageComponent,
    children: [
      { path: 'list', component: ProbeListPageComponent },
      { path: 'noauth', component: NoAuthProbeListPageComponent },
      { path: 'noauth/:id', component: NoAuthProbeDetailPageComponent },
      { path: 'download', component: ProbeDownloadPageComponent },
      { path: 'download/:idx', component: ProbeDownloadPageComponent },
      { path: ':id/info', component: ProbeDetailPageComponent },
      { path: ':probeID/target', loadChildren: '@app/pages/targets/target-page.module#TargetPageModule' },
      // { path: ':id/target/:id/info', loadChildren: '@app/pages/targets/target-page.module#TargetPageModule' },
      { path: ':id/history', component: null },
    ]
  },
];

// D:\project\overFlow\member_webapp\src\app\pages\targets\target-page.module.ts

@NgModule({
  imports: [RouterModule.forChild(routes)],
  exports: [RouterModule]
})
export class ProbeTabPageRoutingModule { }
