]>
Commit | Line | Data |
---|---|---|
9137135a MT |
1 | {% extends "base.html" %} |
2 | ||
5aa556bf | 3 | {% block title %}{{ _("Search results for '%s'") % pattern }}{% end block %} |
9137135a MT |
4 | |
5 | {% block body %} | |
f6e6ff79 | 6 | |
3d2ea9f4 JS |
7 | <div class="row"> |
8 | <div class="col-12 col-sm-12 col-md-12 col-lg-12 col-xl-12"> | |
9 | <nav aria-label="breadcrumb" role="navigation"> | |
10 | <ol class="breadcrumb"> | |
11 | <li class="breadcrumb-item"><a href="/">{{ _("Home") }}</a></li> | |
12 | <li class="breadcrumb-item"><a href="/search">{{ _("Search results") }}</a></li> | |
13 | <li class="breadcrumb-item active"> | |
14 | <a href="/search?q={{ pattern }}">{{ pattern }}</a> | |
15 | </li> | |
16 | </ol> | |
17 | </nav> | |
18 | </div> | |
f6e6ff79 MT |
19 | </div> |
20 | ||
3d2ea9f4 JS |
21 | <div class="row"> |
22 | <div class="col-12 col-sm-12 col-md-12 col-lg-12 col-xl-12"> | |
23 | <h2 style="word-wrap: break-word;"> | |
24 | {{ _("Search results for '%s'") % pattern }} | |
25 | </h2> | |
f6e6ff79 | 26 | </div> |
3d2ea9f4 | 27 | </div> |
f6e6ff79 MT |
28 | |
29 | <div class="row"> | |
3d2ea9f4 JS |
30 | <div class="col-12 col-sm-12 col-md-12 col-lg-12 col-xl-12 mb-2"> |
31 | <form class="form-inline" method="GET" action="/search"> | |
32 | <div class="form-group"> | |
33 | <input type="text" class="form-control mr-2" id="q" name="q" placeholder="{{ _("Search") }}" | |
34 | value="{{ pattern }}"> | |
d61c6433 | 35 | </div> |
3d2ea9f4 | 36 | <button type="submit" class="btn btn-primary">{{ _("Go!") }}</button> |
f6e6ff79 MT |
37 | </form> |
38 | </div> | |
39 | </div> | |
40 | ||
d61c6433 | 41 | |
f6e6ff79 | 42 | {% if pkgs %} |
3d2ea9f4 JS |
43 | <div class="row"> |
44 | <div class="col-12 col-sm-12 col-md-12 col-lg-12 col-xl-12"> | |
45 | <h3 style="word-wrap: break-word;"> | |
46 | {{ _("Packages") }} <small>({{ len(pkgs) }})</small> | |
47 | </h3> | |
48 | <div class="table-responsive mb-2"> | |
49 | <table class="table table-striped table-hover"> | |
50 | <tbody> | |
51 | {% for pkg in pkgs %} | |
52 | <tr> | |
53 | <td> | |
54 | <a href="/package/{{ pkg.name }}"> | |
55 | {{ pkg.name }} | |
56 | </a> | |
57 | </td> | |
58 | <td>{{ pkg.summary }}</td> | |
59 | </tr> | |
60 | {% end %} | |
61 | </tbody> | |
62 | </table> | |
63 | </div> | |
64 | </div> | |
65 | </div> | |
f6e6ff79 MT |
66 | {% end %} |
67 | ||
68 | {% if files %} | |
3d2ea9f4 JS |
69 | <div class="row"> |
70 | <div class="col-12 col-sm-12 col-md-12 col-lg-12 col-xl-12"> | |
71 | <h3 style="word-wrap: break-word;"> | |
72 | {{ _("Files") }} <small>({{ len(files) }})</small> | |
73 | </h3> | |
74 | <p> | |
75 | {{ _("%s was found in the following package.", "%s was found in the following packages.", len(files)) % pattern }} | |
76 | </p> | |
77 | <div class="table-responsive mb-2"> | |
78 | <table class="table table-striped table-hover"> | |
79 | <tbody> | |
80 | {% for pkg, file in files %} | |
81 | <tr> | |
82 | <td> | |
83 | <a href="/package/{{ pkg.uuid }}">{{ pkg.friendly_name }}</a> | |
84 | </td> | |
85 | <td> | |
86 | <pre>{{ format_filemode(file.type, file.mode) }} {{ file.user }}:{{ file.group }} {% if file.size %}{{ format_size(file.size) }}{% else %}-{% end %} {{ file.name }}</pre> | |
87 | </td> | |
88 | </tr> | |
89 | {% end %} | |
90 | </tbody> | |
91 | </table> | |
92 | </div> | |
93 | </div> | |
94 | </div> | |
f6e6ff79 MT |
95 | {% end %} |
96 | ||
97 | {% if users %} | |
3d2ea9f4 JS |
98 | <div class="row"> |
99 | <div class="col-12 col-sm-12 col-md-12 col-lg-12 col-xl-12"> | |
100 | <h3 style="word-wrap: break-word;"> | |
101 | {{ _("Users") }} <small>({{ len(users) }})</small> | |
102 | </h3> | |
103 | <div class="table-responsive mb-2"> | |
104 | <table class="table table-striped table-hover"> | |
105 | <tbody> | |
106 | {% for user in users %} | |
107 | <tr> | |
108 | <td> | |
109 | <a href="/user/{{ user.name }}">{{ user.realname }} | |
110 | {% if not user.name == user.realname %} | |
111 | ({{ user.name }}) | |
112 | {% end %} | |
113 | </a> | |
114 | </td> | |
115 | <td> | |
116 | | |
117 | </td> | |
118 | </tr> | |
119 | {% end %} | |
120 | </tbody> | |
121 | </table> | |
122 | </div> | |
123 | </div> | |
124 | </div> | |
f6e6ff79 | 125 | {% end %} |
9137135a | 126 | {% end block %} |