diff --git a/app/Resources/public/css/base.css b/app/Resources/public/css/base.css index 574efffba2..f4bcaf2af4 100644 --- a/app/Resources/public/css/base.css +++ b/app/Resources/public/css/base.css @@ -7363,9 +7363,12 @@ div#chat-remote-video video { padding-left: 15px; } -#toolbar-agenda .show-tick { +#toolbar-agenda .bootstrap-select { width: 420px; } +#toolbar-agenda .bootstrap-select .dropdown-menu li a { + margin-left: 0px; +} .files-table { padding-top: 20px; @@ -10049,6 +10052,14 @@ ul.dropdown-menu.inner > li > a { grid-row-gap: 16px; grid-template-columns: repeat(2, 1fr); } + +#question_admin_form .bootstrap-select .dropdown-menu li a span.text { + overflow: hidden; + text-overflow: ellipsis; + white-space: nowrap; + width: 100%; +} + .summary-course .course .title{ font-weight: bold; font-size: 14px; @@ -10113,6 +10124,7 @@ ul.dropdown-menu.inner > li > a { .summary-course .list-info .text-color{ color: #0A649F; } +<<<<<<< HEAD .question-result h3{ margin-top: 0; margin-bottom: 10px; @@ -10131,6 +10143,9 @@ ul.dropdown-menu.inner > li > a { display: inline-block; font-weight: bold; } +======= + +>>>>>>> 23bad83a744482179b36bc14365ed0c1bef45a2c @media (min-width: 768px) { .clear-rows-6-4-3 .col-sm-6:nth-child(2n+1) { clear: left; diff --git a/main/admin/dashboard_add_users_to_user.php b/main/admin/dashboard_add_users_to_user.php index 5a4fc2291b..37ad0b9a1a 100755 --- a/main/admin/dashboard_add_users_to_user.php +++ b/main/admin/dashboard_add_users_to_user.php @@ -441,7 +441,7 @@ $result = Database::query($sql);

- diff --git a/main/exercise/UniqueAnswerImage.php b/main/exercise/UniqueAnswerImage.php index 332689e631..b8a3f42470 100644 --- a/main/exercise/UniqueAnswerImage.php +++ b/main/exercise/UniqueAnswerImage.php @@ -97,10 +97,8 @@ class UniqueAnswerImage extends UniqueAnswer } $question = Question::read($questionid); - $selectQuestion[$questionid] = 'Q'.$key.' :'.cut( - $question->selectTitle(), - 20 - ); + $questionTitle = strip_tags($question->selectTitle()); + $selectQuestion[$questionid] = "Q$key: $questionTitle"; } } diff --git a/main/exercise/hotspot.class.php b/main/exercise/hotspot.class.php index 628e5d6e04..7b74a9eae5 100755 --- a/main/exercise/hotspot.class.php +++ b/main/exercise/hotspot.class.php @@ -81,7 +81,7 @@ class HotSpot extends Question parent::processCreation($form, $exercise); if (!empty($fileInfo['tmp_name'])) { - $result = $this->uploadPicture($fileInfo); + $result = $this->uploadPicture($fileInfo['tmp_name']); if ($result) { $this->save($exercise); diff --git a/main/exercise/hotspot_admin.inc.php b/main/exercise/hotspot_admin.inc.php index e35e3f377c..7e9040901f 100755 --- a/main/exercise/hotspot_admin.inc.php +++ b/main/exercise/hotspot_admin.inc.php @@ -9,9 +9,9 @@ use ChamiloSession as Session; * * @package chamilo.exercise * - * @author Toon Keppens + * @author Toon Keppens */ -$modifyAnswers = (int) $_GET['hotspotadmin']; +$modifyAnswers = (int)$_GET['hotspotadmin']; if (!is_object($objQuestion)) { $objQuestion = Question::read($modifyAnswers); @@ -576,30 +576,27 @@ if (isset($modifyAnswers)) { echo Display::return_message($msgErr, 'normal'); //main API } - $hotspot_admin_url = api_get_path(WEB_CODE_PATH).'exercise/admin.php?'.api_get_cidreq().'&hotspotadmin='.$modifyAnswers.'&exerciseId='.$exerciseId; ?> + $hotspot_admin_url = api_get_path(WEB_CODE_PATH).'exercise/admin.php?'.api_get_cidreq().'&' + .http_build_query(['hotspotadmin' => $modifyAnswers, 'exerciseId' => $exerciseId]); ?>
- + - + - + @@ -628,73 +625,74 @@ if (isset($modifyAnswers)) { get_flat_list(); - - for ($i = 1; $i <= $nbrAnswers; $i++) { - // is an delineation - if ($answerType == HOT_SPOT_DELINEATION) { - $option_lp = ''; - - // setting the LP - $isSelected = false; - foreach ($flat_list as $id => $details) { - $selected = ''; - if (isset($lp[$i]) && $id == $lp[$i]) { - $isSelected = true; - $selected = 'selected="selected"'; - } - $option_lp .= ''; - } + // Loading list of LPs + $flat_list = $list->get_flat_list(); + + for ($i = 1; $i <= $nbrAnswers; $i++) { + // is an delineation + if ($answerType == HOT_SPOT_DELINEATION) { + $option_lp = ''; + + // setting the LP + $isSelected = false; + foreach ($flat_list as $id => $details) { + $selected = ''; + if (isset($lp[$i]) && $id == $lp[$i]) { + $isSelected = true; + $selected = 'selected="selected"'; + } + $option_lp .= ''; + } - if ($isSelected) { - $option_lp = ''.$option_lp; - } else { - $option_lp = ''.$option_lp; + } else { + $option_lp = ''.$option_lp; - } + } - // Feedback SELECT - $question_list = $objExercise->selectQuestionList(); - $option_feed = ''; - $option_feed .= ''; + // Feedback SELECT + $question_list = $objExercise->selectQuestionList(); + $option_feed = ''; + $option_feed .= ''; - foreach ($question_list as $key => $questionid) { - $selected = ''; - $question = Question::read($questionid); - $val = 'Q'.$key.' :'.substrwords($question->selectTitle(), ICON_SIZE_SMALL); + foreach ($question_list as $key => $questionid) { + $selected = ''; + $question = Question::read($questionid); + $questionTitle = strip_tags($question->selectTitle()); + $val = "Q$key: $questionTitle"; - if (isset($select_question[$i]) && $questionid == $select_question[$i]) { - $selected = 'selected="selected"'; - } + if (isset($select_question[$i]) && $questionid == $select_question[$i]) { + $selected = 'selected="selected"'; + } - $option_feed .= ''; - } + $option_feed .= ''; + } - if (isset($select_question[$i]) && $select_question[$i] == -1) { - $option_feed .= ''; - } else { - $option_feed .= ''; - } + if (isset($select_question[$i]) && $select_question[$i] == -1) { + $option_feed .= ''; + } else { + $option_feed .= ''; + } - //-------- IF it is a delineation - if ($_SESSION['tmp_answers']['hotspot_type'][$i] == 'delineation') { - $option1 = $option2 = $option3 = ''; - for ($k = 1; $k <= 100; $k++) { - $selected1 = $selected2 = $selected3 = ''; - if ($k == $threadhold1[$i]) { - $selected1 = 'selected="selected"'; - } - if ($k == $threadhold2[$i]) { - $selected2 = 'selected="selected"'; - } - if ($k == $threadhold3[$i]) { - $selected3 = 'selected="selected"'; - } - $option1 .= ''; - $option2 .= ''; - $option3 .= ''; - } ?> + //-------- IF it is a delineation + if ($_SESSION['tmp_answers']['hotspot_type'][$i] == 'delineation') { + $option1 = $option2 = $option3 = ''; + for ($k = 1; $k <= 100; $k++) { + $selected1 = $selected2 = $selected3 = ''; + if ($k == $threadhold1[$i]) { + $selected1 = 'selected="selected"'; + } + if ($k == $threadhold2[$i]) { + $selected2 = 'selected="selected"'; + } + if ($k == $threadhold3[$i]) { + $selected3 = 'selected="selected"'; + } + $option1 .= ''; + $option2 .= ''; + $option3 .= ''; + } ?>