diff options
Diffstat (limited to 'vid-webpack-master/src/app/drawingBoard/guards')
-rw-r--r-- | vid-webpack-master/src/app/drawingBoard/guards/servicePlanningGuard/drawingBoardGuard.ts | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/vid-webpack-master/src/app/drawingBoard/guards/servicePlanningGuard/drawingBoardGuard.ts b/vid-webpack-master/src/app/drawingBoard/guards/servicePlanningGuard/drawingBoardGuard.ts index 4a305b193..d486fb4fa 100644 --- a/vid-webpack-master/src/app/drawingBoard/guards/servicePlanningGuard/drawingBoardGuard.ts +++ b/vid-webpack-master/src/app/drawingBoard/guards/servicePlanningGuard/drawingBoardGuard.ts @@ -1,18 +1,17 @@ import {Injectable} from "@angular/core"; -import {CanActivate, ActivatedRouteSnapshot, RouterStateSnapshot, Router} from "@angular/router"; +import {ActivatedRouteSnapshot, CanActivate, Router, RouterStateSnapshot} from "@angular/router"; import {NgRedux} from "@angular-redux/store"; -import {Observable} from "rxjs"; +import {Observable, of} from "rxjs"; import {HttpClient} from "@angular/common/http"; import {AppState} from "../../../shared/store/reducers"; import {updateDrawingBoardStatus} from "../../../shared/storeUtil/utils/global/global.actions"; import {DrawingBoardModes} from "../../service-planning/drawing-board.modes"; -import {of} from "rxjs"; @Injectable() export class DrawingBoardGuard implements CanActivate { constructor(private store: NgRedux<AppState>, private _http: HttpClient, private _router : Router) { } canActivate(next: ActivatedRouteSnapshot, state: RouterStateSnapshot): Observable<boolean> { - let url : string = `/vid/roles/service_permissions?subscriberId=${next.queryParams['subscriberId']}&serviceType=${next.queryParams['serviceType']}`; + let url : string = `../../roles/service_permissions?subscriberId=${next.queryParams['subscriberId']}&serviceType=${next.queryParams['serviceType']}`; const viewMode = state.url.includes(DrawingBoardModes.RETRY_EDIT)? DrawingBoardModes.RETRY: DrawingBoardModes.VIEW; return this._http.get(url) .map((result : DrawingBoardPermissions) => { |