From c57f1193f3e1f0233ea6040be9d01a0e48729e5c Mon Sep 17 00:00:00 2001 From: insanity Date: Wed, 18 Apr 2018 18:28:54 +0900 Subject: [PATCH] taret --- .../sensor/component/list/list.component.html | 10 +++--- .../sensor/component/list/list.component.ts | 36 +++++++------------ .../target/component/list/list.component.html | 29 +++++++++++---- .../target/component/list/list.component.ts | 3 +- 4 files changed, 41 insertions(+), 37 deletions(-) diff --git a/src/packages/sensor/component/list/list.component.html b/src/packages/sensor/component/list/list.component.html index 50dc137..be47c56 100644 --- a/src/packages/sensor/component/list/list.component.html +++ b/src/packages/sensor/component/list/list.component.html @@ -6,8 +6,6 @@ - -
@@ -17,7 +15,7 @@

Search

- +
@@ -29,10 +27,10 @@
- +
- +
@@ -52,7 +50,7 @@ {{sensor.crawler.name}} | {{sensor.itemCount}} items | {{sensor.status.name}} - + diff --git a/src/packages/sensor/component/list/list.component.ts b/src/packages/sensor/component/list/list.component.ts index 6ceec7c..19193ec 100644 --- a/src/packages/sensor/component/list/list.component.ts +++ b/src/packages/sensor/component/list/list.component.ts @@ -36,7 +36,10 @@ export class ListComponent implements OnInit, AfterContentInit { // filter targetOptions: SelectItem[]; + + filteredName: string; selectedTargets: string[] = []; + selectedStatus: string[] = []; constructor(private router: Router, private store: Store, @@ -127,6 +130,11 @@ export class ListComponent implements OnInit, AfterContentInit { this.sensorSettingDisplay = true; } + onAddSensorWithTarget(target: Target) { + this.target = target; + this.sensorSettingDisplay = true; + } + onSensorSettingClose() { this.sensorSettingDisplay = false; } @@ -135,31 +143,11 @@ export class ListComponent implements OnInit, AfterContentInit { } onSearch() { - + console.log(this.filteredName); + console.log(this.selectedTargets); + console.log(this.selectedStatus); + alert('서버-검색 기능 구현 필요'); } - - - - // Test - onAddSensorWithTarget() { - this.target = { - id: 1, - createDate: new Date(), - displayName: 'Alredy selected target111', - description: 'Desc..', - }; - this.sensorSettingDisplay = true; - } - - onAddSensorWithTarget2() { - this.target = { - id: 2, - createDate: new Date(), - displayName: 'Alredy selected target222', - description: 'Desc..', - }; - this.sensorSettingDisplay = true; - } } diff --git a/src/packages/target/component/list/list.component.html b/src/packages/target/component/list/list.component.html index 30d85b7..b674866 100644 --- a/src/packages/target/component/list/list.component.html +++ b/src/packages/target/component/list/list.component.html @@ -1,8 +1,9 @@

Targets

- - + + + No. Status Type @@ -12,8 +13,13 @@ - - + + + + + + + {{rowIndex}} ?? {{infra.infraType.name}} @@ -21,12 +27,23 @@ ?? {{infra.createDate | date: 'dd.MM.yyyy'}} - + + + + + +
+
요기다가 센서 리스트와 상태 출력
+
+ + +
+
- + \ No newline at end of file diff --git a/src/packages/target/component/list/list.component.ts b/src/packages/target/component/list/list.component.ts index 30be636..604f741 100644 --- a/src/packages/target/component/list/list.component.ts +++ b/src/packages/target/component/list/list.component.ts @@ -124,7 +124,8 @@ export class ListComponent implements OnInit, AfterContentInit { } onRowSelect(event) { - console.log(event.data); + console.log(event.data.target); + // this.router.navigate(['notification']); } onAddSensor(target: Target) {