Fixes - default module
This commit is contained in:
parent
748582509a
commit
bb11403c4b
|
@ -469,7 +469,13 @@ sub PandoraFMS::Recon::Base::test_module($$) {
|
|||
$test->{'id_tipo_modulo'} = $module->{'type'};
|
||||
} else {
|
||||
# Module.
|
||||
$test->{'id_tipo_modulo'} = $module->{'id_modulo'};
|
||||
if (!defined($self->{'module_types'}{$module->{'type'}})) {
|
||||
$self->{'module_types'}{$module->{'type'}} = get_module_id(
|
||||
$self->{'dbh'},$module->{'type'}
|
||||
);
|
||||
}
|
||||
|
||||
$test->{'id_tipo_modulo'} = $self->{'module_types'}{$module->{'type'}};
|
||||
}
|
||||
|
||||
my $value;
|
||||
|
|
|
@ -1475,6 +1475,12 @@ sub scan_subnet($) {
|
|||
$self->call('update_progress', ceil($progress));
|
||||
|
||||
$total_hosts = scalar keys %hosts_alive;
|
||||
if ($total_hosts == 0) {
|
||||
# Populate.
|
||||
$self->{'c_network_percent'} += 50;
|
||||
$self->call('update_progress', ceil($progress)+25);
|
||||
next;
|
||||
}
|
||||
$step = 25.0 / scalar(@subnets) / $total_hosts;
|
||||
$subnet_step = 50.0 / $total_hosts;
|
||||
|
||||
|
|
Loading…
Reference in New Issue