+ Update issue status when close bug.
This commit is contained in:
@@ -1247,6 +1247,8 @@ class bug extends control
|
||||
|
||||
$this->executeHooks($bugID);
|
||||
|
||||
$this->loadModel('gitlab')->pushBug($bugID, $this->post->gitlab, $this->post->gitlabProject);
|
||||
|
||||
if($bug->toTask != 0)
|
||||
{
|
||||
/* If task is not finished, update it's status. */
|
||||
|
||||
@@ -874,7 +874,7 @@ class gitlabModel extends model
|
||||
}
|
||||
|
||||
/* issue->state is null when creating it, we should put status_event when updating it. */
|
||||
if(isset($issue->state)) $issue->status_event=$issue->state;
|
||||
if(isset($issue->state) and $issue->state == 'closed') $issue->state_event='close';
|
||||
|
||||
return $issue;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user