From 601e894935f66257cd7c0969c141f898d99a1e23 Mon Sep 17 00:00:00 2001 From: Thomas Keller Date: Fri, 30 Apr 2010 02:11:40 +0200 Subject: [PATCH] Use the branch / tag name shortener in two other templates as well. --- src/IDF/templates/idf/source/mtn/changelog.html | 12 ++++++++---- src/IDF/templates/idf/source/mtn/file.html | 11 +++++++---- 2 files changed, 15 insertions(+), 8 deletions(-) diff --git a/src/IDF/templates/idf/source/mtn/changelog.html b/src/IDF/templates/idf/source/mtn/changelog.html index fa92f24..bb3dbc5 100644 --- a/src/IDF/templates/idf/source/mtn/changelog.html +++ b/src/IDF/templates/idf/source/mtn/changelog.html @@ -2,15 +2,19 @@ {block context}

{trans 'Branches:'}
{foreach $branches as $branch => $path} -{aurl 'url', 'IDF_Views_Source::changeLog', array($project.shortname, $branch)} -{if $path}{$path}{else}{$branch}{/if}
+{aurl 'url', 'IDF_Views_Source::treeBase', array($project.shortname, $branch)} + + {if $path}{$path|shorten:25}{else}{$branch|shorten:25}{/if} +
{/foreach}

{if $tags}

{trans 'Tags:'}
{foreach $tags as $tag => $path} -{aurl 'url', 'IDF_Views_Source::changeLog', array($project.shortname, $tag)} -{if $path}{$path}{else}{$tag}{/if}
+{aurl 'url', 'IDF_Views_Source::treeBase', array($project.shortname, $tag)} + + {if $path}{$path|shorten:25}{else}{$tag|shorten:25}{/if} +
{/foreach}

{/if} diff --git a/src/IDF/templates/idf/source/mtn/file.html b/src/IDF/templates/idf/source/mtn/file.html index 77b33d8..a8f4e43 100644 --- a/src/IDF/templates/idf/source/mtn/file.html +++ b/src/IDF/templates/idf/source/mtn/file.html @@ -6,7 +6,7 @@ {if !$tree_in and !$tags_in} -{aurl 'url', 'IDF_Views_Source::commit', array($project.shortname, $commit)} +{aurl 'url', 'IDF_Views_Source::commit', array($project.shortname, $commit)}
{blocktrans}Source at commit {$commit} created {$cobject.date|dateago}.{/blocktrans}
{blocktrans}By {$cobject.author|strip_tags|trim}, {$cobject.title}{/blocktrans} @@ -25,19 +25,22 @@

{trans 'Branches:'}
{foreach $branches as $branch => $path} {aurl 'url', 'IDF_Views_Source::treeBase', array($project.shortname, $branch)} -{if $path}{$path}{else}{$branch}{/if}
+ + {if $path}{$path|shorten:25}{else}{$branch|shorten:25}{/if} +
{/foreach}

{if $tags}

{trans 'Tags:'}
{foreach $tags as $tag => $path} {aurl 'url', 'IDF_Views_Source::treeBase', array($project.shortname, $tag)} -{if $path}{$path}{else}{$tag}{/if}
+ + {if $path}{$path|shorten:25}{else}{$tag|shorten:25}{/if} +
{/foreach}

{/if} {/block} - {block javascript}