diff --git a/db/update6.0.sql b/db/update6.0.sql index 120814a9c9..ac2c1034a9 100644 --- a/db/update6.0.sql +++ b/db/update6.0.sql @@ -3,3 +3,4 @@ ALTER TABLE `zt_story` CHANGE `stage` `stage` enum('','wait','planned','projecte ALTER TABLE `zt_testtask` CHANGE `status` `status` enum('blocked','doing','wait','done') COLLATE 'utf8_general_ci' NOT NULL DEFAULT 'wait' AFTER `report`; ALTER TABLE `zt_todo` CHANGE `status` `status` enum('wait','doing','done') COLLATE 'utf8_general_ci' NOT NULL DEFAULT 'wait' AFTER `desc`; ALTER TABLE `zt_team` CHANGE `hours` `hours` float(2,1) unsigned NOT NULL DEFAULT '0' AFTER `days`; +ALTER TABLE `zt_bug` ADD `testtask` mediumint(8) unsigned NOT NULL AFTER `result`; diff --git a/module/bug/control.php b/module/bug/control.php index a6c314e30a..7e00d7add3 100644 --- a/module/bug/control.php +++ b/module/bug/control.php @@ -252,6 +252,8 @@ class bug extends control $buildID = 0; $caseID = 0; $runID = 0; + $testtask = 0; + $version = 0; $title = ''; $steps = $this->lang->bug->tplStep . $this->lang->bug->tplResult . $this->lang->bug->tplExpect; $os = ''; @@ -321,6 +323,9 @@ class bug extends control $this->view->storyID = $storyID; $this->view->buildID = $buildID; $this->view->caseID = $caseID; + $this->view->runID = $runID; + $this->view->version = $version; + $this->view->testtask = $testtask; $this->view->bugTitle = $title; $this->view->steps = htmlspecialchars($steps); $this->view->os = $os; diff --git a/module/bug/view/create.html.php b/module/bug/view/create.html.php index d1615d9662..50cbac12ca 100644 --- a/module/bug/view/create.html.php +++ b/module/bug/view/create.html.php @@ -131,7 +131,11 @@ js::set('refresh', $lang->refresh); - + diff --git a/module/testtask/view/cases.html.php b/module/testtask/view/cases.html.php index 3770a97c5a..2e9619ee14 100644 --- a/module/testtask/view/cases.html.php +++ b/module/testtask/view/cases.html.php @@ -103,7 +103,7 @@ var moduleID = ''; echo html::a("javascript:ajaxDelete(\"$unlinkURL\",\"caseList\",confirmUnlink)", '', '', "title='{$lang->testtask->unlinkCase}' class='btn-icon'"); } - common::printIcon('testcase', 'createBug', "product=$productID&extra=projectID=$task->project,buildID=$task->build,caseID=$run->case,runID=$run->id", $run, 'list', 'bug'); + common::printIcon('testcase', 'createBug', "product=$productID&extra=projectID=$task->project,buildID=$task->build,caseID=$run->case,version=$run->version,runID=$run->id,testtask=$taskID", $run, 'list', 'bug'); ?>