add wanted events support #27

This commit is contained in:
ghost 2023-10-24 00:12:13 +03:00
parent 5f4a14ebe2
commit 24c58d4301
20 changed files with 249 additions and 1 deletions

View file

@ -0,0 +1,23 @@
<div class="row">
<div class="column width-80">
<span class="margin-l-4-px">
{{ 'seeders wanted for torrent' | trans }}
</span>
{% if session.user.moderator or session.user.owner %}
<a href="{{ path('torrent_info', { torrentId : torrent.id }) }}">
{{ torrent.name }}
</a>
{% else %}
{% if torrent.sensitive == true %}
#{{ torrent.id }} ({{ 'sensitive' | trans }})
{% else %}
<a href="{{ path('torrent_info', { torrentId : torrent.id }) }}">
{{ torrent.name }}
</a>
{% endif %}
{% endif %}
</div>
<div class="column width-20 text-right">
{{ added | format_ago }}
</div>
</div>

View file

@ -0,0 +1,17 @@
<item>
<title>
{{ 'seeders wanted for torrent' | trans }}
{% if session.user.moderator or session.user.owner %}
{{ torrent.name }}
{% else %}
{% if torrent.sensitive == true %}
#{{ torrent.id }} ({{ 'sensitive' | trans }})
{% else %}
{{ torrent.name }}
{% endif %}
{% endif %}
</title>
<pubDate>{{ added | date('D, d M Y h:i:s O') }}</pubDate>
<guid>{{ url('torrent_info', { torrentId : torrent.id }) }}#activity-{{ id }}</guid>
<link>{{ url('torrent_info', { torrentId : torrent.id }) }}#activity</link>
</item>