diff --git a/circle.yml b/circle.yml index 112b236..770c4fd 100644 --- a/circle.yml +++ b/circle.yml @@ -10,7 +10,7 @@ general: dependencies: override: - npm install npm@latest -g - - npm install -g angular-cli@1.0.0-beta.20-4 + - npm install -g git+ssh://git@github.com/AnalogJ/angular-cli.git#AnalogJ-patch-1 - npm install test: diff --git a/package.json b/package.json index af0ed78..0e57592 100644 --- a/package.json +++ b/package.json @@ -20,7 +20,6 @@ "@angular/platform-browser": "~2.1.0", "@angular/platform-browser-dynamic": "~2.1.0", "@angular/router": "~3.1.0", - "angular2-cookie": "^1.2.5", "angular2-infinite-scroll": "^0.2.6", "angular2-jwt": "^0.1.25", "angular2-moment": "^1.0.0-beta.rc.1", @@ -33,7 +32,7 @@ "devDependencies": { "@types/jasmine": "^2.2.30", "@types/node": "^6.0.42", - "angular-cli": "1.0.0-beta.20-4", + "angular-cli": "AnalogJ/angular-cli#AnalogJ-patch-1", "codelyzer": "1.0.0-beta.1", "jasmine-core": "2.4.1", "jasmine-spec-reporter": "2.5.0", diff --git a/src/app/app.module.ts b/src/app/app.module.ts index da33546..f11614b 100644 --- a/src/app/app.module.ts +++ b/src/app/app.module.ts @@ -18,7 +18,6 @@ import { ApiService } from './services/api.service' import { CacheService } from './services/cache.service' import { AuthGuard } from './services/auth-guard.service' import { provideAuth } from 'angular2-jwt'; -import { CookieService } from 'angular2-cookie/services/cookies.service'; import {MomentModule} from 'angular2-moment'; import { InfiniteScrollModule } from 'angular2-infinite-scroll'; @@ -61,7 +60,6 @@ import { InfiniteScrollModule } from 'angular2-infinite-scroll'; providers: [ ApiService, CacheService, - CookieService, AuthGuard, provideAuth({ globalHeaders: [{'Content-Type':'application/json'}] diff --git a/src/app/auth-callback/auth-callback.component.ts b/src/app/auth-callback/auth-callback.component.ts index 6bf159d..0eb838d 100644 --- a/src/app/auth-callback/auth-callback.component.ts +++ b/src/app/auth-callback/auth-callback.component.ts @@ -2,7 +2,6 @@ import { Component, OnInit, ViewChild, AfterViewInit } from '@angular/core'; import { ApiService } from '../services/api.service'; import { ActivatedRoute } from '@angular/router'; import { ModalDirective } from 'ng2-bootstrap/ng2-bootstrap'; -import { CookieService } from 'angular2-cookie/core'; import {Router} from '@angular/router' @Component({ @@ -15,7 +14,7 @@ export class AuthCallbackComponent implements AfterViewInit { successfulCallback = true - constructor(private apiService: ApiService, private router: Router, private cookieService:CookieService, private activatedRoute: ActivatedRoute) { } + constructor(private apiService: ApiService, private router: Router, private activatedRoute: ActivatedRoute) { } ngAfterViewInit() { this.childModal.show() @@ -30,7 +29,8 @@ export class AuthCallbackComponent implements AfterViewInit { data => { console.log(data) localStorage.setItem('id_token', data.token) //set the JWT token - this.cookieService.put('CAPSULECD_SERVICE_TYPE',data.service_type) + localStorage.setItem('service_type', data.service_type) + this.router.navigate(['/dashboard']) }, error => console.log(error) diff --git a/src/app/dashboard/dashboard.component.html b/src/app/dashboard/dashboard.component.html index 41dd2ee..2055b53 100644 --- a/src/app/dashboard/dashboard.component.html +++ b/src/app/dashboard/dashboard.component.html @@ -8,6 +8,16 @@