Mercurial > kallithea
comparison pylons_app/templates/summary/summary.html @ 282:237470e64bb8
switched filters into webhelpers for easy of usage.
Rewrite of html to use predefined templates from branches shortlog tags, for DRY usage.
Added info messages about empty branches/tags etc.
author | Marcin Kuzminski <marcin@python-works.com> |
---|---|
date | Sun, 13 Jun 2010 23:56:16 +0200 |
parents | 373ddb868bd6 |
children | 558eb7c5028f |
comparison
equal
deleted
inserted
replaced
281:cd2ee462fc2c | 282:237470e64bb8 |
---|---|
1 <%inherit file="/base/base.html"/> | 1 <%inherit file="/base/base.html"/> |
2 <%! | |
3 from pylons_app.lib import filters | |
4 %> | |
5 <%def name="title()"> | 2 <%def name="title()"> |
6 ${_('Repository managment')} | 3 ${_('Repository managment')} |
7 </%def> | 4 </%def> |
8 <%def name="breadcrumbs()"> | 5 <%def name="breadcrumbs()"> |
9 ${h.link_to(u'Home',h.url('/'))} | 6 ${h.link_to(u'Home',h.url('/'))} |
39 <dt>${_('description')}</dt> | 36 <dt>${_('description')}</dt> |
40 <dd>${c.repo_info.description}</dd> | 37 <dd>${c.repo_info.description}</dd> |
41 <dt>${_('contact')}</dt> | 38 <dt>${_('contact')}</dt> |
42 <dd>${c.repo_info.contact}</dd> | 39 <dd>${c.repo_info.contact}</dd> |
43 <dt>${_('last change')}</dt> | 40 <dt>${_('last change')}</dt> |
44 <dd>${c.repo_info.last_change|n,filters.age} - ${c.repo_info.last_change|n,filters.rfc822date}</dd> | 41 <dd>${h.age(c.repo_info.last_change)} - ${h.rfc822date(c.repo_info.last_change)}</dd> |
45 <dt>${_('clone url')}</dt> | 42 <dt>${_('clone url')}</dt> |
46 <dd><input type="text" id="clone_url" readonly="readonly" value="hg clone ${c.clone_repo_url}" size="70"/></dd> | 43 <dd><input type="text" id="clone_url" readonly="readonly" value="hg clone ${c.clone_repo_url}" size="70"/></dd> |
47 <dt>${_('download')}</dt> | 44 <dt>${_('download')}</dt> |
48 <dd> | 45 <dd> |
49 %for cnt,archive in enumerate(c.repo_info._get_archives()): | 46 %for cnt,archive in enumerate(c.repo_info._get_archives()): |
61 ${h.link_to(_('Atom'),h.url('atom_feed_home',repo_name=c.repo_info.name),class_='atom_logo')} | 58 ${h.link_to(_('Atom'),h.url('atom_feed_home',repo_name=c.repo_info.name),class_='atom_logo')} |
62 </dd> | 59 </dd> |
63 </dl> | 60 </dl> |
64 | 61 |
65 <h2>${h.link_to(_('Last ten changes'),h.url('changelog_home',repo_name=c.repo_name))}</h2> | 62 <h2>${h.link_to(_('Last ten changes'),h.url('changelog_home',repo_name=c.repo_name))}</h2> |
66 <table class="table_disp"> | 63 <%include file='../shortlog/shortlog_data.html'/> |
67 <tr class="header"> | |
68 <td>${_('date')}</td> | |
69 <td>${_('author')}</td> | |
70 <td>${_('revision')}</td> | |
71 <td>${_('commit message')}</td> | |
72 <td>${_('branch')}</td> | |
73 <td>${_('tags')}</td> | |
74 <td>${_('links')}</td> | |
75 | |
76 </tr> | |
77 %for cnt,cs in enumerate(c.repo_changesets): | |
78 <tr class="parity${cnt%2}"> | |
79 <td>${cs._ctx.date()|n,filters.age}</td> | |
80 <td>${cs.author|n,filters.person}</td> | |
81 <td>r${cs.revision}:${cs.raw_id}</td> | |
82 <td> | |
83 ${h.link_to(h.truncate(cs.message,60), | |
84 h.url('changeset_home',repo_name=c.repo_name,revision=cs._short), | |
85 title=cs.message)} | |
86 </td> | |
87 <td> | |
88 <span class="logtags"> | |
89 <span class="branchtag">${cs.branch}</span> | |
90 </span> | |
91 </td> | |
92 <td> | |
93 <span class="logtags"> | |
94 %for tag in cs.tags: | |
95 <span class="tagtag">${tag}</span> | |
96 %endfor | |
97 </span> | |
98 </td> | |
99 <td class="nowrap"> | |
100 ${h.link_to(_('changeset'),h.url('changeset_home',repo_name=c.repo_name,revision=cs._short))} | |
101 | | |
102 ${h.link_to(_('files'),h.url('files_home',repo_name=c.repo_name,revision=cs._short))} | |
103 </td> | |
104 </tr> | |
105 %endfor | |
106 </table> | |
107 | 64 |
108 <h2>${h.link_to(_('Last ten tags'),h.url('tags_home',repo_name=c.repo_name))}</h2> | 65 <h2>${h.link_to(_('Last ten tags'),h.url('tags_home',repo_name=c.repo_name))}</h2> |
109 <table class="table_disp"> | 66 <%include file='../tags/tags_data.html'/> |
110 <tr class="header"> | 67 |
111 <td>${_('date')}</td> | |
112 <td>${_('revision')}</td> | |
113 <td>${_('name')}</td> | |
114 <td>${_('links')}</td> | |
115 </tr> | |
116 %for cnt,tag in enumerate(c.repo_tags.items()): | |
117 <tr class="parity${cnt%2}"> | |
118 <td>${tag[1]._ctx.date()|n,filters.age}</td> | |
119 <td>r${tag[1].revision}:${tag[1].raw_id}</td> | |
120 <td> | |
121 <span class="logtags"> | |
122 <span class="tagtag">${h.link_to(tag[0], | |
123 h.url('changeset_home',repo_name=c.repo_name,revision=tag[1].raw_id))}</span> | |
124 </span> | |
125 </td> | |
126 <td class="nowrap"> | |
127 ${h.link_to(_('changeset'),h.url('changeset_home',repo_name=c.repo_name,revision=tag[1].raw_id))} | |
128 | | |
129 ${h.link_to(_('files'),h.url('files_home',repo_name=c.repo_name,revision=tag[1].raw_id))} | |
130 </td> | |
131 </tr> | |
132 %endfor | |
133 </table> | |
134 | |
135 <h2>${h.link_to(_('Last ten branches'),h.url('branches_home',repo_name=c.repo_name))}</h2> | 68 <h2>${h.link_to(_('Last ten branches'),h.url('branches_home',repo_name=c.repo_name))}</h2> |
136 <table class="table_disp"> | 69 <%include file='../branches/branches_data.html'/> |
137 <tr class="header"> | |
138 <td>${_('date')}</td> | |
139 <td>${_('revision')}</td> | |
140 <td>${_('name')}</td> | |
141 <td>${_('links')}</td> | |
142 </tr> | |
143 %for cnt,branch in enumerate(c.repo_branches.items()): | |
144 <tr class="parity${cnt%2}"> | |
145 <td>${branch[1]._ctx.date()|n,filters.age}</td> | |
146 <td>r${branch[1].revision}:${branch[1].raw_id}</td> | |
147 <td> | |
148 <span class="logtags"> | |
149 <span class="branchtag">${h.link_to(branch[0], | |
150 h.url('changeset_home',repo_name=c.repo_name,revision=branch[1].raw_id))}</span> | |
151 </span> | |
152 </td> | |
153 <td class="nowrap"> | |
154 ${h.link_to(_('changeset'),h.url('changeset_home',repo_name=c.repo_name,revision=branch[1].raw_id))} | |
155 | | |
156 ${h.link_to(_('files'),h.url('files_home',repo_name=c.repo_name,revision=branch[1].raw_id))} | |
157 </td> | |
158 </tr> | |
159 %endfor | |
160 </table> | |
161 | 70 |
162 </%def> | 71 </%def> |