diff options
| author | Gunnar Mills <gmills@us.ibm.com> | 2018-09-18 15:49:33 -0500 |
|---|---|---|
| committer | Gunnar Mills <gmills@us.ibm.com> | 2018-11-02 14:02:56 +0000 |
| commit | 8751084c3a7430509a3a3c9e5c415e963f7922e4 (patch) | |
| tree | e7819ef20518dd75785cf644aaa20315490ca00e /app/configuration/controllers/snmp-controller.html | |
| parent | 31461a1d9a5db4762e1616792cf8a718a99bf488 (diff) | |
| download | phosphor-webui-8751084c3a7430509a3a3c9e5c415e963f7922e4.tar.gz phosphor-webui-8751084c3a7430509a3a3c9e5c415e963f7922e4.zip | |
Only update SNMP fields if changed
Use ng-change to determine if the SNMP fields, Address and Port,
have changed and should be updated.
Tested: Only see the rest calls when the fields have changed.
Change-Id: I324c9c422a8b6dfb8816925167953e16099f8044
Signed-off-by: Gunnar Mills <gmills@us.ibm.com>
Diffstat (limited to 'app/configuration/controllers/snmp-controller.html')
| -rw-r--r-- | app/configuration/controllers/snmp-controller.html | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/app/configuration/controllers/snmp-controller.html b/app/configuration/controllers/snmp-controller.html index 3fd9aa3..f4b7279 100644 --- a/app/configuration/controllers/snmp-controller.html +++ b/app/configuration/controllers/snmp-controller.html @@ -12,11 +12,11 @@ <div class="snmp__managers" ng-repeat="manager in managers track by $index"> <div class="snmp__manager-field"> <label>SNMP Manager Server</label> - <input class="inline" id="snmp-manager{{$index+1}}-address" type="text" ng-model="manager.address" ng-blur="managers[$index].address = manager.address"/> + <input class="inline" id="snmp-manager{{$index+1}}-address" ng-change="manager.update_address = true" type="text" ng-model="manager.address" ng-blur="managers[$index].address = manager.address"/> </div> <div class="snmp__manager-field"> <label>Port</label> - <input class="inline" id="snmp-manager{{$index+1}}-port" type="text" ng-model="manager.port" ng-blur="managers[$index].port = manager.port"/> + <input class="inline" id="snmp-manager{{$index+1}}-port" type="text" ng-change="manager.update_port = true" ng-model="manager.port" ng-blur="managers[$index].port = manager.port"/> </div> <button class="snmp__manager-remove" ng-click="removeSNMPManager($index)">Remove</button> </div> |

