From e9acc3834b8164b727e2fc28e026a51fe090d5a2 Mon Sep 17 00:00:00 2001 From: caoyanyi Date: Tue, 9 Apr 2024 10:45:08 +0800 Subject: [PATCH] * Adjust task create repo branch btn style. --- module/task/ui/view.html.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/module/task/ui/view.html.php b/module/task/ui/view.html.php index 0a778265ca..0117027d9a 100644 --- a/module/task/ui/view.html.php +++ b/module/task/ui/view.html.php @@ -37,8 +37,8 @@ foreach($actions as $key => $action) { if(isset($action['url']) && strpos($action['url'], 'createBranch') !== false) { - $hasRepo = common::hasPriv('repo', 'createBranch') && $this->loadModel('repo')->getRepoPairs('execution', $task->execution, false); - if(empty($hasRepo) || !common::hasPriv('repo', 'createBranch') || !common::canModify('execution', $execution)) unset($actions[$key]); + $hasRepo = $this->loadModel('repo')->getRepoPairs('execution', $task->execution, false); + if(empty($hasRepo)) unset($actions[$key]); } if(isset($action['url']) && strpos($action['url'], 'view') !== false && $task->parent == 0) unset($actions[$key]); if(isset($actions[$key]['url']))