OpenSlides/client/src/app/site/users/users-routing.module.ts

59 lines
1.8 KiB
TypeScript
Raw Normal View History

import { NgModule } from '@angular/core';
import { Routes, RouterModule } from '@angular/router';
2019-01-11 18:55:09 +01:00
import { GroupListComponent } from './components/group-list/group-list.component';
import { PasswordComponent } from './components/password/password.component';
import { PresenceDetailComponent } from './presence-detail/presence-detail.component';
2019-01-11 18:55:09 +01:00
import { UserDetailComponent } from './components/user-detail/user-detail.component';
import { UserImportListComponent } from './components/user-import/user-import-list.component';
import { UserListComponent } from './components/user-list/user-list.component';
2018-09-18 18:27:14 +02:00
const routes: Routes = [
{
path: '',
component: UserListComponent
},
{
path: 'password',
component: PasswordComponent
},
{
path: 'password/:id',
component: PasswordComponent
},
2018-09-18 18:27:14 +02:00
{
path: 'new',
component: UserDetailComponent
},
2019-01-11 18:55:09 +01:00
{
path: 'import',
component: UserImportListComponent
},
{
path: 'presence',
component: PresenceDetailComponent
// FIXME: CRITICAL: restricted to basePerm: 'users.can_manage' and config 'users_enable_presence_view'
},
{
path: 'groups',
component: GroupListComponent
/**
* FIXME: CRITICAL:
* Refreshing the page, even while having the required permission, will navigate you back to "/"
* Makes developing protected areas impossible.
* Has the be (temporarily) removed if this page should be edited.
*/
// data: { basePerm: 'users.can_manage' }
},
2018-09-18 18:27:14 +02:00
{
path: ':id',
component: UserDetailComponent
}
];
@NgModule({
imports: [RouterModule.forChild(routes)],
exports: [RouterModule]
})
export class UsersRoutingModule {}