diff --git a/web-app/src/app/routes/monitor/monitor-edit/monitor-edit.component.ts b/web-app/src/app/routes/monitor/monitor-edit/monitor-edit.component.ts index 3044010..b558bf1 100644 --- a/web-app/src/app/routes/monitor/monitor-edit/monitor-edit.component.ts +++ b/web-app/src/app/routes/monitor/monitor-edit/monitor-edit.component.ts @@ -51,6 +51,7 @@ export class MonitorEditComponent implements OnInit { }); } this.params = message.data.params; + this.detected = message.data.detected; } else { console.warn(message.msg); this.notifySvc.error("查询异常,此监控不存在", message.msg); @@ -72,6 +73,14 @@ export class MonitorEditComponent implements OnInit { if (param.field === "host") { param.value = this.monitor.host; } + } else { + if (define.type === "boolean") { + if (param.value != null) { + param.value = param.value.toLowerCase() == 'true'; + } else { + param.value = false; + } + } } this.params.push(param); })