import { CommonModule } from '@angular/common';
import { NgModule } from '@angular/core';
import { FormsModule, ReactiveFormsModule } from '@angular/forms';
import { AppCommonModule } from '@app/shared/common/app-common.module';
import { UtilsModule } from '@shared/utils/utils.module';
import { FileUploadModule } from 'ng2-file-upload';
import { ModalModule, PopoverModule, TabsModule, TooltipModule, BsDropdownModule, TimepickerModule } from 'ngx-bootstrap';
import { TimePickerModule } from '@progress/kendo-angular-dateinputs';
import { BsDatepickerModule, BsDatepickerConfig, BsDaterangepickerConfig, BsLocaleService } from 'ngx-bootstrap/datepicker';
import { AutoCompleteModule } from 'primeng/autocomplete';
import { EditorModule} from 'primeng/editor';
import { FileUploadModule as PrimeNgFileUploadModule } from 'primeng/fileupload';
import { InputMaskModule } from 'primeng/inputmask';
import { PaginatorModule } from 'primeng/paginator';
import { TableModule } from 'primeng/table';
import { TreeModule } from 'primeng/tree';
import { DragDropModule } from 'primeng/dragdrop';
import { TreeDragDropService } from 'primeng/api';
import { ContextMenuModule } from 'primeng/contextmenu';
import { NgxChartsModule } from '@swimlane/ngx-charts';
import { CountoModule } from 'angular2-counto';
import { TextMaskModule } from 'angular2-text-mask';
import { ImageCropperModule } from 'ngx-image-cropper';
import { AngularFontAwesomeModule } from 'angular-font-awesome';
import { NgxBootstrapDatePickerConfigService } from 'assets/ngx-bootstrap/ngx-bootstrap-datepicker-config.service';
import { SprintShipRoutingModule } from './sprintship-routing.module';
import { OrderStatusTypeComponent } from './order-management/order-status-types/order-status-type.component';
import { CreateOrderStatuTypeModalComponent } from './order-management/order-status-types/create-order-status-types-modal.component';
import { UpdateOrderStatuTypeModalComponent } from './order-management/order-status-types/update-order-status-types-modal.component';
import { TagTypeComponent } from './order-management/tag-types/tag-type.component';
import { CreateTagTypeModalComponent } from './order-management/tag-types/create-tag-types-modal.component';
import { UpdateTagTypeModalComponent } from './order-management/tag-types/update-tag-types-modal.component';
import { OrderComponent } from './order-management/orders/order.component';
import { FleetsComponent } from './fleet-management/fleet/fleets.component';
import { CreateFleetModalComponent } from './fleet-management/fleet/create-fleet-modal.component';
import { EditFleetModalComponent } from './fleet-management/fleet/edit-fleet-modal.component';
import { VehiclesComponent } from './fleet-management/vehicle/vehicles.component';
import { CreateVehicleModalComponent } from './fleet-management/vehicle/create-vehicle-modal.component';
import { EditVehicleModalComponent } from './fleet-management/vehicle/edit-vehicle-modal.component';
import { ContactComponent } from './contact-management/contacts/contacts.component';
import { CreateContactModalComponent } from './contact-management/contacts/create-contact-modal.component';
import { EditContactModalComponent } from './contact-management/contacts/edit-contact-modal.component';
import { AddressTypeComponent } from './contact-management/address-types/address-types.component';
import { CreateAddressTypeModalComponent } from './contact-management/address-types/create-address-type-modal.component';
import { UpdateAddressTypeModalComponent } from './contact-management/address-types/edit-address-type-modal.component';
import { TimeZonesComponent } from './location-management/timezones/timezones.component';
import { CreateTimeZoneModalComponent } from './location-management/timezones/create-timezones-modal.component';
import { EditTimeZoneModalComponent } from './location-management/timezones/edit-timezones-modal.component';
import { ProximityComponent } from './location-management/proximity/proximity.component';
import { CreateProximityModalComponent } from './location-management/proximity/create-proximity-modal.component';
import { EditProximityModalComponent } from './location-management/proximity/edit-proximity-modal.component';
import { LocationsComponent } from './location-management/locations/location.component';
import { CreateLocationModalComponent } from './location-management/locations/create-location-modal.component';
import { CreateUpdateLocationComponent } from './location-management/locations/create-update-location.component';
import { EditLocationComponent } from './location-management/locations/edit-location.component';
import { EditLocationModalComponent } from './location-management/locations/edit-location-modal.component';
import { VehicleLocationComponent } from './location-management/vehicle-location/vehicle-location.component';
import { CreateVehicleLocationModalComponent } from './location-management/vehicle-location/create-vehicle-location-modal.component';
import { EditVehicleLocationModalComponent } from './location-management/vehicle-location/edit-vehicle-location-modal.component';
import { UserLocationComponent } from './location-management/user-location/user-location.component';
import { CreateUserLocationModalComponent } from './location-management/user-location/create-user-location-modal.component';
import { EditUserLocationModalComponent } from './location-management/user-location/edit-user-location-modal.component';
import { IncidentComponent } from './incident/incident.component';
import { CreateIncidentModalComponent } from './incident/create-incident-modal.component';
import { EditIncidentModalComponent } from './incident/edit-incident-modal.component';
import { ViewIncidentImageModalComponent } from './incident/view-incident-image-modal.component';
import { CreateOrderModalComponent } from './order-management/orders/create-order-modal.component';
import { RoutesComponent } from './routes/routes.component';
import { CreateRouteModalComponent } from './routes/create-routes-modal.component';
import { EditRouteModalComponent } from './routes/edit-routes-modal.component';
import { RoutesTemplateComponent } from './routes-template/routestemplate.component';
import { RouteTemplateTypesComponent } from './route-template-types/route-template-types.component';
import { CreateRouteTemplateTypeModalComponent } from './route-template-types/create-route-template-types-modal.component';
import { EditRouteTemplateTypeModalComponent } from './route-template-types/edit-route-template-types-modal.component';
import { CreateOrEditRoutesTemplateModalComponent } from './routes-template/create-or-edit-routestemplate-modal.component';
import { PackageTypeComponent } from './package-management/package-types/package-type.component';
import { CreatePackageTypeModalComponent } from './package-management/package-types/create-packagetype-modal.component';
import { UpdatePackageTypeModalComponent } from './package-management/package-types/update-packagetype-modal.component';
import { TimeSheetComponent } from './employees/timesheets/timesheet.component';
import { CreateOrEditTimeSheetModalComponent } from './employees/timesheets/create-or-edit-timesheet.component';
import { EmployeeReviewComponent } from './employees/reviews/employee-review.component';
import { DriverIncidentsComponent } from './employees/driver-incident/driver-incidents.component';
import { CreateOrEditDriverIncidentModalComponent } from './employees/driver-incident/create-or-edit-driver-incident.component';
import { CreateOrEditEmployeeReviewModalComponent } from './employees/reviews/create-or-edit-review.component';
import { AddressComponent } from './contact-management/addresses/address.component';
import { CreateAddressModalComponent } from './contact-management/addresses/create-address-modal.component';
import { UpdateAddressModalComponent } from './contact-management/addresses/edit-address-modal.component';
import { EmailComponent } from './contact-management/emails/email.component';
import { CreateEmailModalComponent } from './contact-management/emails/create-email-modal.component';
import { DriversComponent } from './fleet-management/drivers/drivers.component';
import { TagComponent } from './order-management/tags/tag.component';
import { CreateTagModalComponent } from './order-management/tags/create-tag-modal.component';
import { UpdateTagModalComponent } from './order-management/tags/update-tag-modal.component';
import { OrderPackageComponent } from './order-management/order-package/order-package.component';
import { CreateOrderPackageModalComponent } from './order-management/order-package/create-order-package-modal.component';
import { UpdateOrderPackageModalComponent } from './order-management/order-package/update-order-package-modal.component';
import { OrderStatusComponent } from './order-management/order-status/order-status.component';
import { CreateOrderStatusComponent } from './order-management/order-status/create-order-status.component';
import { VendorsComponent } from './vendor-management/vendors/vendors.component';
import { CreateDriverComponent } from './fleet-management/drivers/create-driver.component';
import { EditDriverComponent } from './fleet-management/drivers/edit-driver.component';
import { UpdateOrderComponent } from './order-management/orders/update-order.component';
import { CreateOrderComponent } from './order-management/orders/create-order.component';
import { CreateVendorComponent } from './vendor-management/vendors/create-vendor.component';
import { EditVendorComponent } from './vendor-management/vendors/edit-vendor.component';
import { AddressFormComponent } from '@app/shared/layout/form/address-form.component';
import { CreateContactComponent } from './contact-management/contacts/create-contact.component';
import { EditContactComponent } from './contact-management/contacts/edit-contact.component';
import { ContactFormComponent } from '@app/shared/layout/form/contact.form.component';
import { PostalCodesComponent } from './contact-management/postal-codes/postal-codes.component';
import { CreatePostalCodesModalComponent } from './contact-management/postal-codes/create-postal-codes-modal.component';
import { EditPostalCodesModalComponent } from './contact-management/postal-codes/edit-postal-codes-modal.component';
import { CRoutesComponent } from './controller/routes/croutes.component';
import { RouteDetailComponent } from './controller/route-detail/route-detail.component';
import { KPIBoxComponent } from './controller/kpi-box/kpi-box.component';
import { TableComponents } from './core-components/table-details.component';
import { LocatorTabComponent } from './controller/locator/locator.component';
import { AppConsts } from '@shared/AppConsts';
import { FlyOutComponent } from '@app/shared/layout/flyout/flyout.component';
import { MapComponent } from '@app/shared/layout/map/map.component';
import { MapFlyOutComponent } from '@app/shared/layout/flyout/map/map-flyout.component';
import { TableRoutesComponents } from './controller/routes/table-routes-details.component';
import { AgmCoreModule } from '@agm/core';
import { DevicesComponent } from './controller/devices/devices.component';
import { StatusComponent } from './controller/status/status.component';
import { CheckBoxComponent } from './core-components/checkbox/checkbox.component';
import { DriverListTabComponent } from './controller/drivers/driver-list.component';

@NgModule({
    imports: [
        FormsModule,
        ReactiveFormsModule,
        CommonModule,
        FileUploadModule,
        ModalModule.forRoot(),
        TabsModule.forRoot(),
        TooltipModule.forRoot(),
        PopoverModule.forRoot(),
        BsDropdownModule.forRoot(),
        BsDatepickerModule.forRoot(),
        TimepickerModule.forRoot(),
        TimePickerModule,
        UtilsModule,
        AppCommonModule,
        TableModule,
        TreeModule,
        DragDropModule,
        ContextMenuModule,
        PaginatorModule,
        PrimeNgFileUploadModule,
        AutoCompleteModule,
        EditorModule,
        InputMaskModule,
        NgxChartsModule,
        CountoModule,
        TextMaskModule,
        ImageCropperModule,
        SprintShipRoutingModule,
        AngularFontAwesomeModule,
        AgmCoreModule.forRoot({
          // please get your own API key here:
          // https://developers.google.com/maps/documentation/javascript/get-api-key?hl=en
          apiKey: 'AIzaSyDS2kFDBSQClK7PEB8p9gy23KBtP2_MLtE'
        })
    ],
    declarations: [
        OrderStatusTypeComponent,
        CreateOrderStatuTypeModalComponent,
        UpdateOrderStatuTypeModalComponent,
        TagTypeComponent,
        CreateTagTypeModalComponent,
        UpdateTagTypeModalComponent,
        OrderComponent,
        TagComponent,
        CreateTagModalComponent,
        UpdateTagModalComponent,
        CreateOrderModalComponent,
        UpdateOrderComponent,
        CreateOrderComponent,
        OrderPackageComponent,
        CreateOrderPackageModalComponent,
        UpdateOrderPackageModalComponent,
        OrderStatusComponent,
        CreateOrderStatusComponent,
        FleetsComponent,
        CreateFleetModalComponent,
        EditFleetModalComponent,
        DriversComponent,
        CreateDriverComponent,
        EditDriverComponent,
        VendorsComponent,
        CreateVendorComponent,
        EditVendorComponent,
        VehiclesComponent,
        CreateVehicleModalComponent,
        EditVehicleModalComponent,
        RoutesComponent,
        CreateRouteModalComponent,
        EditRouteModalComponent,
        RoutesTemplateComponent,
        RouteTemplateTypesComponent,
        CreateRouteTemplateTypeModalComponent,
        EditRouteTemplateTypeModalComponent,
        CreateOrEditRoutesTemplateModalComponent,
        EditContactModalComponent,
        CreateUpdateLocationComponent,
        EditLocationComponent,
        ContactComponent,
        CreateContactModalComponent,
        CreateContactComponent,
        EditContactComponent,
        AddressTypeComponent,
        CreateAddressTypeModalComponent,
        UpdateAddressTypeModalComponent,
        TimeZonesComponent,
        CreateTimeZoneModalComponent,
        EditTimeZoneModalComponent,
        ProximityComponent,
        EditProximityModalComponent,
        CreateProximityModalComponent,
        LocationsComponent,
        CreateLocationModalComponent,
        EditLocationModalComponent,
        VehicleLocationComponent,
        CreateVehicleLocationModalComponent,
        EditVehicleLocationModalComponent,
        UserLocationComponent,
        CreateUserLocationModalComponent,
        EditUserLocationModalComponent,
        IncidentComponent,
        CreateIncidentModalComponent,
        EditIncidentModalComponent,
        ViewIncidentImageModalComponent,
        PackageTypeComponent,
        CreatePackageTypeModalComponent,
        UpdatePackageTypeModalComponent,
        TimeSheetComponent,
        CreateOrEditTimeSheetModalComponent,
        EmployeeReviewComponent,
        CreateOrEditEmployeeReviewModalComponent,
        DriverIncidentsComponent,
        CreateOrEditDriverIncidentModalComponent,
        AddressComponent,
        CreateAddressModalComponent,
        UpdateAddressModalComponent,
        EmailComponent,
        CreateEmailModalComponent,
        AddressFormComponent,
        ContactFormComponent,
        PostalCodesComponent,
        CreatePostalCodesModalComponent,
        EditPostalCodesModalComponent,
        CRoutesComponent,
        KPIBoxComponent,
        TableComponents,
        LocatorTabComponent,
        MapComponent,
        RouteDetailComponent,
        MapFlyOutComponent,
        TableRoutesComponents,
        DevicesComponent,
        StatusComponent,
        CheckBoxComponent,
        DriverListTabComponent
    ],
    exports: [
    ],
    providers: [
        TreeDragDropService,
        { provide: BsDatepickerConfig, useFactory: NgxBootstrapDatePickerConfigService.getDatepickerConfig },
        { provide: BsDaterangepickerConfig, useFactory: NgxBootstrapDatePickerConfigService.getDaterangepickerConfig },
        { provide: BsLocaleService, useFactory: NgxBootstrapDatePickerConfigService.getDatepickerLocale }
    ]
})
export class SprintShipModule { }
