diff --git a/public/main/gradebook/lib/be/category.class.php b/public/main/gradebook/lib/be/category.class.php index eef0f996ae5..eb39341db84 100644 --- a/public/main/gradebook/lib/be/category.class.php +++ b/public/main/gradebook/lib/be/category.class.php @@ -2012,7 +2012,6 @@ public static function generateUserCertificate( bool $sendNotification = false, bool $skipGenerationIfExists = false ) { - $user_id = (int) $user_id; $categoryId = $category->getId(); $sessionId = $category->getSession() ? $category->getSession()->getId() : 0; $courseId = $category->getCourse()->getId(); diff --git a/public/main/lp/learnpath.class.php b/public/main/lp/learnpath.class.php index 5a1c9e64ab3..6530b7479f9 100644 --- a/public/main/lp/learnpath.class.php +++ b/public/main/lp/learnpath.class.php @@ -4356,211 +4356,197 @@ public function showBuildSideBar($updateAudio = false, $dropElementHere = false, $ajax_url = api_get_path(WEB_AJAX_PATH).'lp.ajax.php?lp_id='.$this->get_id().'&'.api_get_cidreq(); $content = ' - '; + }); + }); + '; $content .= " - "; + "; $content .= $this->return_new_tree($updateAudio, $dropElementHere); $documentId = isset($_GET['path_item']) ? (int) $_GET['path_item'] : 0; @@ -4657,11 +4643,18 @@ public function getBuildTree($noWrapper = false, $dropElement = false): string return ''; }, 'childOpen' => function($child) { - $id = $child['iid']; + $id = $child['iid']; + $type = $child['itemType'] ?? ($child['item_type'] ?? ''); + $isFinal = (TOOL_LP_FINAL_ITEM === $type); + $extraClass = $isFinal ? ' final-item disable_drag' : ''; + $extraAttr = $isFinal ? ' data-fixed="final"' : ''; + return '