update folder structure based on style guide

This commit is contained in:
Art Lowel
2021-07-23 17:18:51 +02:00
parent 146ec49a32
commit 124845bee1
667 changed files with 280 additions and 280 deletions

View File

@@ -0,0 +1,75 @@
import { NgModule } from '@angular/core';
import { RouterModule } from '@angular/router';
import { ItemPageResolver } from './item-page.resolver';
import { AuthenticatedGuard } from '../core/auth/authenticated.guard';
import { ItemBreadcrumbResolver } from '../core/breadcrumbs/item-breadcrumb.resolver';
import { DSOBreadcrumbsService } from '../core/breadcrumbs/dso-breadcrumbs.service';
import { LinkService } from '../core/cache/builders/link.service';
import { UploadBitstreamComponent } from './bitstreams/upload/upload-bitstream.component';
import { ITEM_EDIT_PATH, UPLOAD_BITSTREAM_PATH } from './item-page-routing-paths';
import { ItemPageAdministratorGuard } from './item-page-administrator.guard';
import { MenuItemType } from '../shared/menu/initial-menus-state';
import { LinkMenuItemModel } from '../shared/menu/menu-item/models/link.model';
import { ThemedItemPageComponent } from './simple/themed-item-page.component';
import { ThemedFullItemPageComponent } from './full/themed-full-item-page.component';
@NgModule({
imports: [
RouterModule.forChild([
{
path: ':id',
resolve: {
dso: ItemPageResolver,
breadcrumb: ItemBreadcrumbResolver
},
runGuardsAndResolvers: 'always',
children: [
{
path: '',
component: ThemedItemPageComponent,
pathMatch: 'full',
},
{
path: 'full',
component: ThemedFullItemPageComponent,
},
{
path: ITEM_EDIT_PATH,
loadChildren: () => import('./edit-item-page/edit-item-page.module')
.then((m) => m.EditItemPageModule),
},
{
path: UPLOAD_BITSTREAM_PATH,
component: UploadBitstreamComponent,
canActivate: [AuthenticatedGuard]
}
],
data: {
menu: {
public: [{
id: 'statistics_item_:id',
active: true,
visible: true,
model: {
type: MenuItemType.LINK,
text: 'menu.section.statistics',
link: 'statistics/items/:id/',
} as LinkMenuItemModel,
}],
},
},
}
])
],
providers: [
ItemPageResolver,
ItemBreadcrumbResolver,
DSOBreadcrumbsService,
LinkService,
ItemPageAdministratorGuard,
]
})
export class ItemPageRoutingModule {
}