mirror of
https://github.com/paperless-ngx/paperless-ngx.git
synced 2025-12-14 02:27:06 +01:00
Settings navigation warning dialog
This commit is contained in:
parent
6c5f9bbabb
commit
b0fa0f2319
5 changed files with 58 additions and 15 deletions
|
|
@ -11,6 +11,7 @@ import { SettingsComponent } from './components/manage/settings/settings.compone
|
|||
import { TagListComponent } from './components/manage/tag-list/tag-list.component';
|
||||
import { NotFoundComponent } from './components/not-found/not-found.component';
|
||||
import { SearchComponent } from './components/search/search.component';
|
||||
import { FormDirtyGuard } from './guards/dirty-form.guard';
|
||||
|
||||
const routes: Routes = [
|
||||
{path: '', redirectTo: 'dashboard', pathMatch: 'full'},
|
||||
|
|
@ -20,13 +21,13 @@ const routes: Routes = [
|
|||
{path: 'view/:id', component: DocumentListComponent },
|
||||
{path: 'search', component: SearchComponent },
|
||||
{path: 'documents/:id', component: DocumentDetailComponent },
|
||||
|
||||
|
||||
{path: 'tags', component: TagListComponent },
|
||||
{path: 'documenttypes', component: DocumentTypeListComponent },
|
||||
{path: 'correspondents', component: CorrespondentListComponent },
|
||||
{path: 'logs', component: LogsComponent },
|
||||
{path: 'settings', component: SettingsComponent },
|
||||
]},
|
||||
{path: 'settings', component: SettingsComponent, canDeactivate: [FormDirtyGuard] },
|
||||
]},
|
||||
|
||||
{path: '404', component: NotFoundComponent},
|
||||
{path: '**', redirectTo: '/404', pathMatch: 'full'}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue