mirror of
https://github.com/gitbucket/gitbucket.git
synced 2025-11-02 03:26:06 +01:00
Add close and re-open of the issue.
This commit is contained in:
@@ -185,12 +185,12 @@ trait IssuesService {
|
||||
} get
|
||||
|
||||
def createComment(owner: String, repository: String, loginUser: String,
|
||||
issueId: Int, content: String) =
|
||||
issueId: Int, content: String, action: Option[String]) =
|
||||
IssueComments.autoInc insert (
|
||||
owner,
|
||||
repository,
|
||||
issueId,
|
||||
None,
|
||||
action,
|
||||
loginUser,
|
||||
content,
|
||||
currentDate,
|
||||
@@ -213,6 +213,14 @@ trait IssuesService {
|
||||
t.content ~ t.updatedDate
|
||||
} update (content, currentDate)
|
||||
|
||||
def updateClosed(owner: String, repository: String, issueId: Int, closed: Boolean) =
|
||||
Issues
|
||||
.filter (_.byPrimaryKey(owner, repository, issueId))
|
||||
.map { t =>
|
||||
t.closed ~ t.updatedDate
|
||||
}
|
||||
.update (closed, currentDate)
|
||||
|
||||
}
|
||||
|
||||
object IssuesService {
|
||||
|
||||
Reference in New Issue
Block a user