X-Git-Url: https://gerrit.automotivelinux.org/gerrit/gitweb?a=blobdiff_plain;f=webapp%2Fsrc%2Fapp%2Fdevel%2Fdevel.component.ts;fp=webapp%2Fsrc%2Fapp%2Fdevel%2Fdevel.component.ts;h=0000000000000000000000000000000000000000;hb=38c0c21a969e621c725245ce91c78e77076c5ce7;hp=eda03eff7fbc28ba9a1713eaa02f45c84d309cd8;hpb=b0d130807fb9bf36f5ac1abe21cbd558eb86d5cc;p=src%2Fxds%2Fxds-agent.git diff --git a/webapp/src/app/devel/devel.component.ts b/webapp/src/app/devel/devel.component.ts deleted file mode 100644 index eda03ef..0000000 --- a/webapp/src/app/devel/devel.component.ts +++ /dev/null @@ -1,34 +0,0 @@ -import { Component, OnInit, ViewEncapsulation } from '@angular/core'; -import { Observable } from 'rxjs/Observable'; - -import { ProjectService, IProject } from '../services/project.service'; - -@Component({ - selector: 'xds-devel', - templateUrl: './devel.component.html', - styleUrls: ['./devel.component.css'], - encapsulation: ViewEncapsulation.None -}) - -export class DevelComponent implements OnInit { - - curPrj: IProject; - Prjs$: Observable; - - constructor(private projectSvr: ProjectService) { - } - - ngOnInit() { - this.Prjs$ = this.projectSvr.Projects$; - this.Prjs$.subscribe((prjs) => { - // Select project if no one is selected or no project exists - if (this.curPrj && 'id' in this.curPrj) { - this.curPrj = prjs.find(p => p.id === this.curPrj.id) || prjs[0]; - } else if (this.curPrj == null) { - this.curPrj = prjs[0]; - } else { - this.curPrj = null; - } - }); - } -}