[% # Menu SET menu = [ { name => 'info', description => gettext('Info') }, { name => 'peers', description => gettext('Peers') }, { name => 'files', description => gettext('Files') }, { name => 'trackers', description => gettext('Trackers') }, #{ name => 'chunks', description => gettext('Chunks') }, #{ name => 'transfer', description => gettext('Transfer') }, ]; %] [% FOR item = menu %] [% SET class = ['item', item.name]; IF data.prop == item.name; class.push('selected'); END; %]
[% item.description %]
[% END %] [% IF data.prop == 'files' %]
[% END %]
[% UNLESS data.current && data.info %]
[% UNLESS data.current %]

[% gettext('Select torrent to show') %] [% END %]
[% ELSE %]
[% SWITCH data.prop; CASE 'info'; INCLUDE 'prop.info.tt.html'; CASE 'peers'; INCLUDE 'prop.peers.tt.html'; CASE 'files'; INCLUDE 'prop.files.tt.html'; CASE 'trackers'; INCLUDE 'prop.trackers.tt.html'; CASE 'chunks'; INCLUDE 'prop.chunks.tt.html'; CASE 'transfer'; INCLUDE 'prop.transfer.tt.html'; CASE DEFAULT; gettext('Unknown property page'); END %]
[% END %]