From 2e2dc5581b0bbc91b7004845001623b6d23d9af5 Mon Sep 17 00:00:00 2001 From: tanghucheng Date: Mon, 24 Jan 2022 16:48:06 +0800 Subject: [PATCH] * fix project index and global create card. --- module/block/control.php | 4 ++++ module/task/control.php | 4 +++- module/task/view/create.html.php | 2 +- 3 files changed, 8 insertions(+), 2 deletions(-) diff --git a/module/block/control.php b/module/block/control.php index 7265816bdf..1b1d60e25f 100644 --- a/module/block/control.php +++ b/module/block/control.php @@ -274,6 +274,10 @@ class block extends control { $block->moreLink = $this->createLink('project', 'dynamic', "projectID=$projectID&type=all"); } + elseif($moduleName == 'project' and $method == 'execution') + { + $block->moreLink = $this->createLink('project', 'execution', "status=all&projectID=$projectID"); + } elseif($moduleName == 'project' and $method == 'testtask') { $block->moreLink = $this->createLink('project', 'testtask', "projectID=$projectID"); diff --git a/module/task/control.php b/module/task/control.php index d7f6a99608..50f9007b47 100644 --- a/module/task/control.php +++ b/module/task/control.php @@ -223,6 +223,8 @@ class task extends control $position[] = $this->lang->task->common; $position[] = $this->lang->task->create; + $projectID = $execution ? $execution->project : 0; + /* Set Custom*/ foreach(explode(',', $this->config->task->customCreateFields) as $field) $customFields[$field] = $this->lang->task->$field; if($execution->type == 'ops') unset($customFields['story']); @@ -235,7 +237,7 @@ class task extends control $this->view->position = $position; $this->view->gobackLink = (isset($output['from']) and $output['from'] == 'global') ? $this->createLink('execution', 'task', "executionID=$executionID") : ''; $this->view->execution = $execution; - $this->view->executions = $this->config->systemMode == 'classic' ? $executions : $this->execution->getByProject(0, 'all', 0, true); + $this->view->executions = $this->config->systemMode == 'classic' ? $executions : $this->execution->getByProject($projectID, 'all', 0, true); $this->view->task = $task; $this->view->users = $users; $this->view->storyID = $storyID; diff --git a/module/task/view/create.html.php b/module/task/view/create.html.php index d161c2f6f0..d269a0193a 100644 --- a/module/task/view/create.html.php +++ b/module/task/view/create.html.php @@ -35,7 +35,7 @@ ?>
- type != 'kanban'):?> + type != 'kanban' or $this->config->vision == 'lite'):?>
task->execution;?> id, "class='form-control chosen' onchange='loadAll(this.value)' required");?>