Changeset 89
- Timestamp:
- 11/06/06 10:58:58 (3 years ago)
- Location:
- infra/TracX/tracx/templates
- Files:
-
- 2 modified
-
layout.html (modified) (4 diffs)
-
wiki_view.html (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
infra/TracX/tracx/templates/layout.html
r87 r89 1 <!DOCTYPE html1 <!DOCTYPE html 2 2 PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" 3 3 "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> … … 11 11 <head py:match="head"> 12 12 <title py:with="title = unicode(select('title/text()'))"> 13 ${' – '.join(filter(None, [title, project.name, 'Trac']))}13 ${' - '.join(filter(None, [title, project.name]))} 14 14 </title> 15 <meta py:if="norobots" name="ROBOTS" content="NOINDEX, NOFOLLOW" />16 15 <py:if test="chrome.links"> 17 16 <py:for each="rel, links in chrome.links.items()"> … … 46 45 src="${chrome.logo.src}" alt="${chrome.logo.alt}" /></a> 47 46 </div> 48 <form py:if=" perm.has_permission('SEARCH_VIEW')" id="search"47 <form py:if="'SEARCH_VIEW' in perm" id="search" 49 48 action="${href.search()}" method="get"><div> 50 49 <label for="proj-search">Search:</label> … … 63 62 <div id="main"> 64 63 ${select('*|text()')} 64 65 <script type="text/javascript" py:if="chrome.late_links"> 66 <py:for each="link in chrome.late_links.get('stylesheet')"> 67 $.loadStyleSheet("${link.href}", "${link.title}"); 68 </py:for> 69 </script> 70 <script py:for="script in chrome.late_scripts" 71 type="${script.type}" src="${script.href}"></script> 65 72 66 73 <div id="altlinks" py:if="chrome.links.alternate"> -
infra/TracX/tracx/templates/wiki_view.html
r78 r89 9 9 <head> 10 10 <title>$title</title> 11 <meta py:if="version" name="ROBOTS" content="NOINDEX, NOFOLLOW" /> 11 12 <script type="text/javascript"> 12 13 $(document).ready(function() { … … 43 44 ${backlinking('backlinks')} 44 45 45 46 <py:if test="comment_html"> 46 <py:if test="version"> 47 47 <table id="info" summary="Revision info"> 48 48 <tbody> 49 <tr><th scope="col">Version $page.version (modified by $page.author, ${dateinfo(page.time)} ago)</th></tr> 50 <tr><td class="message">$comment_html</td></tr> 49 <tr><th scope="row"> 50 Version $page.version (modified by $page.author, ${dateinfo(page.time)} ago) 51 </th></tr> 52 <tr><td class="message"> 53 ${wiki_to_oneliner(comment or '--')} 54 </td></tr> 51 55 </tbody> 52 56 </table> 53 57 </py:if> 54 58 55 <div class="wikipage searchable"> 56 $page_html 59 <div class="wikipage searchable" py:choose=""> 60 <py:when test="page.exists"> 61 ${wiki_to_html(page.text)} 62 </py:when> 63 <py:otherwise> 64 Describe ${page.name} here. 65 </py:otherwise> 57 66 </div> 58 67 59 68 ${list_of_attachments(attachments, attach_href, compact=True)} 60 69 61 <py:with vars="modify_perm = perm.has_permission('WIKI_MODIFY');62 delete_perm = perm.has_permission('WIKI_DELETE');63 admin_perm = perm.has_permission('WIKI_ADMIN')">64 <py:if test="admin_perm or (not readonly and (modify_perm or delete_perm))">70 <py:with vars="modify_perm = 'WIKI_MODIFY' in perm; 71 delete_perm = 'WIKI_DELETE' in perm; 72 admin_perm = 'WIKI_ADMIN' in perm"> 73 <py:if test="admin_perm or (not page.readonly and (modify_perm or delete_perm))"> 65 74 <div class="buttons"> 66 75 <py:if test="modify_perm">