mirror of
				https://github.com/paperless-ngx/paperless-ngx.git
				synced 2025-10-30 03:56:23 -05:00 
			
		
		
		
	Refactor, missed import
This commit is contained in:
		| @@ -11,7 +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'; | ||||
| import { DirtyFormGuard } from './guards/dirty-form.guard'; | ||||
|  | ||||
| const routes: Routes = [ | ||||
|   {path: '', redirectTo: 'dashboard', pathMatch: 'full'}, | ||||
| @@ -20,13 +20,13 @@ const routes: Routes = [ | ||||
|     {path: 'documents', component: DocumentListComponent }, | ||||
|     {path: 'view/:id', component: DocumentListComponent }, | ||||
|     {path: 'search', component: SearchComponent }, | ||||
|     {path: 'documents/:id', component: DocumentDetailComponent, canDeactivate: [FormDirtyGuard] }, | ||||
|     {path: 'documents/:id', component: DocumentDetailComponent, canDeactivate: [DirtyFormGuard] }, | ||||
|  | ||||
|     {path: 'tags', component: TagListComponent }, | ||||
|     {path: 'documenttypes', component: DocumentTypeListComponent }, | ||||
|     {path: 'correspondents', component: CorrespondentListComponent }, | ||||
|     {path: 'logs', component: LogsComponent }, | ||||
|     {path: 'settings', component: SettingsComponent, canDeactivate: [FormDirtyGuard] }, | ||||
|     {path: 'settings', component: SettingsComponent, canDeactivate: [DirtyFormGuard] }, | ||||
|   ]}, | ||||
|  | ||||
|   {path: '404', component: NotFoundComponent}, | ||||
|   | ||||
| @@ -1,4 +1,4 @@ | ||||
| import { Component, Inject, LOCALE_ID, OnInit, Renderer2  } from '@angular/core'; | ||||
| import { Component, Inject, LOCALE_ID, OnInit, OnDestroy, Renderer2  } from '@angular/core'; | ||||
| import { FormControl, FormGroup } from '@angular/forms'; | ||||
| import { PaperlessSavedView } from 'src/app/data/paperless-saved-view'; | ||||
| import { DocumentListViewService } from 'src/app/services/document-list-view.service'; | ||||
|   | ||||
| @@ -6,7 +6,7 @@ import { NgbModal } from '@ng-bootstrap/ng-bootstrap'; | ||||
| import { ConfirmDialogComponent } from 'src/app/components/common/confirm-dialog/confirm-dialog.component'; | ||||
|  | ||||
| @Injectable({ providedIn: 'root' }) | ||||
| export class FormDirtyGuard extends DirtyCheckGuard { | ||||
| export class DirtyFormGuard extends DirtyCheckGuard { | ||||
|   constructor(private modalService: NgbModal) { | ||||
|     super(); | ||||
|   } | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 Michael Shamoon
					Michael Shamoon