Skip to content

Commit

Permalink
Attempt to avoid redirections
Browse files Browse the repository at this point in the history
  • Loading branch information
davorg committed May 1, 2019
1 parent bf83335 commit 6fe55a0
Show file tree
Hide file tree
Showing 10 changed files with 19 additions and 19 deletions.
4 changes: 2 additions & 2 deletions in/actor.tt
Expand Up @@ -14,8 +14,8 @@
[% IF actor.actor_roles.size %]
<ul>
[% FOREACH r IN actor.actor_roles %]
<li>Played <a href="/characters/[% r.character.slug %]">[% r.character.name %]</a> in
<a href="/productions/[% r.production.slug %]">[% r.production.title %]</a>
<li>Played <a href="/characters/[% r.character.slug %]/">[% r.character.name %]</a> in
<a href="/productions/[% r.production.slug %]i">[% r.production.title %]</a>
([% r.production.description %])</li>
[% END %]
</ul>
Expand Down
2 changes: 1 addition & 1 deletion in/actors.tt
Expand Up @@ -5,6 +5,6 @@

<ul>
[% FOREACH a IN actors.all.sort('name')-%]
<li><a href="/actors/[% a.slug %]">[% a.name %]</a></li>
<li><a href="/actors/[% a.slug %]/">[% a.name %]</a></li>
[% END -%]
</ul>
2 changes: 1 addition & 1 deletion in/author.tt
Expand Up @@ -14,7 +14,7 @@
[% IF author.works.size %]
<ul>
[% FOR w IN author.works.sort('published') %]
<li><a href="/works/[% w.slug %]">[% w.title %] ([% w.published.strftime('%Y') %])</a></li>
<li><a href="/works/[% w.slug %]/">[% w.title %] ([% w.published.strftime('%Y') %])</a></li>
[% END %]
</ul>
[% ELSE %]
Expand Down
2 changes: 1 addition & 1 deletion in/authors.tt
Expand Up @@ -2,6 +2,6 @@
<h1 class="display-3">[% template.title or 'Literature on TV' %]</h1>
<ul>
[% FOREACH author IN authors.all.sort('name') -%]
<li><a href="/authors/[% author.slug %]">[% author.name %]</a></li>
<li><a href="/authors/[% author.slug %]/">[% author.name %]</a></li>
[% END -%]
</ul>
8 changes: 4 additions & 4 deletions in/character.tt
Expand Up @@ -8,10 +8,10 @@
[% IF character.works.size %]
<ul>
[% FOR w IN character.works %]
<li><a href="/works/[% w.slug %]">[% w.title %]</a>
<li><a href="/works/[% w.slug %]/">[% w.title %]</a>
by
[% FOR au IN w.authors %]
<a href="/authors/[% au.slug %]">[% au.name %]</a>
<a href="/authors/[% au.slug %]/">[% au.name %]</a>
[% END %]
</li>
[% END %]
Expand All @@ -24,8 +24,8 @@ by
[% IF character.actor_roles.size %]
<ul>
[% FOR r IN character.actor_roles %]
<li><a href="/actors/[% r.actor.slug %]">[% r.actor.name %]</a> in
<a href="/productions/[% r.production.slug %]">[% r.production.title %]
<li><a href="/actors/[% r.actor.slug %]/">[% r.actor.name %]</a> in
<a href="/productions/[% r.production.slug %]/">[% r.production.title %]
([% r.production.description %])</a></li>
[% END %]
[% ELSE %]
Expand Down
2 changes: 1 addition & 1 deletion in/characters.tt
Expand Up @@ -4,6 +4,6 @@

<ul>
[% FOREACH ch IN characters.all.sort('name')-%]
<li><a href="/characters/[% ch.slug %]">[% ch.name %]</a></li>
<li><a href="/characters/[% ch.slug %]/">[% ch.name %]</a></li>
[% END -%]
</ul>
8 changes: 4 additions & 4 deletions in/production.tt
Expand Up @@ -7,9 +7,9 @@
<h1 class="display-3">[% production.title %]</h1>
<p>[% production.description %]<p>
<p>Based on
<a href="/works/[% production.work.slug %]">[% production.work.title %]</a> by
<a href="/works/[% production.work.slug %]/">[% production.work.title %]</a> by
[% FOR a IN production.work.authors %]
<a href="/authors/[% a.slug %]">[% a.name %]</a>
<a href="/authors/[% a.slug %]/">[% a.name %]</a>
[% END %]</p>

<p><a href="http://imdb.com/title/[% production.imdb %]">[% production.title %] on IMDB</a></p>
Expand All @@ -18,8 +18,8 @@
[% IF production.actor_roles.size %]
<ul>
[% FOR a IN production.actor_roles %]
<li><a href="/actors/[% a.actor.slug %]">[% a.actor.name %]</a>
as <a href="/characters/[% a.character.slug %]">[% a.character.name %]</a></li>
<li><a href="/actors/[% a.actor.slug %]/">[% a.actor.name %]</a>
as <a href="/characters/[% a.character.slug %]/">[% a.character.name %]</a></li>
[% END %]
</ul>
[% ELSE %]
Expand Down
2 changes: 1 addition & 1 deletion in/productions.tt
Expand Up @@ -5,7 +5,7 @@

<ul>
[% FOREACH p IN productions.all.sort('year', 'title')-%]
<li><a href="/productions/[% p.slug %]">[% p.title %]</a>
<li><a href="/productions/[% p.slug %]/">[% p.title %]</a>
([% p.description %])</li>
[% END -%]
</ul>
6 changes: 3 additions & 3 deletions in/work.tt
Expand Up @@ -5,12 +5,12 @@
<p class="text-muted">[% template.title or 'Literature on TV' %]</p>

<h1 class="display-3">[% work.title %]</h1>
<p>By [% FOR a IN work.authors; '<a href="/authors/'; a.slug; '">'; a.name; '</a> '; END %]</p>
<p>By [% FOR a IN work.authors; '<a href="/authors/'; a.slug; '/">'; a.name; '</a> '; END %]</p>
<h3>Characters</h3>
[% IF work.characters.size %]
<ul>
[% FOR ch IN work.characters %]
<li><a href="/characters/[% ch.slug %]">[% ch.name %]</a></li>
<li><a href="/characters/[% ch.slug %]/">[% ch.name %]</a></li>
[% END %]
</ul>
[% ELSE %]
Expand All @@ -20,7 +20,7 @@
[% IF work.productions.size %]
<ul>
[% FOR p IN work.productions.sort('year') %]
<li><a href="/productions/[% p.slug %]">[% p.year %] [% IF p.title != p.work.title; '('; p.title; ')'; END %]</a></li>
<li><a href="/productions/[% p.slug %]/">[% p.year %] [% IF p.title != p.work.title; '('; p.title; ')'; END %]</a></li>
[% END %]
</ul>
[% ELSE %]
Expand Down
2 changes: 1 addition & 1 deletion in/works.tt
Expand Up @@ -8,7 +8,7 @@
[% # Display each book in a table row %]
[% FOREACH work IN works.all.sort('title')-%]
<tr>
<td><a href="/works/[% work.slug %]">[% work.title %]</a></td>
<td><a href="/works/[% work.slug %]/">[% work.title %]</a></td>
<td>[% FOREACH a IN work.authors; a.name; ' '; END %]</td>
</tr>
[% END -%]
Expand Down

0 comments on commit 6fe55a0

Please sign in to comment.