mirror of
https://github.com/gitbucket/gitbucket.git
synced 2025-11-02 19:45:57 +01:00
(refs #2)Fix requested repository url in the merge guidance.
This commit is contained in:
@@ -46,17 +46,14 @@ trait PullRequestsControllerBase extends ControllerBase {
|
|||||||
val issueId = params("id").toInt
|
val issueId = params("id").toInt
|
||||||
|
|
||||||
getPullRequest(owner, name, issueId) map { case(issue, pullreq) =>
|
getPullRequest(owner, name, issueId) map { case(issue, pullreq) =>
|
||||||
|
|
||||||
println(pullreq.mergeStartId)
|
|
||||||
println(pullreq.mergeEndId)
|
|
||||||
|
|
||||||
pulls.html.pullreq(
|
pulls.html.pullreq(
|
||||||
issue, pullreq,
|
issue, pullreq,
|
||||||
getComments(owner, name, issueId.toInt),
|
getComments(owner, name, issueId.toInt),
|
||||||
(getCollaborators(owner, name) :+ owner).sorted,
|
(getCollaborators(owner, name) :+ owner).sorted,
|
||||||
getMilestones(owner, name),
|
getMilestones(owner, name),
|
||||||
hasWritePermission(owner, name, context.loginAccount),
|
hasWritePermission(owner, name, context.loginAccount),
|
||||||
repository)
|
repository,
|
||||||
|
s"${baseUrl}${context.path}/git/${pullreq.requestUserName}/${pullreq.requestRepositoryName}.git")
|
||||||
} getOrElse NotFound
|
} getOrElse NotFound
|
||||||
})
|
})
|
||||||
|
|
||||||
|
|||||||
@@ -4,7 +4,8 @@
|
|||||||
collaborators: List[String],
|
collaborators: List[String],
|
||||||
milestones: List[model.Milestone],
|
milestones: List[model.Milestone],
|
||||||
hasWritePermission: Boolean,
|
hasWritePermission: Boolean,
|
||||||
repository: service.RepositoryService.RepositoryInfo)(implicit context: app.Context)
|
repository: service.RepositoryService.RepositoryInfo,
|
||||||
|
requestRepositoryUrl: String)(implicit context: app.Context)
|
||||||
@import context._
|
@import context._
|
||||||
@import view.helpers._
|
@import view.helpers._
|
||||||
@html.main("%s - Issue #%d - %s/%s".format(issue.title, issue.issueId, repository.owner, repository.name)){
|
@html.main("%s - Issue #%d - %s/%s".format(issue.title, issue.issueId, repository.owner, repository.name)){
|
||||||
@@ -120,7 +121,7 @@
|
|||||||
</p>
|
</p>
|
||||||
<div class="input-prepend">
|
<div class="input-prepend">
|
||||||
<span class="add-on">HTTP</span>
|
<span class="add-on">HTTP</span>
|
||||||
<input type="text" value="https://github.com/takezoen/test.git" id="repository-url" readonly>
|
<input type="text" value="@requestRepositoryUrl" id="repository-url" readonly>
|
||||||
</div>
|
</div>
|
||||||
<p>
|
<p>
|
||||||
<strong>Step 1:</strong> Check out a new branch to test the changes — run this from your project directory
|
<strong>Step 1:</strong> Check out a new branch to test the changes — run this from your project directory
|
||||||
@@ -129,7 +130,7 @@
|
|||||||
<p>
|
<p>
|
||||||
<strong>Step 2:</strong> Bring in @{pullreq.requestUserName}'s changes and test
|
<strong>Step 2:</strong> Bring in @{pullreq.requestUserName}'s changes and test
|
||||||
</p>
|
</p>
|
||||||
<pre>git pull https://github.com/@{pullreq.requestUserName}/@{repository.name}.git @{pullreq.requestBranch}</pre>
|
<pre>git pull @{requestRepositoryUrl} @{pullreq.requestBranch}</pre>
|
||||||
<p>
|
<p>
|
||||||
<strong>Step 3:</strong> Merge the changes and update the server
|
<strong>Step 3:</strong> Merge the changes and update the server
|
||||||
</p>
|
</p>
|
||||||
|
|||||||
Reference in New Issue
Block a user