From 7c99a6153d7770ea86133bccdf8fab7ab09cd675 Mon Sep 17 00:00:00 2001 From: Zongjun Lan Date: Tue, 29 Mar 2022 16:11:21 +0800 Subject: [PATCH 1/2] * fix bug gantt --- .../lite/execution/ext/lang/zh-cn/lite.php | 1 - extension/lite/execution/ext/model/lite.php | 19 +++++++++++++------ module/user/view/deny.html.php | 2 ++ 3 files changed, 15 insertions(+), 7 deletions(-) diff --git a/extension/lite/execution/ext/lang/zh-cn/lite.php b/extension/lite/execution/ext/lang/zh-cn/lite.php index 9b74698b2e..268f3efa1b 100644 --- a/extension/lite/execution/ext/lang/zh-cn/lite.php +++ b/extension/lite/execution/ext/lang/zh-cn/lite.php @@ -25,4 +25,3 @@ $lang->execution->icons['grouptask'] = 'sitemap'; $lang->execution->aclList['private'] = "私有(团队成员和项目负责人可访问)"; $lang->execution->common = '项目看板'; -$lang->execution->gantt = '甘特图'; \ No newline at end of file diff --git a/extension/lite/execution/ext/model/lite.php b/extension/lite/execution/ext/model/lite.php index 6322bdbdec..c30cfcba32 100644 --- a/extension/lite/execution/ext/model/lite.php +++ b/extension/lite/execution/ext/model/lite.php @@ -127,13 +127,20 @@ public function getTRActions($currentMethod) foreach($subMenu as $key => $value) { - $tmpValue = explode('|', $value['link']); - $subMenu->{$key}['name'] = $tmpValue[0]; - $subMenu->{$key}['module'] = $tmpValue[1]; - $subMenu->{$key}['method'] = $tmpValue[2]; - $subMenu->{$key}['vars'] = $tmpValue[3]; + if(common::hasPriv('execution', $key)) + { + $tmpValue = explode('|', $value['link']); + $subMenu->{$key}['name'] = $tmpValue[0]; + $subMenu->{$key}['module'] = $tmpValue[1]; + $subMenu->{$key}['method'] = $tmpValue[2]; + $subMenu->{$key}['vars'] = $tmpValue[3]; + } + else + { + unset($subMenu->$key); + } } - + $TRActions = ''; $TRActions .= "
+ cookie->kanbanview) + { + $kanbanview = $this->cookie->kanbanview; + } + else + { + foreach (explode('|', 'kanban|task|calendar|gantt|tree|grouptask') as $view) + { + if(common::hasPriv('execution', $view)) $kanbanview = 'kanban'; + } + } + ?> $kanban):?> -
cookie->kanbanview ? $this->cookie->kanbanview : 'kanban', "kanbanID=$kanban->id");?>'> +
id");?>'>
execution->statusList, $kanban->status);?>