Download
Getting Started
Members
Projects
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
More
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
Toggle navigation
Bugzilla – Attachment 267948 Details for
Bug 371400
Restore bugzilla link in git commit page.
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read
this important communication.
[patch]
Patch from gerrit
bug371400.patch (text/plain), 4.12 KB, created by
Michael Rennie
on 2017-04-24 12:16:13 EDT
(
hide
)
Description:
Patch from gerrit
Filename:
MIME Type:
Creator:
Michael Rennie
Created:
2017-04-24 12:16:13 EDT
Size:
4.12 KB
patch
obsolete
>From 0969253974b1d76c9a0c4b5461a6f123ede95a5c Mon Sep 17 00:00:00 2001 >From: Troy Tao <troytao@ca.ibm.com> >Date: Tue, 12 Jan 2016 15:07:31 -0500 >Subject: [PATCH] Bug 371400 - Restore bugzilla link in git commit page. > >Add bugzilla link to git commit message. > >Change-Id: I464c8e0efd5d8ed35d02683de4ca13cd58a732ff >Signed-off-by: Troy Tao <troytao@ca.ibm.com> >--- > >diff --git a/bundles/org.eclipse.orion.client.git/web/orion/git/widgets/gitCommitInfo.js b/bundles/org.eclipse.orion.client.git/web/orion/git/widgets/gitCommitInfo.js >index c3fd73b..fcc9b52 100644 >--- a/bundles/org.eclipse.orion.client.git/web/orion/git/widgets/gitCommitInfo.js >+++ b/bundles/org.eclipse.orion.client.git/web/orion/git/widgets/gitCommitInfo.js >@@ -102,11 +102,18 @@ > var detailsDiv = document.createElement("td"); //$NON-NLS-0$ > detailsDiv.className = "gitCommitDetailsCell"; //$NON-NLS-0$ > row.appendChild(detailsDiv); >- >+ > var headerMessage = util.trimCommitMessage(commit.Message); >+ var headerMessageSplit = headerMessage.split(" "); >+ var bugID ="null"; >+ if(headerMessageSplit[0] === "Bug"){ >+ bugID = headerMessageSplit[1]; >+ } >+ > var displayMessage = this.showMessage === undefined || this.showMessage; > if (displayMessage) { > var link; >+ > if (this.commitLink) { > link = document.createElement("a"); //$NON-NLS-0$ > link.className = "navlinkonpage"; //$NON-NLS-0$ >@@ -122,18 +129,34 @@ > if (headerMessage.length < commit.Message.length) { > text += "..."; //$NON-NLS-0$ > } >+ > link.appendChild(document.createTextNode(text)); >- detailsDiv.appendChild(link); >+ if(bugID !== "null"){ >+ //This leads to a conflict when commitLink is true and bugID is not "null": >+ //it will ignore the commitLink and just add the bugzilla link. >+ //(I also don't know which one we should display in this case) >+ this.registry.getService("orion.core.textlink").addLinks(text, detailsDiv); >+ } else { >+ detailsDiv.appendChild(link); >+ } > } > if (this.fullMessage && (this.onlyFullMessage || headerMessage.length < commit.Message.length)) { > var fullMessage = document.createElement("div"); //$NON-NLS-0$ > fullMessage.className = "gitCommitFullMessage"; //$NON-NLS-0$ > if (this.simple) { >- fullMessage.textContent = commit.Message; >+ if(bugID !== "null"){ >+ this.registry.getService("orion.core.textlink").addLinks(commit.Message, fullMessage); >+ } else { >+ fullMessage.textContent = commit.Message; >+ } > } else { > var headerSpan = document.createElement("span"); //$NON-NLS-0$ > headerSpan.className = "gitCommitTitle"; //$NON-NLS-0$ >- headerSpan.textContent = headerMessage; >+ if(bugID !== "null"){ >+ this.registry.getService("orion.core.textlink").addLinks(headerMessage, headerSpan); >+ } else { >+ headerSpan.textContent = headerMessage; >+ } > fullMessage.appendChild(headerSpan); > var restSpan = document.createElement("span"); //$NON-NLS-0$ > restSpan.textContent = commit.Message.substring(headerMessage.length); >@@ -144,6 +167,7 @@ > } > detailsDiv.appendChild(fullMessage); > } >+ > > var displayAuthor = this.showAuthor === undefined || this.showAuthor; > var displayCommitter = this.showCommitter === undefined || this.showCommitter; >diff --git a/bundles/org.eclipse.orion.client.git/web/orion/git/widgets/gitCommitList.js b/bundles/org.eclipse.orion.client.git/web/orion/git/widgets/gitCommitList.js >index 81a015b..95ed9e3 100644 >--- a/bundles/org.eclipse.orion.client.git/web/orion/git/widgets/gitCommitList.js >+++ b/bundles/org.eclipse.orion.client.git/web/orion/git/widgets/gitCommitList.js >@@ -1140,6 +1140,7 @@ > showAuthor: false, > showParentLink: false > }); >+ info.registry = this.explorer.registry; > info.display(); > horizontalBox.appendChild(commitDetails); > >@@ -1270,6 +1271,7 @@ > showMore: true, > simple: simple > }); >+ commitInfo.registry = this.explorer.registry; > commitInfo.display(); > > commitInfo.moreButton.addEventListener("click", function() { //$NON-NLS-0$
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 371400
:
211101
| 267948