import {NgModule} from '@angular/core';
import {CommonModule} from '@angular/common';
import {PartialsModule} from '../../partials/partials.module';
import {CoreModule} from '../../../core/core.module';
import {RouterModule} from '@angular/router';
import {
	MAT_DIALOG_DEFAULT_OPTIONS,
	MatAutocompleteModule,
	MatButtonModule,
	MatCardModule,
	MatCheckboxModule,
	MatDatepickerModule,
	MatDialogModule,
	MatExpansionModule,
	MatFormFieldModule,
	MatIconModule,
	MatInputModule,
	MatMenuModule,
	MatNativeDateModule,
	MatPaginatorModule,
	MatProgressBarModule,
	MatProgressSpinnerModule,
	MatRadioModule,
	MatSelectModule,
	MatSnackBarModule,
	MatSortModule,
	MatTableModule,
	MatTabsModule,
	MatTooltipModule
} from '@angular/material';
import {FormsModule, ReactiveFormsModule} from '@angular/forms';
import {NgxPermissionsModule} from 'ngx-permissions';
import {HttpUtilsService, InterceptService, LayoutUtilsService, TypesUtilsService} from '../../../core/_base/crud';
import {HTTP_INTERCEPTORS} from '@angular/common/http';
import {ActionNotificationComponent, DeleteEntityDialogComponent} from '../../partials/content/crud';
import { EncuestaGeneralComponent } from './encuesta-general/encuesta-general.component';
import { ModalFiltrosEncuestaGeneralComponent } from './encuesta-general/modal-filtros-encuesta-general/modal-filtros-encuesta-general.component';

@NgModule({
  declarations: [EncuestaGeneralComponent, ModalFiltrosEncuestaGeneralComponent],
  imports: [
		CommonModule,
		PartialsModule,
		CoreModule,
		RouterModule.forChild([
			{
				path: 'encuesta-general',
				component: EncuestaGeneralComponent
			},
		]),
		MatButtonModule,
		MatTooltipModule,
		MatFormFieldModule,
		MatInputModule,
		MatSelectModule,
		MatIconModule,
		MatTableModule,
		MatMenuModule,
		MatCheckboxModule,
		MatSortModule,
		MatProgressSpinnerModule,
		MatPaginatorModule,
		FormsModule,
		ReactiveFormsModule,
		MatAutocompleteModule,
		MatRadioModule,
		MatNativeDateModule,
		MatProgressBarModule,
		MatDatepickerModule,
		MatCardModule,
		MatSnackBarModule,
		MatExpansionModule,
		MatTabsModule,
		MatDialogModule,
		NgxPermissionsModule
	],
	providers: [
		InterceptService,
		{
			provide: HTTP_INTERCEPTORS,
			useClass: InterceptService,
			multi: true
		},
		{
			provide: MAT_DIALOG_DEFAULT_OPTIONS,
			useValue: {
				hasBackdrop: true,
				panelClass: 'kt-mat-dialog-container__wrapper',
				height: 'auto',
				width: '900px'
			}
		},
		HttpUtilsService,
		TypesUtilsService,
		LayoutUtilsService,
	],
	entryComponents: [
		DeleteEntityDialogComponent,
		ActionNotificationComponent,
		ModalFiltrosEncuestaGeneralComponent
	]
})

export class EncuestaModule { }
