[webapp] 批量处理eslint格式告警
This commit is contained in:
@@ -1,19 +1,17 @@
|
||||
import { NgModule } from '@angular/core';
|
||||
import { RouterModule, Routes } from '@angular/router';
|
||||
import { environment } from '@env/environment';
|
||||
|
||||
// layout
|
||||
import { DetectAuthGuard } from '../core/guard/detect-auth-guard';
|
||||
import { LayoutBasicComponent } from '../layout/basic/basic.component';
|
||||
import { LayoutPassportComponent } from '../layout/passport/passport.component';
|
||||
// dashboard pages
|
||||
import { DashboardComponent } from './dashboard/dashboard.component';
|
||||
// single pages
|
||||
import { CallbackComponent } from './passport/callback.component';
|
||||
import { UserLockComponent } from './passport/lock/lock.component';
|
||||
// passport pages
|
||||
import { UserLoginComponent } from './passport/login/login.component';
|
||||
import { UserRegisterResultComponent } from './passport/register-result/register-result.component';
|
||||
import { UserRegisterComponent } from './passport/register/register.component';
|
||||
import {DetectAuthGuard} from "../core/guard/detect-auth-guard";
|
||||
|
||||
const routes: Routes = [
|
||||
{
|
||||
@@ -23,11 +21,12 @@ const routes: Routes = [
|
||||
canActivate: [DetectAuthGuard],
|
||||
children: [
|
||||
// todo 根据路由自动生成面包屑
|
||||
{ path: '', redirectTo: 'dashboard', pathMatch: 'full'},
|
||||
{ path: '', redirectTo: 'dashboard', pathMatch: 'full' },
|
||||
{ path: 'dashboard', component: DashboardComponent, data: { title: '仪表盘' } },
|
||||
{ path: 'exception', loadChildren: () => import('./exception/exception.module').then(m => m.ExceptionModule) },
|
||||
{ path: 'monitors', loadChildren: () => import('./monitor/monitor.module').then((m) => m.MonitorModule) },
|
||||
{ path: 'alert', loadChildren: () => import('./alert/alert.module').then((m) => m.AlertModule) },]
|
||||
{ path: 'monitors', loadChildren: () => import('./monitor/monitor.module').then(m => m.MonitorModule) },
|
||||
{ path: 'alert', loadChildren: () => import('./alert/alert.module').then(m => m.AlertModule) }
|
||||
]
|
||||
},
|
||||
// 空白布局
|
||||
// {
|
||||
@@ -42,26 +41,21 @@ const routes: Routes = [
|
||||
component: LayoutPassportComponent,
|
||||
children: [
|
||||
{ path: 'login', component: UserLoginComponent, data: { title: '登录' } },
|
||||
{ path: 'register', component: UserRegisterComponent, data: { title: '注册' } },
|
||||
{ path: 'register-result', component: UserRegisterResultComponent, data: { title: '注册结果' } },
|
||||
{ path: 'lock', component: UserLockComponent, data: { title: '锁屏' } },
|
||||
{ path: 'lock', component: UserLockComponent, data: { title: '锁屏' } }
|
||||
]
|
||||
},
|
||||
// 单页不包裹Layout
|
||||
{ path: 'passport/callback/:type', component: CallbackComponent },
|
||||
{ path: '**', redirectTo: 'exception/404' },
|
||||
{ path: '**', redirectTo: 'exception/404' }
|
||||
];
|
||||
|
||||
@NgModule({
|
||||
imports: [
|
||||
RouterModule.forRoot(
|
||||
routes, {
|
||||
useHash: environment.useHash,
|
||||
// NOTICE: If you use `reuse-tab` component and turn on keepingScroll you can set to `disabled`
|
||||
// Pls refer to https://ng-alain.com/components/reuse-tab
|
||||
scrollPositionRestoration: 'top',
|
||||
}
|
||||
)],
|
||||
exports: [RouterModule],
|
||||
RouterModule.forRoot(routes, {
|
||||
useHash: environment.useHash,
|
||||
// NOTICE: If you use `reuse-tab` component and turn on keepingScroll you can set to `disabled`
|
||||
// Pls refer to https://ng-alain.com/components/reuse-tab
|
||||
scrollPositionRestoration: 'top'
|
||||
})
|
||||
],
|
||||
exports: [RouterModule]
|
||||
})
|
||||
export class RouteRoutingModule { }
|
||||
export class RouteRoutingModule {}
|
||||
|
||||
Reference in New Issue
Block a user