diff --git a/module/block/lang/zh-tw.php b/module/block/lang/zh-tw.php
index 1929912983..030dff1817 100644
--- a/module/block/lang/zh-tw.php
+++ b/module/block/lang/zh-tw.php
@@ -260,14 +260,11 @@ $lang->block->default['full']['my']['4']['grid'] = 4;
$lang->block->default['full']['my']['4']['source'] = 'todo';
$lang->block->default['full']['my']['4']['params']['count'] = '20';
-if($config->systemMode == 'new')
-{
- $lang->block->default['full']['my']['5']['title'] = '項目統計';
- $lang->block->default['full']['my']['5']['block'] = 'statistic';
- $lang->block->default['full']['my']['5']['source'] = 'project';
- $lang->block->default['full']['my']['5']['grid'] = 8;
- $lang->block->default['full']['my']['5']['params']['count'] = '20';
-}
+$lang->block->default['full']['my']['5']['title'] = '項目統計';
+$lang->block->default['full']['my']['5']['block'] = 'statistic';
+$lang->block->default['full']['my']['5']['source'] = 'project';
+$lang->block->default['full']['my']['5']['grid'] = 8;
+$lang->block->default['full']['my']['5']['params']['count'] = '20';
$lang->block->default['full']['my']['6']['title'] = '我的貢獻';
$lang->block->default['full']['my']['6']['block'] = 'contribute';
@@ -292,23 +289,15 @@ $lang->block->default['full']['my']['8']['params']['issueCount'] = '20';
$lang->block->default['full']['my']['8']['params']['storyCount'] = '20';
$lang->block->default['full']['my']['8']['params']['meetingCount'] = '20';
-if($config->systemMode == 'new')
-{
- $lang->block->default['full']['my']['9']['title'] = '項目人力投入';
- $lang->block->default['full']['my']['9']['block'] = 'projectteam';
- $lang->block->default['full']['my']['9']['source'] = 'project';
- $lang->block->default['full']['my']['9']['grid'] = 8;
-}
+$lang->block->default['full']['my']['9']['title'] = '項目人力投入';
+$lang->block->default['full']['my']['9']['block'] = 'projectteam';
+$lang->block->default['full']['my']['9']['source'] = 'project';
+$lang->block->default['full']['my']['9']['grid'] = 8;
$lang->block->default['full']['my']['10']['title'] = '項目列表';
$lang->block->default['full']['my']['10']['block'] = 'project';
$lang->block->default['full']['my']['10']['source'] = 'project';
$lang->block->default['full']['my']['10']['grid'] = 8;
-if($config->systemMode == 'classic')
-{
- $lang->block->default['full']['my']['10']['block'] = 'execution';
- $lang->block->default['full']['my']['10']['source'] = 'execution';
-}
$lang->block->default['full']['my']['10']['params']['orderBy'] = 'id_desc';
$lang->block->default['full']['my']['10']['params']['count'] = '15';
@@ -334,7 +323,7 @@ $lang->block->availableBlocks->issue = '我的問題';
$lang->block->availableBlocks->meeting = '我的會議';
$lang->block->availableBlocks->feedback = '我的反饋';
-if($config->systemMode == 'new') $lang->block->moduleList['project'] = '項目';
+$lang->block->moduleList['project'] = '項目';
$lang->block->moduleList['product'] = $lang->productCommon;
$lang->block->moduleList['execution'] = $lang->execution->common;
$lang->block->moduleList['qa'] = '測試';
@@ -345,7 +334,7 @@ $lang->block->modules['project']->availableBlocks = new stdclass();
$lang->block->modules['project']->availableBlocks->project = '項目列表';
$lang->block->modules['project']->availableBlocks->recentproject = '近期項目';
$lang->block->modules['project']->availableBlocks->statistic = '項目統計';
-if($config->systemMode == 'new') $lang->block->modules['project']->availableBlocks->projectteam = '項目人力投入';
+$lang->block->modules['project']->availableBlocks->projectteam = '項目人力投入';
$lang->block->modules['scrum']['index'] = new stdclass();
$lang->block->modules['scrum']['index']->availableBlocks = new stdclass();
@@ -502,7 +491,7 @@ $lang->block->typeList->testtask['done'] = '已測版本';
$lang->block->typeList->testtask['all'] = '全部';
$lang->block->modules['project']->moreLinkList = new stdclass();
-$lang->block->modules['project']->moreLinkList->recentproject = $config->systemMode == 'new' ? 'project|browse|' : 'execution|all|';
+$lang->block->modules['project']->moreLinkList->recentproject = 'project|browse|';
$lang->block->modules['project']->moreLinkList->statistic = 'project|browse|';
$lang->block->modules['project']->moreLinkList->project = 'project|browse|';
$lang->block->modules['project']->moreLinkList->cmmireport = 'weekly|index|';
diff --git a/module/execution/control.php b/module/execution/control.php
index dea8b3e57b..6146f67905 100644
--- a/module/execution/control.php
+++ b/module/execution/control.php
@@ -245,7 +245,7 @@ class execution extends control
$this->view->setModule = true;
$this->view->canBeChanged = common::canModify('execution', $execution); // Determines whether an object is editable.
$this->view->showBranch = $showBranch;
- $this->view->projectName = $this->config->systemMode == 'new' ? $this->loadModel('project')->getById($execution->project)->name . ' / ' . $execution->name : $execution->name;
+ $this->view->projectName = $this->loadModel('project')->getById($execution->project)->name . ' / ' . $execution->name;
$this->display();
}
@@ -1713,11 +1713,11 @@ class execution extends control
if(!empty($this->config->user->moreLink)) $this->config->moreLinks["RD"] = $this->config->user->moreLink;
$this->loadModel('product');
- $allProducts = $this->config->systemMode == 'classic' ? $this->product->getPairs('noclosed') : $this->product->getProductPairsByProject($projectID, 'noclosed');
+ $allProducts = $this->product->getProductPairsByProject($projectID, 'noclosed');
$copyProjects = $this->loadModel('project')->getPairsByProgram(isset($project->parent) ? $project->parent : '', 'noclosed', '', 'order_asc', '', isset($project->model) ? $project->model : '');
$copyProjectID = ($projectID == 0) ? key($copyProjects) : $projectID;
- $this->view->title = (($this->app->tab == 'execution') and ($this->config->systemMode == 'new')) ? $this->lang->execution->createExec : $this->lang->execution->create;
+ $this->view->title = $this->app->tab == 'execution' ? $this->lang->execution->createExec : $this->lang->execution->create;
$this->view->position[] = $this->view->title;
$this->view->gobackLink = (isset($output['from']) and $output['from'] == 'global') ? $this->createLink('execution', 'all') : '';
$this->view->executions = array('' => '') + $this->execution->getList($projectID);
@@ -1741,7 +1741,7 @@ class execution extends control
$this->view->productPlans = array(0 => '') + $productPlans;
$this->view->whitelist = $whitelist;
$this->view->copyExecutionID = $copyExecutionID;
- $this->view->branchGroups = isset($branchGroups) ? $branchGroups : $this->execution->getBranchByProduct(array_keys($products), $this->config->systemMode == 'new' ? $projectID : 0);
+ $this->view->branchGroups = isset($branchGroups) ? $branchGroups : $this->execution->getBranchByProduct(array_keys($products), $projectID);
$this->view->poUsers = $poUsers;
$this->view->pmUsers = $pmUsers;
$this->view->qdUsers = $qdUsers;
@@ -1867,7 +1867,7 @@ class execution extends control
$position[] = html::a($browseExecutionLink, $execution->name);
$position[] = $this->lang->execution->edit;
- $allProducts = $this->config->systemMode == 'classic' ? $this->product->getPairs('noclosed', 0, $linkedProductIdList) : $this->product->getProducts($execution->project, 'noclosed', '', false, $linkedProductIdList);
+ $allProducts = $this->product->getProducts($execution->project, 'noclosed', '', false, $linkedProductIdList);
$allProducts = array(0 => '') + $allProducts;
$this->loadModel('productplan');
@@ -1935,9 +1935,9 @@ class execution extends control
$this->view->unmodifiableBranches = $unmodifiableBranches;
$this->view->multiBranchProducts = $this->product->getMultiBranchPairs();
$this->view->productPlans = $productPlans;
- $this->view->branchGroups = $this->execution->getBranchByProduct(array_keys($linkedProducts), $this->config->systemMode == 'new' ? $execution->project : 0, 'noclosed', $linkedBranchList);
+ $this->view->branchGroups = $this->execution->getBranchByProduct(array_keys($linkedProducts), $execution->project, 'noclosed', $linkedBranchList);
$this->view->teamMembers = $this->execution->getTeamMembers($executionID);
- if($this->config->systemMode == 'new') $this->view->allProjects = $this->project->getPairsByModel($project->model, 0, 'noclosed', $project->id);
+ $this->view->allProjects = $this->project->getPairsByModel($project->model, 0, 'noclosed', $project->id);
$this->display();
}
@@ -2274,12 +2274,9 @@ class execution extends control
$execution->projectInfo = $this->loadModel('project')->getByID($execution->project);
- if($this->config->systemMode == 'new')
- {
- $programList = array_filter(explode(',', $execution->projectInfo->path));
- array_pop($programList);
- $this->view->programList = $this->loadModel('program')->getPairsByList($programList);
- }
+ $programList = array_filter(explode(',', $execution->projectInfo->path));
+ array_pop($programList);
+ $this->view->programList = $this->loadModel('program')->getPairsByList($programList);
$type = $this->config->vision == 'lite' ? 'kanban' : 'stage,sprint,kanban';
if(empty($execution) || strpos($type, $execution->type) === false) return print(js::error($this->lang->notFound) . js::locate('back'));
@@ -2950,7 +2947,7 @@ class execution extends control
$branches = $this->project->getBranchesByProject($executionID);
$linkedProductIdList = empty($branches) ? '' : array_keys($branches);
- $allProducts = $this->config->systemMode == 'classic' ? $this->product->getPairs('noclosed', 0, $linkedProductIdList) : $this->product->getProductPairsByProject($execution->project, 'all', $linkedProductIdList);
+ $allProducts = $this->product->getProductPairsByProject($execution->project, 'all', $linkedProductIdList);
$linkedProducts = $this->product->getProducts($execution->id, 'all', '', true, $linkedProductIdList);
$linkedBranches = array();
$executionStories = $this->project->getStoriesByProject($executionID);
@@ -2985,8 +2982,8 @@ class execution extends control
$this->view->unmodifiableBranches = $unmodifiableBranches;
$this->view->linkedBranches = $linkedBranches;
$this->view->linkedStoryIDList = $linkedStoryIDList;
- $this->view->branchGroups = $this->execution->getBranchByProduct(array_keys($allProducts), $this->config->systemMode == 'new' ? $execution->project : 0, 'ignoreNormal|noclosed');
- $this->view->allBranches = $this->execution->getBranchByProduct(array_keys($allProducts), $this->config->systemMode == 'new' ? $execution->project : 0, 'ignoreNormal');
+ $this->view->branchGroups = $this->execution->getBranchByProduct(array_keys($allProducts), $execution->project, 'ignoreNormal|noclosed');
+ $this->view->allBranches = $this->execution->getBranchByProduct(array_keys($allProducts), $execution->project, 'ignoreNormal');
$this->display();
}
@@ -3474,12 +3471,8 @@ class execution extends control
*/
public function ajaxGetTeamMembers($objectID)
{
- $type = 'execution';
- if($this->config->systemMode == 'new')
- {
- $type = $this->dao->findById($objectID)->from(TABLE_PROJECT)->fetch('type');
- if($type != 'project') $type = 'execution';
- }
+ $type = $this->dao->findById($objectID)->from(TABLE_PROJECT)->fetch('type');
+ if($type != 'project') $type = 'execution';
$users = $this->loadModel('user')->getPairs('nodeleted|noclosed');
$members = $this->user->getTeamMemberPairs($objectID, $type);
@@ -3524,7 +3517,7 @@ class execution extends control
->where('deleted')->eq(0)
->andWhere('type')->in('sprint,stage,kanban')
->beginIF(!$this->app->user->admin)->andWhere('id')->in($this->app->user->view->sprints)->fi()
- ->beginIF($this->config->systemMode == 'new')->andWhere('project')->in(array_keys($projects))->fi()
+ ->andWhere('project')->in(array_keys($projects))
->orderBy('id_desc')
->fetchGroup('project', 'id');
@@ -3534,33 +3527,19 @@ class execution extends control
->fetchGroup('root', 'account');
$projectPairs = array();
- if($this->config->systemMode == 'new')
+ foreach($projects as $project)
{
- foreach($projects as $project)
- {
- $executions = zget($executionGroups, $project->id, array());
- if(isset($project->model) and $project->model == 'waterfall') ksort($executions);
+ $executions = zget($executionGroups, $project->id, array());
+ if(isset($project->model) and $project->model == 'waterfall') ksort($executions);
- foreach($executions as $execution)
- {
- if(isset($orderedExecutions[$execution->parent]) and $project->model != 'waterfall') unset($orderedExecutions[$execution->parent]);
- $execution->teams = zget($teams, $execution->id, array());
- $orderedExecutions[$execution->id] = $execution;
- }
-
- $projectPairs[$project->id] = $project->name;
- }
- }
- else
- {
- foreach($executionGroups as $projectID => $executions)
+ foreach($executions as $execution)
{
- foreach($executions as $execution)
- {
- $execution->teams = zget($teams, $execution->id, array());
- $orderedExecutions[$execution->id] = $execution;
- }
+ if(isset($orderedExecutions[$execution->parent]) and $project->model != 'waterfall') unset($orderedExecutions[$execution->parent]);
+ $execution->teams = zget($teams, $execution->id, array());
+ $orderedExecutions[$execution->id] = $execution;
}
+
+ $projectPairs[$project->id] = $project->name;
}
$projectExecutions = array();
@@ -4010,7 +3989,7 @@ class execution extends control
$projectID = $this->dao->findByID($executionID)->from(TABLE_EXECUTION)->fetch('project');
$planStories = array_keys($planStory);
- if($this->config->systemMode == 'new' and $executionID != $projectID) $this->execution->linkStory($projectID, $planStories, $planProducts);
+ if($executionID != $projectID) $this->execution->linkStory($projectID, $planStories, $planProducts);
$this->execution->linkStory($executionID, $planStories, $planProducts, $extra);
}
@@ -4189,21 +4168,18 @@ class execution extends control
*/
public function ajaxGetProjectStartDate($executionID = 0)
{
- if($this->config->systemMode == 'new')
+ $execution = $this->dao->select('id,project')->from(TABLE_EXECUTION)->where('id')->eq($executionID)->fetch();
+ $project = $this->dao->select('begin,end')->from(TABLE_PROJECT)->where('id')->eq($execution->project)->fetch();
+ if(empty($project))
{
- $execution = $this->dao->select('id,project')->from(TABLE_EXECUTION)->where('id')->eq($executionID)->fetch();
- $project = $this->dao->select('begin,end')->from(TABLE_PROJECT)->where('id')->eq($execution->project)->fetch();
- if(empty($project))
- {
- echo '';
- return false;
- }
-
- $date = array();
- $date['begin'] = $project->begin;
- $date['end'] = $project->end;
- echo json_encode($date);
+ echo '';
+ return false;
}
+
+ $date = array();
+ $date['begin'] = $project->begin;
+ $date['end'] = $project->end;
+ echo json_encode($date);
}
/**
diff --git a/module/execution/lang/zh-cn.php b/module/execution/lang/zh-cn.php
index 87c8b9fac9..027193da13 100644
--- a/module/execution/lang/zh-cn.php
+++ b/module/execution/lang/zh-cn.php
@@ -145,8 +145,7 @@ $lang->execution->estimate = '预计';
$lang->execution->consumed = '消耗';
$lang->execution->left = '剩余';
-if($this->config->systemMode == 'new') $lang->execution->copyTeamTip = "可以选择复制项目或{$lang->execution->common}团队的成员";
-if($this->config->systemMode == 'classic') $lang->execution->copyTeamTip = "可以选择复制{$lang->executionCommon}团队的成员";
+$lang->execution->copyTeamTip = "可以选择复制项目或{$lang->execution->common}团队的成员";
$lang->execution->start = "开始";
$lang->execution->activate = "激活";
@@ -371,8 +370,7 @@ $lang->execution->noMembers = '暂时没有团队成员。';
$lang->execution->workloadTotal = "工作量占比累计不应当超过100, 当前产品下的工作量之和为%s";
// $lang->execution->linkProjectStoryTip = "(关联{$lang->SRCommon}来源于项目下所关联的{$lang->SRCommon})";
$lang->execution->linkAllStoryTip = "(项目下还未关联{$lang->SRCommon},可直接关联该{$lang->execution->common}所关联产品的{$lang->SRCommon})";
-if($config->systemMode == 'classic') $lang->execution->copyTeamTitle = "选择一个{$lang->execution->common}团队";
-if($config->systemMode == 'new') $lang->execution->copyTeamTitle = "选择一个{$lang->project->common}或{$lang->execution->common}团队";
+$lang->execution->copyTeamTitle = "选择一个{$lang->project->common}或{$lang->execution->common}团队";
/* 交互提示。*/
$lang->execution->confirmDelete = "您确定删除{$lang->executionCommon}[%s]吗?";
diff --git a/module/execution/model.php b/module/execution/model.php
index 32b6aaa4e0..8087fd24e3 100644
--- a/module/execution/model.php
+++ b/module/execution/model.php
@@ -92,7 +92,7 @@ class executionModel extends model
$this->session->set('execution', $executionID, $this->app->tab);
/* Unset story, bug, build and testtask if type is ops. */
- if($execution and $execution->type == 'stage' and $this->config->systemMode == 'new')
+ if($execution and $execution->type == 'stage')
{
global $lang;
$this->app->loadLang('project');
@@ -145,31 +145,21 @@ class executionModel extends model
setCookie("lastExecution", $executionID, $this->config->cookieLife, $this->config->webRoot, '', false, true);
$currentExecution = $this->getById($executionID);
- if($this->config->systemMode == 'new')
+ if(isset($currentExecution->type) and $currentExecution->type == 'program') return;
+
+ if($currentExecution->project) $project = $this->loadModel('project')->getByID($currentExecution->project);
+
+ if(isset($project) and $project->model == 'waterfall')
{
- if(isset($currentExecution->type) and $currentExecution->type == 'program') return;
-
- if($currentExecution->project) $project = $this->loadModel('project')->getByID($currentExecution->project);
-
- if(isset($project) and $project->model == 'waterfall')
- {
- $productID = $this->loadModel('product')->getProductIDByProject($project->id);
- $productName = $this->dao->findByID($productID)->from(TABLE_PRODUCT)->fetch('name');
- $currentExecution->name = $productName . '/' . $currentExecution->name;
- }
+ $productID = $this->loadModel('product')->getProductIDByProject($project->id);
+ $productName = $this->dao->findByID($productID)->from(TABLE_PRODUCT)->fetch('name');
+ $currentExecution->name = $productName . '/' . $currentExecution->name;
}
$dropMenuLink = helper::createLink('execution', 'ajaxGetDropMenu', "executionID=$executionID&module=$currentModule&method=$currentMethod&extra=$extra");
$currentExecutionName = '';
if(isset($currentExecution->name)) $currentExecutionName = $currentExecution->name;
- if($this->config->systemMode == 'classic')
- {
- $output = "
";
- }
-
$output = "";
echo "id class='table-nest-icon icon table-nest-toggle'>";
- if($this->config->systemMode == 'new')
- {
- $spanClass = $execution->type == 'stage' ? 'label-warning' : 'label-info';
- echo "{$this->lang->execution->typeList[$execution->type]} ";
- }
+
+ $spanClass = $execution->type == 'stage' ? 'label-warning' : 'label-info';
+ echo "{$this->lang->execution->typeList[$execution->type]} ";
+
if(empty($execution->children))
{
echo html::a(helper::createLink('execution', 'view', "executionID=$execution->id"), $execution->name);
diff --git a/module/execution/view/all.html.php b/module/execution/view/all.html.php
index 715cf14aae..3a5e0c1365 100644
--- a/module/execution/view/all.html.php
+++ b/module/execution/view/all.html.php
@@ -95,8 +95,6 @@ js::set('isCNLang', !$this->loadModel('common')->checkNotCN())
{
if($value->show)
{
- if($config->systemMode == 'classic' and $value->id == 'project') continue;
-
$this->datatable->printHead($value, $orderBy, $vars, $canBatchEdit);
$columns ++;
}
diff --git a/module/execution/view/manageproducts.html.php b/module/execution/view/manageproducts.html.php
index dbe1f2f567..3e0ee44a79 100644
--- a/module/execution/view/manageproducts.html.php
+++ b/module/execution/view/manageproducts.html.php
@@ -53,7 +53,7 @@
- config->systemMode == 'classic' or $execution->grade == 1):?>
+ grade == 1):?>
execution->unlinkedProducts;?>
diff --git a/module/kanban/control.php b/module/kanban/control.php
index ceefd81560..c679094654 100644
--- a/module/kanban/control.php
+++ b/module/kanban/control.php
@@ -1297,16 +1297,8 @@ class kanban extends control
$builds2Imported = array();
$projects = array($this->lang->kanban->allProjects);
- if($this->config->systemMode == 'classic')
- {
- $projects += $this->loadModel('execution')->getPairs();
- $builds2Imported = $this->build->getExecutionBuilds($selectedProjectID, '', '', 't1.date_desc,t1.id_desc', $pager);
- }
- else
- {
- $projects += $this->loadModel('project')->getPairsByProgram('', 'all', false, 'order_asc', 'kanban');
- $builds2Imported = $this->build->getProjectBuilds($selectedProjectID, 'all', 0, 't1.date_desc,t1.id_desc', $pager);
- }
+ $projects += $this->loadModel('project')->getPairsByProgram('', 'all', false, 'order_asc', 'kanban');
+ $builds2Imported = $this->build->getProjectBuilds($selectedProjectID, 'all', 0, 't1.date_desc,t1.id_desc', $pager);
$this->view->projects = $projects;
$this->view->selectedProjectID = $selectedProjectID;
diff --git a/module/kanban/lang/de.php b/module/kanban/lang/de.php
index 55016fdf0b..ba613427d2 100644
--- a/module/kanban/lang/de.php
+++ b/module/kanban/lang/de.php
@@ -84,7 +84,7 @@ $lang->kanban->importRelease = 'Release';
$lang->kanban->importExecution = $lang->execution->common;
$lang->kanban->importBuild = 'Build';
$lang->kanban->allKanban = 'All Kanban';
-$lang->kanban->allProjects = 'All ' . ($this->config->systemMode == 'classic' ? $lang->executionCommon : 'Projects');
+$lang->kanban->allProjects = 'All Projects';
$lang->kanban->allProducts = 'All Products';
$lang->kanban->mine = 'Mine';
$lang->kanban->alignment = 'Alignment';
@@ -124,7 +124,7 @@ $lang->kanban->cardCountTip = 'Please enter the number of cards';
$lang->kanban->selectedKanban = 'Please select Kanban';
$lang->kanban->selectedProduct = 'Please select Product';
-$lang->kanban->selectedProject = 'Please select ' . ($this->config->systemMode == 'classic' ? $lang->executionCommon : 'Project');
+$lang->kanban->selectedProject = 'Please select Project';
$lang->kanban->selectedLane = 'Target Lane';
$lang->kanban->aclGroup['open'] = 'Open';
diff --git a/module/kanban/lang/en.php b/module/kanban/lang/en.php
index de64542c0f..edf3676058 100644
--- a/module/kanban/lang/en.php
+++ b/module/kanban/lang/en.php
@@ -84,7 +84,7 @@ $lang->kanban->importRelease = 'Release';
$lang->kanban->importExecution = $lang->execution->common;
$lang->kanban->importBuild = 'Build';
$lang->kanban->allKanban = 'All Kanban';
-$lang->kanban->allProjects = 'All ' . ($this->config->systemMode == 'classic' ? $lang->executionCommon : 'Projects');
+$lang->kanban->allProjects = 'All Projects';
$lang->kanban->allProducts = 'All Products';
$lang->kanban->mine = 'Mine';
$lang->kanban->alignment = 'Alignment';
@@ -124,7 +124,7 @@ $lang->kanban->cardCountTip = 'Please enter the number of cards';
$lang->kanban->selectedKanban = 'Please select Kanban';
$lang->kanban->selectedProduct = 'Please select Product';
-$lang->kanban->selectedProject = 'Please select ' . ($this->config->systemMode == 'classic' ? $lang->executionCommon : 'Project');
+$lang->kanban->selectedProject = 'Please select Project';
$lang->kanban->selectedLane = 'Target Lane';
$lang->kanban->aclGroup['open'] = 'Open';
diff --git a/module/kanban/lang/fr.php b/module/kanban/lang/fr.php
index 03ac3373b4..306e42a7d0 100644
--- a/module/kanban/lang/fr.php
+++ b/module/kanban/lang/fr.php
@@ -84,7 +84,7 @@ $lang->kanban->importRelease = 'Release';
$lang->kanban->importExecution = $lang->execution->common;
$lang->kanban->importBuild = 'Build';
$lang->kanban->allKanban = 'All Kanban';
-$lang->kanban->allProjects = 'All ' . ($this->config->systemMode == 'classic' ? $lang->executionCommon : 'Projects');
+$lang->kanban->allProjects = 'All Projects';
$lang->kanban->allProducts = 'All Products';
$lang->kanban->mine = 'Mine';
$lang->kanban->alignment = 'Alignment';
@@ -124,7 +124,7 @@ $lang->kanban->cardCountTip = 'Please enter the number of cards';
$lang->kanban->selectedKanban = 'Please select Kanban';
$lang->kanban->selectedProduct = 'Please select Product';
-$lang->kanban->selectedProject = 'Please select ' . ($this->config->systemMode == 'classic' ? $lang->executionCommon : 'Project');
+$lang->kanban->selectedProject = 'Please select Project';
$lang->kanban->selectedLane = 'Target Lane';
$lang->kanban->aclGroup['open'] = 'Open';
diff --git a/module/kanban/lang/zh-cn.php b/module/kanban/lang/zh-cn.php
index 89d62c0633..0c0c68347b 100644
--- a/module/kanban/lang/zh-cn.php
+++ b/module/kanban/lang/zh-cn.php
@@ -84,7 +84,7 @@ $lang->kanban->importRelease = '发布';
$lang->kanban->importExecution = $lang->execution->common;
$lang->kanban->importBuild = '版本';
$lang->kanban->allKanban = '所有看板';
-$lang->kanban->allProjects = '所有' . ($this->config->systemMode == 'classic' ? $lang->executionCommon : '项目');
+$lang->kanban->allProjects = '所有项目';
$lang->kanban->allProducts = '所有产品';
$lang->kanban->mine = '我负责';
$lang->kanban->alignment = '列标题对齐方式';
@@ -124,7 +124,7 @@ $lang->kanban->cardCountTip = '请输入卡片数量';
$lang->kanban->selectedKanban = '请选择看板';
$lang->kanban->selectedProduct = '请选择产品';
-$lang->kanban->selectedProject = '请选择' . ($this->config->systemMode == 'classic' ? $lang->executionCommon : '项目');
+$lang->kanban->selectedProject = '请选择项目';
$lang->kanban->selectedLane = '目标泳道';
$lang->kanban->aclGroup['open'] = '公开';
diff --git a/module/kanban/view/importexecution.html.php b/module/kanban/view/importexecution.html.php
index 6819252b5e..302e56206d 100644
--- a/module/kanban/view/importexecution.html.php
+++ b/module/kanban/view/importexecution.html.php
@@ -23,10 +23,8 @@
- systemMode == 'new'):?>
kanban->selectedProject;?>
-
kanban->selectedLane;?>
@@ -88,9 +86,6 @@
noData;?>
-systemMode == 'classic'):?>
-
-
diff --git a/module/kanban/view/viewarchivedcard.html.php b/module/kanban/view/viewarchivedcard.html.php
index 2c4c142e36..84e8605586 100644
--- a/module/kanban/view/viewarchivedcard.html.php
+++ b/module/kanban/view/viewarchivedcard.html.php
@@ -220,8 +220,7 @@ $(function()
if($item.children('.productplan').length) icon = '';
if($item.children('.release').length) icon = '';
- if($item.children('.execution').length && systemMode == 'new') icon = '';
- if($item.children('.execution').length && systemMode == 'classic') icon = '';
+ if($item.children('.execution').length) icon = '';
$item.children('.cardName').prepend(icon);
});
diff --git a/module/productplan/control.php b/module/productplan/control.php
index 559c0d5c85..8d7aff14c0 100644
--- a/module/productplan/control.php
+++ b/module/productplan/control.php
@@ -792,7 +792,6 @@ class productplan extends control
$pager = new pager($recTotal, $recPerPage, $pageID);
/* Build the search form. */
- if($this->config->systemMode == 'classic') unset($this->config->bug->search['fields']['project']);
$this->config->bug->search['actionURL'] = $this->createLink('productplan', 'view', "planID=$planID&type=bug&orderBy=$orderBy&link=true¶m=" . helper::safe64Encode('&browseType=bySearch&queryID=myQueryID'));
$this->config->bug->search['queryID'] = $queryID;
$this->config->bug->search['style'] = 'simple';
@@ -801,7 +800,7 @@ class productplan extends control
$this->config->bug->search['params']['openedBuild']['values'] = $this->loadModel('build')->getBuildPairs($productID, $branch = 'all', $params = '');
$this->config->bug->search['params']['resolvedBuild']['values'] = $this->build->getBuildPairs($productID, $branch = 'all', $params = '');
$this->config->bug->search['params']['module']['values'] = $this->loadModel('tree')->getOptionMenu($plan->product, 'bug', 0, $plan->branch);
- if($this->config->systemMode == 'new') $this->config->bug->search['params']['project']['values'] = $this->product->getProjectPairsByProduct($productID, $plan->branch);
+ $this->config->bug->search['params']['project']['values'] = $this->product->getProjectPairsByProduct($productID, $plan->branch);
unset($this->config->bug->search['fields']['product']);
if($this->session->currentProductType == 'normal')
diff --git a/module/program/model.php b/module/program/model.php
index ded6984210..1213a2424e 100644
--- a/module/program/model.php
+++ b/module/program/model.php
@@ -581,8 +581,7 @@ class programModel extends model
->andWhere('t1.reviewStatus')->eq('doing')
->fi()
->beginIF($path)->andWhere('t1.path')->like($path . '%')->fi()
- ->beginIF(!$queryAll and !$this->app->user->admin and $this->config->systemMode == 'new')->andWhere('t1.id')->in($this->app->user->view->projects)->fi()
- ->beginIF(!$queryAll and !$this->app->user->admin and $this->config->systemMode == 'classic')->andWhere('t1.id')->in($this->app->user->view->sprints)->fi()
+ ->beginIF(!$queryAll and !$this->app->user->admin)->andWhere('t1.id')->in($this->app->user->view->projects)->fi()
->beginIF($this->cookie->involved or $involved)
->andWhere('t1.openedBy', true)->eq($this->app->user->account)
->orWhere('t1.PM')->eq($this->app->user->account)
diff --git a/module/project/model.php b/module/project/model.php
index e38755458b..344443acfe 100644
--- a/module/project/model.php
+++ b/module/project/model.php
@@ -163,7 +163,7 @@ class projectModel extends model
$project = $this->dao->select('*')->from(TABLE_PROJECT)
->where('id')->eq($projectID)
- ->beginIF($this->config->systemMode == 'new')->andWhere('`type`')->in($type)->fi()
+ ->andWhere('`type`')->in($type)
->fetch();
if(!$project) return false;
@@ -197,12 +197,11 @@ class projectModel extends model
->groupBy('t1.root')
->fetchAll('root');
- $condition = $this->config->systemMode == 'classic' ? 't2.id as project' : 't2.parent as project';
+ $condition = 't2.parent as project';
$estimates = $this->dao->select("$condition, sum(estimate) as estimate")->from(TABLE_TASK)->alias('t1')
->leftJoin(TABLE_PROJECT)->alias('t2')->on('t1.execution = t2.id')
->where('t1.parent')->lt(1)
- ->beginIF($this->config->systemMode == 'new')->andWhere('t2.parent')->in($projectIdList)->fi()
- ->beginIF($this->config->systemMode == 'classic')->andWhere('t2.id')->in($projectIdList)->fi()
+ ->andWhere('t2.parent')->in($projectIdList)
->andWhere('t1.deleted')->eq(0)
->andWhere('t2.deleted')->eq(0)
->groupBy('project')
@@ -895,7 +894,7 @@ class projectModel extends model
$this->config->project->search['params']['parent']['values'] = $programPairs;
if(isset($this->config->setCode) and $this->config->setCode == 0) unset($this->config->project->search['fields']['code'], $this->config->project->search['params']['code']);
- if($this->config->systemMode == 'lite') unset($this->config->project->search['fields']['parent'], $this->config->project->search['params']['parent']);
+ if($this->config->systemMode == 'lean') unset($this->config->project->search['fields']['parent'], $this->config->project->search['params']['parent']);
$this->loadModel('search')->setSearchParams($this->config->project->search);
}
@@ -1231,7 +1230,7 @@ class projectModel extends model
$this->dao->insert(TABLE_TEAM)->data($member)->exec();
$teamMembers[$account] = $member;
}
- if($this->config->systemMode == 'new') $this->loadModel('execution')->addProjectMembers($projectID, $teamMembers);
+ $this->loadModel('execution')->addProjectMembers($projectID, $teamMembers);
$whitelist = explode(',', $project->whitelist);
$this->loadModel('personnel')->updateWhitelist($whitelist, 'project', $projectID);
@@ -2202,9 +2201,9 @@ class projectModel extends model
if(defined('TUTORIAL')) return $this->loadModel('tutorial')->getTeamMembers();
$project = $this->getByID($projectID);
- $type = $this->config->systemMode == 'new' ? $project->type : 'project';
if(empty($project)) return array();
+ $type = $this->config->systemMode == 'new' ? $project->type : 'project';
return $this->dao->select("t1.*, t1.hours * t1.days AS totalHours, t2.id as userID, if(t2.deleted='0', t2.realname, t1.account) as realname")->from(TABLE_TEAM)->alias('t1')
->leftJoin(TABLE_USER)->alias('t2')->on('t1.account = t2.account')
->where('t1.root')->eq((int)$projectID)
@@ -2227,10 +2226,7 @@ class projectModel extends model
if(empty($project)) return array();
$type = 'project';
- if($this->config->systemMode == 'new')
- {
- if($project->type == 'sprint' or $project->type == 'stage' or $project->type == 'kanban') $type = 'execution';
- }
+ if($project->type == 'sprint' or $project->type == 'stage' or $project->type == 'kanban') $type = 'execution';
$members = $this->dao->select("t1.account, if(t2.deleted='0', t2.realname, t1.account) as realname")->from(TABLE_TEAM)->alias('t1')
->leftJoin(TABLE_USER)->alias('t2')->on('t1.account = t2.account')
@@ -2581,7 +2577,7 @@ class projectModel extends model
$menu = '';
$params = "projectID=$project->id";
- $moduleName = $this->config->systemMode == 'classic' ? "execution" : "project";
+ $moduleName = "project";
if($project->status == 'wait' || $project->status == 'suspended')
{
$menu .= $this->buildMenu($moduleName, 'start', $params, $project, 'browse', 'play', '', 'iframe', true);
@@ -2604,14 +2600,14 @@ class projectModel extends model
$from = $project->from == 'project' ? 'project' : 'pgmproject';
$iframe = $this->app->tab == 'program' ? 'iframe' : '';
$onlyBody = $this->app->tab == 'program' ? true : '';
- $dataApp = $this->config->systemMode == 'classic' ? "data-app=execution" : "data-app=project";
+ $dataApp = "data-app=project";
$menu .= $this->buildMenu($moduleName, 'edit', $params, $project, 'browse', 'edit', '', $iframe, $onlyBody, $dataApp);
if($this->config->vision != 'lite')
{
$menu .= $this->buildMenu($moduleName, 'team', $params, $project, 'browse', 'group', '', '', '', $dataApp, $this->lang->execution->team);
- if($this->config->systemMode == 'new') $menu .= $this->buildMenu('project', 'group', "$params&programID={$project->programID}", $project, 'browse', 'lock', '', '', '', $dataApp);
+ $menu .= $this->buildMenu('project', 'group', "$params&programID={$project->programID}", $project, 'browse', 'lock', '', '', '', $dataApp);
if(common::hasPriv($moduleName, 'manageProducts') || common::hasPriv($moduleName, 'whitelist') || common::hasPriv($moduleName, 'delete'))
{
@@ -2619,7 +2615,7 @@ class projectModel extends model
$menu .= "";
$menu .= "";
$menu .= "";
@@ -2628,7 +2624,7 @@ class projectModel extends model
else
{
$menu .= $this->buildMenu($moduleName, 'team', $params, $project, 'browse', 'group', '', '', '', $dataApp, $this->lang->execution->team);
- if($this->config->systemMode == 'new') $menu .= $this->buildMenu('project', 'whitelist', "$params&module=project&from=$from", $project, 'browse', 'shield-check', '', 'btn-action', '', $dataApp);
+ $menu .= $this->buildMenu('project', 'whitelist', "$params&module=project&from=$from", $project, 'browse', 'shield-check', '', 'btn-action', '', $dataApp);
$menu .= $this->buildMenu($moduleName, "delete", $params, $project, 'browse', 'trash', 'hiddenwin', 'btn-action');
}
diff --git a/module/task/control.php b/module/task/control.php
index 8fa8b9b497..60e72764b0 100755
--- a/module/task/control.php
+++ b/module/task/control.php
@@ -291,7 +291,7 @@ class task extends control
/* Set Custom*/
foreach(explode(',', $this->config->task->customCreateFields) as $field) $customFields[$field] = $this->lang->task->$field;
- $executions = $this->config->systemMode == 'classic' ? $executions : $this->execution->getByProject($projectID, 'noclosed', 0, true);
+ $executions = $this->execution->getByProject($projectID, 'noclosed', 0, true);
$testStoryIdList = $this->loadModel('story')->getTestStories(array_keys($stories), $execution->id);
/* Stories that can be used to create test tasks. */
@@ -436,11 +436,8 @@ class task extends control
$modules = $this->loadModel('tree')->getTaskOptionMenu($executionID, 0, 0, $showAllModule ? 'allModule' : '');
/* Set Custom*/
- if($this->config->systemMode == 'new')
- {
- $project = $this->project->getByID($execution->project);
- if($project->model == 'waterfall') $this->config->task->create->requiredFields .= ',estStarted,deadline';
- }
+ $project = $this->project->getByID($execution->project);
+ if($project->model == 'waterfall') $this->config->task->create->requiredFields .= ',estStarted,deadline';
foreach(explode(',', $this->config->task->customBatchCreateFields) as $field)
{
@@ -619,7 +616,7 @@ class task extends control
$this->view->users = $this->loadModel('user')->getPairs('nodeleted|noclosed', "{$this->view->task->openedBy},{$this->view->task->canceledBy},{$this->view->task->closedBy}");
$this->view->showAllModule = isset($this->config->execution->task->allModule) ? $this->config->execution->task->allModule : '';
$this->view->modules = $this->tree->getTaskOptionMenu($this->view->task->execution, 0, 0, $this->view->showAllModule ? 'allModule' : '');
- $this->view->executions = $this->config->systemMode == 'classic' ? $this->execution->getPairs() : $this->execution->getByProject($task->project, 'noclosed', 0, true, false, $task->execution);
+ $this->view->executions = $this->execution->getByProject($task->project, 'noclosed', 0, true, false, $task->execution);
$this->display();
}
@@ -730,11 +727,8 @@ class task extends control
/* Set Custom*/
if(isset($execution))
{
- if($this->config->systemMode == 'new')
- {
- $project = $this->project->getByID($execution->project);
- if($project->model == 'waterfall') $this->config->task->edit->requiredFields .= ',estStarted,deadline';
- }
+ $project = $this->project->getByID($execution->project);
+ if($project->model == 'waterfall') $this->config->task->edit->requiredFields .= ',estStarted,deadline';
foreach(explode(',', $this->config->task->customBatchEditFields) as $field)
{
diff --git a/module/user/model.php b/module/user/model.php
index e779699ede..68a89ddc69 100644
--- a/module/user/model.php
+++ b/module/user/model.php
@@ -1756,7 +1756,7 @@ class userModel extends model
if($allProducts === null) $allProducts = $this->dao->select('id,PO,QD,RD,createdBy,acl,whitelist,program,createdBy')->from(TABLE_PRODUCT)->where('acl')->ne('open')->fetchAll('id');
if($allProjects === null) $allProjects = $this->dao->select('id,PO,PM,QD,RD,acl,type,path,parent,openedBy')->from(TABLE_PROJECT)->where('acl')->ne('open')->andWhere('type')->eq('project')->fetchAll('id');
if($allPrograms === null) $allPrograms = $this->dao->select('id,PO,PM,QD,RD,acl,type,path,parent,openedBy')->from(TABLE_PROGRAM)->where('acl')->ne('open')->andWhere('type')->eq('program')->fetchAll('id');
- if($allSprints === null) $allSprints = $this->dao->select('id,PO,PM,QD,RD,acl,project,path,parent,type,openedBy')->from(TABLE_PROJECT)->where('acl')->eq('private')->beginIF($this->config->systemMode == 'new')->andWhere('type')->in('sprint,stage,kanban')->fi()->fetchAll('id');
+ if($allSprints === null) $allSprints = $this->dao->select('id,PO,PM,QD,RD,acl,project,path,parent,type,openedBy')->from(TABLE_PROJECT)->where('acl')->eq('private')->andWhere('type')->in('sprint,stage,kanban')->fetchAll('id');
/* Get admins. */
$manageObjects = array();
@@ -1938,8 +1938,7 @@ class userModel extends model
$teamGroups = array();
$stmt = $this->dao->select('root,account')->from(TABLE_TEAM)
->where('1=1')
- ->beginIF($this->config->systemMode == 'new')->andWhere('type')->eq('project')->fi()
- ->beginIF($this->config->systemMode == 'classic')->andWhere('type')->eq('execution')->fi()
+ ->andWhere('type')->eq('project')
->andWhere('root')->in(array_keys($projectProducts))
->andWhere('root')->ne(0)
->query();
@@ -2057,8 +2056,8 @@ class userModel extends model
/* Set opened sprints and stages into userview. */
$openedSprints = $this->dao->select('id')->from(TABLE_PROJECT)
->where('acl')->eq('open')
- ->beginIF($this->config->systemMode == 'new')->andWhere('type')->in('sprint,stage,kanban')->fi()
- ->beginIF($this->config->systemMode == 'new')->andWhere('project')->in($userView->projects)->fi()
+ ->andWhere('type')->in('sprint,stage,kanban')
+ ->andWhere('project')->in($userView->projects)
->fetchAll('id');
$openedSprints = join(',', array_keys($openedSprints));
@@ -2516,7 +2515,7 @@ class userModel extends model
}
/* Judge sprint auth. */
- if(($project->type == 'sprint' or $project->type == 'stage' or $project->type == 'kanban') and $project->acl == 'private' and $this->config->systemMode == 'new')
+ if(($project->type == 'sprint' or $project->type == 'stage' or $project->type == 'kanban') and $project->acl == 'private')
{
$parent = $this->dao->select('openedBy,PM')->from(TABLE_PROJECT)->where('id')->eq($project->project)->fetch();
if(empty($parent)) return false;
@@ -2611,7 +2610,7 @@ class userModel extends model
}
/* Judge sprint auth. */
- if(($project->type == 'sprint' || $project->type == 'stage') && $project->acl == 'private' && $this->config->systemMode == 'new')
+ if(($project->type == 'sprint' || $project->type == 'stage') && $project->acl == 'private')
{
$parent = $this->dao->select('openedBy,PM')->from(TABLE_PROJECT)->where('id')->eq($project->project)->fetch();
$users[$parent->openedBy] = $parent->openedBy;
|