import { Injectable } from '@angular/core' ; import { AbpHttpConfigurationService , LogService , MessageService } from 'abp-ng2-module' ; import { Router } from '@angular/router' ; @ Injectable ( { providedIn : 'root' } ) export class ZeroTemplateHttpConfigurationService extends AbpHttpConfigurationService { constructor ( messageService , logService , private _route ) { super ( messageService , logService ) ; } handleUnAuthorizedRequest ( messagePromise , targetUrl ? ) { if ( this . _route . url === '/account/login' ) { return ; } const self = this ; if ( messagePromise ) { messagePromise . done ( ( ) => { this . handleTargetUrl ( targetUrl || '/' ) ; } ) ; } else { self . handleTargetUrl ( targetUrl || '/' ) ; } } }