]> git.ipfire.org Git - people/jschlag/pbs.git/blob - src/templates/modules/repo-actions-table.html
a59611e3e3a200d332eec02ebddab8fc32abb675
[people/jschlag/pbs.git] / src / templates / modules / repo-actions-table.html
1 <div class="repo-actions">
2 {% for action in actions %}
3 <div class="action {{ action.action }}" id="action-{{ action.id }}">
4 <a id="action-link-{{ action.id }}" href="#">{{ action.pkg.friendly_name }}</a>
5 {{ _("added %s") % locale.format_date(action.time_added) }}
6
7 {% if current_user and action.have_permission(current_user) %}
8 <p class="buttons">
9 {% if action.is_doable() %}
10 <a href="javascript:action_run({{ action.id }})">{{ _("Run") }}</a>
11 {% end %}
12 <a href="?action=remove">{{ _("Remove action") }}</a>
13 </p>
14 {% end %}
15
16 <div id="action-info-{{ action.id }}">
17 <p>
18 {% if action.score_needed %}
19 {{ _("One more score needed.", "%(score)s more scores needed.", action.score_needed) % { "score" : action.score_needed } }}
20 {% else %}
21 {{ _("No more scores needed.") }}
22 {% end %}
23 <br />
24 {% if action.pkg.maintainer %}
25 {{ _("Maintainer: %s") % action.pkg.maintainer }}
26 <br />
27 {% end %}
28 <a href="/package/{{ action.pkg.name }}/{{ action.pkg.epoch }}/{{ action.pkg.version }}/{{ action.pkg.release }}">{{ _("Go to package description") }}</a>
29 <br />
30 </p>
31 </div>
32
33 <script>
34 $(function() {
35 $("#action-info-{{ action.id }}").hide();
36 $("#action-link-{{ action.id }}").toggle(
37 function() { $("#action-info-{{ action.id }}").show(); },
38 function() { $("#action-info-{{ action.id }}").hide(); }
39 );
40 });
41 </script>
42 </div>
43 {% end %}
44 </div>
45 <div style="clear: both;">&nbsp;</div>