Files
doneit-web/src/app/home/home-routing.module.ts
T
Peter Maquiran b47154d313 fix
2024-02-29 09:40:51 +01:00

428 lines
14 KiB
TypeScript

import { NgModule } from '@angular/core';
import { Routes, RouterModule } from '@angular/router';
import { AuthGuard } from '../guards/auth.guard';
import { InactivityGuard } from '../guards/inactivity.guard';
import { AgendaPageModule } from '../pages/agenda/agenda.module';
import { ChatPageModule } from '../pages/chat/chat.module';
import { EventsPageModule } from '../pages/events/events.module';
import { GabineteDigitalPageModule } from '../pages/gabinete-digital/gabinete-digital.module';
import { PublicationsPageModule } from '../pages/publications/publications.module';
import { HomePage } from './home.page';
const routes: Routes = [
{
path: 'home',
component: HomePage,
resolve: {
},
children: [
{
path: 'events',
children: [
{
path:'',
loadChildren: ()=> EventsPageModule
},
{
path:':eventId/:caller',
loadChildren: () => import('../pages/agenda/view-event/view-event.module').then( m => m.ViewEventPageModule),
},
{
path:'expediente',
children: [
{
path:':SerialNumber/:caller',
loadChildren: ()=> import('../pages/gabinete-digital/expediente/expediente-detail/expediente-detail.module').then(m => m.ExpedienteDetailPageModule),
},
]
},
{
path:'expedientes-pr',
children: [
{
path:':SerialNumber/:caller',
loadChildren: ()=> import('../pages/gabinete-digital/expedientes-pr/expediente-pr/expediente-pr.module').then(m => m.ExpedientePrPageModule),
},
]
},
]
},
{
path: 'attachments',
children: [
{
path:':eventId',
loadChildren: ()=> import('../pages/events/attachments/attachments.module').then(m => m.AttachmentsPageModule)
},
],
},
{
path: 'attendees',
children: [
{
path:'',
loadChildren: ()=> import('../pages/events/attendees/attendees.module').then(m => m.AttendeesPageModule)
},
],
},
{
path: 'attendees-modal',
children: [
{
path:'',
loadChildren: ()=> import('../shared/event/attendee-modal/attendee-modal.module').then(m => m.AttendeeModalPageModule)
},
],
},
{
path: 'agenda',
children: [
{
path:'',
loadChildren: () => AgendaPageModule
},
{
path:':eventId/:caller',
loadChildren: () => import('../pages/agenda/view-event/view-event.module').then( m => m.ViewEventPageModule),
},
{
path: 'eventId/:caller',
loadChildren: () => import('../pages/agenda/view-event/view-event.module').then( m => m.ViewEventPageModule),
},
{
path: 'edit-event',
loadChildren: () => import('../pages/agenda/edit-event/edit-event.module').then( m => m.EditEventPageModule)
},
{
path: 'emend-message-modal',
loadChildren: () => import('../pages/gabinete-digital/event-list/approve-event-modal/approve-event-modal.module').then( m => m.ApproveEventModalPageModule)
},
{
path: 'view-event',
loadChildren: () => import('../pages/agenda/view-event/view-event.module').then( m => m.ViewEventPageModule)
},
{
path:'event-list',
children: [
{
path:'',
loadChildren: ()=> import('../pages/gabinete-digital/event-list/event-list.module').then(m => m.EventListPageModule)
},
{
path:'approve-event',
children : [
{
path:':serialNumber/:caller',
loadChildren: ()=> import('../pages/gabinete-digital/event-list/approve-event/approve-event.module').then(m => m.ApproveEventPageModule)
},
]
}
]
},
],
},
{
path: 'gabinete-digital',
children: [
{
path:'',
loadChildren: ()=> GabineteDigitalPageModule
},
{
path:'expediente',
children: [
{
path:'',
loadChildren: ()=> import('../pages/gabinete-digital/expediente/expediente.module').then(m => m.ExpedientePageModule)
},
{
path:':SerialNumber',
loadChildren: ()=> import('../pages/gabinete-digital/expediente/expediente-detail/expediente-detail.module').then(m => m.ExpedienteDetailPageModule)
},
{
path:':SerialNumber/:caller',
loadChildren: ()=> import('../pages/gabinete-digital/expediente/expediente-detail/expediente-detail.module').then(m => m.ExpedienteDetailPageModule)
},
{
path:'events/:eventId/:caller',
loadChildren: ()=> import('../pages/events/event-detail/event-detail.module').then(m => m.EventDetailPageModule),
},
{
path:'expediente-task-modal',
loadChildren: ()=> import('../pages/gabinete-digital/expediente/expedient-task-modal/expedient-task-modal.module').then(m => m.ExpedientTaskModalPageModule),
},
]
},
{
path: 'expedientes-pr',
children: [
{
path: '',
loadChildren: ()=> import('../pages/gabinete-digital/expedientes-pr/expedientes-pr.module').then(m => m.ExpedientesPrPageModule),
},
{
path:':SerialNumber/:caller',
loadChildren: ()=> import('../pages/gabinete-digital/expedientes-pr/expediente-pr/expediente-pr.module').then(m => m.ExpedientePrPageModule),
},
]
},
{
path: 'despachos',
children: [
{
path: '',
loadChildren: ()=> import('../pages/gabinete-digital/despachos/despachos.module').then(m => m.DespachosPageModule),
},
{
path:':SerialNumber/:caller',
loadChildren: ()=> import('../pages/gabinete-digital/despachos/despacho/despacho.module').then(m => m.DespachoPageModule),
},
]
},
{
path: 'despachos-pr',
children: [
{
path: '',
loadChildren: ()=> import('../pages/gabinete-digital/despachos-pr/despachos-pr.module').then(m => m.DespachosPrPageModule),
},
{
path:':SerialNumber/:caller',
loadChildren: ()=> import('../pages/gabinete-digital/despachos-pr/despacho-pr/despacho-pr.module').then(m => m.DespachoPrPageModule),
},
]
},
{
path: 'pedidos',
children: [
{
path: '',
loadChildren: ()=> import('../pages/gabinete-digital/pedidos/pedidos.module').then(m => m.PedidosPageModule),
},
{
path:':SerialNumber/:caller',
loadChildren: ()=> import('../pages/gabinete-digital/pedidos/pedido/pedido.module').then(m => m.PedidoPageModule),
},
]
},
{
path: 'diplomas',
children: [
{
path: '',
loadChildren: ()=> import('../pages/gabinete-digital/diplomas/diplomas.module').then(m => m.DiplomasPageModule),
},
{
path:':SerialNumber/:caller',
loadChildren: ()=> import('../pages/gabinete-digital/diplomas/diploma/diploma.module').then(m => m.DiplomaPageModule),
},
]
},
{
path: 'diplomas-assinar',
children: [
{
path: '',
loadChildren: ()=> import('../pages/gabinete-digital/diplomas-assinar/diplomas-assinar.module').then(m => m.DiplomasAssinarPageModule),
},
{
path:':SerialNumber/:caller',
loadChildren: ()=> import('../pages/gabinete-digital/diplomas-assinar/diploma-assinar/diploma-assinar.module').then(m => m.DiplomaAssinarPageModule),
},
]
},
{
path: 'diplomas-gerar',
children: [
{
path: '',
loadChildren: ()=> import('../pages/gabinete-digital/diplomas-gerar/diplomas-gerar.module').then(m => m.DiplomasGerarPageModule),
},
{
path:':SerialNumber/:caller',
loadChildren: ()=> import('../pages/gabinete-digital/diplomas-gerar/diplomas-gerar/diplomas-gerar-routing.module').then(m => m.DiplomasGerarPageRoutingModule),
},
]
},
{
path:'event-list',
children: [
{
path:'',
loadChildren: ()=> import('../pages/gabinete-digital/event-list/event-list.module').then(m => m.EventListPageModule)
},
{
path:'approve-event',
children : [
{
path:':serialNumber/:caller',
loadChildren: ()=> import('../pages/gabinete-digital/event-list/approve-event/approve-event.module').then(m => m.ApproveEventPageModule)
},
]
}
]
},
{
path: 'events-to-approve',
children: [
{
path: '',
loadChildren: ()=> import('../shared/gabinete-digital/edit-event-to-approve/edit-event.module')
}
]
}
],
},
{
path: 'search',
children: [
{
path:'',
loadChildren: ()=> import('../pages/search/search.module').then(m => m.SearchPageModule)
}
],
},
{
path: 'publications',
children: [
{
path:'',
loadChildren: ()=> PublicationsPageModule
},
{
path:':folderId',
loadChildren: ()=> import('../pages/publications/view-publications/view-publications.module').then(m => m.ViewPublicationsPageModule)
},
{
path:'view-publications',
children: [
{
path:':folderId/:publicationId',
loadChildren: ()=> import('../pages/publications/view-publications/publication-detail/publication-detail.module').then(m => m.PublicationDetailPageModule)
},
]
},
{
path:'new-publication',
loadChildren: ()=> import('../shared/publication/new-publication/new-publication.module').then(m => m.NewPublicationPageModule)
},
{
path: 'request-options',
loadChildren: () => import('../shared/popover/request-options/request-options.module').then( m => m.RequestOptionsPageModule)
},
],
},
{
path: 'chat',
children: [
{
path:'',
loadChildren: ()=> ChatPageModule
},
{
path:'messages',
children: [
{
path:':roomId',
loadChildren: ()=> import('../pages/chat/messages/messages.module').then(m => m.MessagesPageModule)
},
{
path:'contacts',
loadChildren: ()=> import('../shared/chat/messages/contacts/contacts.module').then(m => m.ContactsPageModule)
},
{
path:'contacts',
loadChildren: ()=> import('../pages/chat/messages/contacts/contacts.module').then(m => m.ContactsPageModule)
},
]
},
{
path:'group-messages',
children:[
{
path:'',
loadChildren: ()=> import('../pages/chat/group-messages/group-messages.module').then(m => m.GroupMessagesPageModule)
},
{
path:'group-contacts',
loadChildren: ()=> import('../shared/chat/group-messages/group-contacts/group-contacts.module').then(m => m.GroupContactsPageModule)
},
{
path:'group-contacts',
loadChildren: ()=> import('../pages/chat/group-messages/group-contacts/group-contacts.module').then(m => m.GroupContactsPageModule)
},
]
},
{
path:':eventId/:caller',
loadChildren: () => import('../pages/agenda/view-event/view-event.module').then( m => m.ViewEventPageModule),
},
],
canActivate: [AuthGuard]
},
{
path: 'document-detail',
children: [
{
path:'',
loadChildren: ()=> import('../modals/document-detail/document-detail.module').then(m => m.DocumentDetailPageModule)
},
],
},
],
canActivate: [AuthGuard]
},
{
path: 'inactivity',
children: [
{
path:'',
loadChildren: ()=> import('../pages/inactivity/inactivity.module').then(m => m.InactivityPageModule)
},
],
canActivate: [InactivityGuard]
},
{
path: 'login',
children: [
{
path:'',
loadChildren: ()=> import('../pages/inactivity/inactivity.module').then(m => m.InactivityPageModule)
},
],
canActivate: [InactivityGuard]
},
{
path: 'pin',
children: [
{
path:'',
loadChildren: ()=> import('../pages/inactivity/inactivity.module').then(m => m.InactivityPageModule)
},
],
canActivate: [InactivityGuard]
},
{
path: '**',
loadChildren: ()=> import('../pages/not-found/not-found.module').then(m => m.NotFoundPageModule),
},
];
@NgModule({
imports: [RouterModule.forChild(routes)],
exports: [RouterModule],
})
export class HomePageRoutingModule {}