Changeset 131

Show
Ignore:
Timestamp:
03/01/06 15:17:43 (3 years ago)
Author:
ludo
Message:

v 1.4.8: fixed some problems when profile=all (from r3097)

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/webmin/lbs_common/debian/changelog

    r110 r131  
    1 webmin-lbs-common (1.4.7) stable; urgency=low 
     1webmin-lbs-common (1.4.8) stable; urgency=low 
    22 
    33  * New release. See SVN logs for details 
  • trunk/webmin/lbs_common/lang/en

    r110 r131  
    147147err_mac_used=MAC address already declared 
    148148err_name_mandat=The name is mandatory. 
    149 err_name_inval='$1': Invalid name. 
    150 err_name_usedby=Name '$1' is already used by host '$2'. 
    151149err_adminid_mandat=The admin ID is mandatory. 
    152150err_ip_inval='$1': Invalid IP address. 
  • trunk/webmin/lbs_common/lang/fr

    r110 r131  
    145145err_mac_used=Adresse MAC déjà déclarée 
    146146err_name_mandat=Le nom est obligatoire. 
    147 err_name_inval='$1': Format de nom invalide. 
    148 err_name_usedby=Le nom '$1' est déjà utilisé par la machine '$2'. 
    149147err_adminid_mandat=Le mot de passe d'identification est obligatoire. 
    150148err_ip_inval='$1': Adresse IP invalide. 
  • trunk/webmin/lbs_common/lbs_common.pl

    r110 r131  
    308308                                                $todisplay = 1 if ($toreplaces{'mac_with_dot'} && $mac && $mac ne ""); 
    309309                                                $todisplay = 1 if ($toreplaces{'mac_with_dot'} && $mac_with_dot && $mac_with_dot ne ""); 
    310                                                 $todisplay = 1 if ($toreplaces{'group'} && $toreplaces{'group'} && ( $group ne "" || $profile ne "") ); 
     310                                                $todisplay = 1 if ($toreplaces{'group'}); 
    311311                                                $todisplay = 1 if (lc($menu{$onglet}{'DATAS'}{'dont_shade'}) eq "y"); 
    312312                                                 
     
    327327                                                                if $url =~ m/%group%/;            
    328328                                                        $url =~ s/(.*)%profile%(.*)/$1$profile$2/                       # perhaps an "host" arg given ? 
    329                                                                 if $url =~ m/%profile%/;            
     329                                                                if $url =~ m/%profile%/; 
    330330                                                        $template->assign('URL', $url); 
    331331                                                        if ($label) {                                                   # shown only if there is a label 
     
    619619                # first tab is selected 
    620620                $template->assign('IS_SELECTED', "selected"); 
    621                 $template->assign('URL', "?profile=all"); 
     621                $template->assign('URL', "?profile="); 
    622622                $template->assign('PROFIL', text("lab_all")); 
    623623                $template->parse('mainlist.profils.profil'); 
     
    636636                $template->parse('mainlist.profils.profil'); 
    637637                 
    638                 $profile_key = "all"; 
     638                $profile_key = ""; 
    639639                $profile_name = text("lab_all"); 
    640640        } elsif ( (lc($in{'profile'}) eq "none") ) { 
     
    654654                # leading tabs are not selected 
    655655                $template->assign('IS_SELECTED', "unselected"); 
    656                 $template->assign('URL', "?profile=all"); 
     656                $template->assign('URL', "?profile="); 
    657657                $template->assign('PROFIL', text("lab_all")); 
    658658                $template->parse('mainlist.profils.profil'); 
     
    687687                 
    688688                $template->assign('IS_SELECTED', "unselected"); 
    689                 $template->assign('URL', "?profile=all"); 
     689                $template->assign('URL', "?profile="); 
    690690                $template->assign('PROFIL', text("lab_all")); 
    691691                $template->parse('mainlist.profils.profil'); 
     
    11351135# 
    11361136sub checkforspace () { 
    1137     my $run = `df -m /var|tail -1|awk '{print \$4}'`; 
     1137    my $run = `df -Pm /var|tail -1|awk '{print \$4}'`; 
    11381138    if ($run < 100) 
    11391139        { 
     
    14021402# return the available space 
    14031403sub get_server_free_space { 
    1404         return `/bin/df -h` or text('lab_unknown'); 
     1404        return `/bin/df -Ph` or text('lab_unknown'); 
    14051405} 
    14061406 
  • trunk/webmin/lbs_common/lbs_common_priv.pl

    r110 r131  
    1717    if ($in{group}) { 
    1818      my $c = new CGI::Cookie(-name => 'group', 
    19                                   -value => $in{group}
     19                                  -value => "$in{group}"
    2020                                  -expires => '+1M' 
    2121                                 ); 
    2222      print "Set-Cookie: $c\n"; 
    2323    } 
    24     if ($in{profile}) { 
     24 
     25    if ($in{profile} || $in{profile} eq "") { 
    2526      my $c = new CGI::Cookie(-name => 'profile', 
    26                                   -value => $in{profile}
     27                                  -value => "$in{profile}"
    2728                                  -expires => '+1M' 
    2829                                 ); 
     
    3940  my $in = %{$_[0]}; 
    4041 
    41   if (!$in{group}) { 
     42  if (!$in{'group'}) { 
    4243    if ( defined($cookies{'group'}) ) { 
    4344      $in{'group'} = $cookies{'group'}->value; 
    4445    } 
    4546  } 
    46   if (!$in{profile}) { 
     47  if (! defined($in{'profile'}) ) { 
    4748    if ( defined($cookies{'profile'}) ) { 
    4849      $in{'profile'} = $cookies{'profile'}->value; 
  • trunk/webmin/lbs_common/module.info

    r110 r131  
    55name=lbs_common 
    66depends=0.94 
    7 version=1.4.7 
     7version=1.4.8