* set closed info when converted to story.

* closed the bug after converted to story.
This commit is contained in:
wangchunsheng
2011-12-07 01:24:16 +00:00
parent a264e5e348
commit 8514e02b81
3 changed files with 8 additions and 3 deletions
+5 -2
View File
@@ -261,8 +261,11 @@ class bugModel extends model
->add('lastEditedDate', $now)
->setDefault('duplicateBug', 0)
->setDefault('assignedTo', $oldBug->openedBy)
->setIF($this->post->resolution == 'tostory', 'toStory', $storyID)
->setIF($this->post->resolution == 'tostory', 'status', 'closed')
->setIF($this->post->resolution == 'tostory', 'toStory', $storyID)
->setIF($this->post->resolution == 'tostory', 'status', 'closed')
->setIF($this->post->resolution == 'tostory', 'closedBy', $this->app->user->account)
->setIF($this->post->resolution == 'tostory', 'closedDate', $now)
->setIF($this->post->resolution == 'tostory', 'assignedTo', 'closed')
->setIF($this->post->resolution != 'tostory', 'status', 'resolved')
->remove('comment')
->get();