import { AddAttachComponent } from './add-attach/add-attach.component';
import { ConfirmAddEitComponent } from './confirm-add-eit/confirm-add-eit.component';
import { AddEitComponent } from './add-eit/add-eit.component';
import { HmgCommonModule } from 'src/app/hmg-common/hmg-common.module';
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 { EITPage } from './eit.page';
import { HomeComponent } from './home/home.component';
import { EitListComponent } from './eit-list/eit-list.component';
import { DatePicker } from '@ionic-native/date-picker/ngx';
import { WorkListAttachViewComponent } from '../notification/work-list-attach-view/work-list-attach-view.component';
import { EitUpdateListComponent } from './eit-update-list/eit-update-list.component';


const routes: Routes = [
  {
    path: '',
    component: EITPage,
    children: [
      {
        path: 'homepage',
        component: HomeComponent
      },
      {
        path: 'eit-list',
        component: EitListComponent
      },
      {
        path: 'add-eit',
        component: AddEitComponent
      },
      {
        path: 'confirm-add-eit',
        component: ConfirmAddEitComponent
      },
      {
        path: 'add-attach',
        component: AddAttachComponent
      },
      {
        path: 'eit-update-list',
        component: EitUpdateListComponent
      }
    ]
  }
];

@NgModule({
  imports: [
    CommonModule,
    FormsModule,
    IonicModule,
    HmgCommonModule,
    RouterModule.forChild(routes)
  ],
  declarations: [
    EITPage,
    HomeComponent,
    EitListComponent,
    AddEitComponent,
    ConfirmAddEitComponent,
    AddAttachComponent,
    EitUpdateListComponent
  ],
  entryComponents: [
    WorkListAttachViewComponent
  ],
  providers: [
    DatePicker
  ]
})
export class EITPageModule { }
