From 9d28fcff1a8aeb85c802d2a8234c2119caef3a28 Mon Sep 17 00:00:00 2001 From: Matt Visnovsky Date: Tue, 30 Apr 2024 15:13:16 -0600 Subject: [PATCH] Update bean model backend Updates appropriate values async when editing the SNMP monitor --- server/model/monitor.js | 5 +++++ server/server.js | 5 +++++ 2 files changed, 10 insertions(+) diff --git a/server/model/monitor.js b/server/model/monitor.js index 80cff6f97..98dd216e2 100644 --- a/server/model/monitor.js +++ b/server/model/monitor.js @@ -161,6 +161,10 @@ class Monitor extends BeanModel { kafkaProducerMessage: this.kafkaProducerMessage, screenshot, remote_browser: this.remote_browser, + snmpOid: this.snmpOid, + snmpCondition: this.snmpCondition, + snmpControlValue: this.snmpControlValue, + snmpVersion: this.snmpVersion, }; if (includeSensitiveData) { @@ -190,6 +194,7 @@ class Monitor extends BeanModel { tlsCert: this.tlsCert, tlsKey: this.tlsKey, kafkaProducerSaslOptions: JSON.parse(this.kafkaProducerSaslOptions), + snmpCommunityString: this.snmpCommunityString, }; } diff --git a/server/server.js b/server/server.js index d5e3f215f..c4ca06425 100644 --- a/server/server.js +++ b/server/server.js @@ -830,6 +830,11 @@ let needSetup = false; monitor.kafkaProducerAllowAutoTopicCreation; bean.gamedigGivenPortOnly = monitor.gamedigGivenPortOnly; bean.remote_browser = monitor.remote_browser; + bean.snmpVersion = monitor.snmpVersion; + bean.snmpCommunityString = monitor.snmpCommunityString; + bean.snmpOid = monitor.snmpOid; + bean.snmpCondition = monitor.snmpCondition; + bean.snmpControlValue = monitor.snmpControlValue; bean.validate();