Changeset 1499

Show
Ignore:
Timestamp:
02/29/08 14:29:40 (4 years ago)
Author:
jo
Message:

Bugfixes with new multi-group functionality.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • people/jo/multilevel-groups-2/server/Munin.pm.in

    r1498 r1499  
    622622    my $loc  = shift; 
    623623    my $val  = shift; 
    624  
    625     my $tmpvar = shift @$loc; 
     624    my @aloc = @$loc; 
     625 
     626    my $tmpvar = shift @aloc; 
     627    $tmpvar = shift @aloc while (defined $tmpvar and $tmpvar =~ /^#%#/); 
    626628    if ($tmpvar !~ /\S/) { 
    627629        ::logger ("Error: munin_set_var_loc: Cannot work on hash node \"$tmpvar\""); 
    628630        return undef; 
    629631    } 
    630     if (@$loc > 0) { 
     632    if (@aloc > 0) { 
    631633        if (!defined $hash->{$tmpvar}) { # Init the new node 
    632634            $hash->{$tmpvar}->{"#%#parent"} = $hash; 
    633635            $hash->{$tmpvar}->{"#%#name"} = $tmpvar; 
    634636        } 
    635         return munin_set_var_loc ($hash->{$tmpvar}, $loc, $val); 
     637        return munin_set_var_loc ($hash->{$tmpvar}, \@aloc, $val); 
    636638    } else { 
    637639        ::logger ("Warning: munin_set_var_loc: Setting unknown option \"$tmpvar\".") 
     
    10781080    if (ref ($from) eq "HASH") { 
    10791081        foreach my $key (keys %$from) { 
     1082            next if $key =~ /^#%#/; 
    10801083            if (ref ($from->{$key}) eq "HASH") { 
    10811084                munin_copy_node_toloc ($from->{$key}, $to, [@$loc, $key]); 
  • people/jo/multilevel-groups-2/server/munin-nodeview.tmpl.in

    r1352 r1499  
    5151  </TMPL_LOOP> 
    5252  <tr><td class="linkbox"> 
    53  <TMPL_LOOP NAME="DOMAINS"> 
    54 <a href="../<TMPL_VAR NAME="DOMAIN">/index.html"><TMPL_VAR ESCAPE="HTML" NAME="DOMAIN"></a> : 
    55     </TMPL_LOOP> 
     53     <TMPL_VAR NAME="PARENT"> :<TMPL_LOOP NAME="PEERS">: <TMPL_IF NAME="LINK"><a href="<TMPL_VAR NAME="LINK">"></TMPL_IF><TMPL_VAR NAME="NAME"><TMPL_IF NAME="LINK"></a></TMPL_IF></a> </TMPL_LOOP> 
    5654 </td></tr> 
    5755</table>