##// END OF EJS Templates
Move create pull request button in pull requests view into the top...
marcink -
r4081:089fb21d default
parent child Browse files
Show More
@@ -1,55 +1,60 b''
1 <%inherit file="/base/base.html"/>
1 <%inherit file="/base/base.html"/>
2
2
3 <%def name="title()">
3 <%def name="title()">
4 ${_('%s Pull Requests') % c.repo_name} &middot; ${c.rhodecode_name}
4 ${_('%s Pull Requests') % c.repo_name} &middot; ${c.rhodecode_name}
5 </%def>
5 </%def>
6
6
7 <%def name="breadcrumbs_links()">
7 <%def name="breadcrumbs_links()">
8 %if c.from_:
8 %if c.from_:
9 ${_('Pull requests from %s') % c.repo_name}
9 ${_('Pull requests from %s') % c.repo_name}
10 %else:
10 %else:
11 ${_('Pull requests to %s') % c.repo_name}
11 ${_('Pull requests to %s') % c.repo_name}
12 %endif
12 %endif
13 </%def>
13 </%def>
14
14
15 <%def name="page_nav()">
15 <%def name="page_nav()">
16 ${self.menu('repositories')}
16 ${self.menu('repositories')}
17 </%def>
17 </%def>
18
18
19 <%def name="main()">
19 <%def name="main()">
20 ${self.repo_context_bar('showpullrequest')}
20 ${self.repo_context_bar('showpullrequest')}
21
21
22 <div class="box">
22 <div class="box">
23 <!-- box / title -->
23 <!-- box / title -->
24 <div class="title">
24 <div class="title">
25 ${self.breadcrumbs()}
25 ${self.breadcrumbs()}
26 %if c.rhodecode_user.username != 'default':
27 <ul class="links">
28 %if h.HasPermissionAny('hg.admin','hg.create.repository')() or h.HasReposGroupPermissionAny('group.write', 'group.admin')(c.group.group_name if c.group else None):
29 <li>
30 <span>
31 <a id="open_new_pr" href="${h.url('pullrequest_home',repo_name=c.repo_name)}">${_('Open new pull request')}</a>
32 </span>
33 </li>
34 %endif
35 </ul>
36 %endif
26 </div>
37 </div>
27
38
28 <div style="margin: 0 20px">
39 <div style="margin: 0 20px">
29 <div>
40 <div>
30 %if c.from_:
41 %if c.from_:
31 ${h.link_to(_('Instead, show pull requests to %s') % c.repo_name, h.url('pullrequest_show_all',repo_name=c.repo_name,closed=c.closed))}
42 ${h.link_to(_('Instead, show pull requests to %s') % c.repo_name, h.url('pullrequest_show_all',repo_name=c.repo_name,closed=c.closed))}
32 %else:
43 %else:
33 ${h.link_to(_('Instead, show pull requests from %s') % c.repo_name, h.url('pullrequest_show_all',repo_name=c.repo_name,closed=c.closed,from_=1))}
44 ${h.link_to(_('Instead, show pull requests from %s') % c.repo_name, h.url('pullrequest_show_all',repo_name=c.repo_name,closed=c.closed,from_=1))}
34 %endif
45 %endif
35 </div>
46 </div>
36
47
37 <div>
48 <div>
38 %if c.closed:
49 %if c.closed:
39 ${h.link_to(_('Hide closed pull requests'), h.url('pullrequest_show_all',repo_name=c.repo_name,from_=c.from_))}
50 ${h.link_to(_('Hide closed pull requests'), h.url('pullrequest_show_all',repo_name=c.repo_name,from_=c.from_))}
40 %else:
51 %else:
41 ${h.link_to(_('Show closed pull requests too'), h.url('pullrequest_show_all',repo_name=c.repo_name,from_=c.from_,closed=1))}
52 ${h.link_to(_('Show closed pull requests too'), h.url('pullrequest_show_all',repo_name=c.repo_name,from_=c.from_,closed=1))}
42 %endif
53 %endif
43 </div>
54 </div>
44
45 <div>
46 <a id="open_new_pr" href="${h.url('pullrequest_home',repo_name=c.repo_name)}">${_('Open new pull request')}</a>
47 </div>
48
49 </div>
55 </div>
50
56
51 ${c.pullrequest_data}
57 ${c.pullrequest_data}
52
58
53 </div>
59 </div>
54
55 </%def>
60 </%def>
General Comments 0
You need to be logged in to leave comments. Login now