mirror of
https://github.com/GNS3/gns3-web-ui.git
synced 2025-04-18 23:36:53 +00:00
Support for 404
This commit is contained in:
parent
e6e518b40f
commit
0e04e9b021
@ -57,6 +57,7 @@ import { TracengPreferencesComponent } from './components/preferences/traceng/tr
|
||||
import { TracengTemplatesComponent } from './components/preferences/traceng/traceng-templates/traceng-templates.component';
|
||||
import { AddTracengTemplateComponent } from './components/preferences/traceng/add-traceng/add-traceng-template.component';
|
||||
import { TracengTemplateDetailsComponent } from './components/preferences/traceng/traceng-template-details/traceng-template-details.component';
|
||||
import { PageNotFoundComponent } from './components/page-not-found/page-not-found.component';
|
||||
|
||||
const routes: Routes = [
|
||||
{
|
||||
@ -128,15 +129,15 @@ const routes: Routes = [
|
||||
{ path: 'server/:server_id/preferences/iou/templates', component: IouTemplatesComponent },
|
||||
{ path: 'server/:server_id/preferences/iou/templates/:template_id', component: IouTemplateDetailsComponent },
|
||||
{ path: 'server/:server_id/preferences/iou/templates/:template_id/copy', component: CopyIouTemplateComponent },
|
||||
{ path: 'server/:server_id/preferences/iou/addtemplate', component: AddIouTemplateComponent }
|
||||
{ path: 'server/:server_id/preferences/iou/addtemplate', component: AddIouTemplateComponent },
|
||||
{
|
||||
path: '**',
|
||||
component: PageNotFoundComponent
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
path: 'server/:server_id/project/:project_id', component: ProjectMapComponent,
|
||||
},
|
||||
{
|
||||
path: '**',
|
||||
redirectTo: 'servers'
|
||||
}
|
||||
];
|
||||
|
||||
|
@ -245,6 +245,7 @@ import { ScreenshotDialogComponent } from './components/project-map/screenshot-d
|
||||
import { ResizableModule } from 'angular-resizable-element';
|
||||
import { DragAndDropModule } from 'angular-draggable-droppable';
|
||||
import { DragDropModule } from '@angular/cdk/drag-drop';
|
||||
import { PageNotFoundComponent } from './components/page-not-found/page-not-found.component';
|
||||
|
||||
if (environment.production) {
|
||||
Raven.config('https://b2b1cfd9b043491eb6b566fd8acee358@sentry.io/842726', {
|
||||
@ -412,7 +413,8 @@ if (environment.production) {
|
||||
StartCaptureOnStartedLinkActionComponent,
|
||||
LockActionComponent,
|
||||
NavigationDialogComponent,
|
||||
ScreenshotDialogComponent
|
||||
ScreenshotDialogComponent,
|
||||
PageNotFoundComponent
|
||||
],
|
||||
imports: [
|
||||
BrowserModule,
|
||||
|
@ -0,0 +1,6 @@
|
||||
<div class="content">
|
||||
<div class="default-header">
|
||||
<h1>404 Page not found</h1>
|
||||
<button mat-button routerLink="/servers">Navigate to homepage</button>
|
||||
</div>
|
||||
</div>
|
@ -0,0 +1,3 @@
|
||||
div {
|
||||
text-align: center
|
||||
}
|
@ -0,0 +1,10 @@
|
||||
import { Component } from '@angular/core';
|
||||
|
||||
@Component({
|
||||
selector: 'app-page-not-found',
|
||||
templateUrl: './page-not-found.component.html',
|
||||
styleUrls: ['./page-not-found.component.scss']
|
||||
})
|
||||
export class PageNotFoundComponent {
|
||||
constructor(){}
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user