<%inherit file="/base/base.html"/> <%def name="title()"> ${_('%s Pull Request #%s') % (c.repo_name, c.pull_request.pull_request_id)} %if c.rhodecode_name: · ${h.branding(c.rhodecode_name)} %endif <%def name="breadcrumbs_links()"> ${c.pull_request.title} %if c.pull_request.is_closed(): (${_('Closed')}) %endif <%def name="menu_bar_nav()"> ${self.menu_items(active='repositories')} <%def name="menu_bar_subnav()"> ${self.repo_menu(active='showpullrequest')} <%def name="main()">
${self.repo_page_title(c.rhodecode_db_repo)}
${self.breadcrumbs()}
<%summary = lambda n:{False:'summary-short'}.get(n)%>
${_('Pull request #%s') % c.pull_request.pull_request_id} ${_('From')} ${h.format_date(c.pull_request.created_on)} %if c.allowed_to_update:
% if c.allowed_to_delete: ${h.secure_form(url('pullrequest_delete', repo_name=c.pull_request.target_repo.repo_name, pull_request_id=c.pull_request.pull_request_id),method='delete')} ${h.submit('remove_%s' % c.pull_request.pull_request_id, _('Delete'), class_="btn btn-link btn-danger",onclick="return confirm('"+_('Confirm to delete this pull request')+"');")} ${h.end_form()} % else: ${_('Delete')} % endif
${_('Edit')}
%endif
## branch link is only valid if it is a branch %if c.pull_request.source_ref_parts.type == 'branch': ${c.pull_request.source_ref_parts.type}: ${c.pull_request.source_ref_parts.name} %else: ${c.pull_request.source_ref_parts.type}: ${c.pull_request.source_ref_parts.name} %endif ${c.pull_request.source_repo.clone_url()}
%if h.is_hg(c.pull_request.source_repo): %elif h.is_git(c.pull_request.source_repo): %endif
## branch link is only valid if it is a branch %if c.pull_request.target_ref_parts.type == 'branch': ${c.pull_request.target_ref_parts.type}: ${c.pull_request.target_ref_parts.name} %else: ${c.pull_request.target_ref_parts.type}: ${c.pull_request.target_ref_parts.name} %endif ${c.pull_request.target_repo.clone_url()}
## Link to the shadow repository. %if not c.pull_request.is_closed() and c.pull_request.shadow_merge_ref:
%if h.is_hg(c.pull_request.target_repo): %elif h.is_git(c.pull_request.target_repo): %endif
%endif
%if c.pull_request_review_status:
%if c.pull_request.is_closed(): ${_('Closed')}, %endif ${h.commit_status_lbl(c.pull_request_review_status)} - ${ungettext('calculated based on %s reviewer vote', 'calculated based on %s reviewers votes', len(c.pull_request_reviewers)) % len(c.pull_request_reviewers)} %endif
${h.urlify_commit_message(c.pull_request.description, c.repo_name)}
%if c.comments: ${ungettext("%d Pull request comment", "%d Pull request comments", len(c.comments)) % len(c.comments)}, %else: ${ungettext("%d Pull request comment", "%d Pull request comments", len(c.comments)) % len(c.comments)} %endif %if c.inline_cnt: ## this is replaced with a proper link to first comment via JS linkifyComments() func ${ungettext("%d Inline Comment", "%d Inline Comments", c.inline_cnt) % c.inline_cnt} %else: ${ungettext("%d Inline Comment", "%d Inline Comments", c.inline_cnt) % c.inline_cnt} %endif % if c.outdated_cnt: ,${ungettext("%d Outdated Comment", "%d Outdated Comments", c.outdated_cnt) % c.outdated_cnt} ${_('(Show)')} % endif
## AUTHOR
${_('Author')}
  • ${self.gravatar_with_user(c.pull_request.author.email, 16)}
## REVIEWERS
${_('Pull request reviewers')} %if c.allowed_to_update: ${_('Edit')} %endif
## members goes here !
    %for member,reasons,status in c.pull_request_reviewers:
  • ${self.gravatar_with_user(member.email, 16)}
    %for reason in reasons:
    - ${reason}
    %endfor %if c.allowed_to_update: %endif
  • %endfor
%if not c.pull_request.is_closed(): %endif
##DIFF
##CS % if c.missing_requirements:
${_('Missing requirements:')} ${_('These commits cannot be displayed, because this repository uses the Mercurial largefiles extension, which was not enabled.')}
% elif c.missing_commits:
${_('Missing commits')}: ${_('This pull request cannot be displayed, because one or more commits no longer exist in the source repository.')} ${_('Please update this pull request, push the commits back into the source repository, or consider closing this pull request.')}
% endif
% if c.allowed_to_update and not c.pull_request.is_closed(): % endif % if len(c.commit_ranges):

${ungettext('Compare View: %s commit','Compare View: %s commits', len(c.commit_ranges)) % len(c.commit_ranges)}

% endif
% if not c.missing_commits: <%include file="/compare/compare_commits.html" />
<%namespace name="cbdiffs" file="/codeblocks/diffs.html"/> ${cbdiffs.render_diffset_menu()} ${cbdiffs.render_diffset( c.diffset, use_comments=True, collapse_when_files_over=30, disable_new_comments=c.pull_request.is_closed())}
% endif
## template for inline comment form <%namespace name="comment" file="/changeset/changeset_file_comment.html"/> ${comment.comment_inline_form()} ## render comments and inlines ${comment.generate_comments(include_pull_request=True, is_pull_request=True)} % if not c.pull_request.is_closed(): ## main comment form and it status ${comment.comments(h.url('pullrequest_comment', repo_name=c.repo_name, pull_request_id=c.pull_request.pull_request_id), c.pull_request_review_status, is_pull_request=True, change_status=c.allowed_to_change_status)} %endif