import { NgModule } from '@angular/core';
import { CommonModule } from '@angular/common';
import { FormsModule } from '@angular/forms';
import { Routes, RouterModule } from '@angular/router';

import { IonicModule } from '@ionic/angular';

import { MowadhafiPage } from './mowadhafi.page';
import { HmgCommonModule } from '../hmg-common/hmg-common.module';
import {MyRequestComponent} from './my-request/my-request.component';
import {HRRequestComponent} from './hr-request/hr-request.component';
import {RequestDetailsComponent} from'./request-details/request-details.component';
import {HrRequestFormComponent} from './hr-request-form/hr-request-form.component';

const routes: Routes = [
  {
    path: '',
    component: MowadhafiPage,
    children:[{
      path: 'my-request',
      component: MyRequestComponent
    },
    {
      path: 'hr-request',
      component: HRRequestComponent
    },
    {
      path: 'request-details',
      component: RequestDetailsComponent
    },
    {
    path: 'hr-request-form',
    component: HrRequestFormComponent
  }
    
    
  ]
  }
];

@NgModule({
  imports: [
    HmgCommonModule,
    CommonModule,
    FormsModule,
    IonicModule,
    RouterModule.forChild(routes)
  ],
  declarations: [MowadhafiPage,MyRequestComponent,HRRequestComponent
    ,RequestDetailsComponent,HrRequestFormComponent]
})
export class MowadhafiPageModule {}
