* Tue Mar 18 2025 Jean-Philippe Pialasse <jpp@koozali.org> 11.0.0-9.sme

- update config for Nut 2.8.2 [SME: 12657]
  TODO review master/slave mode
  TODO convert master/slave to primary/secondary
  TODO convert to new config data + migrate
  TODO event and action
This commit is contained in:
2025-05-17 01:11:29 -04:00
parent 4e61b36891
commit 21fed495e6
4 changed files with 39 additions and 19 deletions

View File

@@ -247,7 +247,7 @@ sub get_model_options {
sub get_ups_status {
my $c = shift;
$cdb = esmith::ConfigDB->open() || die("Couldn't open config db");
my $nutmode = $cdb->get_prop('nut', 'Mode','standalone');
my $nutmode = $cdb->get_prop('nut', 'Mode') || 'standalone';
if ($cdb->get_prop('nut', 'status', 'disabled') eq 'disabled'){
return $c->l('nut_status_is_disabled')
} elsif ($nutmode eq 'netclient'){

View File

@@ -45,6 +45,12 @@
</span><br>
-->
<span class=label>
%=l('nut_Nut_mode')
</span><span class=data>
%= $nut_data->{Nutmode}
</span><br>
% if ($nut_data->{Nutmode} eq "nutserver") {
<div class=secondaryups>
<p><span class=label>