Mercurial > kallithea
comparison rhodecode/templates/pullrequests/pullrequest_show.html @ 4116:ffd45b185016 rhodecode-2.2.5-gpl
Imported some of the GPLv3'd changes from RhodeCode v2.2.5.
This imports changes between changesets 21af6c4eab3d and 6177597791c2 in
RhodeCode's original repository, including only changes to Python files and HTML.
RhodeCode clearly licensed its changes to these files under GPLv3
in their /LICENSE file, which states the following:
The Python code and integrated HTML are licensed under the GPLv3 license.
(See:
https://code.rhodecode.com/rhodecode/files/v2.2.5/LICENSE
or
http://web.archive.org/web/20140512193334/https://code.rhodecode.com/rhodecode/files/f3b123159901f15426d18e3dc395e8369f70ebe0/LICENSE
for an online copy of that LICENSE file)
Conservancy reviewed these changes and confirmed that they can be licensed as
a whole to the Kallithea project under GPLv3-only.
While some of the contents committed herein are clearly licensed
GPLv3-or-later, on the whole we must assume the are GPLv3-only, since the
statement above from RhodeCode indicates that they intend GPLv3-only as their
license, per GPLv3ยง14 and other relevant sections of GPLv3.
author | Bradley M. Kuhn <bkuhn@sfconservancy.org> |
---|---|
date | Wed, 02 Jul 2014 19:03:13 -0400 |
parents | 6eaee7e2829e |
children | 932d589a89c4 |
comparison
equal
deleted
inserted
replaced
4115:8b7294a804a0 | 4116:ffd45b185016 |
---|---|
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 Request #%s') % (c.repo_name, c.pull_request.pull_request_id)} · ${c.rhodecode_name} | 4 ${_('%s Pull Request #%s') % (c.repo_name, c.pull_request.pull_request_id)} |
5 %if c.rhodecode_name: | |
6 · ${c.rhodecode_name} | |
7 %endif | |
5 </%def> | 8 </%def> |
6 | 9 |
7 <%def name="breadcrumbs_links()"> | 10 <%def name="breadcrumbs_links()"> |
8 ${_('Pull request #%s') % c.pull_request.pull_request_id} | 11 ${_('Pull request #%s') % c.pull_request.pull_request_id} |
9 </%def> | 12 </%def> |
18 <!-- box / title --> | 21 <!-- box / title --> |
19 <div class="title"> | 22 <div class="title"> |
20 ${self.breadcrumbs()} | 23 ${self.breadcrumbs()} |
21 </div> | 24 </div> |
22 | 25 |
23 <div class="pr-details-title ${'closed' if c.pull_request.is_closed() else ''}"> | 26 <div class="form" style="float: left"> |
24 ${_('Title')}: ${c.pull_request.title} | 27 <div class="pr-details-title ${'closed' if c.pull_request.is_closed() else ''}"> |
25 %if c.pull_request.is_closed(): | 28 ${_('Title')}: ${c.pull_request.title} |
26 (${_('Closed')}) | 29 %if c.pull_request.is_closed(): |
27 %endif | 30 (${_('Closed')}) |
28 </div> | 31 %endif |
29 | 32 </div> |
30 <div class="form"> | |
31 <div id="summary" class="fields"> | 33 <div id="summary" class="fields"> |
32 <div class="field"> | 34 <div class="field"> |
33 <div class="label-summary"> | 35 <div class="label-summary"> |
34 <label>${_('Review status')}:</label> | 36 <label>${_('Review status')}:</label> |
35 </div> | 37 </div> |
36 <div class="input"> | 38 <div class="input"> |
37 <div class="changeset-status-container" style="float:none;clear:both"> | 39 <div class="changeset-status-container" style="float:none;clear:both"> |
38 %if c.current_changeset_status: | 40 %if c.current_changeset_status: |
39 <div class="changeset-status-ico" style="padding:0px 4px 0px 0px"><img src="${h.url('/images/icons/flag_status_%s.png' % c.current_changeset_status)}" title="${_('Pull request status calculated from votes')}"/></div> | 41 <div class="changeset-status-ico" style="padding:0px 4px 0px 0px"> |
42 <img src="${h.url('/images/icons/flag_status_%s.png' % c.current_changeset_status)}" title="${_('Pull request status calculated from votes')}"/></div> | |
40 <div class="changeset-status-lbl tooltip" title="${_('Pull request status calculated from votes')}"> | 43 <div class="changeset-status-lbl tooltip" title="${_('Pull request status calculated from votes')}"> |
41 %if c.pull_request.is_closed(): | 44 %if c.pull_request.is_closed(): |
42 ${_('Closed')}, | 45 ${_('Closed')}, |
43 %endif | 46 %endif |
44 ${h.changeset_status_lbl(c.current_changeset_status)} | 47 ${h.changeset_status_lbl(c.current_changeset_status)} |
64 <div class="label-summary"> | 67 <div class="label-summary"> |
65 <label>${_('Origin repository')}:</label> | 68 <label>${_('Origin repository')}:</label> |
66 </div> | 69 </div> |
67 <div class="input"> | 70 <div class="input"> |
68 <div> | 71 <div> |
69 ##%if h.is_hg(c.pull_request.org_repo): | |
70 ## <img class="icon" title="${_('Mercurial repository')}" alt="${_('Mercurial repository')}" src="${h.url('/images/icons/hgicon.png')}"/> | |
71 ##%elif h.is_git(c.pull_request.org_repo): | |
72 ## <img class="icon" title="${_('Git repository')}" alt="${_('Git repository')}" src="${h.url('/images/icons/giticon.png')}"/> | |
73 ##%endif | |
74 | 72 |
75 ## branch link is only valid if it is a branch | 73 ## branch link is only valid if it is a branch |
76 <span class="spantag"><a href="${h.url('summary_home', repo_name=c.pull_request.org_repo.repo_name, anchor=c.pull_request.org_ref_parts[1])}">${c.pull_request.org_ref_parts[0]}: ${c.pull_request.org_ref_parts[1]}</a></span> | 74 <span class="spantag"><a href="${h.url('summary_home', repo_name=c.pull_request.org_repo.repo_name, anchor=c.pull_request.org_ref_parts[1])}">${c.pull_request.org_ref_parts[0]}: ${c.pull_request.org_ref_parts[1]}</a></span> |
77 <span> | 75 <span> |
78 %if h.is_hg(c.pull_request.org_repo): | 76 %if h.is_hg(c.pull_request.org_repo): |
79 | ${_('Pull changes')} <span style="font-family: monospace">hg pull -r ${h.short_id(c.cs_ranges[-1].raw_id)} <a href="${h.url('summary_home', repo_name=c.pull_request.org_repo.repo_name)}">${c.pull_request.org_repo.clone_url()}</a></span> | 77 | ${_('Pull changes')} <span style="font-family: monospace">hg pull -r ${h.short_id(c.cs_ranges[-1].raw_id)} <a href="${h.url('summary_home', repo_name=c.pull_request.org_repo.repo_name)}">${c.pull_request.org_repo.clone_url()}</a></span> |
80 %elif h.is_git(c.pull_request.org_repo): | 78 %elif h.is_git(c.pull_request.org_repo): |
81 | ${_('Pull changes')} | 79 | ${_('Pull changes')} <span style="font-family: monospace">git pull <a href="${h.url('summary_home', repo_name=c.pull_request.org_repo.repo_name)}">${c.pull_request.org_repo.clone_url()}</a> ${c.pull_request.org_ref_parts[1]} </span> |
82 %endif | 80 %endif |
83 </div> | 81 </div> |
84 </div> | 82 </div> |
85 </div> | 83 </div> |
86 <div class="field"> | 84 <div class="field"> |
87 <div class="label-summary"> | 85 <div class="label-summary"> |
88 <label>${_('Description')}:</label> | 86 <label>${_('Description')}:</label> |
89 </div> | 87 </div> |
90 <div class="input"> | 88 <div class="input"> |
91 <div style="white-space:pre-wrap">${h.urlify_commit(c.pull_request.description)}</div> | 89 <div style="white-space:pre-wrap">${h.urlify_commit(c.pull_request.description, c.repo_name)}</div> |
92 </div> | 90 </div> |
93 </div> | 91 </div> |
94 <div class="field"> | 92 <div class="field"> |
95 <div class="label-summary"> | 93 <div class="label-summary"> |
96 <label>${_('Created on')}:</label> | 94 <label>${_('Created on')}:</label> |
99 <div>${h.fmt_date(c.pull_request.created_on)}</div> | 97 <div>${h.fmt_date(c.pull_request.created_on)}</div> |
100 </div> | 98 </div> |
101 </div> | 99 </div> |
102 </div> | 100 </div> |
103 </div> | 101 </div> |
104 | 102 ## REVIEWERS |
105 <div style="overflow: auto;"> | 103 <div style="float:left; border-left:1px dashed #eee"> |
104 <div class="pr-details-title">${_('Pull request reviewers')}</div> | |
105 <div id="reviewers" style="padding:0px 0px 5px 10px"> | |
106 ## members goes here ! | |
107 <div style="min-height:30px"> | |
108 <ul id="review_members" class="group_members"> | |
109 %for member,status in c.pull_request_reviewers: | |
110 <li id="reviewer_${member.user_id}"> | |
111 <div class="reviewers_member"> | |
112 <div class="reviewer_status tooltip" title="${h.tooltip(h.changeset_status_lbl(status[0][1].status if status else 'not_reviewed'))}"> | |
113 <img src="${h.url(str('/images/icons/flag_status_%s.png' % (status[0][1].status if status else 'not_reviewed')))}"/> | |
114 </div> | |
115 <div class="reviewer_gravatar gravatar"><img alt="gravatar" src="${h.gravatar_url(member.email,14)}"/> </div> | |
116 <div style="float:left;">${member.full_name} (${_('owner') if c.pull_request.user_id == member.user_id else _('reviewer')})</div> | |
117 <input type="hidden" value="${member.user_id}" name="review_members" /> | |
118 %if not c.pull_request.is_closed() and (h.HasPermissionAny('hg.admin')() or h.HasRepoPermissionAny('repository.admin')(c.repo_name) or c.pull_request.user_id == c.rhodecode_user.user_id): | |
119 <div class="reviewer_member_remove action_button" onclick="removeReviewMember(${member.user_id})"> | |
120 <i class="icon-remove-sign" style="color: #FF4444;"></i> | |
121 </div> | |
122 %endif | |
123 </div> | |
124 </li> | |
125 %endfor | |
126 </ul> | |
127 </div> | |
128 %if not c.pull_request.is_closed(): | |
129 <div class='ac'> | |
130 %if h.HasPermissionAny('hg.admin')() or h.HasRepoPermissionAny('repository.admin')(c.repo_name) or c.pull_request.author.user_id == c.rhodecode_user.user_id: | |
131 <div class="reviewer_ac"> | |
132 ${h.text('user', class_='yui-ac-input')} | |
133 <span class="help-block">${_('Add or remove reviewer to this pull request.')}</span> | |
134 <div id="reviewers_container"></div> | |
135 </div> | |
136 <div style="padding:0px 10px"> | |
137 <span id="update_pull_request" class="btn btn-mini">${_('Save Changes')}</span> | |
138 </div> | |
139 %endif | |
140 </div> | |
141 %endif | |
142 </div> | |
143 </div> | |
144 | |
145 <div style="overflow: auto; clear: both"> | |
106 ##DIFF | 146 ##DIFF |
107 <div class="table" style="float:left;clear:none"> | 147 <div class="table" style="float:left;clear:none"> |
108 <div id="body" class="diffblock"> | 148 <div id="body" class="diffblock"> |
109 <div style="white-space:pre-wrap;padding:5px">${_('Compare view')}</div> | 149 <div style="white-space:pre-wrap;padding:5px">${_('Compare view')}</div> |
110 </div> | 150 </div> |
137 % if c.limited_diff: | 177 % if c.limited_diff: |
138 <h5>${_('Changeset was too big and was cut off...')} <a href="${h.url.current(fulldiff=1, **request.GET.mixed())}" onclick="return confirm('${_("Showing a huge diff might take some time and resources")}')">${_('Show full diff')}</a></h5> | 178 <h5>${_('Changeset was too big and was cut off...')} <a href="${h.url.current(fulldiff=1, **request.GET.mixed())}" onclick="return confirm('${_("Showing a huge diff might take some time and resources")}')">${_('Show full diff')}</a></h5> |
139 % endif | 179 % endif |
140 </div> | 180 </div> |
141 </div> | 181 </div> |
142 ## REVIEWERS | |
143 <div style="float:left; border-left:1px dashed #eee"> | |
144 <h4>${_('Pull request reviewers')}</h4> | |
145 <div id="reviewers" style="padding:0px 0px 5px 10px"> | |
146 ## members goes here ! | |
147 <div class="group_members_wrap" style="min-height:45px"> | |
148 <ul id="review_members" class="group_members"> | |
149 %for member,status in c.pull_request_reviewers: | |
150 <li id="reviewer_${member.user_id}"> | |
151 <div class="reviewers_member"> | |
152 <div style="float:left;padding:0px 3px 0px 0px" class="tooltip" title="${h.tooltip(h.changeset_status_lbl(status[0][1].status if status else 'not_reviewed'))}"> | |
153 <img src="${h.url(str('/images/icons/flag_status_%s.png' % (status[0][1].status if status else 'not_reviewed')))}"/> | |
154 </div> | |
155 <div class="gravatar"><img alt="gravatar" src="${h.gravatar_url(member.email,14)}"/> </div> | |
156 <div style="float:left">${member.full_name} (${_('owner') if c.pull_request.user_id == member.user_id else _('reviewer')})</div> | |
157 <input type="hidden" value="${member.user_id}" name="review_members" /> | |
158 %if not c.pull_request.is_closed() and (h.HasPermissionAny('hg.admin', 'repository.admin')() or c.pull_request.user_id == c.rhodecode_user.user_id): | |
159 <span class="delete_icon action_button" onclick="removeReviewMember(${member.user_id})"></span> | |
160 %endif | |
161 </div> | |
162 </li> | |
163 %endfor | |
164 </ul> | |
165 </div> | |
166 %if not c.pull_request.is_closed(): | |
167 <div class='ac'> | |
168 %if h.HasPermissionAny('hg.admin', 'repository.admin')() or c.pull_request.author.user_id == c.rhodecode_user.user_id: | |
169 <div class="reviewer_ac"> | |
170 ${h.text('user', class_='yui-ac-input')} | |
171 <span class="help-block">${_('Add or remove reviewer to this pull request.')}</span> | |
172 <div id="reviewers_container"></div> | |
173 </div> | |
174 <div style="padding:0px 10px"> | |
175 <span id="update_pull_request" class="ui-btn xsmall">${_('Save changes')}</span> | |
176 </div> | |
177 %endif | |
178 </div> | |
179 %endif | |
180 </div> | |
181 </div> | |
182 </div> | 182 </div> |
183 <script> | 183 <script> |
184 var _USERS_AC_DATA = ${c.users_array|n}; | 184 var _USERS_AC_DATA = ${c.users_array|n}; |
185 var _GROUPS_AC_DATA = ${c.users_groups_array|n}; | 185 var _GROUPS_AC_DATA = ${c.user_groups_array|n}; |
186 // TODO: switch this to pyroutes | 186 // TODO: switch this to pyroutes |
187 AJAX_COMMENT_URL = "${url('pullrequest_comment',repo_name=c.repo_name,pull_request_id=c.pull_request.pull_request_id)}"; | 187 AJAX_COMMENT_URL = "${url('pullrequest_comment',repo_name=c.repo_name,pull_request_id=c.pull_request.pull_request_id)}"; |
188 AJAX_COMMENT_DELETE_URL = "${url('pullrequest_comment_delete',repo_name=c.repo_name,comment_id='__COMMENT_ID__')}"; | 188 AJAX_COMMENT_DELETE_URL = "${url('pullrequest_comment_delete',repo_name=c.repo_name,comment_id='__COMMENT_ID__')}"; |
189 | 189 |
190 pyroutes.register('pullrequest_comment', "${url('pullrequest_comment',repo_name='%(repo_name)s',pull_request_id='%(pull_request_id)s')}", ['repo_name', 'pull_request_id']); | 190 pyroutes.register('pullrequest_comment', "${url('pullrequest_comment',repo_name='%(repo_name)s',pull_request_id='%(pull_request_id)s')}", ['repo_name', 'pull_request_id']); |