|
|
|
|
@ -134,7 +134,6 @@ $categories = [ |
|
|
|
|
if (!empty($categoriesTempList)) { |
|
|
|
|
$categories = array_merge($categories, $categoriesTempList); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
$userId = api_get_user_id(); |
|
|
|
|
$userInfo = api_get_user_info(); |
|
|
|
|
$lpIsShown = false; |
|
|
|
|
@ -156,14 +155,44 @@ $test_mode = api_get_setting('server_type'); |
|
|
|
|
$showBlockedPrerequisite = api_get_configuration_value('show_prerequisite_as_blocked'); |
|
|
|
|
$allowLpChamiloExport = api_get_configuration_value('allow_lp_chamilo_export'); |
|
|
|
|
$allowMinTime = Tracking::minimunTimeAvailable(api_get_session_id(), api_get_course_int_id()); |
|
|
|
|
$accumulateWorkTimeTotal = 0; |
|
|
|
|
if ($allowMinTime) { |
|
|
|
|
$accumulateWorkTimeTotal = learnpath::getAccumulateWorkTimeTotal(api_get_course_int_id()); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
$user = api_get_user_entity($userId); |
|
|
|
|
$ending = true; |
|
|
|
|
$isInvitee = api_is_invitee(); |
|
|
|
|
$hideScormExportLink = api_get_setting('hide_scorm_export_link'); |
|
|
|
|
$hideScormCopyLink = api_get_setting('hide_scorm_copy_link'); |
|
|
|
|
$hideScormPdfLink = api_get_setting('hide_scorm_pdf_link'); |
|
|
|
|
$options = learnpath::getIconSelect(); |
|
|
|
|
$cidReq = api_get_cidreq(); |
|
|
|
|
|
|
|
|
|
$defaultLpIcon = Display::return_icon( |
|
|
|
|
'learnpath.png', |
|
|
|
|
get_lang('LPName') |
|
|
|
|
); |
|
|
|
|
|
|
|
|
|
$defaultDisableLpIcon = Display::return_icon( |
|
|
|
|
'learnpath_na.png', |
|
|
|
|
get_lang('LPName') |
|
|
|
|
); |
|
|
|
|
|
|
|
|
|
$courseSettingsIcon = Display::return_icon( |
|
|
|
|
'settings.png', |
|
|
|
|
get_lang('CourseSettings') |
|
|
|
|
); |
|
|
|
|
|
|
|
|
|
$courseSettingsDisableIcon = Display::return_icon( |
|
|
|
|
'settings_na.png', |
|
|
|
|
get_lang('CourseSettings') |
|
|
|
|
); |
|
|
|
|
|
|
|
|
|
$data = []; |
|
|
|
|
/** @var CLpCategory $item */ |
|
|
|
|
foreach ($categories as $item) { |
|
|
|
|
$categoryId = $item->getId(); |
|
|
|
|
|
|
|
|
|
if ($categoryId !== 0 && $subscriptionSettings['allow_add_users_to_lp_category'] == true) { |
|
|
|
|
// "Without category" has id = 0 |
|
|
|
|
$categoryVisibility = api_get_item_visibility( |
|
|
|
|
@ -206,17 +235,18 @@ foreach ($categories as $item) { |
|
|
|
|
$lpTimeList = Tracking::getCalculateTime($userId, api_get_course_int_id(), api_get_session_id()); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
$options = learnpath::getIconSelect(); |
|
|
|
|
|
|
|
|
|
if (!empty($flat_list)) { |
|
|
|
|
$max = count($flat_list); |
|
|
|
|
$counter = 0; |
|
|
|
|
$current = 0; |
|
|
|
|
$autolaunch_exists = false; |
|
|
|
|
$accumulateWorkTimeTotal = 0; |
|
|
|
|
if ($allowMinTime) { |
|
|
|
|
$accumulateWorkTimeTotal = learnpath::getAccumulateWorkTimeTotal(api_get_course_int_id()); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
$progressList = learnpath::getProgressFromLpList( |
|
|
|
|
array_column($flat_list, 'lp_old_id'), |
|
|
|
|
$userId, |
|
|
|
|
api_get_course_int_id(), |
|
|
|
|
api_get_session_id() |
|
|
|
|
); |
|
|
|
|
|
|
|
|
|
foreach ($flat_list as $id => $details) { |
|
|
|
|
$id = $details['lp_old_id']; |
|
|
|
|
@ -249,7 +279,6 @@ foreach ($categories as $item) { |
|
|
|
|
$start_time = $end_time = ''; |
|
|
|
|
if (!$is_allowed_to_edit) { |
|
|
|
|
$time_limits = false; |
|
|
|
|
|
|
|
|
|
// This is an old LP (from a migration 1.8.7) so we do nothing |
|
|
|
|
if (empty($details['created_on']) && |
|
|
|
|
empty($details['modified_on']) |
|
|
|
|
@ -303,13 +332,12 @@ foreach ($categories as $item) { |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
$counter++; |
|
|
|
|
$oddclass = 'row_even'; |
|
|
|
|
if (($counter % 2) == 0) { |
|
|
|
|
$oddclass = 'row_odd'; |
|
|
|
|
} else { |
|
|
|
|
$oddclass = 'row_even'; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
$url_start_lp = 'lp_controller.php?'.api_get_cidreq().'&action=view&lp_id='.$id; |
|
|
|
|
$url_start_lp = 'lp_controller.php?'.$cidReq.'&action=view&lp_id='.$id; |
|
|
|
|
$name = Security::remove_XSS($details['lp_name']); |
|
|
|
|
$extra = null; |
|
|
|
|
|
|
|
|
|
@ -327,21 +355,14 @@ foreach ($categories as $item) { |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
$my_title = $name; |
|
|
|
|
$icon_learnpath = Display::return_icon( |
|
|
|
|
'learnpath.png', |
|
|
|
|
get_lang('LPName') |
|
|
|
|
); |
|
|
|
|
|
|
|
|
|
$icon_learnpath = $defaultLpIcon; |
|
|
|
|
if ($details['lp_visibility'] == 0) { |
|
|
|
|
$my_title = Display::tag( |
|
|
|
|
'font', |
|
|
|
|
$name, |
|
|
|
|
['class' => 'text-muted'] |
|
|
|
|
); |
|
|
|
|
$icon_learnpath = Display::return_icon( |
|
|
|
|
'learnpath_na.png', |
|
|
|
|
get_lang('LPName') |
|
|
|
|
); |
|
|
|
|
$icon_learnpath = $defaultDisableLpIcon; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
if (!empty($options)) { |
|
|
|
|
@ -360,10 +381,7 @@ foreach ($categories as $item) { |
|
|
|
|
$name, |
|
|
|
|
['class' => 'text-muted'] |
|
|
|
|
); |
|
|
|
|
$icon_learnpath = Display::return_icon( |
|
|
|
|
'learnpath_na.png', |
|
|
|
|
get_lang('LPName') |
|
|
|
|
); |
|
|
|
|
$icon_learnpath = $defaultDisableLpIcon; |
|
|
|
|
$url_start_lp = '#'; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
@ -376,22 +394,17 @@ foreach ($categories as $item) { |
|
|
|
|
$dsp_default_view = ''; |
|
|
|
|
$dsp_debug = ''; |
|
|
|
|
$dsp_order = ''; |
|
|
|
|
$progress = 0; |
|
|
|
|
|
|
|
|
|
if (!api_is_invitee()) { |
|
|
|
|
$progress = learnpath::getProgress( |
|
|
|
|
$id, |
|
|
|
|
$userId, |
|
|
|
|
api_get_course_int_id(), |
|
|
|
|
api_get_session_id() |
|
|
|
|
); |
|
|
|
|
$progress = 0; |
|
|
|
|
if (!$isInvitee) { |
|
|
|
|
$progress = isset($progressList[$id]) && !empty($progressList[$id]) ? $progressList[$id] : 0; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
if ($is_allowed_to_edit) { |
|
|
|
|
$dsp_progress = '<center>'.$progress.'%</center>'; |
|
|
|
|
} else { |
|
|
|
|
$dsp_progress = ''; |
|
|
|
|
if (!api_is_invitee()) { |
|
|
|
|
if (!$isInvitee) { |
|
|
|
|
$dsp_progress = learnpath::get_progress_bar($progress, '%'); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
@ -444,7 +457,7 @@ foreach ($categories as $item) { |
|
|
|
|
$time_progress_perc = '100%'; |
|
|
|
|
$time_progress_value = 100; |
|
|
|
|
} else { |
|
|
|
|
$time_progress_value = intval(($lpTime * 100) / ($accumulateWorkTime * 60)); |
|
|
|
|
$time_progress_value = (int) (($lpTime * 100) / ($accumulateWorkTime * 60)); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
if ($time_progress_value < 100) { |
|
|
|
|
@ -472,18 +485,11 @@ foreach ($categories as $item) { |
|
|
|
|
// EDIT LP |
|
|
|
|
if ($sessionId == $details['lp_session']) { |
|
|
|
|
$dsp_edit_lp = Display::url( |
|
|
|
|
Display::return_icon( |
|
|
|
|
'settings.png', |
|
|
|
|
get_lang('CourseSettings') |
|
|
|
|
), |
|
|
|
|
"lp_controller.php?".api_get_cidreq() |
|
|
|
|
."&action=edit&lp_id=$id" |
|
|
|
|
$courseSettingsIcon, |
|
|
|
|
'lp_controller.php?'.$cidReq."&action=edit&lp_id=$id" |
|
|
|
|
); |
|
|
|
|
} else { |
|
|
|
|
$dsp_edit_lp = Display::return_icon( |
|
|
|
|
'settings_na.png', |
|
|
|
|
get_lang('CourseSettings') |
|
|
|
|
); |
|
|
|
|
$dsp_edit_lp = $courseSettingsDisableIcon; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
// BUILD |
|
|
|
|
@ -494,7 +500,7 @@ foreach ($categories as $item) { |
|
|
|
|
'edit.png', |
|
|
|
|
get_lang('LearnpathEditLearnpath') |
|
|
|
|
), |
|
|
|
|
'lp_controller.php?'.api_get_cidreq().'&' |
|
|
|
|
'lp_controller.php?'.$cidReq.'&' |
|
|
|
|
.http_build_query( |
|
|
|
|
[ |
|
|
|
|
'action' => 'add_item', |
|
|
|
|
@ -531,13 +537,13 @@ foreach ($categories as $item) { |
|
|
|
|
'invisible.png', |
|
|
|
|
get_lang('Show') |
|
|
|
|
), |
|
|
|
|
api_get_self().'?'.api_get_cidreq() |
|
|
|
|
api_get_self().'?'.$cidReq |
|
|
|
|
."&lp_id=$id&action=toggle_visible&new_status=1" |
|
|
|
|
); |
|
|
|
|
} else { |
|
|
|
|
$dsp_visible = Display::url( |
|
|
|
|
Display::return_icon('visible.png', get_lang('Hide')), |
|
|
|
|
api_get_self().'?'.api_get_cidreq() |
|
|
|
|
api_get_self().'?'.$cidReq |
|
|
|
|
."&lp_id=$id&action=toggle_visible&new_status=0" |
|
|
|
|
); |
|
|
|
|
} |
|
|
|
|
@ -545,7 +551,7 @@ foreach ($categories as $item) { |
|
|
|
|
|
|
|
|
|
// Tracking command |
|
|
|
|
$trackingActionUrl = 'lp_controller.php?' |
|
|
|
|
.api_get_cidreq().'&' |
|
|
|
|
.$cidReq.'&' |
|
|
|
|
.http_build_query(['action' => 'report', 'lp_id' => $id]); |
|
|
|
|
|
|
|
|
|
$trackingAction = Display::url( |
|
|
|
|
@ -558,13 +564,13 @@ foreach ($categories as $item) { |
|
|
|
|
|
|
|
|
|
/* PUBLISH COMMAND */ |
|
|
|
|
if ($sessionId == $details['lp_session']) { |
|
|
|
|
if ($details['lp_published'] == "i") { |
|
|
|
|
if ($details['lp_published'] == 'i') { |
|
|
|
|
$dsp_publish = Display::url( |
|
|
|
|
Display::return_icon( |
|
|
|
|
'lp_publish_na.png', |
|
|
|
|
get_lang('LearnpathPublish') |
|
|
|
|
), |
|
|
|
|
api_get_self().'?'.api_get_cidreq() |
|
|
|
|
api_get_self().'?'.$cidReq |
|
|
|
|
."&lp_id=$id&action=toggle_publish&new_status=v" |
|
|
|
|
); |
|
|
|
|
} else { |
|
|
|
|
@ -573,7 +579,7 @@ foreach ($categories as $item) { |
|
|
|
|
'lp_publish.png', |
|
|
|
|
get_lang('LearnpathDoNotPublish') |
|
|
|
|
), |
|
|
|
|
api_get_self().'?'.api_get_cidreq() |
|
|
|
|
api_get_self().'?'.$cidReq |
|
|
|
|
."&lp_id=$id&action=toggle_publish&new_status=i" |
|
|
|
|
); |
|
|
|
|
} |
|
|
|
|
@ -600,7 +606,7 @@ foreach ($categories as $item) { |
|
|
|
|
'reload.png', |
|
|
|
|
get_lang('PreventMultipleAttempts') |
|
|
|
|
), |
|
|
|
|
"lp_controller.php?".api_get_cidreq() |
|
|
|
|
'lp_controller.php?'.$cidReq |
|
|
|
|
."&action=switch_attempt_mode&lp_id=$id" |
|
|
|
|
); |
|
|
|
|
} |
|
|
|
|
@ -613,7 +619,7 @@ foreach ($categories as $item) { |
|
|
|
|
'reload_na.png', |
|
|
|
|
get_lang('AllowMultipleAttempts') |
|
|
|
|
), |
|
|
|
|
"lp_controller.php?".api_get_cidreq() |
|
|
|
|
'lp_controller.php?'.$cidReq |
|
|
|
|
."&action=switch_attempt_mode&lp_id=$id" |
|
|
|
|
); |
|
|
|
|
} |
|
|
|
|
@ -626,7 +632,7 @@ foreach ($categories as $item) { |
|
|
|
|
'reload.png', |
|
|
|
|
get_lang('AllowMultipleAttempts') |
|
|
|
|
), |
|
|
|
|
"lp_controller.php?".api_get_cidreq() |
|
|
|
|
'lp_controller.php?'.$cidReq |
|
|
|
|
."&action=switch_attempt_mode&lp_id=$id" |
|
|
|
|
); |
|
|
|
|
} |
|
|
|
|
@ -646,7 +652,7 @@ foreach ($categories as $item) { |
|
|
|
|
'view_fullscreen.png', |
|
|
|
|
get_lang('ViewModeFullScreen') |
|
|
|
|
), |
|
|
|
|
'lp_controller.php?'.api_get_cidreq() |
|
|
|
|
'lp_controller.php?'.$cidReq |
|
|
|
|
.'&action=switch_view_mode&lp_id='.$id |
|
|
|
|
.$token_parameter |
|
|
|
|
); |
|
|
|
|
@ -657,7 +663,7 @@ foreach ($categories as $item) { |
|
|
|
|
'view_left_right.png', |
|
|
|
|
get_lang('ViewModeEmbedded') |
|
|
|
|
), |
|
|
|
|
'lp_controller.php?'.api_get_cidreq() |
|
|
|
|
'lp_controller.php?'.$cidReq |
|
|
|
|
.'&action=switch_view_mode&lp_id='.$id |
|
|
|
|
.$token_parameter |
|
|
|
|
); |
|
|
|
|
@ -668,7 +674,7 @@ foreach ($categories as $item) { |
|
|
|
|
'view_nofullscreen.png', |
|
|
|
|
get_lang('ViewModeEmbedFrame') |
|
|
|
|
), |
|
|
|
|
'lp_controller.php?'.api_get_cidreq() |
|
|
|
|
'lp_controller.php?'.$cidReq |
|
|
|
|
.'&action=switch_view_mode&lp_id='.$id |
|
|
|
|
.$token_parameter |
|
|
|
|
); |
|
|
|
|
@ -679,14 +685,14 @@ foreach ($categories as $item) { |
|
|
|
|
'window_list_slide.png', |
|
|
|
|
get_lang('ViewModeImpress') |
|
|
|
|
), |
|
|
|
|
'lp_controller.php?'.api_get_cidreq() |
|
|
|
|
'lp_controller.php?'.$cidReq |
|
|
|
|
.'&action=switch_view_mode&lp_id='.$id |
|
|
|
|
.$token_parameter |
|
|
|
|
); |
|
|
|
|
break; |
|
|
|
|
} |
|
|
|
|
} else { |
|
|
|
|
if ($details['lp_view_mode'] == 'fullscreen') { |
|
|
|
|
if ($details['lp_view_mode'] === 'fullscreen') { |
|
|
|
|
$dsp_default_view = Display::return_icon( |
|
|
|
|
'view_fullscreen_na.png', |
|
|
|
|
get_lang('ViewModeEmbedded') |
|
|
|
|
@ -707,8 +713,7 @@ foreach ($categories as $item) { |
|
|
|
|
'bug.png', |
|
|
|
|
get_lang('HideDebug') |
|
|
|
|
), |
|
|
|
|
"lp_controller.php?".api_get_cidreq() |
|
|
|
|
."&action=switch_scorm_debug&lp_id=$id" |
|
|
|
|
"lp_controller.php?$cidReq&action=switch_scorm_debug&lp_id=$id" |
|
|
|
|
); |
|
|
|
|
} else { |
|
|
|
|
$dsp_debug = Display::url( |
|
|
|
|
@ -716,8 +721,7 @@ foreach ($categories as $item) { |
|
|
|
|
'bug_na.png', |
|
|
|
|
get_lang('ShowDebug') |
|
|
|
|
), |
|
|
|
|
"lp_controller.php?".api_get_cidreq() |
|
|
|
|
."&action=switch_scorm_debug&lp_id=$id" |
|
|
|
|
'lp_controller.php?'.$cidReq."&action=switch_scorm_debug&lp_id=$id" |
|
|
|
|
); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
@ -726,13 +730,13 @@ foreach ($categories as $item) { |
|
|
|
|
if ($details['lp_type'] == 1) { |
|
|
|
|
$dsp_disk = Display::url( |
|
|
|
|
Display::return_icon('cd.png', get_lang('ExportShort')), |
|
|
|
|
api_get_self()."?".api_get_cidreq() |
|
|
|
|
api_get_self()."?".$cidReq |
|
|
|
|
."&action=export&lp_id=$id" |
|
|
|
|
); |
|
|
|
|
} elseif ($details['lp_type'] == 2) { |
|
|
|
|
$dsp_disk = Display::url( |
|
|
|
|
Display::return_icon('cd.png', get_lang('ExportShort')), |
|
|
|
|
api_get_self()."?".api_get_cidreq() |
|
|
|
|
api_get_self()."?".$cidReq |
|
|
|
|
."&action=export&lp_id=$id&export_name=" |
|
|
|
|
.api_replace_dangerous_char($name).".zip" |
|
|
|
|
); |
|
|
|
|
@ -746,7 +750,7 @@ foreach ($categories as $item) { |
|
|
|
|
// Copy |
|
|
|
|
$copy = Display::url( |
|
|
|
|
Display::return_icon('cd_copy.png', get_lang('Copy')), |
|
|
|
|
api_get_self()."?".api_get_cidreq()."&action=copy&lp_id=$id" |
|
|
|
|
api_get_self().'?'.$cidReq."&action=copy&lp_id=$id" |
|
|
|
|
); |
|
|
|
|
|
|
|
|
|
// Subscribe users |
|
|
|
|
@ -759,7 +763,7 @@ foreach ($categories as $item) { |
|
|
|
|
'user.png', |
|
|
|
|
get_lang('SubscribeUsersToLp') |
|
|
|
|
), |
|
|
|
|
api_get_path(WEB_CODE_PATH)."lp/lp_subscribe_users.php?lp_id=$id&".api_get_cidreq() |
|
|
|
|
api_get_path(WEB_CODE_PATH)."lp/lp_subscribe_users.php?lp_id=$id&".$cidReq |
|
|
|
|
); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
@ -774,7 +778,7 @@ foreach ($categories as $item) { |
|
|
|
|
'launch.png', |
|
|
|
|
get_lang('DisableLPAutoLaunch') |
|
|
|
|
), |
|
|
|
|
api_get_self().'?'.api_get_cidreq() |
|
|
|
|
api_get_self().'?'.$cidReq |
|
|
|
|
."&action=auto_launch&status=0&lp_id=$id" |
|
|
|
|
); |
|
|
|
|
} else { |
|
|
|
|
@ -783,7 +787,7 @@ foreach ($categories as $item) { |
|
|
|
|
'launch_na.png', |
|
|
|
|
get_lang('EnableLPAutoLaunch') |
|
|
|
|
), |
|
|
|
|
api_get_self().'?'.api_get_cidreq() |
|
|
|
|
api_get_self().'?'.$cidReq |
|
|
|
|
."&action=auto_launch&status=1&lp_id=$id" |
|
|
|
|
); |
|
|
|
|
} |
|
|
|
|
@ -795,7 +799,7 @@ foreach ($categories as $item) { |
|
|
|
|
'pdf.png', |
|
|
|
|
get_lang('ExportToPDFOnlyHTMLAndImages') |
|
|
|
|
), |
|
|
|
|
api_get_self().'?'.api_get_cidreq() |
|
|
|
|
api_get_self().'?'.$cidReq |
|
|
|
|
."&action=export_to_pdf&lp_id=$id" |
|
|
|
|
); |
|
|
|
|
|
|
|
|
|
@ -806,7 +810,7 @@ foreach ($categories as $item) { |
|
|
|
|
'delete.png', |
|
|
|
|
get_lang('LearnpathDeleteLearnpath') |
|
|
|
|
), |
|
|
|
|
'lp_controller.php?'.api_get_cidreq()."&action=delete&lp_id=$id", |
|
|
|
|
'lp_controller.php?'.$cidReq."&action=delete&lp_id=$id", |
|
|
|
|
[ |
|
|
|
|
'onclick' => "javascript: return confirmation('".addslashes($name)."');", |
|
|
|
|
] |
|
|
|
|
@ -824,13 +828,13 @@ foreach ($categories as $item) { |
|
|
|
|
if ($details['lp_display_order'] == 1 && $max != 1) { |
|
|
|
|
$dsp_order .= Display::url( |
|
|
|
|
Display::return_icon('down.png', get_lang('MoveDown')), |
|
|
|
|
"lp_controller.php?".api_get_cidreq() |
|
|
|
|
"lp_controller.php?".$cidReq |
|
|
|
|
."&action=move_lp_down&lp_id=$id&category_id=$categoryId" |
|
|
|
|
); |
|
|
|
|
} elseif ($current == $max - 1 && $max != 1) { |
|
|
|
|
$dsp_order .= Display::url( |
|
|
|
|
Display::return_icon('up.png', get_lang('MoveUp')), |
|
|
|
|
"lp_controller.php?".api_get_cidreq() |
|
|
|
|
"lp_controller.php?".$cidReq |
|
|
|
|
."&action=move_lp_up&lp_id=$id&category_id=$categoryId" |
|
|
|
|
); |
|
|
|
|
} elseif ($max == 1) { |
|
|
|
|
@ -838,19 +842,19 @@ foreach ($categories as $item) { |
|
|
|
|
} else { |
|
|
|
|
$dsp_order .= Display::url( |
|
|
|
|
Display::return_icon('down.png', get_lang('MoveDown')), |
|
|
|
|
"lp_controller.php?".api_get_cidreq() |
|
|
|
|
"lp_controller.php?".$cidReq |
|
|
|
|
."&action=move_lp_down&lp_id=$id&category_id=$categoryId" |
|
|
|
|
); |
|
|
|
|
$dsp_order .= Display::url( |
|
|
|
|
Display::return_icon('up.png', get_lang('MoveUp')), |
|
|
|
|
"lp_controller.php?".api_get_cidreq() |
|
|
|
|
"lp_controller.php?".$cidReq |
|
|
|
|
."&action=move_lp_up&lp_id=$id&category_id=$categoryId" |
|
|
|
|
); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
if ($details['lp_type'] == 2) { |
|
|
|
|
$url = api_get_path(WEB_CODE_PATH)."lp/lp_update_scorm.php?".api_get_cidreq()."&lp_id=$id"; |
|
|
|
|
$url = api_get_path(WEB_CODE_PATH).'lp/lp_update_scorm.php?'.$cidReq."&lp_id=$id"; |
|
|
|
|
$actionUpdateScormFile = Display::url( |
|
|
|
|
Display::return_icon('upload_file.png', get_lang('Update')), |
|
|
|
|
$url |
|
|
|
|
@ -863,7 +867,7 @@ foreach ($categories as $item) { |
|
|
|
|
'backup.png', |
|
|
|
|
get_lang('ExportToChamiloFormat') |
|
|
|
|
), |
|
|
|
|
api_get_self().'?'.api_get_cidreq() |
|
|
|
|
api_get_self().'?'.$cidReq |
|
|
|
|
."&action=export_to_course_build&lp_id=$id" |
|
|
|
|
); |
|
|
|
|
} |
|
|
|
|
@ -879,7 +883,7 @@ foreach ($categories as $item) { |
|
|
|
|
if ($details['seriousgame_mode'] == 0) { |
|
|
|
|
$actionSeriousGame = Display::toolbarButton( |
|
|
|
|
null, |
|
|
|
|
api_get_self().'?'.api_get_cidreq() |
|
|
|
|
api_get_self().'?'.$cidReq |
|
|
|
|
."&lp_id=$id&action=toggle_seriousgame", |
|
|
|
|
'trophy', |
|
|
|
|
'default', |
|
|
|
|
@ -891,7 +895,7 @@ foreach ($categories as $item) { |
|
|
|
|
} else { |
|
|
|
|
$actionSeriousGame = Display::toolbarButton( |
|
|
|
|
null, |
|
|
|
|
api_get_self().'?'.api_get_cidreq() |
|
|
|
|
api_get_self().'?'.$cidReq |
|
|
|
|
."&lp_id=$id&action=toggle_seriousgame", |
|
|
|
|
'trophy', |
|
|
|
|
'warning', |
|
|
|
|
@ -906,22 +910,19 @@ foreach ($categories as $item) { |
|
|
|
|
// Student |
|
|
|
|
$export_icon = Display::url( |
|
|
|
|
Display::return_icon('pdf.png', get_lang('ExportToPDF')), |
|
|
|
|
api_get_self().'?'.api_get_cidreq() |
|
|
|
|
api_get_self().'?'.$cidReq |
|
|
|
|
."&action=export_to_pdf&lp_id=$id" |
|
|
|
|
); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
$hideScormExportLink = api_get_setting('hide_scorm_export_link'); |
|
|
|
|
if ($hideScormExportLink === 'true') { |
|
|
|
|
$dsp_disk = null; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
$hideScormCopyLink = api_get_setting('hide_scorm_copy_link'); |
|
|
|
|
if ($hideScormCopyLink === 'true') { |
|
|
|
|
$copy = null; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
$hideScormPdfLink = api_get_setting('hide_scorm_pdf_link'); |
|
|
|
|
if ($hideScormPdfLink === 'true') { |
|
|
|
|
$export_icon = null; |
|
|
|
|
} |
|
|
|
|
|