fuse-angular/src/app/app.module.ts

94 lines
3.1 KiB
TypeScript
Raw Normal View History

2017-07-12 14:34:32 +00:00
import { NgModule } from '@angular/core';
2017-07-15 15:03:40 +00:00
import { BrowserModule } from '@angular/platform-browser';
import { HttpModule } from '@angular/http';
2017-07-15 15:03:40 +00:00
import { HttpClientModule } from '@angular/common/http';
2017-07-12 14:34:32 +00:00
import { BrowserAnimationsModule } from '@angular/platform-browser/animations';
import { RouterModule, Routes } from '@angular/router';
import { InMemoryWebApiModule } from 'angular-in-memory-web-api';
2017-07-15 15:03:40 +00:00
import 'hammerjs';
2017-07-12 12:35:07 +00:00
import { SharedModule } from './core/modules/shared.module';
import { AppComponent } from './app.component';
import { ProjectModule } from './main/content/apps/dashboards/project/project.module';
2017-07-18 16:34:12 +00:00
import { FuseFakeDbService } from './fuse-fake-db/fuse-fake-db.service';
import { FuseMainModule } from './main/main.module';
2017-08-02 08:53:30 +00:00
import { PagesModule } from './main/content/pages/pages.module';
import { UIModule } from './main/content/ui/ui.module';
import { ComponentsModule } from './main/content/components/components.module';
2017-08-18 09:31:17 +00:00
import { FuseSplashScreenService } from './core/services/splash-screen.service';
import { FuseConfigService } from './core/services/config.service';
import { FuseNavigationService } from './core/components/navigation/navigation.service';
import { ComponentsThirdPartyModule } from './main/content/components-third-party/components-third-party.module';
import { ServicesModule } from './main/content/services/services.module';
2017-07-15 15:03:40 +00:00
const appRoutes: Routes = [
2017-07-13 14:43:22 +00:00
{
2017-07-15 15:03:40 +00:00
path : 'apps/mail',
loadChildren: './main/content/apps/mail/mail.module#FuseMailModule'
2017-07-13 14:43:22 +00:00
},
{
path : 'apps/chat',
loadChildren: './main/content/apps/chat/chat.module#FuseChatModule'
},
{
path : 'apps/calendar',
loadChildren: './main/content/apps/calendar/calendar.module#FuseCalendarModule'
},
{
path : 'apps/todo',
loadChildren: './main/content/apps/todo/todo.module#FuseTodoModule'
},
2017-08-01 12:27:32 +00:00
{
path : 'apps/file-manager',
loadChildren: './main/content/apps/file-manager/file-manager.module#FuseFileManagerModule'
2017-08-01 12:27:32 +00:00
},
{
path : 'apps/contacts',
loadChildren: './main/content/apps/contacts/contacts.module#FuseContactsModule'
},
{
path : 'apps/scrumboard',
loadChildren: './main/content/apps/scrumboard/scrumboard.module#FuseScrumboardModule'
},
2017-07-12 12:35:07 +00:00
{
path : '**',
redirectTo: 'apps/dashboards/project'
2017-07-15 15:03:40 +00:00
}
];
@NgModule({
2017-07-04 09:42:00 +00:00
declarations: [
2017-08-17 07:40:25 +00:00
AppComponent
2017-07-04 09:42:00 +00:00
],
imports : [
BrowserModule,
2017-07-17 15:11:34 +00:00
HttpModule,
2017-07-15 15:03:40 +00:00
HttpClientModule,
2017-07-04 09:42:00 +00:00
BrowserAnimationsModule,
2017-07-12 12:35:07 +00:00
RouterModule.forRoot(appRoutes),
SharedModule,
2017-07-13 14:43:22 +00:00
InMemoryWebApiModule.forRoot(FuseFakeDbService, {delay: 0}),
2017-08-02 08:53:30 +00:00
FuseMainModule,
2017-07-13 14:43:22 +00:00
ProjectModule,
2017-07-13 14:43:22 +00:00
PagesModule,
2017-07-29 13:42:53 +00:00
UIModule,
ServicesModule,
ComponentsModule,
ComponentsThirdPartyModule
2017-07-04 09:42:00 +00:00
],
providers : [
FuseSplashScreenService,
FuseConfigService,
FuseNavigationService
2017-08-18 09:31:17 +00:00
],
bootstrap : [
AppComponent
]
})
2017-07-04 09:42:00 +00:00
export class AppModule
{
}