diff pylons_app/templates/summary/summary.html @ 260:6ada8c223374

made global funcion to clean repo names, and remove all special chars from the name. Switched message slug into webhelpers function
author Marcin Kuzminski <marcin@python-works.com>
date Sun, 06 Jun 2010 21:54:54 +0200
parents 7c4fa2a66195
children 0e5455fda8fd
line wrap: on
line diff
--- a/pylons_app/templates/summary/summary.html	Sun Jun 06 10:57:49 2010 +0200
+++ b/pylons_app/templates/summary/summary.html	Sun Jun 06 21:54:54 2010 +0200
@@ -64,22 +64,13 @@
 
     <h2>${h.link_to(_('Changes'),h.url('changelog_home',repo_name=c.repo_name))}</h2>
     <table>
-	<%def name="message_slug(msg)">
-		<%
-		limit = 60
-		if len(msg) > limit:
-			return msg[:limit]+'...'
-		else:
-			return msg
-		%>
-	</%def>    
 	%for cnt,cs in enumerate(c.repo_changesets):
 		<tr class="parity${cnt%2}">
 			<td>${cs._ctx.date()|n,filters.age}</td>
 			<td>${cs.author|n,filters.person}</td>
 			<td>r${cs.revision}</td>
 			<td>
-				${h.link_to(message_slug(cs.message),
+				${h.link_to(truncate(cs.message,60),
 				h.url('changeset_home',repo_name=c.repo_name,revision=cs._short),
 				title=cs.message)}
 			</td>