Broker System for Supercredit
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

45 lines
2.6KB

  1. import { NgModule } from '@angular/core';
  2. import { Routes, RouterModule } from '@angular/router';
  3. import { AuthComponent } from './auth/auth.component';
  4. import { DashboardComponent } from './dashboard/dashboard.component';
  5. import { AuthGuard } from './service/auth-guard.service';
  6. import { TransactionListComponent } from './transaction-list/transaction-list.component';
  7. import { TransactionComponent } from './transaction/transaction.component';
  8. import {ListAllLoansComponent} from './list-all-loans/list-all-loans.component';
  9. import {LoanEditComponent} from './loan-edit/loan-edit.component';
  10. import {LenderUploadsComponent} from './lender-uploads/lender-uploads.component';
  11. import {BrokerLoanListComponent} from './broker-loan-list/broker-loan-list.component';
  12. import {BrokerRewardComponent} from './broker-reward/broker-reward.component';
  13. import {BrokerProfileComponent} from './broker-profile/broker-profile.component';
  14. import {ClientLoanListComponent} from './client-loan-list/client-loan-list.component';
  15. import {ClientProfileComponent} from './client-profile/client-profile.component';
  16. import {E403Component} from './e403/e403.component';
  17. const routes: Routes = [
  18. {path : '', component: DashboardComponent, canActivate: [AuthGuard]},
  19. {path : 'dashboard', component: DashboardComponent, canActivate: [AuthGuard] },
  20. {path : 'login', component: AuthComponent},
  21. {path : 'transaction', component: TransactionComponent, canActivate: [AuthGuard]},
  22. {path : 'transaction-list', component: TransactionListComponent, canActivate: [AuthGuard]},
  23. {path : 'list-all-loans', component: ListAllLoansComponent, canActivate: [AuthGuard]},
  24. {path : 'edit-loan/:id', component: LoanEditComponent, canActivate: [AuthGuard]},
  25. {path : 'edit-loan', component: LoanEditComponent, canActivate: [AuthGuard]},
  26. {path : 'uploads', component: LenderUploadsComponent, canActivate: [AuthGuard]},
  27. {path : 'uploads/:id', component: LenderUploadsComponent, canActivate: [AuthGuard]},
  28. {path : 'broker-loan-list', component: BrokerLoanListComponent, canActivate: [AuthGuard] },
  29. {path : 'broker-reward', component: BrokerRewardComponent, canActivate: [AuthGuard] },
  30. {path : 'broker-profile', component: BrokerProfileComponent, canActivate: [AuthGuard]},
  31. {path : 'client-loan-list', component: ClientLoanListComponent, canActivate: [AuthGuard] },
  32. {path : 'client-profile', component: ClientProfileComponent, canActivate: [AuthGuard] },
  33. {path : 'e403', component: E403Component, },
  34. ];
  35. @NgModule({
  36. imports: [RouterModule.forRoot(routes, {useHash: true} )],
  37. exports: [RouterModule]
  38. })
  39. export class AppRoutingModule {
  40. }