From 1fcbef1a7923442e9e5c80a403dad303fe605cf3 Mon Sep 17 00:00:00 2001 From: liyuchun Date: Tue, 29 Mar 2022 13:45:36 +0800 Subject: [PATCH] * Fix bug #13194. --- module/common/model.php | 10 ++++++++++ module/tutorial/view/index.html.php | 1 - 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/module/common/model.php b/module/common/model.php index 8991412729..a7c28e4ec8 100644 --- a/module/common/model.php +++ b/module/common/model.php @@ -2279,6 +2279,16 @@ EOD; $module = strtolower($module); $method = strtolower($method); + /* If the user is doing a tutorial, have all tutorial privs. */ + if(defined('TUTORIAL')) + { + $app->loadLang('tutorial'); + foreach($lang->tutorial->tasks as $task) + { + if($task['nav']['module'] == $module and $task['nav']['method'] = $method) return true; + } + } + /* Check the parent object is closed. */ if(!empty($method) and strpos('close|batchclose', $method) === false and !commonModel::canBeChanged($module, $object)) return false; diff --git a/module/tutorial/view/index.html.php b/module/tutorial/view/index.html.php index 454c6edcf4..f0136f8685 100644 --- a/module/tutorial/view/index.html.php +++ b/module/tutorial/view/index.html.php @@ -76,7 +76,6 @@