* Fix the project logic to which the lookup execution belongs.
This commit is contained in:
@@ -79,7 +79,7 @@ class bugModel extends model
|
||||
->remove('files,labels,uid,oldTaskID,contactListMenu,region,lane')
|
||||
->get();
|
||||
|
||||
if($bug->execution != 0) $bug->project = $this->dao->select('parent')->from(TABLE_EXECUTION)->where('id')->eq($bug->execution)->fetch('parent');
|
||||
if($bug->execution != 0) $bug->project = $this->dao->select('project')->from(TABLE_EXECUTION)->where('id')->eq($bug->execution)->fetch('project');
|
||||
|
||||
/* Check repeat bug. */
|
||||
$result = $this->loadModel('common')->removeDuplicate('bug', $bug, "product={$bug->product}");
|
||||
@@ -211,7 +211,7 @@ class bugModel extends model
|
||||
|
||||
if(isset($data->lanes[$i])) $bug->laneID = $data->lanes[$i];
|
||||
|
||||
if($bug->execution != 0) $bug->project = $this->dao->select('parent')->from(TABLE_EXECUTION)->where('id')->eq($bug->execution)->fetch('parent');
|
||||
if($bug->execution != 0) $bug->project = $this->dao->select('project')->from(TABLE_EXECUTION)->where('id')->eq($bug->execution)->fetch('project');
|
||||
|
||||
/* Assign the bug to the person in charge of the module. */
|
||||
if(!empty($moduleOwners[$bug->module]))
|
||||
@@ -349,7 +349,7 @@ class bugModel extends model
|
||||
$bug->task = 0;
|
||||
$bug->pri = 3;
|
||||
$bug->severity = 3;
|
||||
$bug->project = $this->dao->select('parent')->from(TABLE_EXECUTION)->where('id')->eq($executionID)->fetch('parent');
|
||||
$bug->project = $this->dao->select('project')->from(TABLE_EXECUTION)->where('id')->eq($executionID)->fetch('project');
|
||||
|
||||
$this->dao->insert(TABLE_BUG)->data($bug, $skip = 'gitlab,gitlabProject')->autoCheck()->batchCheck($this->config->bug->create->requiredFields, 'notempty')->exec();
|
||||
if(!dao::isError()) return $this->dao->lastInsertID();
|
||||
|
||||
Reference in New Issue
Block a user