source: Farmatiko/ClientApp/src/app/app.module.ts@ 993189e

Last change on this file since 993189e was 993189e, checked in by Mile Jankuloski <mile.jankuloski@…>, 2 years ago

Auth guards and services, refactored components

  • Property mode set to 100644
File size: 2.8 KB
RevLine 
[30a465f]1import { BrowserModule } from '@angular/platform-browser';
2import { NgModule } from '@angular/core';
3import { FormsModule } from '@angular/forms';
4import { HttpClientModule, HTTP_INTERCEPTORS } from '@angular/common/http';
5import { RouterModule } from '@angular/router';
[785b8bd]6import { MaterialModule } from './shared/material.module';
7import { ReactiveFormsModule } from '@angular/forms';
[30a465f]8
[ee137aa]9import { DataService } from './shared/data.service';
10
[30a465f]11import { AppComponent } from './app.component';
12import { NavMenuComponent } from './nav-menu/nav-menu.component';
13import { HomeComponent } from './home/home.component';
14import { CounterComponent } from './counter/counter.component';
[ec6ac45]15import { BrowserAnimationsModule } from '@angular/platform-browser/animations';
16import { KoronaComponent } from './korona/korona.component';
[785b8bd]17import { AdminComponent } from './admin/admin.component';
18import { DashboardComponent } from './dashboard/dashboard.component';
19import { LoginComponent } from './login/login.component';
[ee137aa]20import { MedicineDialogComponent } from './dialogs/medicine-dialog/medicine-dialog.component';
21import { PharmacyDialogComponent } from './dialogs/pharmacy-dialog/pharmacy-dialog.component';
22import { FacilityDialogComponent } from './dialogs/facility-dialog/facility-dialog.component';
23import { WorkerDialogComponent } from './dialogs/worker-dialog/worker-dialog.component';
24import { EditPharmacyDialogComponent } from './dialogs/edit-pharmacy-dialog/edit-pharmacy-dialog.component';
25import { EditPharmacyHeadDialogComponent } from './dialogs/edit-pharmacy-head-dialog/edit-pharmacy-head-dialog.component';
26import { PharmacyHeadDialogComponent } from './nav-menu/dialogs/pharmacy-head-dialog/pharmacy-head-dialog.component';
[993189e]27import { AuthGuard } from './shared/auth.guard';
[30a465f]28
29@NgModule({
30 declarations: [
31 AppComponent,
32 NavMenuComponent,
33 HomeComponent,
34 CounterComponent,
[785b8bd]35 KoronaComponent,
36 AdminComponent,
37 DashboardComponent,
[ee137aa]38 LoginComponent,
39 MedicineDialogComponent,
40 PharmacyDialogComponent,
41 FacilityDialogComponent,
42 WorkerDialogComponent,
43 EditPharmacyDialogComponent,
44 EditPharmacyHeadDialogComponent,
45 PharmacyHeadDialogComponent
[30a465f]46 ],
47 imports: [
48 BrowserModule.withServerTransition({ appId: 'ng-cli-universal' }),
49 HttpClientModule,
50 FormsModule,
51 RouterModule.forRoot([
52 { path: '', component: HomeComponent, pathMatch: 'full' },
[ec6ac45]53 { path: 'mapa', component: CounterComponent },
[785b8bd]54 { path: 'koronavirus', component: KoronaComponent },
55 { path: 'admin', component: AdminComponent },
[993189e]56 { path: 'dashboard', component: DashboardComponent, canActivate: [AuthGuard] },
[785b8bd]57 { path: 'login', component: LoginComponent }
[ec6ac45]58 ]),
[785b8bd]59 BrowserAnimationsModule,
60 MaterialModule,
61 ReactiveFormsModule
[30a465f]62 ],
[ee137aa]63 providers: [
64 DataService
65 ],
[30a465f]66 bootstrap: [AppComponent]
67})
68export class AppModule { }
Note: See TracBrowser for help on using the repository browser.