member_webapp/@overflow/noauth-probe/component/noauth-probe-detail.component.ts
2018-06-14 14:35:59 +09:00

46 lines
1.2 KiB
TypeScript

import { Component, Input, Output, EventEmitter, OnInit } from '@angular/core';
import { Probe, ProbeHost } from '@overflow/commons-typescript/model/probe';
import { Store, select } from '@ngrx/store';
import { Observable, of, Subscription } from 'rxjs';
import { catchError, exhaustMap, map, tap, take } from 'rxjs/operators';
import { NoAuthProbeService } from '../service/noauth-probe.service';
@Component({
selector: 'of-noauth-probe-detail',
templateUrl: './noauth-probe-detail.component.html',
})
export class NoAuthProbeDetailComponent implements OnInit {
// @Input() probeHostID;
pending$: Observable<boolean>;
error$: Observable<any>;
@Output() discovery = new EventEmitter<number>();
constructor(
private noAuthProbeService: NoAuthProbeService,
) {
}
ngOnInit() {
// this.noAuthProbeService.read(1)
// .pipe(
// tap(() => {
// this.pending$ = of(true);
// }),
// map((probeHost: ProbeHost) => {
// this.probeHost = probeHost;
// }),
// catchError(error => {
// this.error$ = of(error);
// return of();
// }),
// tap(() => {
// this.pending$ = of(false);
// }),
// take(1),
// ).subscribe();
}
}