[demo] better? demo mode
This commit is contained in:
@@ -1,6 +1,8 @@
|
||||
import { Component, OnInit } from '@angular/core';
|
||||
import { StateService } from '@app/services/state.service';
|
||||
import { WebsocketService } from '@app/services/websocket.service';
|
||||
import { Router, ActivatedRoute } from '@angular/router';
|
||||
import { handleDemoRedirect } from '../../shared/common.utils';
|
||||
|
||||
@Component({
|
||||
selector: 'app-graphs',
|
||||
@@ -13,7 +15,9 @@ export class GraphsComponent implements OnInit {
|
||||
|
||||
constructor(
|
||||
public stateService: StateService,
|
||||
private websocketService: WebsocketService
|
||||
private websocketService: WebsocketService,
|
||||
private router: Router,
|
||||
private route: ActivatedRoute
|
||||
) { }
|
||||
|
||||
ngOnInit(): void {
|
||||
@@ -22,5 +26,7 @@ export class GraphsComponent implements OnInit {
|
||||
if (this.stateService.env.ACCELERATOR === true && (this.stateService.env.MINING_DASHBOARD === true || this.stateService.env.LIGHTNING === true)) {
|
||||
this.flexWrap = true;
|
||||
}
|
||||
|
||||
handleDemoRedirect(this.route, this.router);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user