X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=httemplate%2Fsearch%2Felements%2Fsearch-html.html;h=75b0e9aee241b0e25e704ba29bd271e53cab6b02;hb=ae10bcf15845d1397a51152ff185b1c8ca77b259;hp=297774dfd6a4e3c822785f1158c9cddfc2fca691;hpb=ed6084d4ccabb81493ffa1ee42c2afd237c05f45;p=freeside.git diff --git a/httemplate/search/elements/search-html.html b/httemplate/search/elements/search-html.html index 297774dfd..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,18 +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
-% $cgi->param('_type', 'html-print'); - as printable copy +% if ( defined($opt{xml_elements}) ) { +% $cgi->param('_type', 'xml'); + as query_string %>">XML file
+% } - <% $opt{'extra_choices_callback'} - ? &{$opt{'extra_choices_callback'}}($cgi->query_string) - : '' - %> +% $cgi->param('_type', 'html-print'); + as query_string %>">printable copy % $cgi->param('_type', "html" ); @@ -182,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} ) { @@ -198,6 +211,7 @@ <% $style %> > @@ -346,7 +360,9 @@ % } % $a = qq(); % } -% +% elsif ( $onclick ) { +% $a = qq(); +% } % } % % } @@ -413,9 +429,11 @@ % } % if ( $type eq 'html-print' ) { +% unless ( $opt{nohtmlheader} ) { +% } % } else { <% defined($opt{'html_foot'}) @@ -426,7 +444,10 @@ : '' %> - <% include( '/elements/footer.html' ) %> + <% $opt{nohtmlheader} + ? '' + : include( '/elements/footer.html' ) + %> % } @@ -443,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;