From 52d8f2d7deaf9c14ab4393183ca412cccdec8ce9 Mon Sep 17 00:00:00 2001 From: Jamie Cameron Date: Sun, 11 Sep 2011 21:58:10 -0700 Subject: [PATCH] option to show long field in search --- webminlog/index.cgi | 4 ++++ webminlog/lang/en | 1 + webminlog/search.cgi | 4 ++-- 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/webminlog/index.cgi b/webminlog/index.cgi index 5ef44e92c..6d780fa0e 100755 --- a/webminlog/index.cgi +++ b/webminlog/index.cgi @@ -93,6 +93,10 @@ if ($config{'host_search'}) { &ui_textbox("webmin", undef, 30) ] ])); } +# Show full descriptions? +print &ui_table_row($text{'index_long'}, + &ui_yesno_radio("long", 0)); + print &ui_table_end(); print &ui_form_end([ [ undef, $text{'index_search'} ] ]); diff --git a/webminlog/lang/en b/webminlog/lang/en index 991472f1e..781defd25 100644 --- a/webminlog/lang/en +++ b/webminlog/lang/en @@ -27,6 +27,7 @@ index_dall=Any change index_diff=Changes containing index_stimes=Actions on dates index_shost=Source Webmin server +index_long=Show full action descriptions? index_global=<Not in any module> search_title=Search Results diff --git a/webminlog/search.cgi b/webminlog/search.cgi index f959f2456..853a22ef6 100755 --- a/webminlog/search.cgi +++ b/webminlog/search.cgi @@ -141,7 +141,7 @@ if ($in{'csv'}) { my %minfo = &get_module_info($m); $minfo = $minfo_cache{$m} = \%minfo; } - my $desc = &get_action_description($act, 0); + my $desc = &get_action_description($act, $in{'long'}); $desc =~ s/<[^>]+>//g; @cols = ( $desc, $minfo->{'desc'}, @@ -189,7 +189,7 @@ elsif (@match) { } my @cols; - my $desc = &get_action_description($act, 0); + my $desc = &get_action_description($act, $in{'long'}); my $anno = &get_annotation($act); push(@cols, "