Show More
@@ -930,6 +930,25 b' class Repository(Base, BaseModel):' | |||||
930 | def last_db_change(self): |
|
930 | def last_db_change(self): | |
931 | return self.updated_on |
|
931 | return self.updated_on | |
932 |
|
932 | |||
|
933 | def clone_url(self, **override): | |||
|
934 | from pylons import url | |||
|
935 | from urlparse import urlparse | |||
|
936 | import urllib | |||
|
937 | parsed_url = urlparse(url('home', qualified=True)) | |||
|
938 | default_clone_uri = '%(scheme)s://%(user)s%(pass)s%(netloc)s%(prefix)s%(path)s' | |||
|
939 | decoded_path = safe_unicode(urllib.unquote(parsed_url.path)) | |||
|
940 | args = { | |||
|
941 | 'user': '', | |||
|
942 | 'pass': '', | |||
|
943 | 'scheme': parsed_url.scheme, | |||
|
944 | 'netloc': parsed_url.netloc, | |||
|
945 | 'prefix': decoded_path, | |||
|
946 | 'path': self.repo_name | |||
|
947 | } | |||
|
948 | ||||
|
949 | args.update(override) | |||
|
950 | return default_clone_uri % args | |||
|
951 | ||||
933 | #========================================================================== |
|
952 | #========================================================================== | |
934 | # SCM PROPERTIES |
|
953 | # SCM PROPERTIES | |
935 | #========================================================================== |
|
954 | #========================================================================== | |
@@ -1794,6 +1813,14 b' class PullRequest(Base, BaseModel):' | |||||
1794 | def revisions(self, val): |
|
1813 | def revisions(self, val): | |
1795 | self._revisions = ':'.join(val) |
|
1814 | self._revisions = ':'.join(val) | |
1796 |
|
1815 | |||
|
1816 | @property | |||
|
1817 | def org_ref_parts(self): | |||
|
1818 | return self.org_ref.split(':') | |||
|
1819 | ||||
|
1820 | @property | |||
|
1821 | def other_ref_parts(self): | |||
|
1822 | return self.other_ref.split(':') | |||
|
1823 | ||||
1797 | author = relationship('User', lazy='joined') |
|
1824 | author = relationship('User', lazy='joined') | |
1798 | reviewers = relationship('PullRequestReviewers', |
|
1825 | reviewers = relationship('PullRequestReviewers', | |
1799 | cascade="all, delete, delete-orphan") |
|
1826 | cascade="all, delete, delete-orphan") |
@@ -2778,7 +2778,9 b' h3.files_location {' | |||||
2778 | margin: 0px 2px; |
|
2778 | margin: 0px 2px; | |
2779 | } |
|
2779 | } | |
2780 |
|
2780 | |||
2781 |
.right .logtags .branchtag, |
|
2781 | .right .logtags .branchtag, | |
|
2782 | .logtags .branchtag, | |||
|
2783 | .spantag { | |||
2782 | padding: 1px 3px 1px 3px; |
|
2784 | padding: 1px 3px 1px 3px; | |
2783 | background-color: #bfbfbf; |
|
2785 | background-color: #bfbfbf; | |
2784 | font-size: 10px; |
|
2786 | font-size: 10px; |
@@ -51,6 +51,24 b'' | |||||
51 | %endif |
|
51 | %endif | |
52 | </div> |
|
52 | </div> | |
53 | </div> |
|
53 | </div> | |
|
54 | <div class="field"> | |||
|
55 | <div class="label-summary"> | |||
|
56 | <label>${_('Origin repository')}:</label> | |||
|
57 | </div> | |||
|
58 | <div class="input"> | |||
|
59 | <div> | |||
|
60 | ##%if h.is_hg(c.pull_request.org_repo): | |||
|
61 | ## <img class="icon" title="${_('Mercurial repository')}" alt="${_('Mercurial repository')}" src="${h.url('/images/icons/hgicon.png')}"/> | |||
|
62 | ##%elif h.is_git(c.pull_request.org_repo): | |||
|
63 | ## <img class="icon" title="${_('Git repository')}" alt="${_('Git repository')}" src="${h.url('/images/icons/giticon.png')}"/> | |||
|
64 | ##%endif | |||
|
65 | <span class="spantag">${c.pull_request.org_ref_parts[0]}</span> | |||
|
66 | : | |||
|
67 | <span class="spantag">${c.pull_request.org_ref_parts[1]}</span> | |||
|
68 | <span>${c.pull_request.org_repo.clone_url()}</span> | |||
|
69 | </div> | |||
|
70 | </div> | |||
|
71 | </div> | |||
54 | </div> |
|
72 | </div> | |
55 | </div> |
|
73 | </div> | |
56 | <div style="white-space:pre-wrap;padding:3px 3px 5px 20px">${h.literal(c.pull_request.description)}</div> |
|
74 | <div style="white-space:pre-wrap;padding:3px 3px 5px 20px">${h.literal(c.pull_request.description)}</div> |
General Comments 0
You need to be logged in to leave comments.
Login now