Minor - format code

pull/3565/head^2
Julio Montoya 5 years ago
parent 0ca1ec7118
commit fb9cc740b9
  1. 26
      main/mySpace/session_filter.php
  2. 9
      main/survey/fillsurvey.php
  3. 7
      main/ticket/new_ticket.php

@ -268,20 +268,18 @@ if ($form->validate()) {
$extraFields[] = $fieldValue;
}
//foreach ($filterCheckList as $fieldId => $field) {
$list = GradebookUtils::get_list_gradebook_certificates_by_user_id($value['user_id'], $categoryId);
foreach ($list as $valueCertificate) {
$item = [];
$item[] = $sessionInfo['name'];
$item[] = $courseInfo['title'];
$item[] = $value['firstname'];
$item[] = $value['lastname'];
$item[] = $valueCertificate['score_certificate'];
$item[] = api_get_local_time($valueCertificate['created_at']);
$item = array_merge($item, $extraFields);
$dataToExport[] = $item;
}
//}
$list = GradebookUtils::get_list_gradebook_certificates_by_user_id($value['user_id'], $categoryId);
foreach ($list as $valueCertificate) {
$item = [];
$item[] = $sessionInfo['name'];
$item[] = $courseInfo['title'];
$item[] = $value['firstname'];
$item[] = $value['lastname'];
$item[] = $valueCertificate['score_certificate'];
$item[] = api_get_local_time($valueCertificate['created_at']);
$item = array_merge($item, $extraFields);
$dataToExport[] = $item;
}
}
Export::arrayToCsv($dataToExport, 'export');
}

@ -3,7 +3,8 @@
/* For licensing terms, see /license.txt */
use ChamiloSession as Session;
$lastQuestion = 0;
$lastQuestion = 0;
/**
* @author unknown, the initial survey that did not make it in 1.8 because of bad code
@ -812,10 +813,10 @@ if ((isset($_GET['show']) && $_GET['show'] != '') ||
}
$counter++;
// see GH#3582
if (isset($_GET['show']) && (int)$_GET['show'] >= 0) {
$lastQuestion = (int)$_GET['show'] - 1;
if (isset($_GET['show']) && (int) $_GET['show'] >= 0) {
$lastQuestion = (int) $_GET['show'] - 1;
} else {
$lastQuestion = (int)$row['question_option_id'];
$lastQuestion = (int) $row['question_option_id'];
}
}
}

@ -1,9 +1,7 @@
<?php
/* For licensing terms, see /license.txt */
/**
* @package chamilo.ticket
*/
require_once __DIR__.'/../inc/global.inc.php';
if (!api_is_platform_admin() && api_get_setting('ticket_allow_student_add') !== 'true') {
@ -85,7 +83,7 @@ function updateLpList(courseId, sessionId) {
}, function (lpList) {
$("<option>", {
value: 0,
text: "' . get_lang('Select') . '"
text: "'.get_lang('Select').'"
}).appendTo($selectLp);
if (lpList.length > 0) {
@ -95,7 +93,6 @@ function updateLpList(courseId, sessionId) {
text: lp.text
}).appendTo($selectLp);
});
$selectLp.find("option[value=\'' . $lpId . '\']").attr("selected",true);
}

Loading…
Cancel
Save