]> git.sur5r.net Git - bacula/bacula/commitdiff
ebl Search also tpl on lang/<lang>/tpl/*.tpl
authorEric Bollengier <eric@eb.homelinux.org>
Tue, 21 Oct 2008 12:43:00 +0000 (12:43 +0000)
committerEric Bollengier <eric@eb.homelinux.org>
Tue, 21 Oct 2008 12:43:00 +0000 (12:43 +0000)
git-svn-id: https://bacula.svn.sourceforge.net/svnroot/bacula/trunk@7865 91ce42f0-d328-0410-95d8-f526ca767f89

gui/bweb/lib/Bweb.pm

index 76dd86408fc3479ea1cf3f48bd2303f0a1498e37..a50453b93fbe9acf0c91d3ae7a3a360368a31986 100644 (file)
@@ -157,6 +157,7 @@ sub display
     my $lang = $self->{lang} || 'en';
     my $template = HTML::Template->new(filename => $tpl,
                                       path =>["$dir/$lang",
+                                               "$dir/$lang/tpl",
                                               $dir],
                                       die_on_bad_params => 0,
                                       case_sensitive => 0);
@@ -1820,10 +1821,10 @@ sub get_form
            my $value = CGI::param($i) || $opt_i{$i} ;
            if ($value =~ /^(\d+)$/) {
                $ret{$i} = $1;
-           } elsif ($value eq 'age' &&  # can have unit
-                    $i =~ /^(?:\d+(?:[ywdhms]\s*)?)+\s*$/) # 2y1h2m34s
+           } elsif ($i eq 'age' &&  # can have unit
+                    $value =~ /^(?:\d+(?:[ywdhms]\s*)?)+\s*$/) # 2y1h2m34s
            {
-               $ret{$i} = human_sec_unit($i);
+               $ret{$i} = human_sec_unit($value);
            }
        } elsif ($opt_s{$i}) {  # simple string param
            my $value = CGI::param($i) || '';