import {NgModule} from "@angular/core";
import {RouterModule, Routes} from "@angular/router";
import {ConfirmExitGuard} from "@webbpm/base-package";
import {RolesGuard} from "./guard/RolesGuard";

const appRoutes: Routes = [
  {
    path: 'milregistration',
    loadChildren: 'generated-sources/page-milregistration.module#PagemilregistrationModule',
    canActivate: [ConfirmExitGuard, RolesGuard],
  },
  {
    path: 'appeals',
    loadChildren: 'generated-sources/page-appeals.module#PageappealsModule',
    canActivate: [ConfirmExitGuard, RolesGuard],
  },
  {
    path: 'ratings',
    loadChildren: 'generated-sources/page-ratings.module#PageratingsModule',
    canActivate: [ConfirmExitGuard, RolesGuard],
  },
  {
    path: 'recruitment',
    loadChildren: 'generated-sources/page-recruitment.module#PagerecruitmentModule',
    canActivate: [ConfirmExitGuard, RolesGuard],
  },
  {
    path: 'notregistered',
    loadChildren: 'generated-sources/page-notregistered.module#PagenotregisteredModule',
    canActivate: [ConfirmExitGuard, RolesGuard],
  },
  {
    path: 'citizen',
    loadChildren: 'generated-sources/page-citizen.module#PagecitizenModule',
    canActivate: [ConfirmExitGuard, RolesGuard],
  },
  {
    path: 'citizencard/:id',
    loadChildren: 'generated-sources/page-citizencard.module#PagecitizencardModule',
    canActivate: [ConfirmExitGuard, RolesGuard],
  },
  {
    path: 'main',
    loadChildren: 'generated-sources/page-main.module#PagemainModule',
    canActivate: [ConfirmExitGuard, RolesGuard]
  },
  {
    path: 'total_registered_second',
    loadChildren: 'generated-sources/page-total_registered_second.module#Pagetotal_registered_secondModule',
    canActivate: [ConfirmExitGuard, RolesGuard]
  }
];

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

}
