Moved to Angular 6.0

----

Pending
* Table width for the points column in incentive
* Linting
* keyboard navigation where it was used earlier
* can remove the unused totals calculated serverside in productledger
* spinner and loading bars
* Activate Guard for Employee Function tabs
* Progress for Fingerprint uploads
* deleted reconcile and receipe features as they were not being used
* focus the right control on component load
This commit is contained in:
tanshu
2018-05-25 19:19:00 +05:30
parent b3cb01da02
commit 6be1dd5a3a
1380 changed files with 23914 additions and 18722 deletions

View File

@ -0,0 +1,25 @@
import {async, ComponentFixture, TestBed} from '@angular/core/testing';
import {LogoutComponent} from './logout.component';
describe('LogoutComponent', () => {
let component: LogoutComponent;
let fixture: ComponentFixture<LogoutComponent>;
beforeEach(async(() => {
TestBed.configureTestingModule({
declarations: [LogoutComponent]
})
.compileComponents();
}));
beforeEach(() => {
fixture = TestBed.createComponent(LogoutComponent);
component = fixture.componentInstance;
fixture.detectChanges();
});
it('should create', () => {
expect(component).toBeTruthy();
});
});

View File

@ -0,0 +1,25 @@
import {Component, OnInit} from '@angular/core';
import {Router} from '@angular/router';
import {AuthService} from '../auth.service';
import {ToasterService} from '../../core/toaster.service';
@Component({
selector: 'app-logout',
template: ''
})
export class LogoutComponent implements OnInit {
constructor(private auth: AuthService, private router: Router, private toaster: ToasterService) {
}
ngOnInit() {
this.auth.logout().subscribe(
(result) => {
this.toaster.show('Success', 'Logged Out');
this.router.navigateByUrl('/');
},
(error) => this.toaster.show('Danger', error.error)
);
}
}