From 15f50e9ba5f64594ac610ad42ac75e484147f8a2 Mon Sep 17 00:00:00 2001 From: Arne Georg Gleditsch Date: Tue, 4 Dec 2007 08:45:41 +0100 Subject: Add file search caps, some tuning. --- tmpl/search_result.tt2 | 117 ++++++++++++++++++++++++++++--------------------- 1 file changed, 68 insertions(+), 49 deletions(-) (limited to 'tmpl') diff --git a/tmpl/search_result.tt2 b/tmpl/search_result.tt2 index d093968..cc2af1c 100644 --- a/tmpl/search_result.tt2 +++ b/tmpl/search_result.tt2 @@ -4,63 +4,82 @@ [% IF search_type == "code" or (code_res and code_res.idents.0) %] -
Code search: [% code_res.query %]
- +
Code search: [% code_res.query %]
+ [% ptype = '' %] + [% FOREACH ident = code_res.idents %] + [% IF ptype != ident.1 %] + [% ident.1 %] + [% ptype = ident.1 %] + [% END %] + + [% INCLUDE line_reference.tt2, file = ident.2, line = ident.3 %] + [usage...] + + [% END %] [% END %] [% IF ident_res %] -
Identifier: -[% ident_res.ident.1 %] - -[% ident_res.query %], from -[% INCLUDE line_reference.tt2, - file = ident_res.ident.2, line = ident_res.ident.3 %] -
-References: - -[% END %] +
Identifier: + + [% ident_res.query %] + +
+ + [% ident_res.ident.1 %] + [% IF ident_res.ident.4 %] + in [% ident_res.ident.5 %] + + [% ident_res.ident.4 %] + + [% END %] + at + + [% INCLUDE line_reference.tt2, + file = ident_res.ident.2, line = ident_res.ident.3 %] -[% IF text_res %] -
Freetext search: [% text_res.query %] -([% text_res.total %] estimated hits)
- + [% FOREACH file = ident_res.refs.keys.sort %] + [% IF loop.first %] + References: + [% END %] + + [% FOREACH line = ident_res.refs.$file %] + + [% INCLUDE line_reference.tt2, + file = file, line = line %] + + [% END %] + [% END %] [% END %] [% IF file_res %] -
Filename search: [% file_res.query %]
- + +[% IF text_res %] +
Freetext search: [% text_res.query %] + ([% text_res.total %] estimated hits)
+ + [% FOREACH file = text_res.files %] + + [% INCLUDE line_reference.tt2, file = file.1, line = file.2 %] + ([% file.0 %]%) + + [% END %] [% END %] [% IF ambig_res %] -- cgit v1.2.3