goback, '', "class='btn'");?>
" . $lang->action->dynamic->hidden, '', "class='btn btn-danger'");?>
@@ -36,10 +35,10 @@
action->objectType);?>
- idAB);?>
+ idAB);?>
action->objectName;?>
- action->actor);?>
- action->date);?>
+ action->actor);?>
+ action->date);?>
actions;?>
diff --git a/module/block/control.php b/module/block/control.php
index 4c495d49c3..db47998338 100644
--- a/module/block/control.php
+++ b/module/block/control.php
@@ -205,16 +205,17 @@ class block extends control
*
* @param string $module
* @param string $type
+ * @param int $projectID
* @access public
* @return void
*/
- public function dashboard($module, $type = '')
+ public function dashboard($module, $type = '', $projectID = 0)
{
if($this->loadModel('user')->isLogon()) $this->session->set('blockModule', $module);
$blocks = $this->block->getBlockList($module, $type);
$commonField = 'common';
- if($module == 'project')
+ if($module == 'project' and $projectID)
{
$project = $this->loadModel('project')->getByID($this->session->project);
$commonField = $project->model . 'common';
diff --git a/module/block/view/projectblock.html.php b/module/block/view/projectblock.html.php
index 8d80bab6bf..93862595ea 100644
--- a/module/block/view/projectblock.html.php
+++ b/module/block/view/projectblock.html.php
@@ -10,10 +10,10 @@
project->name;?>
- program->PM;?>
- program->status;?>
+ program->PM;?>
+ program->status;?>
- program->teamCount;?>
+ program->teamCount;?>
task->consumed;?>
program->budget;?>
project->leftStories;?>
diff --git a/module/build/control.php b/module/build/control.php
index 0ba0fad7ce..8dc13ef88f 100644
--- a/module/build/control.php
+++ b/module/build/control.php
@@ -40,14 +40,21 @@ class build extends control
if($this->app->openApp == 'project')
{
+ $model = $this->dao->select('model')->from(TABLE_PROJECT)->where('id')->eq($projectID)->fetch('model');
+ $this->lang->project->menu = $this->lang->$model->menu;
+ $this->lang->project->menuOrder = $this->lang->$model->menuOrder;
+ commonModel::setMenuVars('project', $projectID);
+
$executions = $this->execution->getPairs($projectID);
$executionID = isset($executions[$this->session->executionID]) ? $this->session->executionID : key($executions);
$this->session->set('executionID', 0);
+ $this->session->set('PRJ', $projectID);
}
elseif($this->app->openApp == 'execution')
{
$executions = $this->execution->getPairs($execution->project);
$this->execution->setMenu($executionID);
+ $this->session->set('project', $execution->project);
}
$productGroups = $this->execution->getProducts($executionID);
@@ -103,6 +110,14 @@ class build extends control
$this->loadModel('product');
$build = $this->build->getById((int)$buildID);
+ if($this->app->openApp == 'project')
+ {
+ $model = $this->dao->select('model')->from(TABLE_PROJECT)->where('id')->eq($build->project)->fetch('model');
+ $this->lang->project->menu = $this->lang->$model->menu;
+ $this->lang->project->menuOrder = $this->lang->$model->menuOrder;
+ commonModel::setMenuVars('project', $build->project);
+ }
+
/* Set menu. */
$this->execution->setMenu($this->execution->getPairs($build->project), $build->execution);
@@ -164,10 +179,19 @@ class build extends control
*/
public function view($buildID, $type = 'story', $link = 'false', $param = '', $orderBy = 'id_desc', $recTotal = 0, $recPerPage = 100, $pageID = 1)
{
+
$build = $this->build->getByID((int)$buildID, true);
if(!$build) die(js::error($this->lang->notFound) . js::locate('back'));
$this->session->PRJ = $build->project;
+ if($this->app->openApp == 'project')
+ {
+ $model = $this->dao->select('model')->from(TABLE_PROJECT)->where('id')->eq($build->project)->fetch('model');
+ $this->lang->project->menu = $this->lang->$model->menu;
+ $this->lang->project->menuOrder = $this->lang->$model->menuOrder;
+ commonModel::setMenuVars('project', $build->project);
+ }
+
/* Set session and load modules. */
if($type == 'story')$this->session->set('storyList', $this->app->getURI(true));
if($type == 'bug') $this->session->set('bugList', $this->app->getURI(true));
@@ -199,7 +223,7 @@ class build extends control
foreach($stages as $storyID => $stage)$stories[$storyID]->stage = $stage;
/* Set menu. */
- commonModel::setAppObjectID('execution', $build->execution);
+ commonModel::setMenuVars('execution', $build->execution);
$executions = $this->loadModel('execution')->getPairs($this->session->PRJ, 'all', 'empty');
$this->view->title = "BUILD #$build->id $build->name - " . $executions[$build->execution];
@@ -550,7 +574,7 @@ class build extends control
if($browseType == 'bySearch')
{
- $allBugs = $this->bug->getBySearch($build->product, $build->branch, $queryID, 'id_desc', $build->bugs, $pager);
+ $allBugs = $this->bug->getBySearch($build->product, $build->branch, $queryID, 'id_desc', $build->bugs, $pager, $build->project);
}
else
{
diff --git a/module/common/lang/en.php b/module/common/lang/en.php
index 6dfa66f140..1d2cd379eb 100644
--- a/module/common/lang/en.php
+++ b/module/common/lang/en.php
@@ -863,17 +863,10 @@ $lang->icons['score'] = 'tint';
/* Scrum menu. */
$lang->menu = new stdclass();
$lang->menu->scrum = new stdclass();
-<<<<<<< Updated upstream
-$lang->menu->scrum->index = 'Index|project|index|project={PROJECT}';
-$lang->menu->scrum->project = "$lang->executionCommon|project|index|locate=no";
-$lang->menu->scrum->projectstory = array('link' => $lang->SRCommon . '|projectstory|story|', 'subModule' => 'story', 'alias' => 'story,track');
-$lang->menu->scrum->doc = 'Doc|doc|index|';
-=======
$lang->menu->scrum->index = 'Index|project|index|project=%s';
$lang->menu->scrum->project = array('link' => "$lang->executionCommon|project|index|locate=no");
$lang->menu->scrum->projectstory = array('link' => $lang->SRCommon . '|projectstory|story|project=%s', 'subModule' => 'story', 'alias' => 'story,track');
$lang->menu->scrum->doc = array('link' => 'Doc|doc|objectLibs|type=project&objectID=%s', 'subModule' => 'doc');
->>>>>>> Stashed changes
$lang->menu->scrum->qa = 'QA|qa|index';
$lang->menu->scrum->ci = 'Code|repo|browse';
$lang->menu->scrum->build = array('link' => 'Build|project|build|project=%s');
diff --git a/module/execution/control.php b/module/execution/control.php
index df23d17c30..3c2631d1fa 100644
--- a/module/execution/control.php
+++ b/module/execution/control.php
@@ -2038,9 +2038,9 @@ class execution extends control
{
/* Delete execution. */
$this->dao->update(TABLE_EXECUTION)->set('deleted')->eq(1)->where('id')->eq($executionID)->exec();
- $this->loadModel('action')->create($this->objectType, $executionID, 'deleted', '', $extra = ACTIONMODEL::CAN_UNDELETED);
- $this->dao->update(TABLE_DOCLIB)->set('deleted')->eq(1)->where('execution')->eq($executionID)->exec();
+ $this->loadModel('action')->create('execution', $executionID, 'deleted', '', ACTIONMODEL::CAN_UNDELETED);
$this->execution->updateUserView($executionID);
+
$this->session->set('execution', '');
$this->executeHooks($executionID);
die(js::locate(inlink('index'), 'parent'));
@@ -2554,7 +2554,7 @@ class execution extends control
* @access public
* @return void
*/
- public function ajaxGetDropMenu($module, $method, $extra)
+ public function ajaxGetDropMenu($executionID, $module, $method, $extra)
{
$projects = $this->dao->select('*')->from(TABLE_PROJECT)->where('id')->in($this->app->user->view->projects)->andWhere('deleted')->eq(0)->orderBy('order_desc')->fetchAll('id');
@@ -2582,6 +2582,7 @@ class execution extends control
$this->view->link = $this->execution->getLink($module, $method, $extra);
$this->view->module = $module;
$this->view->method = $method;
+ $this->view->executionID = $executionID;
$this->view->extra = $extra;
$this->view->projects = $this->project->getPairsByModel();
$this->view->executions = $orderedExecutions;
diff --git a/module/execution/model.php b/module/execution/model.php
index ad5e38f632..e8a1413c60 100644
--- a/module/execution/model.php
+++ b/module/execution/model.php
@@ -139,7 +139,7 @@ class executionModel extends model
}
}
- $dropMenuLink = helper::createLink('execution', 'ajaxGetDropMenu', "module=$currentModule&method=$currentMethod&extra=$extra");
+ $dropMenuLink = helper::createLink('execution', 'ajaxGetDropMenu', "executionID=$executionID&module=$currentModule&method=$currentMethod&extra=$extra");
$currentExecutionName = '';
if(isset($currentExecution->name)) $currentExecutionName = $currentExecution->name;
@@ -850,7 +850,7 @@ class executionModel extends model
$currentExecutionName = $currentExecution->name;
}
- $dropMenuLink = helper::createLink('execution', 'ajaxGetDropMenu', "module=$currentModule&method=$currentMethod&extra=");
+ $dropMenuLink = helper::createLink('execution', 'ajaxGetDropMenu', "executionID=$executionID&module=$currentModule&method=$currentMethod&extra=");
$output = "
+
diff --git a/module/my/control.php b/module/my/control.php
index 4205228d1d..642a2d3089 100644
--- a/module/my/control.php
+++ b/module/my/control.php
@@ -883,7 +883,7 @@ class my extends control
$this->view->programLink = isset($this->config->programLink) ? $this->config->programLink : 'program-browse';
$this->view->productLink = isset($this->config->productLink) ? $this->config->productLink : 'product-all';
$this->view->projectLink = isset($this->config->projectLink) ? $this->config->projectLink : 'project-browse';
- $this->view->executionLink = isset($this->config->executionLink) ? $this->config->executionLink : 'execution-task';
+ //$this->view->executionLink = isset($this->config->executionLink) ? $this->config->executionLink : 'execution-task';
$this->view->preferenceSetted = isset($this->config->preferenceSetted) ? true : false;
$this->display();
diff --git a/module/my/view/preference.html.php b/module/my/view/preference.html.php
index 6f6ca08a32..34462f4885 100755
--- a/module/my/view/preference.html.php
+++ b/module/my/view/preference.html.php
@@ -55,10 +55,12 @@ html,body {height: 100%;}
my->projectLinkList, $projectLink, "class='form-control chosen'");?>
+
diff --git a/module/product/control.php b/module/product/control.php
index b4f889178a..27227d9095 100644
--- a/module/product/control.php
+++ b/module/product/control.php
@@ -134,6 +134,7 @@ class product extends control
$this->loadModel('execution');
/* Set product, module and query. */
+ $productID = $this->app->openApp != 'project' ? $this->product->saveState($productID, $this->products) : $productID;
$branch = ($branch === '') ? (int)$this->cookie->preBranch : (int)$branch;
setcookie('preProductID', $productID, $this->config->cookieLife, $this->config->webRoot, '', false, true);
setcookie('preBranch', (int)$branch, $this->config->cookieLife, $this->config->webRoot, '', false, true);
diff --git a/module/product/view/ajaxgetdropmenu.html.php b/module/product/view/ajaxgetdropmenu.html.php
index c884d064e4..fb30e60d18 100644
--- a/module/product/view/ajaxgetdropmenu.html.php
+++ b/module/product/view/ajaxgetdropmenu.html.php
@@ -22,43 +22,44 @@ $closedProductsHtml = '';
foreach($products as $product)
{
+ $selected = $product->id == $productID ? 'selected' : '';
$productName = $product->program ? zget($programs, $product->program, '') . '/' : '';
$productName .= $product->line ? zget($lines, $product->line, '') . '/' . $product->name : $product->name;
if($product->status == 'normal' and $product->PO == $this->app->user->account)
{
$objectID = ($product->type != 'platform' && $module == 'branch' && $method == 'manage') ? $productID : $product->id;
$linkHtml = $this->product->setParamsForLink($module, $link, $projectID, $product->id);
- $myProductsHtml .= html::a($linkHtml, $productName, '', "class='text-important' title='{$productName}' data-key='" . zget($productsPinYin, $product->name, '') . "' data-app='$openApp'");
+ $myProductsHtml .= html::a($linkHtml, $productName, '', "class='text-important $selected' title='{$productName}' data-key='" . zget($productsPinYin, $product->name, '') . "' data-app='$openApp'");
}
else if($product->status == 'normal' and !($product->PO == $this->app->user->account))
{
$objectID = ($product->type != 'platform' && $module == 'branch' && $method == 'manage') ? $productID : $product->id;
$linkHtml = $this->product->setParamsForLink($module, $link, $projectID, $product->id);
- $normalProductsHtml .= html::a($linkHtml, $productName, '', "title='{$productName}' data-key='" . zget($productsPinYin, $product->name, '') . "' data-app='$openApp'");
+ $normalProductsHtml .= html::a($linkHtml, $productName, '', "class='$selected' title='{$productName}' data-key='" . zget($productsPinYin, $product->name, '') . "' data-app='$openApp'");
}
else if($product->status == 'closed')
{
$objectID = ($product->type != 'platform' && $module == 'branch' && $method == 'manage') ? $productID : $product->id;
$linkHtml = $this->product->setParamsForLink($module, $link, $projectID, $objectID);
- $closedProductsHtml .= html::a($linkHtml, $productName, '', "title='{$productName}' class='closed' data-key='" . zget($productsPinYin, $product->name, '') . "' data-app='$openApp'");
+ $closedProductsHtml .= html::a($linkHtml, $productName, '', "class='$selected' title='{$productName}' class='closed' data-key='" . zget($productsPinYin, $product->name, '') . "' data-app='$openApp'");
}
}
?>
";
+ echo $myProductsHtml;
+ if(!empty($myProductsHtml))
+ {
+ echo "
";
+ echo $myProjectsHtml;
+ if(!empty($myProjectsHtml))
+ {
+ echo "
- id"), sprintf('%03d', $build->id));?>
+ id"), sprintf('%03d', $build->id), '', "data-app='project'");?>
productName;?>
branchName) echo "{$build->branchName}"?>
- createLink('build', 'view', "build=$build->id"), $build->name);?>
+ createLink('build', 'view', "build=$build->id"), $build->name, '', "data-app='project'");?>
executionName;?>
scmPath, 'http') === 0 ? html::a($build->scmPath) : $build->scmPath;?>
@@ -79,7 +79,7 @@
}
common::printIcon('testtask', 'create', "product=$build->product&executionID={$build->execution}&build=$build->id&projectID=$projectID", $build, 'list', 'bullhorn', '', '', '', "data-app='execution'");
$lang->project->bug = $lang->execution->viewBug;
- common::printIcon('execution', 'bug', "project={$build->execution}&orderBy=status&build=$build->id", $build, 'list', '', '', '', '', "data-app='execution'");
+ common::printIcon('build', 'view', "buildID=$build->id&type=generatedBug", $build, 'list', 'bug', '', '', '', "data-app='project'");
common::printIcon('build', 'edit', "buildID=$build->id", $build, 'list');
if(common::hasPriv('build', 'delete', $build))
{
diff --git a/module/project/view/view.html.php b/module/project/view/view.html.php
index a95bfa7f60..a4143dd277 100644
--- a/module/project/view/view.html.php
+++ b/module/project/view/view.html.php
@@ -90,8 +90,9 @@
{$this->lang->execution->common}
";
$output .= "";
$output .= '';
@@ -2444,8 +2444,8 @@ class executionModel extends model
->andWhere('t2.deleted')->eq(0)
->andWhere('t2.status')->ne('closed')
->andWhere('t2.stage')->in('wait,planned,executioned,developing')
- ->groupBy('execution')
- ->fetchAll('execution');
+ ->groupBy('project')
+ ->fetchAll('project');
foreach($burns as $executionID => $burn)
{
diff --git a/module/execution/view/ajaxgetdropmenu.html.php b/module/execution/view/ajaxgetdropmenu.html.php
index fece6733b3..0916abc79d 100644
--- a/module/execution/view/ajaxgetdropmenu.html.php
+++ b/module/execution/view/ajaxgetdropmenu.html.php
@@ -20,33 +20,34 @@ $executionsPinYin = common::convert2Pinyin($executionNames);
foreach($executions as $execution)
{
+ $selected = $execution->id == $executionID ? 'selected' : '';
$executionName = zget($projects, $execution->project) . '/' . $execution->name;
if($execution->status != 'done' and $execution->status != 'closed' and $execution->PM == $this->app->user->account)
{
- $myProjectsHtml .= html::a(sprintf($link, $execution->id), " " . $executionName, '', "class='text-important' title='{$executionName}' data-key='" . zget($executionsPinYin, $execution->name, '') . "'");
+ $myProjectsHtml .= html::a(sprintf($link, $execution->id), " " . $executionName, '', "class='text-important $selected' title='{$executionName}' data-key='" . zget($executionsPinYin, $execution->name, '') . "'");
}
else if($execution->status != 'done' and $execution->status != 'closed' and !($execution->PM == $this->app->user->account))
{
- $normalProjectsHtml .= html::a(sprintf($link, $execution->id), " " . $executionName, '', "title='{$executionName}' data-key='" . zget($executionsPinYin, $execution->name, '') . "'");
+ $normalProjectsHtml .= html::a(sprintf($link, $execution->id), " " . $executionName, '', "class='$selected' title='{$executionName}' data-key='" . zget($executionsPinYin, $execution->name, '') . "'");
}
- else if($execution->status == 'done' or $execution->status == 'closed') $closedProjectsHtml .= html::a(sprintf($link, $execution->id), " " . $executionName, '', "title='{$executionName}' data-key='" . zget($executionsPinYin, $execution->name, '') . "'");
+ else if($execution->status == 'done' or $execution->status == 'closed') $closedProjectsHtml .= html::a(sprintf($link, $execution->id), " " . $executionName, '', "class='$selected' title='{$executionName}' data-key='" . zget($executionsPinYin, $execution->name, '') . "'");
}
?>
";
+ echo $myProjectsHtml;
+ if(!empty($myProjectsHtml))
+ {
+ echo "
- {$lang->execution->mine}
";
- echo $myProjectsHtml;
- if(!empty($myProjectsHtml))
- {
- echo "{$lang->execution->other}
";
- }
- }
- echo $normalProjectsHtml;
- ?>
+ {$lang->execution->mine}{$lang->execution->other}
";
+ }
+ }
+ echo $normalProjectsHtml;
+ ?>
' . $lang->execution->all, '', 'class="not-list-item"'); ?>
@@ -54,10 +55,15 @@ foreach($executions as $execution)
-
-
-
+
- {$lang->product->mine}
";
- echo $myProductsHtml;
- if(!empty($myProductsHtml))
- {
- echo "{$lang->product->other}
";
- }
- }
- echo $normalProductsHtml;
- ?>
+ {$lang->product->mine}{$lang->product->other}
";
+ }
+ }
+ echo $normalProductsHtml;
+ ?>
' . $lang->product->all, '', 'class="not-list-item"'); ?>
@@ -67,8 +68,15 @@ foreach($products as $product)
-
+
diff --git a/module/program/control.php b/module/program/control.php
index 01a907690e..9e515e8d08 100644
--- a/module/program/control.php
+++ b/module/program/control.php
@@ -47,7 +47,7 @@ class program extends control
if(common::hasPriv('program', 'create')) $this->lang->pageActions = html::a($this->createLink('program', 'create'), " " . $this->lang->program->create, '', "class='btn btn-secondary'");
- $this->app->session->set('programList', $this->app->getURI(true));
+ $this->session->set('programList', $this->app->getURI(true));
$programType = $this->cookie->programType ? $this->cookie->programType : 'bylist';
@@ -368,7 +368,7 @@ class program extends control
if($confirm == 'no') die(js::confirm($this->lang->program->confirmDelete, $this->createLink('program', 'delete', "programID=$programID&confirm=yes")));
$this->dao->update(TABLE_PROGRAM)->set('deleted')->eq(1)->where('id')->eq($programID)->exec();
- $this->loadModel('action')->create('program', $programID, 'deleted', '', $extra = ACTIONMODEL::CAN_UNDELETED);
+ $this->loadModel('action')->create('program', $programID, 'deleted', '', ACTIONMODEL::CAN_UNDELETED);
die(js::reload('parent'));
}
diff --git a/module/project/config.php b/module/project/config.php
index 3e000a43ec..a0892f2c03 100644
--- a/module/project/config.php
+++ b/module/project/config.php
@@ -69,7 +69,7 @@ $config->project->datatable->fieldList['budget']['required'] = 'yes';
$config->project->datatable->fieldList['teamCount']['title'] = 'teamCount';
$config->project->datatable->fieldList['teamCount']['fixed'] = 'no';
-$config->project->datatable->fieldList['teamCount']['width'] = '40';
+$config->project->datatable->fieldList['teamCount']['width'] = '70';
$config->project->datatable->fieldList['teamCount']['required'] = 'no';
$config->project->datatable->fieldList['teamCount']['sort'] = 'no';
diff --git a/module/project/control.php b/module/project/control.php
index bf9dc57219..ec0ced4940 100644
--- a/module/project/control.php
+++ b/module/project/control.php
@@ -1325,13 +1325,22 @@ class project extends control
}
else
{
- $projectIdList = $this->project->getExecutionsByProject($projectID);
- $this->project->delete(TABLE_PROJECT, $projectID);
- $this->dao->update(TABLE_PROJECT)->set('deleted')->eq(1)->where('id')->in(array_keys($projectIdList))->exec();
- $this->dao->update(TABLE_DOCLIB)->set('deleted')->eq(1)->where('project')->eq($projectID)->exec();
- $this->project->updateUserView($projectID);
- $this->session->set('project', '');
+ $this->loadModel('user');
+ $this->loadModel('action');
+ $this->project->delete(TABLE_PROJECT, $projectID);
+ $this->dao->update(TABLE_DOCLIB)->set('deleted')->eq(1)->where('execution')->eq($projectID)->exec();
+ $this->user->updateUserView($projectID, 'project');
+
+ /* Delete the execution under the project. */
+ $executionIdList = $this->execution->getByProject($projectID);
+ if(empty($executionIdList)) die(js::reload('parent'));
+
+ $this->dao->update(TABLE_EXECUTION)->set('deleted')->eq(1)->where('id')->in(array_keys($executionIdList))->exec();
+ foreach($executionIdList as $executionID => $execution) $this->action->create('execution', $executionID, 'deleted', '', ACTIONMODEL::CAN_UNDELETED);
+ $this->user->updateUserView($executionIdList, 'sprint');
+
+ $this->session->set('project', '');
die(js::reload('parent'));
}
}
diff --git a/module/project/lang/zh-cn.php b/module/project/lang/zh-cn.php
index 502fe346b9..3f08fa2def 100644
--- a/module/project/lang/zh-cn.php
+++ b/module/project/lang/zh-cn.php
@@ -41,6 +41,7 @@ $lang->project->errorSameProducts = '项目不能关联多个相同的产品。'
$lang->project->errorNoProducts = '最少关联一个产品';
$lang->project->copyNoProject = '没有可用的项目来复制';
$lang->project->searchByName = '输入项目名称进行检索';
+$lang->project->deleted = '已删除';
/* Fields. */
$lang->project->common = '项目';
diff --git a/module/project/view/ajaxgetdropmenu.html.php b/module/project/view/ajaxgetdropmenu.html.php
index d50f5f6b15..9336ed065a 100644
--- a/module/project/view/ajaxgetdropmenu.html.php
+++ b/module/project/view/ajaxgetdropmenu.html.php
@@ -20,34 +20,35 @@ $projectsPinYin = common::convert2Pinyin($projectNames);
foreach($projects as $project)
{
- $link = helper::createLink('project', 'index', "projectID=%s", '', '', $project->id);
+ $selected = $project->id == $projectID ? 'selected' : '';
+ $link = helper::createLink('project', 'index', "projectID=%s", '', '', $project->id);
$projectName = zget($programs, $project->parent, '') ? zget($programs, $project->parent) . '/' . $project->name : $project->name;
if($project->status != 'done' and $project->status != 'closed' and $project->PM == $this->app->user->account)
{
- $myProjectsHtml .= html::a(sprintf($link, $project->id), $projectName, '', "class='text-important' title='{$projectName}' data-key='" . zget($projectsPinYin, $projectName, '') . "'");
+ $myProjectsHtml .= html::a(sprintf($link, $project->id), $projectName, '', "class='text-important $selected' title='{$projectName}' data-key='" . zget($projectsPinYin, $projectName, '') . "'");
}
else if($project->status != 'done' and $project->status != 'closed' and !($project->PM == $this->app->user->account))
{
- $normalProjectsHtml .= html::a(sprintf($link, $project->id), $projectName, '', "title='{$projectName}' data-key='" . zget($projectsPinYin, $projectName, '') . "'");
+ $normalProjectsHtml .= html::a(sprintf($link, $project->id), $projectName, '', "class='$selected' title='{$projectName}' data-key='" . zget($projectsPinYin, $projectName, '') . "'");
}
- else if($project->status == 'done' or $project->status == 'closed') $closedProjectsHtml .= html::a(sprintf($link, $project->id), $projectName, '', "title='{$projectName}' data-key='" . zget($projectsPinYin, $projectName, '') . "'");
+ else if($project->status == 'done' or $project->status == 'closed') $closedProjectsHtml .= html::a(sprintf($link, $project->id), $projectName, '', "class='$selected' title='{$projectName}' data-key='" . zget($projectsPinYin, $projectName, '') . "'");
}
?>
-
-
+
- {$lang->project->myProject}
";
- echo $myProjectsHtml;
- if(!empty($myProjectsHtml))
- {
- echo "{$lang->project->other}
";
- }
- }
- echo $normalProjectsHtml;
- ?>
+ {$lang->project->myProject}{$lang->project->other}
";
+ }
+ }
+ echo $normalProjectsHtml;
+ ?>
' . $lang->project->all, '', 'class="not-list-item"'); ?>
@@ -55,10 +56,15 @@ foreach($projects as $project)
-
+
diff --git a/module/project/view/build.html.php b/module/project/view/build.html.php
index 6ceca83724..388b786cc3 100644
--- a/module/project/view/build.html.php
+++ b/module/project/view/build.html.php
@@ -60,11 +60,11 @@
$builds):?>
$build):?>
-
-
+
id";
- common::printBack(inlink('browse'));
+ $params = "project=$project->id";
+ $browseLink = $this->session->projectList ? $this->session->projectList : inlink('browse');
+ common::printBack($browseLink);
if(!$project->deleted)
{
echo "";
diff --git a/module/search/model.php b/module/search/model.php
index 194c103036..093c0a245c 100644
--- a/module/search/model.php
+++ b/module/search/model.php
@@ -578,13 +578,13 @@ class searchModel extends model
{
if(!isset($this->config->objectTables[$record->objectType])) continue;
$table = $this->config->objectTables[$record->objectType];
- $executionID = $this->dao->select('execution')->from($table)->where('id')->eq($record->objectID)->fetch('execution');
- $record->url = helper::createLink($module, $method, "id={$record->objectID}", '', false, $executionID);
+ $projectID = $this->dao->select('project')->from($table)->where('id')->eq($record->objectID)->fetch('project');
+ $record->url = helper::createLink($module, $method, "id={$record->objectID}", '', false, $projectID);
}
elseif($module == 'issue')
{
- $issue = $this->dao->select('id,execution,owner')->from(TABLE_ISSUE)->where('id')->eq($record->objectID)->fetch();
- $record->url = helper::createLink($module, $method, "id={$record->objectID}", '', false, $issue->execution);
+ $issue = $this->dao->select('id,project,owner')->from(TABLE_ISSUE)->where('id')->eq($record->objectID)->fetch();
+ $record->url = helper::createLink($module, $method, "id={$record->objectID}", '', false, $issue->project);
$record->extraType = empty($issue->owner) ? 'commonIssue' : 'stakeholderIssue';
}
elseif($module == 'story')
diff --git a/module/story/view/view.html.php b/module/story/view/view.html.php
index a6bda3ae77..766abc2f33 100644
--- a/module/story/view/view.html.php
+++ b/module/story/view/view.html.php
@@ -12,7 +12,7 @@
?>
-session->storyList != false ? $app->session->storyList : $this->createLink('product', 'browse', "productID=$story->product&branch=$story->branch&moduleID=$story->module");?>
+session->storyList ? $app->session->storyList : $this->createLink('product', 'browse', "productID=$story->product&branch=$story->branch&moduleID=$story->module");?>