X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=httemplate%2Fsearch%2Felements%2Fsearch-html.html;h=75b0e9aee241b0e25e704ba29bd271e53cab6b02;hb=ae10bcf15845d1397a51152ff185b1c8ca77b259;hp=6b915a617ab32bda3d6d1c9233481fd5ca06478d;hpb=1368f0fa8982d3114e950eb6c0b3d8c05a1d12c0;p=freeside.git diff --git a/httemplate/search/elements/search-html.html b/httemplate/search/elements/search-html.html index 6b915a617..75b0e9aee 100644 --- a/httemplate/search/elements/search-html.html +++ b/httemplate/search/elements/search-html.html @@ -32,11 +32,17 @@ % % if ( $type eq 'html-print' ) { - <% include( '/elements/header-popup.html', $opt{'title'} ) %> + <% $opt{nohtmlheader} + ? '' + : include( '/elements/header-popup.html', $opt{'title'} ) + %> % } elsif ( $type eq 'select' ) { - <% include( '/elements/header-popup.html', $opt{'title'} ) %> + <% $opt{nohtmlheader} + ? '' + : include( '/elements/header-popup.html', $opt{'title'} ) + %> <% defined($opt{'html_init'}) ? ( ref($opt{'html_init'}) ? &{$opt{'html_init'}}() @@ -54,9 +60,11 @@ % # @menubar = ( 'Main menu' => $p ); % } - <% include( '/elements/header.html', $opt{'title'}, - include( '/elements/menubar.html', @menubar ) - ) + <% $opt{nohtmlheader} + ? '' + : include( '/elements/header.html', $opt{'title'}, + include( '/elements/menubar.html', @menubar ) + ) %> <% defined($opt{'html_init'}) @@ -95,7 +103,7 @@ % $cgi->delete('maxrecords'); % $cgi->param('_dummy', 1); - ( show query_string %>;maxrecords=' + this.options[this.selectedIndex].value;"> % foreach my $max ( map { $_ * $confmax } qw( 1 5 10 25 ) ) { @@ -136,13 +144,18 @@ Download full results
% $cgi->param('_type', "$xlsname.xls" ); - as Excel spreadsheet
+ as query_string %>">Excel spreadsheet
% $cgi->param('_type', 'csv'); - as CSV file
+ as query_string %>">CSV file
+ +% if ( defined($opt{xml_elements}) ) { +% $cgi->param('_type', 'xml'); + as query_string %>">XML file
+% } % $cgi->param('_type', 'html-print'); - as printable copy + as query_string %>">printable copy % $cgi->param('_type', "html" ); @@ -177,8 +190,13 @@ % my $h2 = 0; +% my $colspan = 0; % foreach my $header ( @{ $opt{header} } ) { +% $colspan-- if $colspan > 0; +% next if $colspan; +% % my $label = ref($header) ? $header->{label} : $header; +% $colspan = ref($header) ? $header->{colspan} : 0; % my $rowspan = 1; % my $style = ''; % if ( $opt{header2} ) { @@ -193,6 +211,7 @@ <% $style %> > @@ -410,9 +429,11 @@ % } % if ( $type eq 'html-print' ) { +% unless ( $opt{nohtmlheader} ) { +% } % } else { <% defined($opt{'html_foot'}) @@ -423,7 +444,10 @@ : '' %> - <% include( '/elements/footer.html' ) %> + <% $opt{nohtmlheader} + ? '' + : include( '/elements/footer.html' ) + %> % } @@ -440,6 +464,7 @@ my $confmax = $args{'confmax'}; my $maxrecords = $args{'maxrecords'}; my $offset = $args{'offset'}; my %opt = %{ $args{'opt'} }; +my $self_url = $opt{'url'} || $cgi->url('-path_info' => 1, '-full' =>1); my $count_sth = dbh->prepare($opt{'count_query'}) or die "Error preparing $opt{'count_query'}: ". dbh->errstr;