2019-01-18 18:03:45 +01:00
|
|
|
import { NgModule } from '@angular/core';
|
|
|
|
import { RouterModule, Routes } from '@angular/router';
|
|
|
|
import { DmpEditorComponent } from './editor/dmp-editor.component';
|
|
|
|
import { InvitationAcceptedComponent } from './invitation/accepted/dmp-invitation-accepted.component';
|
|
|
|
import { DmpListingComponent } from './listing/dmp-listing.component';
|
|
|
|
import { DmpWizardComponent } from './wizard/dmp-wizard.component';
|
2019-05-21 15:42:28 +02:00
|
|
|
import { DmpOverviewComponent } from './overview/dmp-overview.component';
|
2019-08-30 15:02:02 +02:00
|
|
|
import { DmpCloneComponent } from './clone/dmp-clone.component';
|
2019-01-18 18:03:45 +01:00
|
|
|
|
|
|
|
const routes: Routes = [
|
|
|
|
{
|
|
|
|
path: '',
|
|
|
|
component: DmpListingComponent,
|
|
|
|
data: {
|
|
|
|
breadcrumb: true
|
|
|
|
},
|
|
|
|
},
|
|
|
|
{
|
|
|
|
path: 'versions/:groupId',
|
|
|
|
component: DmpListingComponent,
|
|
|
|
data: {
|
|
|
|
breadcrumb: true
|
|
|
|
},
|
|
|
|
},
|
2019-10-30 09:54:41 +01:00
|
|
|
// Uncomment to get dmp plans for grant with grantId
|
2019-12-16 11:18:49 +01:00
|
|
|
{
|
|
|
|
path: 'grant/:grantId',
|
|
|
|
component: DmpListingComponent,
|
|
|
|
data: {
|
|
|
|
breadcrumb: true
|
|
|
|
},
|
|
|
|
},
|
2019-01-18 18:03:45 +01:00
|
|
|
{
|
|
|
|
path: 'edit/:id',
|
|
|
|
component: DmpEditorComponent,
|
|
|
|
data: {
|
2019-09-16 17:46:19 +02:00
|
|
|
breadcrumb: true,
|
|
|
|
title: 'GENERAL.TITLES.DMP-EDIT'
|
2019-01-18 18:03:45 +01:00
|
|
|
},
|
|
|
|
},
|
2019-05-21 15:42:28 +02:00
|
|
|
{
|
2019-06-11 10:25:32 +02:00
|
|
|
path: 'publicEdit/:publicId',
|
|
|
|
component: DmpEditorComponent,
|
2019-05-21 15:42:28 +02:00
|
|
|
data: {
|
2019-09-16 17:46:19 +02:00
|
|
|
breadcrumb: true,
|
|
|
|
title: 'GENERAL.TITLES.DMP-PUBLIC-EDIT'
|
2019-05-21 15:42:28 +02:00
|
|
|
},
|
|
|
|
},
|
2019-04-26 16:05:15 +02:00
|
|
|
{
|
2019-06-11 10:25:32 +02:00
|
|
|
path: 'overview/:id',
|
|
|
|
component: DmpOverviewComponent,
|
2019-04-26 16:05:15 +02:00
|
|
|
data: {
|
2019-09-16 17:46:19 +02:00
|
|
|
breadcrumb: true,
|
|
|
|
title: 'GENERAL.TITLES.DMP-OVERVIEW'
|
2019-04-26 16:05:15 +02:00
|
|
|
},
|
|
|
|
},
|
2019-10-04 09:53:35 +02:00
|
|
|
// ----------- UNCOMMENT TO ADD AGAIN GRANTS --------
|
|
|
|
// {
|
|
|
|
// path: 'new/grant/:grantId',
|
|
|
|
// component: DmpEditorComponent,
|
|
|
|
// data: {
|
|
|
|
// breadcrumbs: 'new'
|
|
|
|
// }
|
|
|
|
// },
|
2019-01-18 18:03:45 +01:00
|
|
|
{
|
|
|
|
path: 'new',
|
|
|
|
component: DmpEditorComponent,
|
|
|
|
data: {
|
2019-09-16 17:46:19 +02:00
|
|
|
breadcrumbs: 'new',
|
|
|
|
title: 'GENERAL.TITLES.PLANS-NEW'
|
2019-01-18 18:03:45 +01:00
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
|
|
|
path: 'new_version/:id',
|
2019-09-02 10:19:16 +02:00
|
|
|
// component: DmpWizardComponent,
|
|
|
|
component: DmpCloneComponent,
|
2019-01-18 18:03:45 +01:00
|
|
|
data: {
|
|
|
|
clone: false,
|
2019-09-16 17:46:19 +02:00
|
|
|
breadcrumb: true,
|
|
|
|
title: 'GENERAL.TITLES.DMP-NEW-VERSION'
|
2019-01-18 18:03:45 +01:00
|
|
|
},
|
|
|
|
},
|
|
|
|
{
|
|
|
|
path: 'clone/:id',
|
2019-08-30 15:02:02 +02:00
|
|
|
component: DmpCloneComponent,
|
2019-01-18 18:03:45 +01:00
|
|
|
data: {
|
|
|
|
clone: false,
|
2019-09-16 17:46:19 +02:00
|
|
|
breadcrumb: true,
|
|
|
|
title: 'GENERAL.TITLES.DMP-CLONE'
|
2019-01-18 18:03:45 +01:00
|
|
|
},
|
|
|
|
},
|
|
|
|
{
|
|
|
|
path: 'invitation/:id',
|
|
|
|
component: InvitationAcceptedComponent,
|
|
|
|
data: {
|
|
|
|
breadcrumb: true
|
|
|
|
},
|
|
|
|
}
|
|
|
|
];
|
|
|
|
|
|
|
|
@NgModule({
|
|
|
|
imports: [RouterModule.forChild(routes)],
|
|
|
|
exports: [RouterModule]
|
|
|
|
})
|
2019-04-26 16:05:15 +02:00
|
|
|
export class DmpRoutingModule { }
|