diff --git a/src/app/app-routing.module.ts b/src/app/app-routing.module.ts
index 5f9176d..c99456c 100644
--- a/src/app/app-routing.module.ts
+++ b/src/app/app-routing.module.ts
@@ -4,7 +4,7 @@ import {Routes, RouterModule} from '@angular/router';
const routes: Routes = [
{
path: '',
- redirectTo: '/tspinfopage',
+ redirectTo: '/kanban-fixed',
pathMatch: 'full',
}
];
diff --git a/src/app/app.component.ts b/src/app/app.component.ts
index 59a8fe3..bba9ad1 100644
--- a/src/app/app.component.ts
+++ b/src/app/app.component.ts
@@ -2,26 +2,11 @@ import {Component, OnDestroy, OnInit} from '@angular/core';
import {Subscription} from "rxjs/Subscription";
import {TimerObservable} from "rxjs/observable/TimerObservable";
-import {KanbanService} from "./kanban/shared/kanban.service";
-// import {ActivatedRoute, NavigationEnd, Router} from "@angular/router";
+import {KanbanService} from "./kanban/shared";
import {SelfUpdaterService} from "./kanban/shared/self-updater.service";
-// import {TspInfoService} from "./tsp-info/shared/tsp-info.service";
-
const TIMER_DEPLOY_REFRESH = 30000;
const TIMER_JIRA_REFRESH = 60000;
-// const TIMER_TSPINFO_REFRESH = 60000;
-// const TIMER_PAGE_SWITCH_TICK = 1000;
-
-/**
- * Page switch timer in seconds
- * @type {number}
- */
-// const TIMESPENT_KANBAN = 120000;
-// const TIMESPENT_TSPINFO = 30000;
-
-// const PAGE_KANBAN = '/kanban';
-// const PAGE_TSPINFO = '/tspinfopage';
@Component({
selector: 'app-root',
@@ -29,20 +14,12 @@ const TIMER_JIRA_REFRESH = 60000;
styleUrls: ['./app.component.css']
})
export class AppComponent implements OnInit, OnDestroy {
- // private currentPage: string = PAGE_KANBAN;
- // private lastNavOccured: number = Date.now();
- // private autoSwitchEnabled: boolean = true;
private selfUpdateCheckerTimer: Subscription;
private reloadKanbanTimer: Subscription;
- // private reloadTspInfoTimer: Subscription;
- // private pageSwitchTimer: Subscription;
constructor(private selfUpdaterService: SelfUpdaterService,
private kanbanService: KanbanService,
- // private tspInfoService: TspInfoService,
- // private router: Router,
- // private activatedRoute: ActivatedRoute
) {}
/**
@@ -60,81 +37,10 @@ export class AppComponent implements OnInit, OnDestroy {
this.reloadKanbanTimer = timer1.subscribe(() => {
this.kanbanService.reload();
});
- // let timer2 = TimerObservable.create(TIMER_TSPINFO_REFRESH, TIMER_TSPINFO_REFRESH);
- // this.reloadTspInfoTimer = timer2.subscribe(() => {
- // this.tspInfoService.reload();
- // });
-
- // this.router.events
- // .filter(e => e instanceof NavigationEnd)
- // .map(() => {
- // let route = this.activatedRoute;
- // while (route.firstChild) {
- // route = route.firstChild;
- // }
- // return route;
- // })
- // .filter((route) => route.outlet === 'primary')
- // .mergeMap((route) => route.data)
- // .subscribe(data => {
- // if (!data['disableAutoSwitch']) {
- // let timer4 = TimerObservable.create(TIMER_PAGE_SWITCH_TICK, TIMER_PAGE_SWITCH_TICK);
- // this.pageSwitchTimer = timer4.subscribe(this.switchSubscriber.bind(this));
- // }
- // });
}
public ngOnDestroy() {
this.selfUpdateCheckerTimer.unsubscribe();
this.reloadKanbanTimer.unsubscribe();
- // this.reloadTspInfoTimer.unsubscribe();
- // if (this.pageSwitchTimer) {
- // this.pageSwitchTimer.unsubscribe();
- // }
}
-
- // private switchSubscriber() {
- // let now = new Date();
- // let weekDay = now.getDay();
- // // on weekdays
- // if (weekDay > 0 && weekDay < 6) {
- // if (now.getHours() == 10) {
- // if (this.autoSwitchEnabled && now.getMinutes() > 14) {
- // this.navigateToPage(PAGE_KANBAN);
- // this.autoSwitchEnabled = false;
- // }
- // if (!this.autoSwitchEnabled && now.getMinutes() > 30) {
- // this.autoSwitchEnabled = true;
- // }
- // }
- // }
- // if (this.autoSwitchEnabled) {
- // let compareTimer: number = 0;
- // let switchTo: string = '';
- // switch (this.currentPage) {
- // case PAGE_KANBAN:
- // compareTimer = TIMESPENT_KANBAN;
- // switchTo = PAGE_TSPINFO;
- // break;
- // case PAGE_TSPINFO:
- // compareTimer = TIMESPENT_TSPINFO;
- // switchTo = PAGE_KANBAN;
- // break;
- // default:
- // console.error("Unknown page in pageSwitcherTimer");
- // return false;
- // }
- // if ((Date.now() - this.lastNavOccured) > compareTimer) {
- // this.navigateToPage(switchTo);
- // }
- // }
- // }
- //
- // private navigateToPage(page: string) {
- // if (page != this.currentPage) {
- // this.router.navigate([page]);
- // this.currentPage = page;
- // this.lastNavOccured = Date.now();
- // }
- // }
}
diff --git a/src/app/app.module.ts b/src/app/app.module.ts
index ee80576..e305fcc 100644
--- a/src/app/app.module.ts
+++ b/src/app/app.module.ts
@@ -4,8 +4,6 @@ import { NgModule } from '@angular/core';
import { AppRoutingModule } from './app-routing.module';
import { AppComponent } from './app.component';
import { KanbanModule } from './kanban/kanban.module';
-import { TspInfoModule } from "./tsp-info/tsp-info.module";
-import { FunService } from "./shared/fun.service";
@NgModule({
declarations: [
@@ -15,11 +13,7 @@ import { FunService } from "./shared/fun.service";
BrowserModule,
AppRoutingModule,
KanbanModule,
- TspInfoModule,
- ],
- providers: [
- FunService,
],
bootstrap: [AppComponent]
})
-export class AppModule { }
+export class AppModule {}
diff --git a/src/app/kanban/kanban-entry-item/kanban-entry-item.component.html b/src/app/kanban/kanban-entry-item/kanban-entry-item.component.html
index 2f58d4f..c08d372 100644
--- a/src/app/kanban/kanban-entry-item/kanban-entry-item.component.html
+++ b/src/app/kanban/kanban-entry-item/kanban-entry-item.component.html
@@ -10,6 +10,8 @@
[ngClass]="entryClass(kanbanEntry)">
+
{{kanbanEntry.epicName}}
{{label|uppercase|blockedDays:kanbanEntry.daysBlocked}}
diff --git a/src/app/kanban/kanban-entry-item/kanban-entry-item.component.ts b/src/app/kanban/kanban-entry-item/kanban-entry-item.component.ts
index 78f0971..3ae8e11 100644
--- a/src/app/kanban/kanban-entry-item/kanban-entry-item.component.ts
+++ b/src/app/kanban/kanban-entry-item/kanban-entry-item.component.ts
@@ -1,11 +1,11 @@
import {Component, Input} from '@angular/core';
-import {environment} from "../../../environments/environment";
-import {KanbanEntry} from "../shared";
-import { JiraAssignee } from "../shared/jira-assignee.model";
+import { environment } from "../../../environments/environment";
+import { KanbanEntry } from "../shared";
+import { JiraAssignee } from "../shared";
const DEFAULT_AVATAR = '/assets/riddler.png';
-const JIRA_BOARD_BASE_HREF = 'https://jirapducc.mo.ca.am.ericsson.se/browse/';
+const JIRA_BOARD_BASE_HREF = 'https://cc-jira.rnd.ki.sw.ericsson.se/browse/';
const labelColors = {
TSP: 'teal',
diff --git a/src/app/kanban/kanban.module.ts b/src/app/kanban/kanban.module.ts
index 5bfc597..0d2994b 100644
--- a/src/app/kanban/kanban.module.ts
+++ b/src/app/kanban/kanban.module.ts
@@ -4,14 +4,13 @@ import { HttpModule } from "@angular/http";
import { KanbanBoardComponent } from './kanban-board/kanban-board.component';
-import { KanbanService } from './shared/kanban.service';
+import { KanbanService } from './shared';
import { KanbanEntryItemComponent } from './kanban-entry-item/kanban-entry-item.component';
import { PriorityColorPipe } from './shared/priority-color.pipe';
import { ShortenTextPipe } from './shared/shorten-text.pipe';
import { SelfUpdaterService } from './shared/self-updater.service';
import { BlockedDaysPipe } from './shared/blocked-days.pipe';
import { KanbanRoutingModule } from "./kanban-routing.module";
-import { TspInfoModule } from "../tsp-info/tsp-info.module";
import { PrefixJiraIdPipe } from './shared/prefix-jira-id.pipe';
@NgModule({
@@ -19,7 +18,6 @@ import { PrefixJiraIdPipe } from './shared/prefix-jira-id.pipe';
CommonModule,
HttpModule,
KanbanRoutingModule,
- TspInfoModule
],
declarations: [
KanbanBoardComponent,
diff --git a/src/app/kanban/shared/kanban-entry.model.ts b/src/app/kanban/shared/kanban-entry.model.ts
index b97a2db..dec4f24 100644
--- a/src/app/kanban/shared/kanban-entry.model.ts
+++ b/src/app/kanban/shared/kanban-entry.model.ts
@@ -7,22 +7,23 @@ export class KanbanEntry {
public key: string;
public summary: string;
public issueType: JiraIssueType;
+ public epicName: string;
public status: JiraStatus;
public assignee: JiraAssignee;
public additionalAssignees: Array = [];
public issuePriority: string;
public issuePriorityIcon: string;
public labels: Array;
- public prio: number;
- public functionalAreas: Array;
- public externalId: string;
- public externalLink: string;
- public project: string;
- public mhwebStatus: string;
- public mhwebHot: boolean;
- public mhwebExternal: boolean;
- public team: string;
- public answerCode: string;
+ // public prio: number;
+ // public functionalAreas: Array;
+ // public externalId: string;
+ // public externalLink: string;
+ // public project: string;
+ // public mhwebStatus: string;
+ // public mhwebHot: boolean;
+ // public mhwebExternal: boolean;
+ // public team: string;
+ // public answerCode: string;
public isLastOfPriority: boolean;
public worklog: number;
public daysBlocked: number;
diff --git a/src/app/kanban/shared/kanban.service.ts b/src/app/kanban/shared/kanban.service.ts
index f6ec934..4c1aed5 100644
--- a/src/app/kanban/shared/kanban.service.ts
+++ b/src/app/kanban/shared/kanban.service.ts
@@ -1,7 +1,7 @@
import { Injectable } from '@angular/core';
-import { Http, Headers } from "@angular/http";
+import { Http } from "@angular/http";
import 'rxjs/Rx';
-import { Router, Resolve, ActivatedRouteSnapshot } from '@angular/router';
+import { ActivatedRouteSnapshot } from '@angular/router';
import { Observable } from 'rxjs/Observable';
import { environment } from '../../../environments/environment';
@@ -23,7 +23,6 @@ export class KanbanService {
* @returns {Observable}
*/
public getList(): Observable {
- // return this.httpService.get(this.url).map(res => this.preprocessPriorities(res.json()));
return this.httpService.get(this.url).map(res => res.json());
}
@@ -51,27 +50,4 @@ export class KanbanService {
set kanbanBoard(kanbanBoard: KanbanBoard) {
this.cachedKanbanBoard = kanbanBoard;
}
-
- /**
- * Used to preprocess all the entries, mark last item of every priority type for display formatting
- *
- * @param {KanbanBoard} kanbanBoard
- * @returns {KanbanBoard}
- */
- // private preprocessPriorities(kanbanBoard: KanbanBoard): KanbanBoard {
- // ['inbox','inProgress','verification'].map(progress => {
- // kanbanBoard[progress].map(entry => entry.isLastOfPriority = false);
- // ['Trivial',
- // 'Minor',
- // 'Major',
- // 'Critical',
- // 'Blocker'].map(prio => {
- // let prioLastIndex = kanbanBoard[progress].reduce((accumulator, value, idx) => value.issuePriority==prio ? idx : accumulator, -1);
- // try {
- // kanbanBoard[progress][prioLastIndex].isLastOfPriority = true;
- // } catch(e) {}
- // });
- // });
- // return kanbanBoard;
- // }
}
diff --git a/src/app/shared/anim-gif.model.ts b/src/app/shared/anim-gif.model.ts
deleted file mode 100644
index 0ef3ee8..0000000
--- a/src/app/shared/anim-gif.model.ts
+++ /dev/null
@@ -1,4 +0,0 @@
-export class AnimGif {
- public url: string;
- public label: string;
-}
diff --git a/src/app/shared/fun.model.ts b/src/app/shared/fun.model.ts
deleted file mode 100644
index 31e58a2..0000000
--- a/src/app/shared/fun.model.ts
+++ /dev/null
@@ -1,6 +0,0 @@
-import {AnimGif} from "./anim-gif.model";
-
-export class Fun {
- public cameraUrls: Array = [];
- public animGifs: Array = [];
-}
diff --git a/src/app/shared/fun.service.spec.ts b/src/app/shared/fun.service.spec.ts
deleted file mode 100644
index 2995898..0000000
--- a/src/app/shared/fun.service.spec.ts
+++ /dev/null
@@ -1,15 +0,0 @@
-import { TestBed, inject } from '@angular/core/testing';
-
-import { FunService } from './fun.service';
-
-describe('FunService', () => {
- beforeEach(() => {
- TestBed.configureTestingModule({
- providers: [FunService]
- });
- });
-
- it('should be created', inject([FunService], (service: FunService) => {
- expect(service).toBeTruthy();
- }));
-});
diff --git a/src/app/shared/fun.service.ts b/src/app/shared/fun.service.ts
deleted file mode 100644
index 0734fd1..0000000
--- a/src/app/shared/fun.service.ts
+++ /dev/null
@@ -1,53 +0,0 @@
-import {Injectable} from '@angular/core';
-import {Http, Headers} from "@angular/http";
-import 'rxjs/Rx';
-import {Router, Resolve, ActivatedRouteSnapshot} from '@angular/router';
-import {Observable} from 'rxjs/Observable';
-
-import {environment} from '../../environments/environment';
-import {Fun} from "./fun.model";
-
-@Injectable()
-export class FunService {
- private url = environment.apiUri + '/api/want-some-fun';
-
- private cachedFun: Fun = new Fun();
-
- constructor(private httpService: Http) {
- }
-
- /**
- * Returns an observable instance to the kanban board api
- *
- * @returns {Observable}
- */
- public getList(): Observable {
- return this.httpService.get(this.url).map(res => res.json());
- }
-
- /**
- * Route preload resolver
- *
- * @param {ActivatedRouteSnapshot} route
- * @returns {Promise}
- */
- public resolve(route: ActivatedRouteSnapshot): Promise {
- return this.getList().toPromise().then(result => result ? result : false);
- }
-
- /**
- * Reload the board
- */
- public reload() {
- this.getList().subscribe(result => this.cachedFun = result);
- }
-
- get fun(): Fun {
- return this.cachedFun;
- }
-
- set fun(fun: Fun) {
- this.cachedFun = fun;
- }
-
-}
diff --git a/src/app/shared/index.ts b/src/app/shared/index.ts
deleted file mode 100644
index 3e3cee6..0000000
--- a/src/app/shared/index.ts
+++ /dev/null
@@ -1,4 +0,0 @@
-export * from './anim-gif.model';
-export * from './fun.model';
-
-export * from './fun.service';
diff --git a/src/app/tsp-info/animgif/animgif.component.css b/src/app/tsp-info/animgif/animgif.component.css
deleted file mode 100644
index f3b6776..0000000
--- a/src/app/tsp-info/animgif/animgif.component.css
+++ /dev/null
@@ -1,13 +0,0 @@
-:host(.kanban-view) {
- position: absolute;
- z-index: 100;
- bottom: 0;
- right: 0;
- background-color: rgba(0,41,94,0.95);
- width: 480px;
- height: 500px;
-}
-
-.widget.camera {
- padding: 0;
-}
diff --git a/src/app/tsp-info/animgif/animgif.component.html b/src/app/tsp-info/animgif/animgif.component.html
deleted file mode 100644
index 1dbaf2d..0000000
--- a/src/app/tsp-info/animgif/animgif.component.html
+++ /dev/null
@@ -1,3 +0,0 @@
-
diff --git a/src/app/tsp-info/animgif/animgif.component.spec.ts b/src/app/tsp-info/animgif/animgif.component.spec.ts
deleted file mode 100644
index 2e64049..0000000
--- a/src/app/tsp-info/animgif/animgif.component.spec.ts
+++ /dev/null
@@ -1,25 +0,0 @@
-import { async, ComponentFixture, TestBed } from '@angular/core/testing';
-
-import { AnimgifComponent } from './animgif.component';
-
-describe('AnimgifComponent', () => {
- let component: AnimgifComponent;
- let fixture: ComponentFixture;
-
- beforeEach(async(() => {
- TestBed.configureTestingModule({
- declarations: [ AnimgifComponent ]
- })
- .compileComponents();
- }));
-
- beforeEach(() => {
- fixture = TestBed.createComponent(AnimgifComponent);
- component = fixture.componentInstance;
- fixture.detectChanges();
- });
-
- it('should be created', () => {
- expect(component).toBeTruthy();
- });
-});
diff --git a/src/app/tsp-info/animgif/animgif.component.ts b/src/app/tsp-info/animgif/animgif.component.ts
deleted file mode 100644
index 3d92881..0000000
--- a/src/app/tsp-info/animgif/animgif.component.ts
+++ /dev/null
@@ -1,37 +0,0 @@
-import {Component, Input, OnDestroy, OnInit} from '@angular/core';
-import {InfoBoxComponent} from "../info-box/info-box.component";
-import {AnimGif} from "../../shared/anim-gif.model";
-
-// import gifyParse from "gify-parse/gify-parse";
-
-@Component({
- selector: 'app-animgif',
- templateUrl: './animgif.component.html',
- styleUrls: [
- '../info-box/info-box.component.css',
- './animgif.component.css'
- ]
-})
-export class AnimgifComponent extends InfoBoxComponent implements OnInit, OnDestroy {
-
- @Input() data: Array = [];
- @Input() cameraUrls: Array = [];
-
- constructor() {
- super();
- // gifyParse.getInfo();
- }
-
- ngOnInit() {
- // @todo subscriber
- }
-
- ngOnDestroy() {
-
- }
-
- get imgHref(): string {
- return this.cameraUrls[1];
- }
-
-}
diff --git a/src/app/tsp-info/expedites/expedites.component.css b/src/app/tsp-info/expedites/expedites.component.css
deleted file mode 100644
index a9ec512..0000000
--- a/src/app/tsp-info/expedites/expedites.component.css
+++ /dev/null
@@ -1,16 +0,0 @@
-h2 {
- text-transform: uppercase;
- font-size: 76px;
- font-weight: 700
-}
-
-h3 {
- font-weight: 500;
- font-size: 30px;
- color: white;
-}
-
-p {
- font-size: 15px;
- color: rgba(255, 255, 255, 0.7);
-}
\ No newline at end of file
diff --git a/src/app/tsp-info/expedites/expedites.component.html b/src/app/tsp-info/expedites/expedites.component.html
deleted file mode 100644
index b6bef4b..0000000
--- a/src/app/tsp-info/expedites/expedites.component.html
+++ /dev/null
@@ -1,7 +0,0 @@
-
\ No newline at end of file
diff --git a/src/app/tsp-info/expedites/expedites.component.spec.ts b/src/app/tsp-info/expedites/expedites.component.spec.ts
deleted file mode 100644
index f6d4c09..0000000
--- a/src/app/tsp-info/expedites/expedites.component.spec.ts
+++ /dev/null
@@ -1,25 +0,0 @@
-import { async, ComponentFixture, TestBed } from '@angular/core/testing';
-
-import { ExpeditesComponent } from './expedites.component';
-
-describe('ExpeditesComponent', () => {
- let component: ExpeditesComponent;
- let fixture: ComponentFixture;
-
- beforeEach(async(() => {
- TestBed.configureTestingModule({
- declarations: [ ExpeditesComponent ]
- })
- .compileComponents();
- }));
-
- beforeEach(() => {
- fixture = TestBed.createComponent(ExpeditesComponent);
- component = fixture.componentInstance;
- fixture.detectChanges();
- });
-
- it('should be created', () => {
- expect(component).toBeTruthy();
- });
-});
diff --git a/src/app/tsp-info/expedites/expedites.component.ts b/src/app/tsp-info/expedites/expedites.component.ts
deleted file mode 100644
index f3c4070..0000000
--- a/src/app/tsp-info/expedites/expedites.component.ts
+++ /dev/null
@@ -1,30 +0,0 @@
-import {Component, Input, OnInit} from '@angular/core';
-import {InfoBoxComponent} from "../info-box/info-box.component";
-import {ExpediteInfo} from "../shared/expedite-info.model";
-
-@Component({
- selector: 'app-expedites',
- templateUrl: './expedites.component.html',
- styleUrls: [
- '../info-box/info-box.component.css',
- './expedites.component.css'
- ]
-})
-export class ExpeditesComponent extends InfoBoxComponent implements OnInit {
-
- @Input() data: ExpediteInfo;
-
- constructor() {
- super();
- }
-
- ngOnInit() {}
-
- get widgetClass(): string {
- return this.data.unassigned > 0
- ? 'critical'
- : this.data.all > 0
- ? 'warn'
- : 'ok';
- }
-}
diff --git a/src/app/tsp-info/info-box/info-box.component.css b/src/app/tsp-info/info-box/info-box.component.css
deleted file mode 100644
index 807450c..0000000
--- a/src/app/tsp-info/info-box/info-box.component.css
+++ /dev/null
@@ -1,107 +0,0 @@
-:host {
- position: absolute;
- z-index: 2;
- display: table;
- width: 468px;
- height: 525px;
- background-color: #00285F;
- color: rgba(255, 255, 255, 0.7);
- font-family: 'Open Sans', "Helvetica Neue", Helvetica, Arial, sans-serif;
- font-size: 20px;
- box-shadow: 5px 5px 10px #222;
-}
-
-:host-context(.sizex2) {
- width: 946px;
-}
-
-:host-context(.sizey2) {
- height: 1060px;
-}
-
-:host-context(.col1) {
- left: 10px;
-}
-
-:host-context(.col2) {
- left: 488px;
-}
-
-:host-context(.col3) {
- left: 966px;
-}
-
-:host-context(.col4) {
- left: 1444px;
-}
-
-:host-context(.row1) {
- top: 10px;
-}
-
-:host-context(.row2) {
- top: 545px;
-}
-
-h1 {
- font-family: 'EricssonCapital', "Helvetica Neue", Helvetica, Arial, sans-serif;
- margin-bottom: 12px;
- text-align: center;
- font-size: 30px;
- font-weight: bold;
- padding: 0;
-}
-
-ul {
- list-style: none;
- margin: 0 15px;
- padding: 0;
- overflow: hidden;
-}
-
-ul > li {
- margin: 0 0 5px;
- overflow: hidden;
-}
-
-ul > li > span.label {
- float: left;
-}
-
-ul > li > span.value {
- float: right;
-}
-
-.widget {
- width: 100%;
- height: 100%;
- padding: 52px 12px;
- display: table-cell;
- vertical-align: middle;
- text-align: center;
- position: relative;
-}
-
-.icon-background {
- width: 100% !important;
- height: 100%;
- position: absolute;
- left: 0;
- top: 0;
- opacity: 0.1;
- font-size: 300px;
- text-align: center;
- margin-top: 255px;
-}
-
-.ok {
- background-color: rgb(137, 186, 23);
-}
-
-.warn {
- background-color: #E95C38;
-}
-
-.critical {
- background-color: rgb(227, 33, 25);
-}
diff --git a/src/app/tsp-info/info-box/info-box.component.html b/src/app/tsp-info/info-box/info-box.component.html
deleted file mode 100644
index 9eb7d13..0000000
--- a/src/app/tsp-info/info-box/info-box.component.html
+++ /dev/null
@@ -1 +0,0 @@
-info-box works!
diff --git a/src/app/tsp-info/info-box/info-box.component.spec.ts b/src/app/tsp-info/info-box/info-box.component.spec.ts
deleted file mode 100644
index 527ba2d..0000000
--- a/src/app/tsp-info/info-box/info-box.component.spec.ts
+++ /dev/null
@@ -1,25 +0,0 @@
-import { async, ComponentFixture, TestBed } from '@angular/core/testing';
-
-import { InfoBoxComponent } from './info-box.component';
-
-describe('InfoBoxComponent', () => {
- let component: InfoBoxComponent;
- let fixture: ComponentFixture;
-
- beforeEach(async(() => {
- TestBed.configureTestingModule({
- declarations: [ InfoBoxComponent ]
- })
- .compileComponents();
- }));
-
- beforeEach(() => {
- fixture = TestBed.createComponent(InfoBoxComponent);
- component = fixture.componentInstance;
- fixture.detectChanges();
- });
-
- it('should be created', () => {
- expect(component).toBeTruthy();
- });
-});
diff --git a/src/app/tsp-info/info-box/info-box.component.ts b/src/app/tsp-info/info-box/info-box.component.ts
deleted file mode 100644
index a490651..0000000
--- a/src/app/tsp-info/info-box/info-box.component.ts
+++ /dev/null
@@ -1,21 +0,0 @@
-import {Component, Input, OnInit} from '@angular/core';
-
-@Component({
- selector: 'app-info-box',
- templateUrl: './info-box.component.html',
- styleUrls: ['./info-box.component.css']
-})
-export class InfoBoxComponent implements OnInit {
-
- @Input() title = '';
- @Input() data: any;
-
- constructor() { }
-
- ngOnInit() {
- }
-
- get widgetClass(): string {
- return '';
- }
-}
diff --git a/src/app/tsp-info/info-page/info-page.component.css b/src/app/tsp-info/info-page/info-page.component.css
deleted file mode 100644
index e69de29..0000000
diff --git a/src/app/tsp-info/info-page/info-page.component.html b/src/app/tsp-info/info-page/info-page.component.html
deleted file mode 100644
index 8387feb..0000000
--- a/src/app/tsp-info/info-page/info-page.component.html
+++ /dev/null
@@ -1,22 +0,0 @@
-
-
-
-
-
-
diff --git a/src/app/tsp-info/info-page/info-page.component.spec.ts b/src/app/tsp-info/info-page/info-page.component.spec.ts
deleted file mode 100644
index 52ce52c..0000000
--- a/src/app/tsp-info/info-page/info-page.component.spec.ts
+++ /dev/null
@@ -1,25 +0,0 @@
-import { async, ComponentFixture, TestBed } from '@angular/core/testing';
-
-import { InfoPageComponent } from './info-page.component';
-
-describe('InfoPageComponent', () => {
- let component: InfoPageComponent;
- let fixture: ComponentFixture;
-
- beforeEach(async(() => {
- TestBed.configureTestingModule({
- declarations: [ InfoPageComponent ]
- })
- .compileComponents();
- }));
-
- beforeEach(() => {
- fixture = TestBed.createComponent(InfoPageComponent);
- component = fixture.componentInstance;
- fixture.detectChanges();
- });
-
- it('should be created', () => {
- expect(component).toBeTruthy();
- });
-});
diff --git a/src/app/tsp-info/info-page/info-page.component.ts b/src/app/tsp-info/info-page/info-page.component.ts
deleted file mode 100644
index 2428a3d..0000000
--- a/src/app/tsp-info/info-page/info-page.component.ts
+++ /dev/null
@@ -1,51 +0,0 @@
-import {Component, OnInit} from '@angular/core';
-import {ActivatedRoute} from "@angular/router";
-import {Title} from "@angular/platform-browser";
-
-import {
- TspInfo,
- TspInfoService,
-} from "../shared";
-import {FunService} from "../../shared/fun.service";
-import {Fun} from "../../shared/fun.model";
-
-@Component({
- selector: 'app-info-page',
- templateUrl: './info-page.component.html',
- styleUrls: ['./info-page.component.css']
-})
-export class InfoPageComponent implements OnInit {
-
- constructor(private titleService: Title,
- private route: ActivatedRoute,
- private tspInfoService: TspInfoService,
- private funService: FunService) {
- }
-
- ngOnInit() {
- this.titleService.setTitle('TaurusXFT : TSP INFO');
- this.route.data.subscribe((data: {
- tspInfo: TspInfo,
- fun: Fun
- }) => {
- this.tspInfo = data.tspInfo;
- this.fun = data.fun;
- });
- }
-
- get tspInfo(): TspInfo {
- return this.tspInfoService.tspInfo;
- }
-
- set tspInfo(tspInfo: TspInfo) {
- this.tspInfoService.tspInfo = tspInfo;
- }
-
- get fun(): Fun {
- return this.funService.fun;
- }
-
- set fun(fun: Fun) {
- this.funService.fun = fun;
- }
-}
diff --git a/src/app/tsp-info/pra-goals/pra-goals.component.css b/src/app/tsp-info/pra-goals/pra-goals.component.css
deleted file mode 100644
index 349fc03..0000000
--- a/src/app/tsp-info/pra-goals/pra-goals.component.css
+++ /dev/null
@@ -1,28 +0,0 @@
-p > span {
- margin: 0 30px;
-}
-
-.header {
- margin: 0 20px 0;
- font-size: 20px;
- font-weight: 200;
-}
-
-.smallnum {
- font-size: 30px;
- font-weight: 500;
-}
-
-.bignum {
- text-transform: uppercase;
- font-size: 76px;
- font-weight: 700;
-}
-
-.numok {
- color: rgb(137, 186, 23);
-}
-
-.numbad {
- color: rgb(227, 33, 25);
-}
\ No newline at end of file
diff --git a/src/app/tsp-info/pra-goals/pra-goals.component.html b/src/app/tsp-info/pra-goals/pra-goals.component.html
deleted file mode 100644
index 2930e2e..0000000
--- a/src/app/tsp-info/pra-goals/pra-goals.component.html
+++ /dev/null
@@ -1,27 +0,0 @@
-
diff --git a/src/app/tsp-info/pra-goals/pra-goals.component.spec.ts b/src/app/tsp-info/pra-goals/pra-goals.component.spec.ts
deleted file mode 100644
index 5e47721..0000000
--- a/src/app/tsp-info/pra-goals/pra-goals.component.spec.ts
+++ /dev/null
@@ -1,25 +0,0 @@
-import { async, ComponentFixture, TestBed } from '@angular/core/testing';
-
-import { PraGoalsComponent } from './pra-goals.component';
-
-describe('PraGoalsComponent', () => {
- let component: PraGoalsComponent;
- let fixture: ComponentFixture;
-
- beforeEach(async(() => {
- TestBed.configureTestingModule({
- declarations: [ PraGoalsComponent ]
- })
- .compileComponents();
- }));
-
- beforeEach(() => {
- fixture = TestBed.createComponent(PraGoalsComponent);
- component = fixture.componentInstance;
- fixture.detectChanges();
- });
-
- it('should be created', () => {
- expect(component).toBeTruthy();
- });
-});
diff --git a/src/app/tsp-info/pra-goals/pra-goals.component.ts b/src/app/tsp-info/pra-goals/pra-goals.component.ts
deleted file mode 100644
index b85736c..0000000
--- a/src/app/tsp-info/pra-goals/pra-goals.component.ts
+++ /dev/null
@@ -1,47 +0,0 @@
-import {Component, Input, OnInit} from '@angular/core';
-import {InfoBoxComponent} from "../info-box/info-box.component";
-import {PrioValues} from "../shared/prio-values.model";
-
-@Component({
- selector: 'app-pra-goals',
- templateUrl: './pra-goals.component.html',
- styleUrls: [
- '../info-box/info-box.component.css',
- './pra-goals.component.css'
- ]
-})
-export class PraGoalsComponent extends InfoBoxComponent implements OnInit {
-
- @Input() data: {
- core: PrioValues,
- sig: PrioValues,
- tade: PrioValues
- };
-
- constructor() {
- super();
- }
-
- ngOnInit() {
- }
-
- get sumA(): number {
- return this.sum('A');
- }
-
- get sumB(): number {
- return this.sum('B');
- }
-
- get sumC(): number {
- return this.sum('C');
- }
-
- public sum(prio: string) {
- return ['core', 'sig', 'tade'].reduce((sum,unit) => sum + this.data[unit][prio], 0);
- }
-
- public getClass(value: number) {
- return value < 1 ? 'numok' : 'numbad';
- }
-}
diff --git a/src/app/tsp-info/shared/expedite-info.model.ts b/src/app/tsp-info/shared/expedite-info.model.ts
deleted file mode 100644
index fd98a49..0000000
--- a/src/app/tsp-info/shared/expedite-info.model.ts
+++ /dev/null
@@ -1,4 +0,0 @@
-export class ExpediteInfo {
- public unassigned: number;
- public all: number;
-}
diff --git a/src/app/tsp-info/shared/index.ts b/src/app/tsp-info/shared/index.ts
deleted file mode 100644
index e375372..0000000
--- a/src/app/tsp-info/shared/index.ts
+++ /dev/null
@@ -1,8 +0,0 @@
-export * from './expedite-info.model';
-export * from './lab-temperature.model';
-export * from './tr-flow-error.model';
-export * from './prio-values.model';
-export * from './tr-progress.model';
-export * from './tsp-info.model';
-
-export * from './tsp-info.service';
diff --git a/src/app/tsp-info/shared/lab-temperature.model.ts b/src/app/tsp-info/shared/lab-temperature.model.ts
deleted file mode 100644
index f591cf0..0000000
--- a/src/app/tsp-info/shared/lab-temperature.model.ts
+++ /dev/null
@@ -1,2 +0,0 @@
-export class LabTemperature {
-}
diff --git a/src/app/tsp-info/shared/prio-values.model.ts b/src/app/tsp-info/shared/prio-values.model.ts
deleted file mode 100644
index ee66f3d..0000000
--- a/src/app/tsp-info/shared/prio-values.model.ts
+++ /dev/null
@@ -1,5 +0,0 @@
-export class PrioValues {
- public A: number = 0;
- public B: number = 0;
- public C: number = 0;
-}
diff --git a/src/app/tsp-info/shared/tr-flow-error.model.ts b/src/app/tsp-info/shared/tr-flow-error.model.ts
deleted file mode 100644
index f84d0fe..0000000
--- a/src/app/tsp-info/shared/tr-flow-error.model.ts
+++ /dev/null
@@ -1,4 +0,0 @@
-export class TrFlowError {
- public label: string = '';
- public value: number = 0;
-}
diff --git a/src/app/tsp-info/shared/tr-progress.model.ts b/src/app/tsp-info/shared/tr-progress.model.ts
deleted file mode 100644
index a68f587..0000000
--- a/src/app/tsp-info/shared/tr-progress.model.ts
+++ /dev/null
@@ -1,6 +0,0 @@
-export class TrProgress {
- public eriref: string = '';
- public heading: string = '';
- public prio: string = '';
- public lastProgressInDays: number = 0;
-}
diff --git a/src/app/tsp-info/shared/tsp-info.model.ts b/src/app/tsp-info/shared/tsp-info.model.ts
deleted file mode 100644
index cdee451..0000000
--- a/src/app/tsp-info/shared/tsp-info.model.ts
+++ /dev/null
@@ -1,28 +0,0 @@
-import {
- ExpediteInfo,
- LabTemperature,
- PrioValues,
- TrProgress,
- TrFlowError
-} from ".";
-
-
-export class TspInfo {
- public praGoals: {
- core: PrioValues,
- sig: PrioValues,
- tade: PrioValues
- };
- public trProgressInfo: Array = [];
- public trFlowErrors: Array = [];
- public expedites: ExpediteInfo = {
- unassigned: 0,
- all: 0
- };
- public isVacationSoon: boolean = false;
- public labTemperature: LabTemperature = {
- back_right: 0,
- back_middle: 0,
- back_left: 0
- };
-}
diff --git a/src/app/tsp-info/shared/tsp-info.service.spec.ts b/src/app/tsp-info/shared/tsp-info.service.spec.ts
deleted file mode 100644
index 79a32bb..0000000
--- a/src/app/tsp-info/shared/tsp-info.service.spec.ts
+++ /dev/null
@@ -1,15 +0,0 @@
-import { TestBed, inject } from '@angular/core/testing';
-
-import { TspInfoService } from './tsp-info.service';
-
-describe('TspInfoService', () => {
- beforeEach(() => {
- TestBed.configureTestingModule({
- providers: [TspInfoService]
- });
- });
-
- it('should be created', inject([TspInfoService], (service: TspInfoService) => {
- expect(service).toBeTruthy();
- }));
-});
diff --git a/src/app/tsp-info/shared/tsp-info.service.ts b/src/app/tsp-info/shared/tsp-info.service.ts
deleted file mode 100644
index ab2505f..0000000
--- a/src/app/tsp-info/shared/tsp-info.service.ts
+++ /dev/null
@@ -1,54 +0,0 @@
-import {Injectable} from '@angular/core';
-import {Http, Headers} from "@angular/http";
-import 'rxjs/Rx';
-import {Router, Resolve, ActivatedRouteSnapshot} from '@angular/router';
-import {Observable} from 'rxjs/Observable';
-
-import {environment} from '../../../environments/environment';
-import {
- TspInfo
-} from '.';
-
-@Injectable()
-export class TspInfoService {
- private url = environment.apiUri + '/api/tsp-info';
-
- private cachedTspInfo: TspInfo = new TspInfo();
-
- constructor(private httpService: Http) {}
-
- /**
- * Returns an observable instance to the kanban board api
- *
- * @returns {Observable}
- */
- public getList(): Observable {
- return this.httpService.get(this.url).map(res => res.json());
- }
-
- /**
- * Route preload resolver
- *
- * @param {ActivatedRouteSnapshot} route
- * @returns {Promise}
- */
- public resolve(route: ActivatedRouteSnapshot): Promise {
- return this.getList().toPromise().then(result => result ? result : false);
- }
-
- /**
- * Reload the board
- */
- public reload() {
- this.getList().subscribe(result => this.cachedTspInfo = result);
- }
-
- get tspInfo(): TspInfo {
- return this.cachedTspInfo;
- }
-
- set tspInfo(tspInfo: TspInfo) {
- this.cachedTspInfo = tspInfo;
- }
-
-}
diff --git a/src/app/tsp-info/tr-flow-errors/tr-flow-errors.component.css b/src/app/tsp-info/tr-flow-errors/tr-flow-errors.component.css
deleted file mode 100644
index e69de29..0000000
diff --git a/src/app/tsp-info/tr-flow-errors/tr-flow-errors.component.html b/src/app/tsp-info/tr-flow-errors/tr-flow-errors.component.html
deleted file mode 100644
index e12ca18..0000000
--- a/src/app/tsp-info/tr-flow-errors/tr-flow-errors.component.html
+++ /dev/null
@@ -1,10 +0,0 @@
-
\ No newline at end of file
diff --git a/src/app/tsp-info/tr-flow-errors/tr-flow-errors.component.spec.ts b/src/app/tsp-info/tr-flow-errors/tr-flow-errors.component.spec.ts
deleted file mode 100644
index 2a57b94..0000000
--- a/src/app/tsp-info/tr-flow-errors/tr-flow-errors.component.spec.ts
+++ /dev/null
@@ -1,25 +0,0 @@
-import { async, ComponentFixture, TestBed } from '@angular/core/testing';
-
-import { TrFlowErrorsComponent } from './tr-flow-errors.component';
-
-describe('TrFlowErrorsComponent', () => {
- let component: TrFlowErrorsComponent;
- let fixture: ComponentFixture;
-
- beforeEach(async(() => {
- TestBed.configureTestingModule({
- declarations: [ TrFlowErrorsComponent ]
- })
- .compileComponents();
- }));
-
- beforeEach(() => {
- fixture = TestBed.createComponent(TrFlowErrorsComponent);
- component = fixture.componentInstance;
- fixture.detectChanges();
- });
-
- it('should be created', () => {
- expect(component).toBeTruthy();
- });
-});
diff --git a/src/app/tsp-info/tr-flow-errors/tr-flow-errors.component.ts b/src/app/tsp-info/tr-flow-errors/tr-flow-errors.component.ts
deleted file mode 100644
index 70eb768..0000000
--- a/src/app/tsp-info/tr-flow-errors/tr-flow-errors.component.ts
+++ /dev/null
@@ -1,31 +0,0 @@
-import {Component, Input, OnInit} from '@angular/core';
-import {InfoBoxComponent} from "../info-box/info-box.component";
-import {TrFlowError} from "../shared/tr-flow-error.model";
-
-@Component({
- selector: 'app-tr-flow-errors',
- templateUrl: './tr-flow-errors.component.html',
- styleUrls: [
- '../info-box/info-box.component.css',
- './tr-flow-errors.component.css'
- ]
-})
-export class TrFlowErrorsComponent extends InfoBoxComponent implements OnInit {
-
- @Input() data: Array = [];
-
- constructor() {
- super();
- }
-
- ngOnInit() {
- }
-
- get errorSum(): number {
- return this.data.reduce((sum: number, flowError: TrFlowError) => sum + flowError.value, 0);
- }
-
- get widgetClass(): string {
- return this.data.length ? 'warn' : 'ok';
- }
-}
diff --git a/src/app/tsp-info/tr-progress/tr-progress.component.css b/src/app/tsp-info/tr-progress/tr-progress.component.css
deleted file mode 100644
index 7017376..0000000
--- a/src/app/tsp-info/tr-progress/tr-progress.component.css
+++ /dev/null
@@ -1,3 +0,0 @@
-.separator {
- margin-top: 65px;
-}
\ No newline at end of file
diff --git a/src/app/tsp-info/tr-progress/tr-progress.component.html b/src/app/tsp-info/tr-progress/tr-progress.component.html
deleted file mode 100644
index e90307e..0000000
--- a/src/app/tsp-info/tr-progress/tr-progress.component.html
+++ /dev/null
@@ -1,17 +0,0 @@
-
diff --git a/src/app/tsp-info/tr-progress/tr-progress.component.spec.ts b/src/app/tsp-info/tr-progress/tr-progress.component.spec.ts
deleted file mode 100644
index 562c9f3..0000000
--- a/src/app/tsp-info/tr-progress/tr-progress.component.spec.ts
+++ /dev/null
@@ -1,25 +0,0 @@
-import { async, ComponentFixture, TestBed } from '@angular/core/testing';
-
-import { TrProgressComponent } from './tr-progress.component';
-
-describe('TrProgressComponent', () => {
- let component: TrProgressComponent;
- let fixture: ComponentFixture;
-
- beforeEach(async(() => {
- TestBed.configureTestingModule({
- declarations: [ TrProgressComponent ]
- })
- .compileComponents();
- }));
-
- beforeEach(() => {
- fixture = TestBed.createComponent(TrProgressComponent);
- component = fixture.componentInstance;
- fixture.detectChanges();
- });
-
- it('should be created', () => {
- expect(component).toBeTruthy();
- });
-});
diff --git a/src/app/tsp-info/tr-progress/tr-progress.component.ts b/src/app/tsp-info/tr-progress/tr-progress.component.ts
deleted file mode 100644
index fc7b61c..0000000
--- a/src/app/tsp-info/tr-progress/tr-progress.component.ts
+++ /dev/null
@@ -1,38 +0,0 @@
-import {Component, Input, OnInit} from '@angular/core';
-import {InfoBoxComponent} from "../info-box/info-box.component";
-import {TrProgress} from "../shared/tr-progress.model";
-import {TrFlowError} from "../shared/tr-flow-error.model";
-
-@Component({
- selector: 'app-tr-progress',
- templateUrl: './tr-progress.component.html',
- styleUrls: [
- '../info-box/info-box.component.css',
- './tr-progress.component.css'
- ]
-})
-export class TrProgressComponent extends InfoBoxComponent implements OnInit {
-
- @Input() data: {
- topData: Array,
- bottomData: Array,
- };
-
- constructor() {
- super();
- }
-
- ngOnInit() {
- }
-
- get widgetClass(): string {
- return [
- this.data.topData,
- this.data.bottomData
- ].every(data => data.length > 0) ? 'critical' : 'ok';
- }
-
- get errorSum(): number {
- return this.data.bottomData.reduce((sum: number, flowError: TrFlowError) => sum + flowError.value, 0);
- }
-}
diff --git a/src/app/tsp-info/tsp-info-routing.module.ts b/src/app/tsp-info/tsp-info-routing.module.ts
deleted file mode 100644
index a707103..0000000
--- a/src/app/tsp-info/tsp-info-routing.module.ts
+++ /dev/null
@@ -1,24 +0,0 @@
-import {NgModule} from '@angular/core';
-import {Routes, RouterModule} from '@angular/router';
-import {InfoPageComponent} from "./info-page/info-page.component";
-import {TspInfoService} from "./shared/tsp-info.service";
-import {FunService} from "../shared/fun.service";
-
-const routes: Routes = [
- {
- path: 'tspinfopage',
- children: [],
- component: InfoPageComponent,
- resolve: {
- tspInfo: TspInfoService,
- fun: FunService,
- },
- }
-];
-
-@NgModule({
- imports: [RouterModule.forChild(routes)],
- exports: [RouterModule]
-})
-export class TspInfoRoutingModule {
-}
diff --git a/src/app/tsp-info/tsp-info.module.ts b/src/app/tsp-info/tsp-info.module.ts
deleted file mode 100644
index b70f537..0000000
--- a/src/app/tsp-info/tsp-info.module.ts
+++ /dev/null
@@ -1,36 +0,0 @@
-import {NgModule} from '@angular/core';
-import {CommonModule} from '@angular/common';
-
-import {TspInfoRoutingModule} from './tsp-info-routing.module';
-import {InfoBoxComponent} from './info-box/info-box.component';
-import {TrProgressComponent} from './tr-progress/tr-progress.component';
-import {ExpeditesComponent} from './expedites/expedites.component';
-import {TrFlowErrorsComponent} from './tr-flow-errors/tr-flow-errors.component';
-import {PraGoalsComponent} from './pra-goals/pra-goals.component';
-import {InfoPageComponent} from './info-page/info-page.component';
-import {AnimgifComponent} from './animgif/animgif.component';
-import {TspInfoService} from './shared/tsp-info.service';
-import {HttpModule} from "@angular/http";
-
-@NgModule({
- imports: [
- CommonModule,
- HttpModule,
- TspInfoRoutingModule
- ],
- exports:[
- AnimgifComponent,
- ],
- declarations: [
- InfoBoxComponent,
- TrProgressComponent,
- ExpeditesComponent,
- TrFlowErrorsComponent,
- PraGoalsComponent,
- InfoPageComponent,
- AnimgifComponent
- ],
- providers: [TspInfoService]
-})
-export class TspInfoModule {
-}