diff --git a/db/update17.6.1.sql b/db/update17.6.1.sql index f47a93a119..9212dea25a 100644 --- a/db/update17.6.1.sql +++ b/db/update17.6.1.sql @@ -1 +1 @@ -ALTER table `zt_project` ADD `noSprint` enum('0', '1') NOT NULL DEFAULT '0'; +ALTER table `zt_project` ADD `multiple` enum('0', '1') NOT NULL DEFAULT '1'; diff --git a/db/zentao.sql b/db/zentao.sql index ac8c8e6aa5..62923fcfeb 100755 --- a/db/zentao.sql +++ b/db/zentao.sql @@ -1193,7 +1193,7 @@ CREATE TABLE IF NOT EXISTS `zt_project` ( `vision` varchar(10) NOT NULL DEFAULT 'rnd', `displayCards` smallint(6) NOT NULL default '0', `fluidBoard` enum('0','1') NOT NULL DEFAULT '0', - `noSprint` enum('0','1') NOT NULL DEFAULT '0', + `multiple` enum('0','1') NOT NULL DEFAULT '1', `deleted` enum('0','1') NOT NULL DEFAULT '0', PRIMARY KEY (`id`), KEY `parent` (`parent`), diff --git a/framework/router.class.php b/framework/router.class.php index 1efaa3d059..7c62ef8e30 100755 --- a/framework/router.class.php +++ b/framework/router.class.php @@ -171,7 +171,7 @@ class router extends baseRouter try { - $commonSettings = $this->dbh->query('SELECT section, `key`, value FROM' . TABLE_CONFIG . "WHERE `owner`='system' AND (`module`='custom' or `module`='common') and `key` in ('sprintConcept', 'hourPoint', 'URSR', 'mode', 'URAndSR', 'scoreStatus', 'projectMode')")->fetchAll(); + $commonSettings = $this->dbh->query('SELECT section, `key`, value FROM' . TABLE_CONFIG . "WHERE `owner`='system' AND (`module`='custom' or `module`='common') and `key` in ('sprintConcept', 'hourPoint', 'URSR', 'mode', 'URAndSR', 'scoreStatus')")->fetchAll(); } catch (PDOException $exception) { @@ -187,14 +187,12 @@ class router extends baseRouter foreach($commonSettings as $setting) { - if($setting->key == 'sprintConcept') $projectKey = $setting->value; - if($setting->key == 'hourPoint') $hourKey = $setting->value; - if($setting->key == 'URSR') $URSR = $setting->value; - if($setting->key == 'URAndSR') $URAndSR = $setting->value; - if($setting->key == 'mode' and $setting->section == 'global') $mode = $setting->value; - if($setting->key == 'scoreStatus' and $setting->section == 'global') $score = $setting->value; - - if($setting->key == 'projectMode' && $setting->section == 'global') $config->projectMode = $setting->value; + if($setting->key == 'sprintConcept') $projectKey = $setting->value; + if($setting->key == 'hourPoint') $hourKey = $setting->value; + if($setting->key == 'URSR') $URSR = $setting->value; + if($setting->key == 'URAndSR') $URAndSR = $setting->value; + if($setting->key == 'mode' and $setting->section == 'global') $mode = $setting->value; + if($setting->key == 'scoreStatus' and $setting->section == 'global') $score = $setting->value; } /* Lite Version is compatible with classic modes */ diff --git a/module/block/lang/de.php b/module/block/lang/de.php index 6f30292284..98659639c3 100644 --- a/module/block/lang/de.php +++ b/module/block/lang/de.php @@ -322,11 +322,8 @@ $lang->block->default['full']['my']['10']['title'] = 'Project List'; $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(!isset($config->projectMode) || $config->projectMode != 'noSprint') -{ - $lang->block->default['full']['my']['10']['block'] = 'project'; - $lang->block->default['full']['my']['10']['source'] = 'project'; -} +$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'; @@ -353,11 +350,11 @@ $lang->block->availableBlocks->issue = 'My Issues'; $lang->block->availableBlocks->meeting = 'My Meetings'; $lang->block->availableBlocks->feedback = 'My Feedbacks'; -$lang->block->moduleList['product'] = $lang->productCommon; -$lang->block->moduleList['project'] = 'Project'; -if(!isset($config->projectMode) || $config->projectMode != 'noSprint') $lang->block->moduleList['execution'] = $lang->execution->common; -$lang->block->moduleList['qa'] = 'QA'; -$lang->block->moduleList['todo'] = 'Todos'; +$lang->block->moduleList['product'] = $lang->productCommon; +$lang->block->moduleList['project'] = 'Project'; +$lang->block->moduleList['execution'] = $lang->execution->common; +$lang->block->moduleList['qa'] = 'QA'; +$lang->block->moduleList['todo'] = 'Todos'; $lang->block->modules['project'] = new stdclass(); $lang->block->modules['project']->availableBlocks = new stdclass(); diff --git a/module/block/lang/en.php b/module/block/lang/en.php index b085a9443e..00061bc057 100644 --- a/module/block/lang/en.php +++ b/module/block/lang/en.php @@ -322,11 +322,8 @@ $lang->block->default['full']['my']['10']['title'] = 'Project List'; $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(!isset($config->projectMode) || $config->projectMode != 'noSprint') -{ - $lang->block->default['full']['my']['10']['block'] = 'execution'; - $lang->block->default['full']['my']['10']['source'] = 'execution'; -} +$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'; @@ -353,11 +350,11 @@ $lang->block->availableBlocks->issue = 'Issues'; $lang->block->availableBlocks->meeting = 'Meetings'; $lang->block->availableBlocks->feedback = 'My Feedbacks'; -$lang->block->moduleList['product'] = $lang->productCommon; -$lang->block->moduleList['project'] = 'Project'; -if(!isset($config->projectMode) || $config->projectMode != 'noSprint') $lang->block->moduleList['execution'] = $lang->execution->common; -$lang->block->moduleList['qa'] = 'Test'; -$lang->block->moduleList['todo'] = 'Todo'; +$lang->block->moduleList['product'] = $lang->productCommon; +$lang->block->moduleList['project'] = 'Project'; +$lang->block->moduleList['execution'] = $lang->execution->common; +$lang->block->moduleList['qa'] = 'Test'; +$lang->block->moduleList['todo'] = 'Todo'; $lang->block->modules['project'] = new stdclass(); $lang->block->modules['project']->availableBlocks = new stdclass(); diff --git a/module/block/lang/fr.php b/module/block/lang/fr.php index 9b6c1e8db1..cec285f8f3 100644 --- a/module/block/lang/fr.php +++ b/module/block/lang/fr.php @@ -322,11 +322,8 @@ $lang->block->default['full']['my']['10']['title'] = 'Project List'; $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(!isset($config->projectMode) || $config->projectMode != 'noSprint') -{ - $lang->block->default['full']['my']['10']['block'] = 'project'; - $lang->block->default['full']['my']['10']['source'] = 'project'; -} +$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'; @@ -353,11 +350,11 @@ $lang->block->availableBlocks->issue = 'My Issues'; $lang->block->availableBlocks->meeting = 'My Meetings'; $lang->block->availableBlocks->feedback = 'My Feedbacks'; -$lang->block->moduleList['product'] = $lang->productCommon; -$lang->block->moduleList['project'] = 'Project'; -if(!isset($config->projectMode) || $config->projectMode != 'noSprint') $lang->block->moduleList['execution'] = $lang->execution->common; -$lang->block->moduleList['qa'] = 'Test'; -$lang->block->moduleList['todo'] = 'Todo'; +$lang->block->moduleList['product'] = $lang->productCommon; +$lang->block->moduleList['project'] = 'Project'; +$lang->block->moduleList['execution'] = $lang->execution->common; +$lang->block->moduleList['qa'] = 'Test'; +$lang->block->moduleList['todo'] = 'Todo'; $lang->block->modules['project'] = new stdclass(); $lang->block->modules['project']->availableBlocks = new stdclass(); diff --git a/module/block/lang/zh-cn.php b/module/block/lang/zh-cn.php index 2a4ac76a7a..e17f727749 100644 --- a/module/block/lang/zh-cn.php +++ b/module/block/lang/zh-cn.php @@ -322,11 +322,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(!isset($config->projectMode) || $config->projectMode != 'noSprint') -{ - $lang->block->default['full']['my']['10']['block'] = 'execution'; - $lang->block->default['full']['my']['10']['source'] = 'execution'; -} +$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'; @@ -353,11 +350,11 @@ $lang->block->availableBlocks->issue = '问题'; $lang->block->availableBlocks->meeting = '会议'; $lang->block->availableBlocks->feedback = '反馈'; -$lang->block->moduleList['product'] = $lang->productCommon; -$lang->block->moduleList['project'] = '项目'; -if(!isset($config->projectMode) || $config->projectMode != 'noSprint') $lang->block->moduleList['execution'] = $lang->execution->common; -$lang->block->moduleList['qa'] = '测试'; -$lang->block->moduleList['todo'] = '待办'; +$lang->block->moduleList['product'] = $lang->productCommon; +$lang->block->moduleList['project'] = '项目'; +$lang->block->moduleList['execution'] = $lang->execution->common; +$lang->block->moduleList['qa'] = '测试'; +$lang->block->moduleList['todo'] = '待办'; $lang->block->modules['project'] = new stdclass(); $lang->block->modules['project']->availableBlocks = new stdclass(); diff --git a/module/block/model.php b/module/block/model.php index 29a9538e3e..347ed7c0ea 100644 --- a/module/block/model.php +++ b/module/block/model.php @@ -137,7 +137,6 @@ class blockModel extends model ->andWhere('vision')->eq($this->config->vision) ->andWhere('hidden')->eq(0) ->beginIF($type)->andWhere('type')->eq($type)->fi() - ->beginIF(isset($this->config->projectMode) && $this->config->projectMode == 'noSprint')->andWhere('source')->ne('execution')->fi() ->orderBy('`order`') ->fetchAll('id'); } diff --git a/module/bug/view/create.html.php b/module/bug/view/create.html.php index 418c3668fa..b4f5b1a0a2 100644 --- a/module/bug/view/create.html.php +++ b/module/bug/view/create.html.php @@ -78,7 +78,6 @@ if($this->app->tab == 'project') js::set('objectID', $projectID); - projectMode) and $config->projectMode == 'noSprint');?> bug->project : $lang->bug->type;?> @@ -111,7 +110,6 @@ if($this->app->tab == 'project') js::set('objectID', $projectID); -
@@ -123,11 +121,6 @@ if($this->app->tab == 'project') js::set('objectID', $projectID);
- -
- -
- diff --git a/module/common/lang/menu.php b/module/common/lang/menu.php index 76448e4f92..7e4a430107 100644 --- a/module/common/lang/menu.php +++ b/module/common/lang/menu.php @@ -62,7 +62,6 @@ $lang->mainNav->menuOrder[55] = 'system'; $lang->mainNav->menuOrder[60] = 'admin'; if($config->systemMode == 'lean') unset($lang->mainNav->program, $lang->mainNav->menuOrder[10]); -if(isset($config->projectMode) and $config->projectMode == 'noSprint') unset($lang->mainNav->execution, $lang->mainNav->menuOrder[25]); /* My menu. */ $lang->my->menu = new stdclass(); @@ -89,7 +88,6 @@ $lang->my->menuOrder[45] = 'score'; $lang->my->menuOrder[50] = 'contacts'; if(!$config->systemScore) unset($lang->my->menu->score, $lang->my->menuOrder[45]); -if(isset($config->projectMode) and $config->projectMode == 'noSprint') unset($lang->my->menu->execution, $lang->my->menuOrder[30]); $lang->my->menu->work['subMenu'] = new stdclass(); $lang->my->menu->work['subMenu']->task = array('link' => "{$lang->task->common}|my|work|mode=task", 'subModule' => 'task'); @@ -377,45 +375,45 @@ $lang->execution->menu->settings['subMenu']->whitelist = array('link' => "$lang- $lang->execution->dividerMenu = ',story,build,'; -$lang->noSprint = new stdclass(); -$lang->noSprint->scrum = new stdclass(); -$lang->noSprint->scrum->menu = new stdclass(); -$lang->noSprint->scrum->menu->task = $lang->execution->menu->task; -$lang->noSprint->scrum->menu->kanban = $lang->execution->menu->kanban; -$lang->noSprint->scrum->menu->burn = $lang->execution->menu->burn; -$lang->noSprint->scrum->menu->view = $lang->execution->menu->view; -$lang->noSprint->scrum->menu->story = $lang->execution->menu->story; -$lang->noSprint->scrum->menu->qa = $lang->scrum->menu->qa; -$lang->noSprint->scrum->menu->devops = $lang->scrum->menu->devops; -$lang->noSprint->scrum->menu->doc = $lang->scrum->menu->doc; -$lang->noSprint->scrum->menu->build = $lang->scrum->menu->build; -$lang->noSprint->scrum->menu->dynamic = $lang->scrum->menu->dynamic; -$lang->noSprint->scrum->menu->settings = $lang->scrum->menu->settings; +$lang->project->noMultiple = new stdclass(); +$lang->project->noMultiple->scrum = new stdclass(); +$lang->project->noMultiple->scrum->menu = new stdclass(); +$lang->project->noMultiple->scrum->menu->task = $lang->execution->menu->task; +$lang->project->noMultiple->scrum->menu->kanban = $lang->execution->menu->kanban; +$lang->project->noMultiple->scrum->menu->burn = $lang->execution->menu->burn; +$lang->project->noMultiple->scrum->menu->view = $lang->execution->menu->view; +$lang->project->noMultiple->scrum->menu->story = $lang->execution->menu->story; +$lang->project->noMultiple->scrum->menu->qa = $lang->scrum->menu->qa; +$lang->project->noMultiple->scrum->menu->devops = $lang->scrum->menu->devops; +$lang->project->noMultiple->scrum->menu->doc = $lang->scrum->menu->doc; +$lang->project->noMultiple->scrum->menu->build = $lang->scrum->menu->build; +$lang->project->noMultiple->scrum->menu->dynamic = $lang->scrum->menu->dynamic; +$lang->project->noMultiple->scrum->menu->settings = $lang->scrum->menu->settings; -$lang->noSprint->kanban = new stdclass(); -$lang->noSprint->kanban->menu = new stdclass(); -$lang->noSprint->kanban->menu->kanban = array('link' => "{$lang->kanban->common}|execution|kanban|executionID=%s"); -$lang->noSprint->kanban->menu->build = $lang->kanbanProject->menu->build; -$lang->noSprint->kanban->menu->settings = $lang->kanbanProject->menu->settings; +$lang->project->noMultiple->kanban = new stdclass(); +$lang->project->noMultiple->kanban->menu = new stdclass(); +$lang->project->noMultiple->kanban->menu->kanban = array('link' => "{$lang->kanban->common}|execution|kanban|executionID=%s"); +$lang->project->noMultiple->kanban->menu->build = $lang->kanbanProject->menu->build; +$lang->project->noMultiple->kanban->menu->settings = $lang->kanbanProject->menu->settings; -$lang->noSprint->scrum->dividerMenu = ',story,build,'; -$lang->noSprint->kanban->dividerMenu = ''; +$lang->project->noMultiple->scrum->dividerMenu = ',story,build,'; +$lang->project->noMultiple->kanban->dividerMenu = ''; -$lang->noSprint->scrum->menuOrder[5] = 'task'; -$lang->noSprint->scrum->menuOrder[10] = 'kanban'; -$lang->noSprint->scrum->menuOrder[15] = 'burn'; -$lang->noSprint->scrum->menuOrder[20] = 'view'; -$lang->noSprint->scrum->menuOrder[25] = 'story'; -$lang->noSprint->scrum->menuOrder[30] = 'qa'; -$lang->noSprint->scrum->menuOrder[35] = 'devops'; -$lang->noSprint->scrum->menuOrder[40] = 'doc'; -$lang->noSprint->scrum->menuOrder[45] = 'build'; -$lang->noSprint->scrum->menuOrder[50] = 'dynamic'; -$lang->noSprint->scrum->menuOrder[55] = 'settings'; +$lang->project->noMultiple->scrum->menuOrder[5] = 'task'; +$lang->project->noMultiple->scrum->menuOrder[10] = 'kanban'; +$lang->project->noMultiple->scrum->menuOrder[15] = 'burn'; +$lang->project->noMultiple->scrum->menuOrder[20] = 'view'; +$lang->project->noMultiple->scrum->menuOrder[25] = 'story'; +$lang->project->noMultiple->scrum->menuOrder[30] = 'qa'; +$lang->project->noMultiple->scrum->menuOrder[35] = 'devops'; +$lang->project->noMultiple->scrum->menuOrder[40] = 'doc'; +$lang->project->noMultiple->scrum->menuOrder[45] = 'build'; +$lang->project->noMultiple->scrum->menuOrder[50] = 'dynamic'; +$lang->project->noMultiple->scrum->menuOrder[55] = 'settings'; -$lang->noSprint->kanban->menuOrder[5] = 'kanban'; -$lang->noSprint->kanban->menuOrder[10] = 'build'; -$lang->noSprint->kanban->menuOrder[15] = 'settings'; +$lang->project->noMultiple->kanban->menuOrder[5] = 'kanban'; +$lang->project->noMultiple->kanban->menuOrder[10] = 'build'; +$lang->project->noMultiple->kanban->menuOrder[15] = 'settings'; /* QA menu.*/ $lang->qa->menu = new stdclass(); @@ -500,13 +498,11 @@ $lang->doc->menuOrder[30] = 'project'; $lang->doc->menuOrder[35] = 'execution'; $lang->doc->menuOrder[36] = 'api'; $lang->doc->menuOrder[40] = 'custom'; -if(isset($config->projectMode) and $config->projectMode == 'noSprint') unset($lang->doc->menu->execution, $lang->doc->menuOrder[35]); $lang->doc->menu->product['subMenu'] = new stdclass(); $lang->doc->menu->project['subMenu'] = new stdclass(); $lang->doc->menu->execution['subMenu'] = new stdclass(); $lang->doc->menu->custom['subMenu'] = new stdclass(); -if(isset($config->projectMode) and $config->projectMode == 'noSprint') unset($lang->doc->menu->execution['subMenu']); $lang->doc->menu->api['subMenu'] = new stdclass(); $lang->doc->menu->api['subMenu']->index = array('link' => "{$lang->doc->apiDoc}|api|index|libID=%s", 'alias' => 'create,edit'); diff --git a/module/common/model.php b/module/common/model.php index bfc9312ab0..a937aea4a5 100644 --- a/module/common/model.php +++ b/module/common/model.php @@ -613,7 +613,6 @@ class commonModel extends model if($config->edition == 'open') unset($lang->createIcons['effort']); if($config->systemMode != 'new') unset($lang->createIcons['program']); - if(!isset($config->projectMode) || $config->projectMode == 'noSprint') unset($lang->createIcons['execution']); /* Check whether the creation permission is available, and print create buttons. */ @@ -1240,7 +1239,6 @@ class commonModel extends model $searchObjects = $lang->searchObjects; if($config->systemMode != 'new') unset($searchObjects['program']); - if(!isset($config->projectMode) || $config->projectMode == 'noSprint') unset($searchObjects['execution']); foreach($searchObjects as $key => $value) { diff --git a/module/custom/control.php b/module/custom/control.php index 10951d3871..e383c0c981 100644 --- a/module/custom/control.php +++ b/module/custom/control.php @@ -640,7 +640,6 @@ class custom extends control /* 只有没有关联项目集的产品和项目关联到默认项目集下. */ $this->loadModel('upgrade')->relationDefaultProgram($program); - if($mode == 'new') $this->loadModel('setting')->deleteItems('owner=system&module=common§ion=global&key=projectMode'); if($mode == 'lean') $this->custom->processProjectAcl(); return $this->send(array('result' => 'success', 'message' => $this->lang->saveSuccess, 'locate' => 'top')); diff --git a/module/execution/control.php b/module/execution/control.php index dc21336b3a..f82083527a 100644 --- a/module/execution/control.php +++ b/module/execution/control.php @@ -139,7 +139,7 @@ class execution extends control $recentExecutions = array_unique($recentExecutions); $recentExecutions = array_slice($recentExecutions, 0, 5); $recentExecutions = join(',', $recentExecutions); - if($this->session->noSprint) + if(!$this->session->multiple) { if(!isset($this->config->execution->recentExecutions) or $this->config->execution->recentExecutions != $recentExecutions) $this->setting->updateItem($this->app->user->account . 'common.execution.recentExecutions', $recentExecutions); if(!isset($this->config->execution->lastExecution) or $this->config->execution->lastExecution != $executionID) $this->setting->updateItem($this->app->user->account . 'common.execution.lastExecution', $executionID); @@ -3129,7 +3129,7 @@ class execution extends control $products = $this->product->getProducts($objectID); $queryID = ($browseType == 'bySearch') ? (int)$param : 0; $browseLink = $this->session->executionStoryList; - if($this->app->tab == 'project' and empty($object->noSprint)) $browseLink = $this->createLink('projectstory', 'story', "objectID=$objectID"); + if($this->app->tab == 'project' and $object->multiple) $browseLink = $this->createLink('projectstory', 'story', "objectID=$objectID"); $this->session->set('storyList', $this->app->getURI(true), $this->app->tab); // Save session. @@ -3517,7 +3517,7 @@ class execution extends control $projects = $this->loadModel('program')->getProjectList(0, 'all', 0, 'order_asc', null, 0, 0, true); $executionGroups = $this->dao->select('*')->from(TABLE_EXECUTION) ->where('deleted')->eq(0) - ->andWhere('noSprint')->eq('0') + ->andWhere('multiple')->eq('1') ->andWhere('type')->in('sprint,stage,kanban') ->beginIF(!$this->app->user->admin)->andWhere('id')->in($this->app->user->view->sprints)->fi() ->andWhere('project')->in(array_keys($projects)) diff --git a/module/execution/model.php b/module/execution/model.php index 06532cc23c..25743654d4 100644 --- a/module/execution/model.php +++ b/module/execution/model.php @@ -123,7 +123,7 @@ class executionModel extends model $this->lang->switcherMenu = $this->getSwitcher($executionID, $this->app->rawModule, $this->app->rawMethod); common::setMenuVars('execution', $executionID); - $this->loadModel('project')->setNoSprintMenu($executionID); + $this->loadModel('project')->setNoMultipleMenu($executionID); } /** @@ -1268,7 +1268,7 @@ class executionModel extends model $executions = $this->dao->select('*, IF(INSTR("done,closed", status) < 2, 0, 1) AS isDone, INSTR("doing,wait,suspended,closed", status) AS sortStatus')->from(TABLE_EXECUTION) ->where('deleted')->eq(0) ->andWhere('vision')->eq($this->config->vision) - ->beginIF($this->session->noSprint and $this->app->tab == 'execution')->andWhere('noSprint')->eq('0')->fi() + ->beginIF(!$this->session->multiple and $this->app->tab == 'execution')->andWhere('multiple')->eq('1')->fi() ->beginIF($type == 'all')->andWhere('type')->in('stage,sprint,kanban')->fi() ->beginIF($projectID)->andWhere('project')->eq($projectID)->fi() ->beginIF($type != 'all')->andWhere('type')->eq($type)->fi() @@ -1488,7 +1488,7 @@ class executionModel extends model ->where('t1.type')->in('sprint,stage,kanban') ->andWhere('t1.deleted')->eq('0') ->andWhere('t1.vision')->eq($this->config->vision) - ->andWhere('t1.noSprint')->eq('0') + ->andWhere('t1.multiple')->eq('1') ->beginIF(!$this->app->user->admin)->andWhere('t1.id')->in($this->app->user->view->sprints)->fi() ->beginIF(!empty($executionQuery))->andWhere($executionQuery)->fi() ->beginIF($productID)->andWhere('t3.product')->eq($productID)->fi() @@ -4966,7 +4966,7 @@ class executionModel extends model $_POST['QD'] = ''; $_POST['PM'] = ''; $_POST['RD'] = ''; - $_POST['noSprint'] = 1; + $_POST['multiple'] = '0'; $executionID = $this->create(); if($project->model == 'kanban') diff --git a/module/execution/view/kanban.html.php b/module/execution/view/kanban.html.php index 61e559e878..65a1d2a4db 100644 --- a/module/execution/view/kanban.html.php +++ b/module/execution/view/kanban.html.php @@ -157,13 +157,13 @@ js::set('priv', echo html::a('javascript:toggleRDSearchBox()', " " . $lang->searchAB, '', "class='btn btn-link querybox-toggle'"); echo html::a('javascript:fullScreen()', " " . $lang->kanban->fullScreen, '', "class='btn btn-link'"); if(common::hasPriv('execution', 'setKanban')) echo html::a(helper::createLink('execution', 'setKanban', "executionID=$execution->id", '', true), ' ' . $lang->settings, '', "class='iframe btn btn-link text-left' data-width='$width'"); - if($execution->noSprint && common::hasPriv('project', 'edit')) $editURL = helper::createLink('project', 'edit', "projectID=$execution->project", '', true); - if(!$execution->noSprint && common::hasPriv('execution', 'edit')) $editURL = helper::createLink('execution', 'edit', "executionID=$execution->id", '', true); + if(!$execution->multiple and common::hasPriv('project', 'edit')) $editURL = helper::createLink('project', 'edit', "projectID=$execution->project", '', true); + if($execution->multiple and common::hasPriv('execution', 'edit')) $editURL = helper::createLink('execution', 'edit', "executionID=$execution->id", '', true); if(!empty($editURL)) echo html::a($editURL, ' ' . $lang->edit, '', "class='iframe btn btn-link text-left' data-width='80%'"); $actions = ''; $printSettingBtn = (common::hasPriv('execution', 'close') or common::hasPriv('execution', 'delete') or !empty($executionActions)); - if($printSettingBtn && !$execution->noSprint) + if($printSettingBtn and $execution->multiple) { $actions .= "