Mercurial > kallithea
comparison rhodecode/templates/switch_to_list.html @ 3425:46e10b3de4e3 beta
added same switch to logic for tags and bookmarks containing /.
added "at" GET params to visualize switching for revisions with /
author | Marcin Kuzminski <marcin@python-works.com> |
---|---|
date | Sat, 02 Mar 2013 16:36:14 +0100 |
parents | 440fab755fa9 |
children | ec6354949623 |
comparison
equal
deleted
inserted
replaced
3424:440fab755fa9 | 3425:46e10b3de4e3 |
---|---|
2 <li> | 2 <li> |
3 ${h.link_to('%s (%s)' % (_('branches'),len(c.rhodecode_repo.branches.values()),),h.url('branches_home',repo_name=c.repo_name),class_='branches childs')} | 3 ${h.link_to('%s (%s)' % (_('branches'),len(c.rhodecode_repo.branches.values()),),h.url('branches_home',repo_name=c.repo_name),class_='branches childs')} |
4 <ul> | 4 <ul> |
5 %if c.rhodecode_repo.branches.values(): | 5 %if c.rhodecode_repo.branches.values(): |
6 %for cnt,branch in enumerate(c.rhodecode_repo.branches.items()): | 6 %for cnt,branch in enumerate(c.rhodecode_repo.branches.items()): |
7 <li><div><pre>${h.link_to('%s - %s' % (branch[0],h.short_id(branch[1])),h.url('files_home',repo_name=c.repo_name,revision=(branch[0] if '/' not in branch[0] else branch[1])))}</pre></div></li> | 7 <li><div><pre>${h.link_to('%s - %s' % (branch[0],h.short_id(branch[1])),h.url('files_home',repo_name=c.repo_name,revision=(branch[0] if '/' not in branch[0] else branch[1]), at=branch[0]))}</pre></div></li> |
8 %endfor | 8 %endfor |
9 %else: | 9 %else: |
10 <li>${h.link_to(_('There are no branches yet'),'#')}</li> | 10 <li>${h.link_to(_('There are no branches yet'),'#')}</li> |
11 %endif | 11 %endif |
12 </ul> | 12 </ul> |
14 <li> | 14 <li> |
15 ${h.link_to('%s (%s)' % (_('tags'),len(c.rhodecode_repo.tags.values()),),h.url('tags_home',repo_name=c.repo_name),class_='tags childs')} | 15 ${h.link_to('%s (%s)' % (_('tags'),len(c.rhodecode_repo.tags.values()),),h.url('tags_home',repo_name=c.repo_name),class_='tags childs')} |
16 <ul> | 16 <ul> |
17 %if c.rhodecode_repo.tags.values(): | 17 %if c.rhodecode_repo.tags.values(): |
18 %for cnt,tag in enumerate(c.rhodecode_repo.tags.items()): | 18 %for cnt,tag in enumerate(c.rhodecode_repo.tags.items()): |
19 <li><div><pre>${h.link_to('%s - %s' % (tag[0],h.short_id(tag[1])),h.url('files_home',repo_name=c.repo_name,revision=tag[0]))}</pre></div></li> | 19 <li><div><pre>${h.link_to('%s - %s' % (tag[0],h.short_id(tag[1])),h.url('files_home',repo_name=c.repo_name,revision=(tag[0] if '/' not in tag[0] else tag[1]), at=tag[0]))}</pre></div></li> |
20 %endfor | 20 %endfor |
21 %else: | 21 %else: |
22 <li>${h.link_to(_('There are no tags yet'),'#')}</li> | 22 <li>${h.link_to(_('There are no tags yet'),'#')}</li> |
23 %endif | 23 %endif |
24 </ul> | 24 </ul> |
27 <li> | 27 <li> |
28 ${h.link_to('%s (%s)' % (_('bookmarks'),len(c.rhodecode_repo.bookmarks.values()),),h.url('bookmarks_home',repo_name=c.repo_name),class_='bookmarks childs')} | 28 ${h.link_to('%s (%s)' % (_('bookmarks'),len(c.rhodecode_repo.bookmarks.values()),),h.url('bookmarks_home',repo_name=c.repo_name),class_='bookmarks childs')} |
29 <ul> | 29 <ul> |
30 %if c.rhodecode_repo.bookmarks.values(): | 30 %if c.rhodecode_repo.bookmarks.values(): |
31 %for cnt,book in enumerate(c.rhodecode_repo.bookmarks.items()): | 31 %for cnt,book in enumerate(c.rhodecode_repo.bookmarks.items()): |
32 <li><div><pre>${h.link_to('%s - %s' % (book[0],h.short_id(book[1])),h.url('files_home',repo_name=c.repo_name,revision=book[1]))}</pre></div></li> | 32 <li><div><pre>${h.link_to('%s - %s' % (book[0],h.short_id(book[1])),h.url('files_home',repo_name=c.repo_name,revision=(book[0] if '/' not in book[0] else book[1]), at=book[0]))}</pre></div></li> |
33 %endfor | 33 %endfor |
34 %else: | 34 %else: |
35 <li>${h.link_to(_('There are no bookmarks yet'),'#')}</li> | 35 <li>${h.link_to(_('There are no bookmarks yet'),'#')}</li> |
36 %endif | 36 %endif |
37 </ul> | 37 </ul> |