Show More
@@ -1,356 +1,356 b'' | |||||
1 | ## -*- coding: utf-8 -*- |
|
1 | ## -*- coding: utf-8 -*- | |
2 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> |
|
2 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> | |
3 | <html xmlns="http://www.w3.org/1999/xhtml" id="mainhtml"> |
|
3 | <html xmlns="http://www.w3.org/1999/xhtml" id="mainhtml"> | |
4 | <head> |
|
4 | <head> | |
5 | <title>${next.title()}</title> |
|
5 | <title>${next.title()}</title> | |
6 | <link rel="icon" href="/images/icons/database_gear.png" type="image/png" /> |
|
6 | <link rel="icon" href="/images/icons/database_gear.png" type="image/png" /> | |
7 | <meta http-equiv="Content-Type" content="text/html;charset=utf-8" /> |
|
7 | <meta http-equiv="Content-Type" content="text/html;charset=utf-8" /> | |
8 | <meta name="robots" content="index, nofollow"/> |
|
8 | <meta name="robots" content="index, nofollow"/> | |
9 | <!-- stylesheets --> |
|
9 | <!-- stylesheets --> | |
10 | ${self.css()} |
|
10 | ${self.css()} | |
11 | <!-- scripts --> |
|
11 | <!-- scripts --> | |
12 | ${self.js()} |
|
12 | ${self.js()} | |
13 | </head> |
|
13 | </head> | |
14 | <body> |
|
14 | <body> | |
15 | <!-- header --> |
|
15 | <!-- header --> | |
16 | <div id="header"> |
|
16 | <div id="header"> | |
17 | <!-- user --> |
|
17 | <!-- user --> | |
18 | <ul id="logged-user"> |
|
18 | <ul id="logged-user"> | |
19 | <li class="first"> |
|
19 | <li class="first"> | |
20 | <div class="gravatar"> |
|
20 | <div class="gravatar"> | |
21 | <img alt="gravatar" src="${h.gravatar_url(c.rhodecode_user.email,24)}" /> |
|
21 | <img alt="gravatar" src="${h.gravatar_url(c.rhodecode_user.email,24)}" /> | |
22 | </div> |
|
22 | </div> | |
23 | %if c.rhodecode_user.username == 'default': |
|
23 | %if c.rhodecode_user.username == 'default': | |
24 | <div class="account"> |
|
24 | <div class="account"> | |
25 | ${h.link_to('%s %s'%(c.rhodecode_user.name,c.rhodecode_user.lastname),h.url('#'))}<br/> |
|
25 | ${h.link_to('%s %s'%(c.rhodecode_user.name,c.rhodecode_user.lastname),h.url('#'))}<br/> | |
26 | ${h.link_to(c.rhodecode_user.username,h.url('#'))} |
|
26 | ${h.link_to(c.rhodecode_user.username,h.url('#'))} | |
27 | </div> |
|
27 | </div> | |
28 | </li> |
|
28 | </li> | |
29 | <li class="last highlight">${h.link_to(u'Login',h.url('login_home'))}</li> |
|
29 | <li class="last highlight">${h.link_to(u'Login',h.url('login_home'))}</li> | |
30 | %else: |
|
30 | %else: | |
31 |
|
31 | |||
32 | <div class="account"> |
|
32 | <div class="account"> | |
33 | ${h.link_to('%s %s'%(c.rhodecode_user.name,c.rhodecode_user.lastname),h.url('admin_settings_my_account'))}<br/> |
|
33 | ${h.link_to('%s %s'%(c.rhodecode_user.name,c.rhodecode_user.lastname),h.url('admin_settings_my_account'))}<br/> | |
34 | ${h.link_to(c.rhodecode_user.username,h.url('admin_settings_my_account'))} |
|
34 | ${h.link_to(c.rhodecode_user.username,h.url('admin_settings_my_account'))} | |
35 | </div> |
|
35 | </div> | |
36 | </li> |
|
36 | </li> | |
37 | <li class="last highlight">${h.link_to(u'Logout',h.url('logout_home'))}</li> |
|
37 | <li class="last highlight">${h.link_to(u'Logout',h.url('logout_home'))}</li> | |
38 | %endif |
|
38 | %endif | |
39 | </ul> |
|
39 | </ul> | |
40 | <!-- end user --> |
|
40 | <!-- end user --> | |
41 | <div id="header-inner" class="title top-left-rounded-corner top-right-rounded-corner"> |
|
41 | <div id="header-inner" class="title top-left-rounded-corner top-right-rounded-corner"> | |
42 | <!-- logo --> |
|
42 | <!-- logo --> | |
43 | <div id="logo"> |
|
43 | <div id="logo"> | |
44 | <h1><a href="${h.url('home')}">${c.rhodecode_name}</a></h1> |
|
44 | <h1><a href="${h.url('home')}">${c.rhodecode_name}</a></h1> | |
45 | </div> |
|
45 | </div> | |
46 | <!-- end logo --> |
|
46 | <!-- end logo --> | |
47 | <!-- menu --> |
|
47 | <!-- menu --> | |
48 | ${self.page_nav()} |
|
48 | ${self.page_nav()} | |
49 | <!-- quick --> |
|
49 | <!-- quick --> | |
50 | </div> |
|
50 | </div> | |
51 | </div> |
|
51 | </div> | |
52 | <!-- end header --> |
|
52 | <!-- end header --> | |
53 |
|
53 | |||
54 | <!-- CONTENT --> |
|
54 | <!-- CONTENT --> | |
55 | <div id="content"> |
|
55 | <div id="content"> | |
56 | <div class="flash_msg"> |
|
56 | <div class="flash_msg"> | |
57 | <% messages = h.flash.pop_messages() %> |
|
57 | <% messages = h.flash.pop_messages() %> | |
58 | % if messages: |
|
58 | % if messages: | |
59 | <ul id="flash-messages"> |
|
59 | <ul id="flash-messages"> | |
60 | % for message in messages: |
|
60 | % for message in messages: | |
61 | <li class="${message.category}_msg">${message}</li> |
|
61 | <li class="${message.category}_msg">${message}</li> | |
62 | % endfor |
|
62 | % endfor | |
63 | </ul> |
|
63 | </ul> | |
64 | % endif |
|
64 | % endif | |
65 | </div> |
|
65 | </div> | |
66 | <div id="main"> |
|
66 | <div id="main"> | |
67 | ${next.main()} |
|
67 | ${next.main()} | |
68 | </div> |
|
68 | </div> | |
69 | </div> |
|
69 | </div> | |
70 | <!-- END CONTENT --> |
|
70 | <!-- END CONTENT --> | |
71 |
|
71 | |||
72 | <!-- footer --> |
|
72 | <!-- footer --> | |
73 | <div id="footer"> |
|
73 | <div id="footer"> | |
74 | <div id="footer-inner" class="title bottom-left-rounded-corner bottom-right-rounded-corner"> |
|
74 | <div id="footer-inner" class="title bottom-left-rounded-corner bottom-right-rounded-corner"> | |
75 | <div> |
|
75 | <div> | |
76 | <p class="footer-link">${h.link_to(_('Submit a bug'),h.url('bugtracker'))}</p> |
|
76 | <p class="footer-link">${h.link_to(_('Submit a bug'),h.url('bugtracker'))}</p> | |
77 | <p class="footer-link">${h.link_to(_('GPL license'),h.url('gpl_license'))}</p> |
|
77 | <p class="footer-link">${h.link_to(_('GPL license'),h.url('gpl_license'))}</p> | |
78 | <p>RhodeCode ${c.rhodecode_version} © 2010 by Marcin Kuzminski</p> |
|
78 | <p>RhodeCode ${c.rhodecode_version} © 2010 by Marcin Kuzminski</p> | |
79 | </div> |
|
79 | </div> | |
80 | </div> |
|
80 | </div> | |
81 | <script type="text/javascript">${h.tooltip.activate()}</script> |
|
81 | <script type="text/javascript">${h.tooltip.activate()}</script> | |
82 | </div> |
|
82 | </div> | |
83 | <!-- end footer --> |
|
83 | <!-- end footer --> | |
84 | </body> |
|
84 | </body> | |
85 |
|
85 | |||
86 | </html> |
|
86 | </html> | |
87 |
|
87 | |||
88 | ### MAKO DEFS ### |
|
88 | ### MAKO DEFS ### | |
89 | <%def name="page_nav()"> |
|
89 | <%def name="page_nav()"> | |
90 | ${self.menu()} |
|
90 | ${self.menu()} | |
91 | </%def> |
|
91 | </%def> | |
92 |
|
92 | |||
93 | <%def name="menu(current=None)"> |
|
93 | <%def name="menu(current=None)"> | |
94 | <% |
|
94 | <% | |
95 | def is_current(selected): |
|
95 | def is_current(selected): | |
96 | if selected == current: |
|
96 | if selected == current: | |
97 | return h.literal('class="current"') |
|
97 | return h.literal('class="current"') | |
98 | %> |
|
98 | %> | |
99 | %if current not in ['home','admin']: |
|
99 | %if current not in ['home','admin']: | |
100 | ##REGULAR MENU |
|
100 | ##REGULAR MENU | |
101 | <ul id="quick"> |
|
101 | <ul id="quick"> | |
102 | <!-- repo switcher --> |
|
102 | <!-- repo switcher --> | |
103 | <li> |
|
103 | <li> | |
104 | <a id="repo_switcher" title="${_('Switch repository')}" href="#"> |
|
104 | <a id="repo_switcher" title="${_('Switch repository')}" href="#"> | |
105 | <span class="icon"> |
|
105 | <span class="icon"> | |
106 | <img src="/images/icons/database.png" alt="${_('Products')}" /> |
|
106 | <img src="/images/icons/database.png" alt="${_('Products')}" /> | |
107 | </span> |
|
107 | </span> | |
108 | <span>↓</span> |
|
108 | <span>↓</span> | |
109 | </a> |
|
109 | </a> | |
110 | <ul class="repo_switcher"> |
|
110 | <ul class="repo_switcher"> | |
111 | %for repo in c.cached_repo_list: |
|
111 | %for repo in c.cached_repo_list: | |
112 |
|
112 | |||
113 | %if repo['repo'].dbrepo.private: |
|
113 | %if repo['repo'].dbrepo.private: | |
114 | <li><img src="/images/icons/lock.png" alt="${_('Private repository')}" class="repo_switcher_type"/>${h.link_to(repo['repo'].name,h.url('summary_home',repo_name=repo['repo'].name),class_="%s" % repo['repo'].dbrepo.repo_type)}</li> |
|
114 | <li><img src="/images/icons/lock.png" alt="${_('Private repository')}" class="repo_switcher_type"/>${h.link_to(repo['repo'].name,h.url('summary_home',repo_name=repo['repo'].name),class_="%s" % repo['repo'].dbrepo.repo_type)}</li> | |
115 | %else: |
|
115 | %else: | |
116 | <li><img src="/images/icons/lock_open.png" alt="${_('Public repository')}" class="repo_switcher_type" />${h.link_to(repo['repo'].name,h.url('summary_home',repo_name=repo['repo'].name),class_="%s" % repo['repo'].dbrepo.repo_type)}</li> |
|
116 | <li><img src="/images/icons/lock_open.png" alt="${_('Public repository')}" class="repo_switcher_type" />${h.link_to(repo['repo'].name,h.url('summary_home',repo_name=repo['repo'].name),class_="%s" % repo['repo'].dbrepo.repo_type)}</li> | |
117 | %endif |
|
117 | %endif | |
118 | %endfor |
|
118 | %endfor | |
119 | </ul> |
|
119 | </ul> | |
120 | </li> |
|
120 | </li> | |
121 |
|
121 | |||
122 | <li ${is_current('summary')}> |
|
122 | <li ${is_current('summary')}> | |
123 | <a title="${_('Summary')}" href="${h.url('summary_home',repo_name=c.repo_name)}"> |
|
123 | <a title="${_('Summary')}" href="${h.url('summary_home',repo_name=c.repo_name)}"> | |
124 | <span class="icon"> |
|
124 | <span class="icon"> | |
125 | <img src="/images/icons/clipboard_16.png" alt="${_('Summary')}" /> |
|
125 | <img src="/images/icons/clipboard_16.png" alt="${_('Summary')}" /> | |
126 | </span> |
|
126 | </span> | |
127 | <span>${_('Summary')}</span> |
|
127 | <span>${_('Summary')}</span> | |
128 | </a> |
|
128 | </a> | |
129 | </li> |
|
129 | </li> | |
130 | ##<li ${is_current('shortlog')}> |
|
130 | ##<li ${is_current('shortlog')}> | |
131 | ## <a title="${_('Shortlog')}" href="${h.url('shortlog_home',repo_name=c.repo_name)}"> |
|
131 | ## <a title="${_('Shortlog')}" href="${h.url('shortlog_home',repo_name=c.repo_name)}"> | |
132 | ## <span class="icon"> |
|
132 | ## <span class="icon"> | |
133 | ## <img src="/images/icons/application_view_list.png" alt="${_('Shortlog')}" /> |
|
133 | ## <img src="/images/icons/application_view_list.png" alt="${_('Shortlog')}" /> | |
134 | ## </span> |
|
134 | ## </span> | |
135 | ## <span>${_('Shortlog')}</span> |
|
135 | ## <span>${_('Shortlog')}</span> | |
136 | ## </a> |
|
136 | ## </a> | |
137 | ##</li> |
|
137 | ##</li> | |
138 | <li ${is_current('changelog')}> |
|
138 | <li ${is_current('changelog')}> | |
139 | <a title="${_('Changelog')}" href="${h.url('changelog_home',repo_name=c.repo_name)}"> |
|
139 | <a title="${_('Changelog')}" href="${h.url('changelog_home',repo_name=c.repo_name)}"> | |
140 | <span class="icon"> |
|
140 | <span class="icon"> | |
141 | <img src="/images/icons/time.png" alt="${_('Changelog')}" /> |
|
141 | <img src="/images/icons/time.png" alt="${_('Changelog')}" /> | |
142 | </span> |
|
142 | </span> | |
143 | <span>${_('Changelog')}</span> |
|
143 | <span>${_('Changelog')}</span> | |
144 | </a> |
|
144 | </a> | |
145 | </li> |
|
145 | </li> | |
146 |
|
146 | |||
147 | <li ${is_current('switch_to')}> |
|
147 | <li ${is_current('switch_to')}> | |
148 | <a title="${_('Switch to')}" href="#"> |
|
148 | <a title="${_('Switch to')}" href="#"> | |
149 | <span class="icon"> |
|
149 | <span class="icon"> | |
150 | <img src="/images/icons/arrow_switch.png" alt="${_('Switch to')}" /> |
|
150 | <img src="/images/icons/arrow_switch.png" alt="${_('Switch to')}" /> | |
151 | </span> |
|
151 | </span> | |
152 | <span>${_('Switch to')}</span> |
|
152 | <span>${_('Switch to')}</span> | |
153 | </a> |
|
153 | </a> | |
154 | <ul> |
|
154 | <ul> | |
155 | <li> |
|
155 | <li> | |
156 | ${h.link_to('%s (%s)' % (_('branches'),len(c.repository_branches.values()),),h.url('branches_home',repo_name=c.repo_name),class_='branches childs')} |
|
156 | ${h.link_to('%s (%s)' % (_('branches'),len(c.repository_branches.values()),),h.url('branches_home',repo_name=c.repo_name),class_='branches childs')} | |
157 | <ul> |
|
157 | <ul> | |
158 | %if c.repository_branches.values(): |
|
158 | %if c.repository_branches.values(): | |
159 | %for cnt,branch in enumerate(c.repository_branches.items()): |
|
159 | %for cnt,branch in enumerate(c.repository_branches.items()): | |
160 | <li>${h.link_to('%s - %s' % (branch[0],h.short_id(branch[1])),h.url('files_home',repo_name=c.repo_name,revision=branch[1]))}</li> |
|
160 | <li>${h.link_to('%s - %s' % (branch[0],h.short_id(branch[1])),h.url('files_home',repo_name=c.repo_name,revision=branch[1]))}</li> | |
161 | %endfor |
|
161 | %endfor | |
162 | %else: |
|
162 | %else: | |
163 | <li>${h.link_to(_('There are no branches yet'),'#')}</li> |
|
163 | <li>${h.link_to(_('There are no branches yet'),'#')}</li> | |
164 | %endif |
|
164 | %endif | |
165 | </ul> |
|
165 | </ul> | |
166 | </li> |
|
166 | </li> | |
167 | <li> |
|
167 | <li> | |
168 | ${h.link_to('%s (%s)' % (_('tags'),len(c.repository_tags.values()),),h.url('tags_home',repo_name=c.repo_name),class_='tags childs')} |
|
168 | ${h.link_to('%s (%s)' % (_('tags'),len(c.repository_tags.values()),),h.url('tags_home',repo_name=c.repo_name),class_='tags childs')} | |
169 | <ul> |
|
169 | <ul> | |
170 | %if c.repository_tags.values(): |
|
170 | %if c.repository_tags.values(): | |
171 | %for cnt,tag in enumerate(c.repository_tags.items()): |
|
171 | %for cnt,tag in enumerate(c.repository_tags.items()): | |
172 | <li>${h.link_to('%s - %s' % (tag[0],h.short_id(tag[1])),h.url('files_home',repo_name=c.repo_name,revision=tag[1]))}</li> |
|
172 | <li>${h.link_to('%s - %s' % (tag[0],h.short_id(tag[1])),h.url('files_home',repo_name=c.repo_name,revision=tag[1]))}</li> | |
173 | %endfor |
|
173 | %endfor | |
174 | %else: |
|
174 | %else: | |
175 | <li>${h.link_to(_('There are no tags yet'),'#')}</li> |
|
175 | <li>${h.link_to(_('There are no tags yet'),'#')}</li> | |
176 | %endif |
|
176 | %endif | |
177 | </ul> |
|
177 | </ul> | |
178 | </li> |
|
178 | </li> | |
179 | </ul> |
|
179 | </ul> | |
180 | </li> |
|
180 | </li> | |
181 | <li ${is_current('files')}> |
|
181 | <li ${is_current('files')}> | |
182 | <a title="${_('Files')}" href="${h.url('files_home',repo_name=c.repo_name)}"> |
|
182 | <a title="${_('Files')}" href="${h.url('files_home',repo_name=c.repo_name)}"> | |
183 | <span class="icon"> |
|
183 | <span class="icon"> | |
184 | <img src="/images/icons/file.png" alt="${_('Files')}" /> |
|
184 | <img src="/images/icons/file.png" alt="${_('Files')}" /> | |
185 | </span> |
|
185 | </span> | |
186 | <span>${_('Files')}</span> |
|
186 | <span>${_('Files')}</span> | |
187 | </a> |
|
187 | </a> | |
188 | </li> |
|
188 | </li> | |
189 |
|
189 | |||
190 | <li ${is_current('options')}> |
|
190 | <li ${is_current('options')}> | |
191 | <a title="${_('Options')}" href="#"> |
|
191 | <a title="${_('Options')}" href="#"> | |
192 | <span class="icon"> |
|
192 | <span class="icon"> | |
193 | <img src="/images/icons/table_gear.png" alt="${_('Admin')}" /> |
|
193 | <img src="/images/icons/table_gear.png" alt="${_('Admin')}" /> | |
194 | </span> |
|
194 | </span> | |
195 | <span>${_('Options')}</span> |
|
195 | <span>${_('Options')}</span> | |
196 | </a> |
|
196 | </a> | |
197 | <ul> |
|
197 | <ul> | |
198 | %if h.HasRepoPermissionAll('repository.admin')(c.repo_name): |
|
198 | %if h.HasRepoPermissionAll('repository.admin')(c.repo_name): | |
199 | <li>${h.link_to(_('settings'),h.url('repo_settings_home',repo_name=c.repo_name),class_='settings')}</li> |
|
199 | <li>${h.link_to(_('settings'),h.url('repo_settings_home',repo_name=c.repo_name),class_='settings')}</li> | |
200 | %endif |
|
|||
201 | <li>${h.link_to(_('fork'),h.url('repo_fork_home',repo_name=c.repo_name),class_='fork')}</li> |
|
200 | <li>${h.link_to(_('fork'),h.url('repo_fork_home',repo_name=c.repo_name),class_='fork')}</li> | |
|
201 | %endif | |||
202 | <li>${h.link_to(_('search'),h.url('search_repo',search_repo=c.repo_name),class_='search')}</li> |
|
202 | <li>${h.link_to(_('search'),h.url('search_repo',search_repo=c.repo_name),class_='search')}</li> | |
203 |
|
203 | |||
204 | %if h.HasPermissionAll('hg.admin')('access admin main page'): |
|
204 | %if h.HasPermissionAll('hg.admin')('access admin main page'): | |
205 | <li> |
|
205 | <li> | |
206 | ${h.link_to(_('admin'),h.url('admin_home'),class_='admin')} |
|
206 | ${h.link_to(_('admin'),h.url('admin_home'),class_='admin')} | |
207 | <ul> |
|
207 | <ul> | |
208 | <li>${h.link_to(_('journal'),h.url('admin_home'),class_='journal')}</li> |
|
208 | <li>${h.link_to(_('journal'),h.url('admin_home'),class_='journal')}</li> | |
209 | <li>${h.link_to(_('repositories'),h.url('repos'),class_='repos')}</li> |
|
209 | <li>${h.link_to(_('repositories'),h.url('repos'),class_='repos')}</li> | |
210 | <li>${h.link_to(_('users'),h.url('users'),class_='users')}</li> |
|
210 | <li>${h.link_to(_('users'),h.url('users'),class_='users')}</li> | |
211 | <li>${h.link_to(_('permissions'),h.url('edit_permission',id='default'),class_='permissions')}</li> |
|
211 | <li>${h.link_to(_('permissions'),h.url('edit_permission',id='default'),class_='permissions')}</li> | |
212 | <li class="last">${h.link_to(_('settings'),h.url('admin_settings'),class_='settings')}</li> |
|
212 | <li class="last">${h.link_to(_('settings'),h.url('admin_settings'),class_='settings')}</li> | |
213 | </ul> |
|
213 | </ul> | |
214 | </li> |
|
214 | </li> | |
215 | %endif |
|
215 | %endif | |
216 |
|
216 | |||
217 | </ul> |
|
217 | </ul> | |
218 | </li> |
|
218 | </li> | |
219 |
|
219 | |||
220 | <li> |
|
220 | <li> | |
221 | <a title="${_('Followers')}" href="#"> |
|
221 | <a title="${_('Followers')}" href="#"> | |
222 | <span class="icon_short"> |
|
222 | <span class="icon_short"> | |
223 | <img src="/images/icons/heart.png" alt="${_('Followers')}" /> |
|
223 | <img src="/images/icons/heart.png" alt="${_('Followers')}" /> | |
224 | </span> |
|
224 | </span> | |
225 | <span class="short">${c.repository_followers}</span> |
|
225 | <span class="short">${c.repository_followers}</span> | |
226 | </a> |
|
226 | </a> | |
227 | </li> |
|
227 | </li> | |
228 | <li> |
|
228 | <li> | |
229 | <a title="${_('Forks')}" href="#"> |
|
229 | <a title="${_('Forks')}" href="#"> | |
230 | <span class="icon_short"> |
|
230 | <span class="icon_short"> | |
231 | <img src="/images/icons/arrow_divide.png" alt="${_('Forks')}" /> |
|
231 | <img src="/images/icons/arrow_divide.png" alt="${_('Forks')}" /> | |
232 | </span> |
|
232 | </span> | |
233 | <span class="short">${c.repository_forks}</span> |
|
233 | <span class="short">${c.repository_forks}</span> | |
234 | </a> |
|
234 | </a> | |
235 | </li> |
|
235 | </li> | |
236 |
|
236 | |||
237 |
|
237 | |||
238 |
|
238 | |||
239 | </ul> |
|
239 | </ul> | |
240 | %else: |
|
240 | %else: | |
241 | ##ROOT MENU |
|
241 | ##ROOT MENU | |
242 | <ul id="quick"> |
|
242 | <ul id="quick"> | |
243 | <li> |
|
243 | <li> | |
244 | <a title="${_('Home')}" href="${h.url('home')}"> |
|
244 | <a title="${_('Home')}" href="${h.url('home')}"> | |
245 | <span class="icon"> |
|
245 | <span class="icon"> | |
246 | <img src="/images/icons/home_16.png" alt="${_('Home')}" /> |
|
246 | <img src="/images/icons/home_16.png" alt="${_('Home')}" /> | |
247 | </span> |
|
247 | </span> | |
248 | <span>${_('Home')}</span> |
|
248 | <span>${_('Home')}</span> | |
249 | </a> |
|
249 | </a> | |
250 | </li> |
|
250 | </li> | |
251 |
|
251 | |||
252 | <li> |
|
252 | <li> | |
253 | <a title="${_('Journal')}" href="${h.url('journal')}"> |
|
253 | <a title="${_('Journal')}" href="${h.url('journal')}"> | |
254 | <span class="icon"> |
|
254 | <span class="icon"> | |
255 | <img src="/images/icons/book.png" alt="${_('Journal')}" /> |
|
255 | <img src="/images/icons/book.png" alt="${_('Journal')}" /> | |
256 | </span> |
|
256 | </span> | |
257 | <span>${_('Journal')}</span> |
|
257 | <span>${_('Journal')}</span> | |
258 | </a> |
|
258 | </a> | |
259 | </li> |
|
259 | </li> | |
260 |
|
260 | |||
261 | <li> |
|
261 | <li> | |
262 | <a title="${_('Search')}" href="${h.url('search')}"> |
|
262 | <a title="${_('Search')}" href="${h.url('search')}"> | |
263 | <span class="icon"> |
|
263 | <span class="icon"> | |
264 | <img src="/images/icons/search_16.png" alt="${_('Search')}" /> |
|
264 | <img src="/images/icons/search_16.png" alt="${_('Search')}" /> | |
265 | </span> |
|
265 | </span> | |
266 | <span>${_('Search')}</span> |
|
266 | <span>${_('Search')}</span> | |
267 | </a> |
|
267 | </a> | |
268 | </li> |
|
268 | </li> | |
269 |
|
269 | |||
270 | %if h.HasPermissionAll('hg.admin')('access admin main page'): |
|
270 | %if h.HasPermissionAll('hg.admin')('access admin main page'): | |
271 | <li ${is_current('admin')}> |
|
271 | <li ${is_current('admin')}> | |
272 | <a title="${_('Admin')}" href="${h.url('admin_home')}"> |
|
272 | <a title="${_('Admin')}" href="${h.url('admin_home')}"> | |
273 | <span class="icon"> |
|
273 | <span class="icon"> | |
274 | <img src="/images/icons/cog_edit.png" alt="${_('Admin')}" /> |
|
274 | <img src="/images/icons/cog_edit.png" alt="${_('Admin')}" /> | |
275 | </span> |
|
275 | </span> | |
276 | <span>${_('Admin')}</span> |
|
276 | <span>${_('Admin')}</span> | |
277 | </a> |
|
277 | </a> | |
278 | <ul> |
|
278 | <ul> | |
279 | <li>${h.link_to(_('journal'),h.url('admin_home'),class_='journal')}</li> |
|
279 | <li>${h.link_to(_('journal'),h.url('admin_home'),class_='journal')}</li> | |
280 | <li>${h.link_to(_('repositories'),h.url('repos'),class_='repos')}</li> |
|
280 | <li>${h.link_to(_('repositories'),h.url('repos'),class_='repos')}</li> | |
281 | <li>${h.link_to(_('users'),h.url('users'),class_='users')}</li> |
|
281 | <li>${h.link_to(_('users'),h.url('users'),class_='users')}</li> | |
282 | <li>${h.link_to(_('permissions'),h.url('edit_permission',id='default'),class_='permissions')}</li> |
|
282 | <li>${h.link_to(_('permissions'),h.url('edit_permission',id='default'),class_='permissions')}</li> | |
283 | <li class="last">${h.link_to(_('settings'),h.url('admin_settings'),class_='settings')}</li> |
|
283 | <li class="last">${h.link_to(_('settings'),h.url('admin_settings'),class_='settings')}</li> | |
284 | </ul> |
|
284 | </ul> | |
285 | </li> |
|
285 | </li> | |
286 | %endif |
|
286 | %endif | |
287 |
|
287 | |||
288 | </ul> |
|
288 | </ul> | |
289 | %endif |
|
289 | %endif | |
290 | </%def> |
|
290 | </%def> | |
291 |
|
291 | |||
292 |
|
292 | |||
293 | <%def name="css()"> |
|
293 | <%def name="css()"> | |
294 | <link rel="stylesheet" type="text/css" href="/css/style.css" media="screen" /> |
|
294 | <link rel="stylesheet" type="text/css" href="/css/style.css" media="screen" /> | |
295 | <link rel="stylesheet" type="text/css" href="/css/pygments.css" /> |
|
295 | <link rel="stylesheet" type="text/css" href="/css/pygments.css" /> | |
296 | <link rel="stylesheet" type="text/css" href="/css/diff.css" /> |
|
296 | <link rel="stylesheet" type="text/css" href="/css/diff.css" /> | |
297 | </%def> |
|
297 | </%def> | |
298 |
|
298 | |||
299 | <%def name="js()"> |
|
299 | <%def name="js()"> | |
300 | ##<script type="text/javascript" src="/js/yui/utilities/utilities.js"></script> |
|
300 | ##<script type="text/javascript" src="/js/yui/utilities/utilities.js"></script> | |
301 | ##<script type="text/javascript" src="/js/yui/container/container.js"></script> |
|
301 | ##<script type="text/javascript" src="/js/yui/container/container.js"></script> | |
302 | ##<script type="text/javascript" src="/js/yui/datasource/datasource.js"></script> |
|
302 | ##<script type="text/javascript" src="/js/yui/datasource/datasource.js"></script> | |
303 | ##<script type="text/javascript" src="/js/yui/autocomplete/autocomplete.js"></script> |
|
303 | ##<script type="text/javascript" src="/js/yui/autocomplete/autocomplete.js"></script> | |
304 | ##<script type="text/javascript" src="/js/yui/selector/selector-min.js"></script> |
|
304 | ##<script type="text/javascript" src="/js/yui/selector/selector-min.js"></script> | |
305 |
|
305 | |||
306 | <script type="text/javascript" src="/js/yui2a.js"></script> |
|
306 | <script type="text/javascript" src="/js/yui2a.js"></script> | |
307 | <!--[if IE]><script language="javascript" type="text/javascript" src="/js/excanvas.min.js"></script><![endif]--> |
|
307 | <!--[if IE]><script language="javascript" type="text/javascript" src="/js/excanvas.min.js"></script><![endif]--> | |
308 | <script type="text/javascript" src="/js/yui.flot.js"></script> |
|
308 | <script type="text/javascript" src="/js/yui.flot.js"></script> | |
309 |
|
309 | |||
310 | <script type="text/javascript"> |
|
310 | <script type="text/javascript"> | |
311 | var base_url ='/_admin/toggle_following'; |
|
311 | var base_url ='/_admin/toggle_following'; | |
312 | var YUC = YAHOO.util.Connect; |
|
312 | var YUC = YAHOO.util.Connect; | |
313 | var YUD = YAHOO.util.Dom; |
|
313 | var YUD = YAHOO.util.Dom; | |
314 | var YUE = YAHOO.util.Event; |
|
314 | var YUE = YAHOO.util.Event; | |
315 |
|
315 | |||
316 | function onSuccess(){ |
|
316 | function onSuccess(){ | |
317 |
|
317 | |||
318 | var f = YUD.get('follow_toggle'); |
|
318 | var f = YUD.get('follow_toggle'); | |
319 | if(f.getAttribute('class')=='follow'){ |
|
319 | if(f.getAttribute('class')=='follow'){ | |
320 | f.setAttribute('class','following'); |
|
320 | f.setAttribute('class','following'); | |
321 | f.setAttribute('title',"${_('Stop following this repository')}"); |
|
321 | f.setAttribute('title',"${_('Stop following this repository')}"); | |
322 | } |
|
322 | } | |
323 | else{ |
|
323 | else{ | |
324 | f.setAttribute('class','follow'); |
|
324 | f.setAttribute('class','follow'); | |
325 | f.setAttribute('title',"${_('Start following this repository')}"); |
|
325 | f.setAttribute('title',"${_('Start following this repository')}"); | |
326 | } |
|
326 | } | |
327 | } |
|
327 | } | |
328 |
|
328 | |||
329 | function toggleFollowingUser(fallows_user_id,token){ |
|
329 | function toggleFollowingUser(fallows_user_id,token){ | |
330 | args = 'follows_user_id='+fallows_user_id; |
|
330 | args = 'follows_user_id='+fallows_user_id; | |
331 | args+= '&auth_token='+token; |
|
331 | args+= '&auth_token='+token; | |
332 | YUC.asyncRequest('POST',base_url,{ |
|
332 | YUC.asyncRequest('POST',base_url,{ | |
333 | success:function(o){ |
|
333 | success:function(o){ | |
334 | onSuccess(); |
|
334 | onSuccess(); | |
335 | } |
|
335 | } | |
336 | },args); return false; |
|
336 | },args); return false; | |
337 | } |
|
337 | } | |
338 |
|
338 | |||
339 | function toggleFollowingRepo(fallows_repo_id,token){ |
|
339 | function toggleFollowingRepo(fallows_repo_id,token){ | |
340 | args = 'follows_repo_id='+fallows_repo_id; |
|
340 | args = 'follows_repo_id='+fallows_repo_id; | |
341 | args+= '&auth_token='+token; |
|
341 | args+= '&auth_token='+token; | |
342 | YUC.asyncRequest('POST',base_url,{ |
|
342 | YUC.asyncRequest('POST',base_url,{ | |
343 | success:function(o){ |
|
343 | success:function(o){ | |
344 | onSuccess(); |
|
344 | onSuccess(); | |
345 | } |
|
345 | } | |
346 | },args); return false; |
|
346 | },args); return false; | |
347 | } |
|
347 | } | |
348 | </script> |
|
348 | </script> | |
349 |
|
349 | |||
350 | </%def> |
|
350 | </%def> | |
351 |
|
351 | |||
352 | <%def name="breadcrumbs()"> |
|
352 | <%def name="breadcrumbs()"> | |
353 | <div class="breadcrumbs"> |
|
353 | <div class="breadcrumbs"> | |
354 | ${self.breadcrumbs_links()} |
|
354 | ${self.breadcrumbs_links()} | |
355 | </div> |
|
355 | </div> | |
356 | </%def> No newline at end of file |
|
356 | </%def> |
General Comments 0
You need to be logged in to leave comments.
Login now