import { NgModule } from '@angular/core';
import { RouterModule } from '@angular/router';
import { CommonModule, DecimalPipe } from '@angular/common';
import { FormsModule, ReactiveFormsModule } from '@angular/forms';
import { AdminLayoutRoutes } from './admin-layout.routing';
import { DashboardComponent } from '../../dashboard/dashboard.component';
import { UsersAddComponent } from '../../users-add/users-add.component';
import { OrdersComponent } from 'app/orders/orders.component';
import { ConfigurationComponent } from 'app/configuration/configuration.component';
import { UsersDeliveryComponent } from 'app/users-delivery/users-delivery.component';
import { ReportsComponent } from 'app/reports/reports.component';
import { CustomersPrescriptionComponent } from 'app/customers-prescription/customers-prescription.component';
import { InventoryAdjustComponent } from 'app/inventory-adjust/inventory-adjust.component';
import { InventoryBuyComponent } from 'app/inventory-buy/inventory-buy.component';
import { InventoryComponent } from 'app/inventory/inventory.component';
import { InventoryWarehouseComponent } from 'app/inventory-warehouse/inventory-warehouse.component';
import { InventoryMoveComponent } from 'app/inventory-move/inventory-move.component';
import { UsersComponent } from 'app/users/users.component';
import { CatalogCategoryComponent } from 'app/catalog-category/catalog-category.component';
import { CatalogProductsComponent } from 'app/catalog-products/catalog-products.component';
import { TypographyComponent } from '../../typography/typography.component';
import { IconsComponent } from '../../icons/icons.component';
import { MapsComponent } from '../../maps/maps.component';
import { NotificationsComponent } from '../../notifications/notifications.component';
import { UpgradeComponent } from '../../upgrade/upgrade.component';
import { LightboxModule } from 'ngx-lightbox';
import {
  MatButtonModule,
  MatInputModule,
  MatRippleModule,
  MatFormFieldModule,
  MatTooltipModule,
  MatSelectModule,
  MatDatepickerModule,
  MatNativeDateModule,
  MatTabsModule,
  MatCheckboxModule,
  MAT_DATE_LOCALE

} from '@angular/material';
import { SweetAlert2Module } from '@toverux/ngx-sweetalert2';
import { CustomersInvitationsAddComponent } from 'app/customers-invitations-add/customers-invitations-add.component';
import { CustomersPrescriptionPendingComponent } from 'app/customers-prescription-pending/customers-prescription-pending.component';
import { CustomersComponent } from 'app/customers/customers.component';
import { CustomersAddComponent } from 'app/customers-add/customers-add.component';
import { Ng2Rut } from 'ng2-rut';
import { CustomersBalanceComponent } from 'app/customers-balance/customers-balance.component';
import { OrdersAddComponent } from 'app/orders-add/orders-add.component';
import { OrdersPackingComponent } from 'app/orders-packing/orders-packing.component';
import { CatalogProductsAddComponent } from 'app/catalog-products-add/catalog-products-add.component';
import { CatalogCategoryAddComponent } from 'app/catalog-category-add/catalog-category-add.component';
import { InventoryReturnsComponent } from 'app/inventory-returns/inventory-returns.component';
import { InventoryWarehouseAddComponent } from 'app/inventory-warehouse-add/inventory-warehouse-add.component';
import { InventoryBuyAddComponent } from 'app/inventory-buy-add/inventory-buy-add.component';
import { InventoryMoveAddComponent } from 'app/inventory-move-add/inventory-move-add.component';
import { InventoryReturnsAddComponent } from 'app/inventory-returns-add/inventory-returns-add.component';
import { InventoryAdjustAddComponent } from 'app/inventory-adjust-add/inventory-adjust-add.component';
import { UsersMessageComponent } from 'app/users-message/users-message.component';
import { AngularEditorModule } from '@kolkov/angular-editor';

@NgModule({
  imports: [
    CommonModule,
    RouterModule.forChild(AdminLayoutRoutes),
    FormsModule,
    MatButtonModule,
    MatRippleModule,
    MatFormFieldModule,
    MatInputModule,
    MatSelectModule,
    MatTooltipModule,
    MatTabsModule,
    MatDatepickerModule,
    MatNativeDateModule,
    MatCheckboxModule,
    SweetAlert2Module,
    Ng2Rut,
    LightboxModule,
    AngularEditorModule
  ],
  entryComponents: [  CustomersAddComponent, 
                      CustomersInvitationsAddComponent, 
                      CustomersPrescriptionComponent, 
                      CustomersBalanceComponent, 
                      OrdersAddComponent,
                      OrdersPackingComponent,
                      CatalogCategoryAddComponent,
                      CatalogProductsAddComponent,
                      InventoryWarehouseAddComponent,
                      InventoryBuyAddComponent,
                      InventoryMoveAddComponent,
                      InventoryReturnsAddComponent,
                      InventoryAdjustAddComponent,
                      UsersAddComponent,
                      UsersMessageComponent
                   ],
  providers: [DecimalPipe, {provide: MAT_DATE_LOCALE, useValue: 'es-CL'}],
  declarations: [
    DashboardComponent,
    UsersAddComponent,
    OrdersComponent,
    OrdersAddComponent,
    TypographyComponent,
    IconsComponent,
    MapsComponent,
    NotificationsComponent,
    UpgradeComponent,
    UsersComponent,
    CatalogCategoryComponent,
    CustomersAddComponent,
    CatalogProductsComponent,
    CustomersComponent,
    CustomersPrescriptionComponent,
    CustomersBalanceComponent,
    CustomersInvitationsAddComponent,
    UsersDeliveryComponent,
    ReportsComponent,
    ConfigurationComponent,
    CustomersPrescriptionPendingComponent,
    InventoryAdjustComponent,
    InventoryBuyComponent,
    InventoryComponent,
    InventoryWarehouseComponent,
    InventoryMoveComponent,
    OrdersPackingComponent,
    CatalogProductsAddComponent,
    CatalogCategoryAddComponent,
    InventoryReturnsComponent,
    InventoryWarehouseAddComponent,
    InventoryBuyAddComponent,
    InventoryMoveAddComponent,
    InventoryReturnsAddComponent,
    InventoryAdjustAddComponent,
    UsersMessageComponent
  ]
})

export class AdminLayoutModule {}
