import { NgModule, NO_ERRORS_SCHEMA } from '@angular/core';
import { NativeScriptCommonModule } from '@nativescript/angular';
import { NgxsModule } from '@ngxs/store';
import { TNSCheckBoxModule } from '@nstudio/nativescript-checkbox/angular';
import { NativeScriptUIDataFormModule } from 'nativescript-ui-dataform/angular';
import { NativeScriptUIListViewModule } from 'nativescript-ui-listview/angular/listview-directives';
import { EvaluationRoutingModule } from '~/pages/evaluation/evaluation-routing.module';
import { SharedModule } from '~/shared/shared.module';
import { UnitDetailState } from '../unit/state-mgmt/unit-detail.state';
import { EvaluationAnswersComponent } from './components/evaluation-answers/evaluation-answers.component';
import { EvaluationCreateFormComponent } from './components/evaluation-create-form/evaluation-create-form.component';
import { EvaluationCreateComponent } from './components/evaluation-create/evaluation-create.component';
import { EvaluationDetailAnswersComponent } from './components/evaluation-detail-answers/evaluation-detail-answers.component';
import { EvaluationDetailComponent } from './components/evaluation-detail/evaluation-detail.component';
import { EvaluationListComponent } from './components/evaluation-list/evaluation-list.component';
import { EvaluationSearchFormComponent } from './components/evaluation-search-form/evaluation-search-form.component';
import { EvaluationComponent } from './components/evaluation/evaluation.component';
import { EvaluationSubtypesState } from './state-mgmt/evaluation-all-eval-subtypes.state';
import { AnswersIndividualState } from './state-mgmt/evaluation-answers-individual.state';
import { AnswersState } from './state-mgmt/evaluation-answers.state';
import { SearchEvaluationDetailState } from './state-mgmt/evaluation-detail.state';
import { SearchEvaluationListState } from './state-mgmt/evaluation-list.state';
import { EvaluationPermissionState } from './state-mgmt/evaluation-permission.state';
import { SearchEvaluationPersonAllState } from './state-mgmt/evaluation-person-all.state';
import { InsertIndivEvaluationState } from './state-mgmt/evaluation-person-insert.state';
import { UpdateIndivEvaluationState } from './state-mgmt/evaluation-person-update.state';
import { StatesState } from './state-mgmt/evaluation-states.state';
import { YearsCreateState } from './state-mgmt/evaluation-years-create.state';
import { YearsState } from './state-mgmt/evaluation-years.state';

@NgModule({
    imports: [
        NativeScriptCommonModule,
        EvaluationRoutingModule,
        NativeScriptUIDataFormModule,
        TNSCheckBoxModule,
        NativeScriptUIListViewModule,
        SharedModule,
        NgxsModule.forFeature([
            YearsState,
            YearsCreateState,
            StatesState,
            SearchEvaluationListState,
            SearchEvaluationDetailState,
            UnitDetailState,
            SearchEvaluationPersonAllState,
            InsertIndivEvaluationState,
            EvaluationSubtypesState,
            AnswersIndividualState,
            UpdateIndivEvaluationState,
            EvaluationPermissionState,
            AnswersState
        ])
    ],
    declarations: [
        EvaluationComponent,
        EvaluationSearchFormComponent,
        EvaluationListComponent,
        EvaluationDetailComponent,
        EvaluationCreateComponent,
        EvaluationCreateFormComponent,
        EvaluationAnswersComponent,
        EvaluationDetailAnswersComponent
    ],
    schemas: [
        NO_ERRORS_SCHEMA
    ]
})
export class EvaluationModule {
}
