meta crawler
This commit is contained in:
parent
4ae2106219
commit
928c09eb7f
|
@ -17,6 +17,6 @@ export class MetaCrawlerService {
|
||||||
}
|
}
|
||||||
|
|
||||||
public readAll(): Observable<MetaCrawler[]> {
|
public readAll(): Observable<MetaCrawler[]> {
|
||||||
return this.rpcClient.call('CrawlerService.readAll');
|
return this.rpcClient.call('MetaCrawlerService.readAll');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -16,7 +16,7 @@ import { MetaCrawler } from 'packages/meta/crawler/model/MetaCrawler';
|
||||||
})
|
})
|
||||||
export class CrawlerSelectorComponent implements OnInit, OnChanges, AfterContentInit {
|
export class CrawlerSelectorComponent implements OnInit, OnChanges, AfterContentInit {
|
||||||
|
|
||||||
crawlers$ = this.listStore.pipe(select(ReadAllCrawlerSelector.select('list')));
|
crawlers$ = this.listStore.pipe(select(ReadAllCrawlerSelector.select('metaCrawlerList')));
|
||||||
|
|
||||||
@Input() selectedTarget: Target;
|
@Input() selectedTarget: Target;
|
||||||
crawlers: MetaCrawler[];
|
crawlers: MetaCrawler[];
|
||||||
|
@ -30,7 +30,7 @@ export class CrawlerSelectorComponent implements OnInit, OnChanges, AfterContent
|
||||||
this.crawlers$.subscribe(
|
this.crawlers$.subscribe(
|
||||||
(list: MetaCrawler[]) => {
|
(list: MetaCrawler[]) => {
|
||||||
if (list !== null) {
|
if (list !== null) {
|
||||||
console.log(list);
|
this.crawlers = list;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
(error: RPCError) => {
|
(error: RPCError) => {
|
||||||
|
@ -44,18 +44,9 @@ export class CrawlerSelectorComponent implements OnInit, OnChanges, AfterContent
|
||||||
}
|
}
|
||||||
|
|
||||||
ngOnChanges() {
|
ngOnChanges() {
|
||||||
if (this.selectedTarget) {
|
// if (this.selectedTarget) {
|
||||||
console.log('Getting valid crawlers for ' + this.selectedTarget.displayName);
|
// console.log('Getting valid crawlers for ' + this.selectedTarget.displayName);
|
||||||
}
|
// }
|
||||||
|
|
||||||
this.crawlers = new Array();
|
|
||||||
for (let i = 0; i < 3; i++) {
|
|
||||||
const c: MetaCrawler = {
|
|
||||||
id: i,
|
|
||||||
name: 'Crawler' + i,
|
|
||||||
};
|
|
||||||
this.crawlers.push(c);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
crawlerSelected(crawler: MetaCrawler) {
|
crawlerSelected(crawler: MetaCrawler) {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user