Scrutinizer Auto-Fixes

This commit consists of patches automatically generated for this project on https://scrutinizer-ci.com
pull/2487/head
Scrutinizer Auto-Fixer 9 years ago
parent a699a9f0a4
commit b3ec3c22f6
  1. 60
      main/admin/access_url_add_users_to_url.php
  2. 26
      main/dashboard/dashboard.php
  3. 24
      main/document/slideshow.inc.php
  4. 2
      main/forum/viewforumcategory.php
  5. 4
      main/forum/viewthread_threaded.inc.php
  6. 18
      main/gradebook/gradebook_display_certificate.php
  7. 24
      main/gradebook/lib/be/gradebookitem.class.php
  8. 124
      main/mySpace/coaches.php
  9. 182
      main/reports/templates/courseArticulate.reports.php
  10. 8
      main/session/add_many_session_to_category.php
  11. 14
      main/session/add_teachers_to_session.php
  12. 40
      main/session/resume_session.php
  13. 10
      main/session/session_category_edit.php
  14. 72
      main/session/session_course_edit.php
  15. 52
      main/session/session_course_list.php
  16. 14
      main/session/session_course_user_list.php
  17. 2
      main/social/vcard_export.php
  18. 6
      main/survey/reporting.php
  19. 20
      main/survey/survey.lib.php
  20. 2
      main/timeline/index.php
  21. 8
      src/Chamilo/CoreBundle/Component/Editor/Connector.php
  22. 4
      src/Chamilo/CoreBundle/Component/Editor/Driver/DropBoxDriver.php
  23. 4
      src/Chamilo/CoreBundle/Component/Editor/TinyMce/Toolbar/Basic.php
  24. 14
      src/Chamilo/CoreBundle/Component/Filesystem/Data.php
  25. 1
      src/Chamilo/CoreBundle/Entity/AccessUrlRelUserGroup.php
  26. 22
      src/Chamilo/CoreBundle/Entity/ExtraFieldOptionRelFieldOption.php
  27. 14
      src/Chamilo/CoreBundle/Entity/ExtraFieldValues.php
  28. 2
      src/Chamilo/CoreBundle/Entity/Repository/SequenceRepository.php

@ -13,8 +13,8 @@ $this_section = SECTION_PLATFORM_ADMIN;
api_protect_global_admin_script();
if (!api_get_multiple_access_url()) {
header('Location: index.php');
exit;
header('Location: index.php');
exit;
}
$form_sent = 0;
@ -44,36 +44,36 @@ echo '</div>';
api_display_tool_title($tool_name);
if ($_POST['form_sent']) {
$form_sent = $_POST['form_sent'];
$users = is_array($_POST['user_list']) ? $_POST['user_list'] : array() ;
$url_list = is_array($_POST['url_list']) ? $_POST['url_list'] : array() ;
$first_letter_user = $_POST['first_letter_user'];
$form_sent = $_POST['form_sent'];
$users = is_array($_POST['user_list']) ? $_POST['user_list'] : array() ;
$url_list = is_array($_POST['url_list']) ? $_POST['url_list'] : array() ;
$first_letter_user = $_POST['first_letter_user'];
foreach($users as $key => $value) {
$users[$key] = intval($value);
}
foreach($users as $key => $value) {
$users[$key] = intval($value);
}
if ($form_sent == 1) {
if (count($users) == 0 || count($url_list) == 0) {
Display :: display_error_message(get_lang('AtLeastOneUserAndOneURL'));
} else {
UrlManager::add_users_to_urls($users,$url_list);
Display :: display_confirmation_message(get_lang('UsersBelongURL'));
}
}
if ($form_sent == 1) {
if (count($users) == 0 || count($url_list) == 0) {
Display :: display_error_message(get_lang('AtLeastOneUserAndOneURL'));
} else {
UrlManager::add_users_to_urls($users,$url_list);
Display :: display_confirmation_message(get_lang('UsersBelongURL'));
}
}
}
/* Display GUI */
if (empty($first_letter_user)) {
$sql = "SELECT count(*) as nb_users FROM $tbl_user";
$result = Database::query($sql);
$num_row = Database::fetch_array($result);
$sql = "SELECT count(*) as nb_users FROM $tbl_user";
$result = Database::query($sql);
$num_row = Database::fetch_array($result);
if ($num_row['nb_users']>1000) {
//if there are too much users to gracefully handle with the HTML select list,
// assign a default filter on users names
$first_letter_user = 'A';
}
unset($result);
unset($result);
}
$first_letter_user_lower = Database::escape_string(api_strtolower($first_letter_user));
@ -104,7 +104,7 @@ unset($result);
<option value="">--</option>
<?php
echo Display :: get_alphabet_options($first_letter_user);
?>
?>
</select>
</td>
<td width="20%">&nbsp;</td>
@ -116,14 +116,14 @@ unset($result);
<td width="40%" align="center">
<select name="user_list[]" multiple="multiple" size="20" style="width:380px;">
<?php
foreach ($db_users as $user) {
?>
foreach ($db_users as $user) {
?>
<option value="<?php echo $user['user_id']; ?>" <?php if(in_array($user['user_id'], $users)) echo 'selected="selected"'; ?>>
<?php echo api_get_person_name($user['firstname'], $user['lastname']).' ('.$user['username'].')'; ?>
</option>
<?php
}
?>
}
?>
</select>
</td>
<td width="20%" valign="middle" align="center">
@ -132,14 +132,14 @@ unset($result);
<td width="40%" align="center">
<select name="url_list[]" multiple="multiple" size="20" style="width:230px;">
<?php
foreach ($db_urls as $url_obj) {
?>
foreach ($db_urls as $url_obj) {
?>
<option value="<?php echo $url_obj['id']; ?>" <?php if(in_array($url_obj['id'],$url_list)) echo 'selected="selected"'; ?>>
<?php echo $url_obj['url']; ?>
</option>
<?php
}
?>
}
?>
</select>
</td>
</tr>

@ -14,23 +14,23 @@ api_block_anonymous_users();
$views = array('blocks', 'list');
if(isset($_GET['view']) && in_array($_GET['view'], $views)){
$dashboard_view = $_GET['view'];
$dashboard_view = $_GET['view'];
}
$link_blocks_view = $link_list_view = null;
if (isset($dashboard_view) && $dashboard_view == 'list') {
$link_blocks_view = '<a href="'.api_get_self().'?view=blocks">'.
Display::return_icon('blocks.png',get_lang('DashboardBlocks'),'',ICON_SIZE_MEDIUM).'</a>';
$link_blocks_view = '<a href="'.api_get_self().'?view=blocks">'.
Display::return_icon('blocks.png',get_lang('DashboardBlocks'),'',ICON_SIZE_MEDIUM).'</a>';
} else {
$link_list_view = '<a href="'.api_get_self().'?view=list">'.
Display::return_icon('edit.png',get_lang('EditBlocks'),'',ICON_SIZE_MEDIUM).'</a>';
$link_list_view = '<a href="'.api_get_self().'?view=list">'.
Display::return_icon('edit.png',get_lang('EditBlocks'),'',ICON_SIZE_MEDIUM).'</a>';
}
$configuration_link = null;
if (api_is_platform_admin()) {
$configuration_link = '<a href="'.api_get_path(WEB_CODE_PATH).'admin/settings.php?category=Plugins">'
.Display::return_icon('settings.png',get_lang('ConfigureDashboardPlugin'),'',ICON_SIZE_MEDIUM).'</a>';
$configuration_link = '<a href="'.api_get_path(WEB_CODE_PATH).'admin/settings.php?category=Plugins">'
.Display::return_icon('settings.png',get_lang('ConfigureDashboardPlugin'),'',ICON_SIZE_MEDIUM).'</a>';
}
echo '<div class="actions">';
@ -87,10 +87,10 @@ if (isset($dashboard_view) && $dashboard_view == 'blocks') {
}
} else {
// block dashboard list
if (isset($success)) {
Display::display_confirmation_message(get_lang('BlocksHaveBeenUpdatedSuccessfully'));
}
$user_id = api_get_user_id();
DashboardManager::display_user_dashboard_list($user_id);
// block dashboard list
if (isset($success)) {
Display::display_confirmation_message(get_lang('BlocksHaveBeenUpdatedSuccessfully'));
}
$user_id = api_get_user_id();
DashboardManager::display_user_dashboard_list($user_id);
}

@ -15,8 +15,6 @@
This file has two large sections.
1. code that belongs in document.php, but to avoid clutter I put the code here
2. the function resize_image that handles the image resizing
* @author Patrick Cool
* @package chamilo.document
* @todo convert comments to be understandable to phpDocumentor
@ -34,16 +32,16 @@
* view is also possible when you choose not to resize the source images
*/
function resize_image($image, $target_width, $target_height, $slideshow = 0) {
// Modifications by Ivan Tcholakov, 04-MAY-2009.
$result = array();
if ( (isset($_SESSION['image_resizing']) && $_SESSION['image_resizing']== 'resizing') or $slideshow == 1) {
$new_sizes = api_resize_image($image, $target_width, $target_height);
$result[] = $new_sizes['height'];
$result[] = $new_sizes['width'];
} else {
// Modifications by Ivan Tcholakov, 04-MAY-2009.
$result = array();
if ( (isset($_SESSION['image_resizing']) && $_SESSION['image_resizing']== 'resizing') or $slideshow == 1) {
$new_sizes = api_resize_image($image, $target_width, $target_height);
$result[] = $new_sizes['height'];
$result[] = $new_sizes['width'];
} else {
$size = api_getimagesize($image);
$result[] = $size['height'];
$result[] = $size['width'];
}
return $result;
$result[] = $size['height'];
$result[] = $size['width'];
}
return $result;
}

@ -503,7 +503,7 @@ if ($action_forums != 'add') {
$html .= '</div>';
$html .= '</div></div>';
}
echo $html;
echo $html;
}
}
if (count($forum_list) == 0) {

@ -457,8 +457,8 @@ if (!empty($attachment_list) && is_array($attachment_list)) {
// The post has been displayed => it can be removed from the what's new array
if (isset($whatsnew_post_info[$forumId][$threadId][$row['post_id']])) {
unset($whatsnew_post_info[$forumId][$threadId][$row['post_id']]);
unset($_SESSION['whatsnew_post_info'][$forumId][$threadId][$row['post_id']]);
unset($whatsnew_post_info[$forumId][$threadId][$row['post_id']]);
unset($_SESSION['whatsnew_post_info'][$forumId][$threadId][$row['post_id']]);
}
echo "</table>";

@ -162,17 +162,17 @@ if ($filter === 'true') {
if ($form->validate()) {
$officialCode = $form->getSubmitValue('filter');
if ($officialCode == 'all') {
if ($officialCode == 'all') {
$certificate_list = GradebookUtils::get_list_users_certificates($cat_id);
} else {
$userList = UserManager::getUsersByOfficialCode($officialCode);
if (!empty($userList)) {
$certificate_list = GradebookUtils::get_list_users_certificates(
$cat_id,
$userList
);
}
}
$userList = UserManager::getUsersByOfficialCode($officialCode);
if (!empty($userList)) {
$certificate_list = GradebookUtils::get_list_users_certificates(
$cat_id,
$userList
);
}
}
} else {
$certificate_list = GradebookUtils::get_list_users_certificates($cat_id);
}

@ -8,16 +8,16 @@
*/
interface GradebookItem
{
public function get_item_type();
public function get_id();
public function get_name();
public function get_description();
public function get_course_code();
public function get_weight();
public function get_date();
public function is_visible();
public function get_icon_name();
public function getStudentList();
public function setStudentList($list);
public function calc_score($stud_id = null, $type = null);
public function get_item_type();
public function get_id();
public function get_name();
public function get_description();
public function get_course_code();
public function get_weight();
public function get_date();
public function is_visible();
public function get_icon_name();
public function getStudentList();
public function setStudentList($list);
public function calc_score($stud_id = null, $type = null);
}

@ -41,26 +41,26 @@ $tbl_track_login = Database :: get_main_table(TABLE_STATISTIC_TRACK_E_LOGIN);
*/
if (isset($_POST['export'])) {
$order_clause = api_is_western_name_order(PERSON_NAME_DATA_EXPORT) ? ' ORDER BY firstname, lastname' : ' ORDER BY lastname, firstname';
$order_clause = api_is_western_name_order(PERSON_NAME_DATA_EXPORT) ? ' ORDER BY firstname, lastname' : ' ORDER BY lastname, firstname';
} else {
$order_clause = api_sort_by_first_name() ? ' ORDER BY firstname, lastname' : ' ORDER BY lastname, firstname';
$order_clause = api_sort_by_first_name() ? ' ORDER BY firstname, lastname' : ' ORDER BY lastname, firstname';
}
if (isset($_GET["id_student"])) {
$id_student = intval($_GET["id_student"]);
$sql_coachs = "SELECT DISTINCT srcru.user_id as id_coach
$id_student = intval($_GET["id_student"]);
$sql_coachs = "SELECT DISTINCT srcru.user_id as id_coach
FROM $tbl_session_rel_course_rel_user as srcru
WHERE srcru.user_id='$id_student' AND srcru.status=2";
} else {
if (api_is_platform_admin()) {
$sql_coachs = "SELECT DISTINCT
if (api_is_platform_admin()) {
$sql_coachs = "SELECT DISTINCT
srcru.user_id as id_coach, user_id, lastname, firstname
FROM $tbl_user, $tbl_session_rel_course_rel_user srcru
WHERE
srcru.user_id=user_id AND
srcru.status=2 ".$order_clause;
} else {
$sql_coachs = "SELECT DISTINCT user_id as id_coach, user.user_id, lastname, firstname
} else {
$sql_coachs = "SELECT DISTINCT user_id as id_coach, user.user_id, lastname, firstname
FROM
$tbl_user as user,
$tbl_session_rel_course_user as srcu,
@ -74,13 +74,13 @@ if (isset($_GET["id_student"])) {
srcu.user_id = user.user_id AND
srcu.status = 2
".$order_clause;
}
}
}
$result_coachs = Database::query($sql_coachs);
if (api_is_western_name_order()) {
echo '<table class="data_table">
echo '<table class="data_table">
<tr>
<th>'.get_lang('FirstName').'</th>
<th>'.get_lang('LastName').'</th>
@ -89,7 +89,7 @@ if (api_is_western_name_order()) {
<th>'.get_lang('Students').'</th>
</tr>';
} else {
echo '<table class="data_table">
echo '<table class="data_table">
<tr>
<th>'.get_lang('LastName').'</th>
<th>'.get_lang('FirstName').'</th>
@ -100,79 +100,79 @@ if (api_is_western_name_order()) {
}
if (api_is_western_name_order(PERSON_NAME_DATA_EXPORT)) {
$header[] = get_lang('FirstName', '');
$header[] = get_lang('LastName', '');
$header[] = get_lang('FirstName', '');
$header[] = get_lang('LastName', '');
} else {
$header[] = get_lang('LastName', '');
$header[] = get_lang('FirstName', '');
$header[] = get_lang('LastName', '');
$header[] = get_lang('FirstName', '');
}
$header[] = get_lang('ConnectionTime', '');
if (Database::num_rows($result_coachs) > 0) {
while ($coachs = Database::fetch_array($result_coachs)) {
$id_coach = $coachs["id_coach"];
while ($coachs = Database::fetch_array($result_coachs)) {
$id_coach = $coachs["id_coach"];
if (isset($_GET["id_student"])) {
$sql_infos_coach = "SELECT lastname, firstname
if (isset($_GET["id_student"])) {
$sql_infos_coach = "SELECT lastname, firstname
FROM $tbl_user
WHERE user_id='$id_coach'";
$result_coachs_infos = Database::query($sql_infos_coach);
$lastname = Database::result($result_coachs_infos, 0, "lastname");
$firstname = Database::result($result_coachs_infos, 0, "firstname");
} else {
$lastname = $coachs["lastname"];
$firstname = $coachs["firstname"];
}
$sql_connection_time = "SELECT login_date, logout_date
$result_coachs_infos = Database::query($sql_infos_coach);
$lastname = Database::result($result_coachs_infos, 0, "lastname");
$firstname = Database::result($result_coachs_infos, 0, "firstname");
} else {
$lastname = $coachs["lastname"];
$firstname = $coachs["firstname"];
}
$sql_connection_time = "SELECT login_date, logout_date
FROM $tbl_track_login
WHERE login_user_id ='$id_coach' AND logout_date <> 'null'";
$result_connection_time = Database::query($sql_connection_time);
$nb_seconds = 0;
while ($connections = Database::fetch_array($result_connection_time)) {
$login_date = $connections["login_date"];
$logout_date = $connections["logout_date"];
$timestamp_login_date = strtotime($login_date);
$timestamp_logout_date = strtotime($logout_date);
$nb_seconds += ($timestamp_logout_date - $timestamp_login_date);
}
if ($nb_seconds == 0) {
$s_connection_time = '';
} else {
$s_connection_time = api_time_to_hms($nb_seconds);
}
if ($i % 2 == 0) {
$css_class = "row_odd";
if ($i % 20 == 0 && $i != 0) {
if (api_is_western_name_order()) {
echo '<tr>
$result_connection_time = Database::query($sql_connection_time);
$nb_seconds = 0;
while ($connections = Database::fetch_array($result_connection_time)) {
$login_date = $connections["login_date"];
$logout_date = $connections["logout_date"];
$timestamp_login_date = strtotime($login_date);
$timestamp_logout_date = strtotime($logout_date);
$nb_seconds += ($timestamp_logout_date - $timestamp_login_date);
}
if ($nb_seconds == 0) {
$s_connection_time = '';
} else {
$s_connection_time = api_time_to_hms($nb_seconds);
}
if ($i % 2 == 0) {
$css_class = "row_odd";
if ($i % 20 == 0 && $i != 0) {
if (api_is_western_name_order()) {
echo '<tr>
<th>'.get_lang('FirstName').'</th>
<th>'.get_lang('LastName').'</th>
<th>'.get_lang('ConnectionTime').'</th>
<th>'.get_lang('AdminCourses').'</th>
<th>'.get_lang('Students').'</th>
</tr>';
} else {
echo '<tr>
} else {
echo '<tr>
<th>'.get_lang('LastName').'</th>
<th>'.get_lang('FirstName').'</th>
<th>'.get_lang('ConnectionTime').'</th>
<th>'.get_lang('AdminCourses').'</th>
<th>'.get_lang('Students').'</th>
</tr>';
}
}
} else {
$css_class = "row_even";
}
}
}
} else {
$css_class = "row_even";
}
$i++;
$i++;
if (api_is_western_name_order()) {
echo '<tr class="'.$css_class.'">
if (api_is_western_name_order()) {
echo '<tr class="'.$css_class.'">
<td>'.$firstname.'</td><td>'.$lastname.'</td><td>'.$s_connection_time.'</td>
<td>
<a href="course.php?type=coach&user_id='.$id_coach.'">
@ -185,8 +185,8 @@ if (Database::num_rows($result_coachs) > 0) {
</a>
</td>
</tr>';
} else {
echo '<tr class="'.$css_class.'">
} else {
echo '<tr class="'.$css_class.'">
<td>'.$lastname.'</td><td>'.$firstname.'</td>
<td>'.$s_connection_time.'</td>
<td>

@ -1,9 +1,9 @@
<?php
$reports_template['CourseArticulate'] = array(
'description' => 'CourseArticulate',
'getSQL' => 'reports_template_CourseArticulate_getSQL',
'wizard' =>
'description' => 'CourseArticulate',
'getSQL' => 'reports_template_CourseArticulate_getSQL',
'wizard' =>
'
<span id="CourseArticulate" class="step">
<span class="font_normal_07em_black">This report does not need any particular settings</span><br />
@ -12,113 +12,113 @@ $reports_template['CourseArticulate'] = array(
');
function reports_template_CourseArticulate_getSQL() {
// settings
// settings
// Nom, prenom
$query = 'select u.lastname as "Last name", u.firstname as "First name" ';
$query .= 'from '.Database::get_main_table(TABLE_MAIN_USER).' u ';
$query .= ' where u.user_id in ('.reports_getVisibilitySQL().') ';
$query .= ' order by u.user_id ';
$queries[0] = $query;
$extraFieldType = \Chamilo\CoreBundle\Entity\ExtraField::USER_FIELD_TYPE;
// Custom Field
foreach (array("tags" => "tags") as $k => $v) { // FIXME
$query = 'select ufv.value as "'.$v.'" ';
$query .= 'from '.Database::get_main_table(TABLE_MAIN_USER).' u ';
$query .= 'left join'.Database::get_main_table(TABLE_EXTRA_FIELD).' uf ';
$query .= ' on uf.variable ="'.$k.'" ';
$query .= 'left outer join '.Database::get_main_table(TABLE_EXTRA_FIELD_VALUES).' ufv ';
$query .= ' on ufv.item_id = u.user_id and ufv.field_id = uf.id ';
$query .= 'where ufv.extra_field_type = '.$extraFieldType.' AND u.user_id in ('.reports_getVisibilitySQL().') ';
$query .= ' order by u.user_id ';
$queries[] = $query;
}
// Nom, prenom
$query = 'select u.lastname as "Last name", u.firstname as "First name" ';
$query .= 'from '.Database::get_main_table(TABLE_MAIN_USER).' u ';
$query .= ' where u.user_id in ('.reports_getVisibilitySQL().') ';
$query .= ' order by u.user_id ';
$queries[0] = $query;
$extraFieldType = \Chamilo\CoreBundle\Entity\ExtraField::USER_FIELD_TYPE;
// Custom Field
foreach (array("tags" => "tags") as $k => $v) { // FIXME
$query = 'select ufv.value as "'.$v.'" ';
$query .= 'from '.Database::get_main_table(TABLE_MAIN_USER).' u ';
$query .= 'left join'.Database::get_main_table(TABLE_EXTRA_FIELD).' uf ';
$query .= ' on uf.variable ="'.$k.'" ';
$query .= 'left outer join '.Database::get_main_table(TABLE_EXTRA_FIELD_VALUES).' ufv ';
$query .= ' on ufv.item_id = u.user_id and ufv.field_id = uf.id ';
$query .= 'where ufv.extra_field_type = '.$extraFieldType.' AND u.user_id in ('.reports_getVisibilitySQL().') ';
$query .= ' order by u.user_id ';
$queries[] = $query;
}
// Stored Value
$sv = array();
foreach ($sv as $k => $v) {
// Stored Value
$sv = array();
foreach ($sv as $k => $v) {
if (!isset($v['sql']))
$v['sql'] = 'FIELD';
$sqlField = str_replace('FIELD', 'sv.sv_value', $v['sql']);
$query = 'select '.$sqlField.' as "'.$v['title'].'" ';
// $query = 'select sec_to_time(sv.sv_value) as "'.$v.'" ';
$query .= 'from '.Database::get_main_table(TABLE_MAIN_USER).' u ';
$query .= ' left outer join '.Database::get_main_table(TABLE_TRACK_STORED_VALUES).' sv ';
$query .= 'on sv.user_id = u.user_id and sv_key = "'.$k.'" ';
$query .= ' where u.user_id in ('.reports_getVisibilitySQL().') ';
$query .= ' group by u.user_id ';
$query .= ' order by u.user_id ';
$queries[] = $query;
}
$query .= 'from '.Database::get_main_table(TABLE_MAIN_USER).' u ';
$query .= ' left outer join '.Database::get_main_table(TABLE_TRACK_STORED_VALUES).' sv ';
$query .= 'on sv.user_id = u.user_id and sv_key = "'.$k.'" ';
$query .= ' where u.user_id in ('.reports_getVisibilitySQL().') ';
$query .= ' group by u.user_id ';
$query .= ' order by u.user_id ';
$queries[] = $query;
}
// first and last connection
$query = 'select min(tel.login_date) as "First connection", max(tel.logout_date) as "Latest connection" ';
$query .= 'from '.Database::get_main_table(TABLE_MAIN_USER).' u ';
$query .= 'left outer join '.Database::get_main_table(TABLE_STATISTIC_TRACK_E_LOGIN).' tel ';
$query .= ' on tel.login_user_id = u.user_id ';
$query .= ' where u.user_id in ('.reports_getVisibilitySQL().') ';
$query .= ' group by u.user_id ';
$query .= ' order by u.user_id ';
$queries[] = $query;
// first and last connection
$query = 'select min(tel.login_date) as "First connection", max(tel.logout_date) as "Latest connection" ';
$query .= 'from '.Database::get_main_table(TABLE_MAIN_USER).' u ';
$query .= 'left outer join '.Database::get_main_table(TABLE_STATISTIC_TRACK_E_LOGIN).' tel ';
$query .= ' on tel.login_user_id = u.user_id ';
$query .= ' where u.user_id in ('.reports_getVisibilitySQL().') ';
$query .= ' group by u.user_id ';
$query .= ' order by u.user_id ';
$queries[] = $query;
// SCORM Data
$scormData = array();
// SCORM Data
$scormData = array();
$course_list = CourseManager::get_courses_list();
foreach ($course_list as $code => $details) {
$courseId = $details['id'];
$list = Database::query('SELECT l.id as lid, l.name as lname, li.id as liid, li.title as lititle '.
' FROM '.Database::get_course_table(TABLE_LP_MAIN).' l, '.Database::get_course_table(TABLE_LP_ITEM).' li '.
' WHERE l.c_id = '.$courseId.' AND li.c_id = '.$courseId.' AND l.id = li.lp_id');
while ($lpItem = Database::fetch_assoc($list)) {
$scormData[] = array(
//'coursedb' => $details['db_name'],
'lid' => $lpItem['lid'],
'liid' => $lpItem['liid'],
'target_view_count' => 1,
'target_indicator' => 'score',
'title' => $details['title'].'/'.$lpItem['lname'].'/'.$lpItem['lititle'].'/1/score',
'sql' => 'FIELD');
$scormData[] = array(
//'coursedb' => $details['db_name'],
'lid' => $lpItem['lid'],
'liid' => $lpItem['liid'],
'target_view_count' => 2,
'target_indicator' => 'score',
'title' => $details['title'].'/'.$lpItem['lname'].'/'.$lpItem['lititle'].'/2/score',
'sql' => 'FIELD');
$scormData[] = array(
//'coursedb' => $details['db_name'],
'lid' => $lpItem['lid'],
'liid' => $lpItem['liid'],
'target_view_count' => null,
'target_indicator' => 'score',
'title' => $details['title'].'/'.$lpItem['lname'].'/'.$lpItem['lititle'].'/all/score',
'sql' => 'avg(FIELD)');
}
}
foreach ($course_list as $code => $details) {
$courseId = $details['id'];
$list = Database::query('SELECT l.id as lid, l.name as lname, li.id as liid, li.title as lititle '.
' FROM '.Database::get_course_table(TABLE_LP_MAIN).' l, '.Database::get_course_table(TABLE_LP_ITEM).' li '.
' WHERE l.c_id = '.$courseId.' AND li.c_id = '.$courseId.' AND l.id = li.lp_id');
while ($lpItem = Database::fetch_assoc($list)) {
$scormData[] = array(
//'coursedb' => $details['db_name'],
'lid' => $lpItem['lid'],
'liid' => $lpItem['liid'],
'target_view_count' => 1,
'target_indicator' => 'score',
'title' => $details['title'].'/'.$lpItem['lname'].'/'.$lpItem['lititle'].'/1/score',
'sql' => 'FIELD');
$scormData[] = array(
//'coursedb' => $details['db_name'],
'lid' => $lpItem['lid'],
'liid' => $lpItem['liid'],
'target_view_count' => 2,
'target_indicator' => 'score',
'title' => $details['title'].'/'.$lpItem['lname'].'/'.$lpItem['lititle'].'/2/score',
'sql' => 'FIELD');
$scormData[] = array(
//'coursedb' => $details['db_name'],
'lid' => $lpItem['lid'],
'liid' => $lpItem['liid'],
'target_view_count' => null,
'target_indicator' => 'score',
'title' => $details['title'].'/'.$lpItem['lname'].'/'.$lpItem['lititle'].'/all/score',
'sql' => 'avg(FIELD)');
}
}
foreach ($scormData as $v) {
foreach ($scormData as $v) {
if (!isset($v['sql'])) {
$v['sql'] = 'FIELD';
}
$sqlField = str_replace('FIELD', $v['target_indicator'], $v['sql']);
$query = 'select '.$sqlField.' as "'.$v['title'].'" ';
$query .= 'from '.Database::get_main_table(TABLE_MAIN_USER).' u ';
$query .= 'left outer join '.Database::get_course_table(TABLE_LP_VIEW).' lv ';
$query .= ' on u.user_id = lv.user_id and lv.lp_id = '.$v['lid'];
$query .= ' left outer join '.Database::get_course_table(TABLE_LP_ITEM_VIEW).' liv ';
$query .= ' on lv.id = liv.lp_view_id ';
if ($v['target_view_count'])
$query .= ' and liv.view_count = '.$v['target_view_count'];
$query .= ' and liv.lp_item_id = '.$v['liid'].' ';
$query .= ' where u.user_id in ('.reports_getVisibilitySQL().') ';
$query .= ' group by u.user_id ';
$query .= ' order by u.user_id ';
$queries[] = $query;
}
$query .= 'left outer join '.Database::get_course_table(TABLE_LP_VIEW).' lv ';
$query .= ' on u.user_id = lv.user_id and lv.lp_id = '.$v['lid'];
$query .= ' left outer join '.Database::get_course_table(TABLE_LP_ITEM_VIEW).' liv ';
$query .= ' on lv.id = liv.lp_view_id ';
if ($v['target_view_count'])
$query .= ' and liv.view_count = '.$v['target_view_count'];
$query .= ' and liv.lp_item_id = '.$v['liid'].' ';
$query .= ' where u.user_id in ('.reports_getVisibilitySQL().') ';
$query .= ' group by u.user_id ';
$query .= ' order by u.user_id ';
$queries[] = $query;
}
return $queries;
return $queries;
}

@ -196,12 +196,12 @@ if (!empty($OkMsg)) {
if (!empty($rows_session_category)) {
foreach($rows_session_category as $category) {
if($category['id'] == $categoryId)
echo '<option value="'.$category['id'].'" selected>'.$category['name'].'</option>';
else
echo '<option value="'.$category['id'].'">'.$category['name'].'</option>';
echo '<option value="'.$category['id'].'" selected>'.$category['name'].'</option>';
else
echo '<option value="'.$category['id'].'">'.$category['name'].'</option>';
}
}
?>
?>
</select>
</td>
</tr>

@ -70,13 +70,13 @@ echo Display::input('hidden', 'form_sent', '1');
<tr>
<td align="center">
<?php
echo Display::select(
'sessions[]',
$sessionList,
'',
array('style'=>'width:360px', 'multiple'=>'multiple','id'=>'sessions', 'size'=>'15px'),
false
);
echo Display::select(
'sessions[]',
$sessionList,
'',
array('style'=>'width:360px', 'multiple'=>'multiple','id'=>'sessions', 'size'=>'15px'),
false
);
?>
</td>
<td align="center">

@ -155,7 +155,7 @@ if ($sessionInfo['nbr_courses'] == 0) {
$sessionRepository = Database::getManager()->getRepository('ChamiloCoreBundle:Session');
$courses = $sessionRepository->getCoursesOrderedByPosition($session);
foreach ($courses as $course) {
foreach ($courses as $course) {
//select the number of users
$sql = "SELECT count(*)
FROM $tbl_session_rel_user sru,
@ -167,37 +167,37 @@ if ($sessionInfo['nbr_courses'] == 0) {
sru.relation_type <> ".SESSION_RELATION_TYPE_RRHH." AND
srcru.session_id = '".intval($sessionId)."'";
$rs = Database::query($sql);
$rs = Database::query($sql);
$numberOfUsers = Database::result($rs, 0, 0);
// Get coachs of the courses in session
// Get coachs of the courses in session
$sql = "SELECT user.lastname, user.firstname, user.username
$sql = "SELECT user.lastname, user.firstname, user.username
FROM $tbl_session_rel_course_rel_user session_rcru, $tbl_user user
WHERE
session_rcru.user_id = user.user_id AND
session_rcru.session_id = '".intval($sessionId)."' AND
session_rcru.c_id ='".intval($course->getId())."' AND
session_rcru.status=2";
$rs = Database::query($sql);
$rs = Database::query($sql);
$coachs = array();
if (Database::num_rows($rs) > 0) {
while($info_coach = Database::fetch_array($rs)) {
$coachs = array();
if (Database::num_rows($rs) > 0) {
while($info_coach = Database::fetch_array($rs)) {
$coachs[] = api_get_person_name(
$info_coach['firstname'],
$info_coach['lastname']
).' ('.$info_coach['username'].')';
}
} else {
$coach = get_lang('None');
}
}
} else {
$coach = get_lang('None');
}
if (count($coachs) > 0) {
$coach = implode('<br />',$coachs);
} else {
$coach = get_lang('None');
}
if (count($coachs) > 0) {
$coach = implode('<br />',$coachs);
} else {
$coach = get_lang('None');
}
$orderButtons = null;
@ -233,8 +233,8 @@ if ($sessionInfo['nbr_courses'] == 0) {
$courseUrl = api_get_course_url($course->getCode(), $sessionId);
// hide_course_breadcrumb the parameter has been added to hide the name
// of the course, that appeared in the default $interbreadcrumb
// hide_course_breadcrumb the parameter has been added to hide the name
// of the course, that appeared in the default $interbreadcrumb
$courseItem .= '
<tr>
<td class="title">'.Display::url(
@ -262,7 +262,7 @@ if ($sessionInfo['nbr_courses'] == 0) {
</td>
</tr>';
$count++;
}
}
$courseListToShow .= $courseItem;
}
$courseListToShow .= '</table><br />';

@ -29,15 +29,15 @@ $interbreadcrumb[] = array(
$sql = "SELECT * FROM $tbl_session_category WHERE id='".$id."' ORDER BY name";
$result = Database::query($sql);
if (!$infos = Database::fetch_array($result)) {
header('Location: session_list.php');
exit();
header('Location: session_list.php');
exit();
}
list($year_start,$month_start,$day_start)=explode('-',$infos['date_start']);
list($year_end,$month_end,$day_end)=explode('-',$infos['date_end']);
if (!api_is_platform_admin() && $infos['session_admin_id']!=$_user['user_id'] && !api_is_session_admin()) {
api_not_allowed(true);
api_not_allowed(true);
}
if (isset($_POST['formSent']) && $_POST['formSent']) {
@ -60,7 +60,7 @@ if (isset($_POST['formSent']) && $_POST['formSent']) {
$day_end
);
if ($return == strval(intval($return))) {
Display::addFlash(Display::return_message(get_lang('SessionCategoryUpdate')));
Display::addFlash(Display::return_message(get_lang('SessionCategoryUpdate')));
header('Location: session_category_list.php');
exit();
}
@ -73,7 +73,7 @@ $thisDay = date('d');
// display the header
Display::display_header($tool_name);
if (!empty($return)) {
Display::display_error_message($return,false);
Display::display_error_message($return,false);
}
?>
<div class="row">

@ -37,8 +37,8 @@ $sql = "SELECT s.name, c.title
$result = Database::query($sql);
if (!list($session_name,$course_title) = Database::fetch_row($result)) {
header('Location: session_course_list.php?id_session='.$id_session);
exit();
header('Location: session_course_list.php?id_session='.$id_session);
exit();
}
//$interbreadcrumb[]=array('url' => 'index.php',"name" => get_lang('PlatformAdmin'));
@ -48,63 +48,63 @@ $interbreadcrumb[]=array('url' => "session_course_list.php?id_session=$id_sessio
$arr_infos = array();
if (isset($_POST['formSent']) && $_POST['formSent']) {
$formSent = 1;
$formSent = 1;
// get all tutor by course_code in the session
$sql = "SELECT user_id
// get all tutor by course_code in the session
$sql = "SELECT user_id
FROM $tbl_session_rel_course_rel_user
WHERE session_id = '$id_session' AND c_id = '".$courseId."' AND status = 2";
$rs_coaches = Database::query($sql);
$rs_coaches = Database::query($sql);
$coaches_course_session = array();
if (Database::num_rows($rs_coaches) > 0){
while ($row_coaches = Database::fetch_row($rs_coaches)) {
$coaches_course_session[] = $row_coaches[0];
}
}
$coaches_course_session = array();
if (Database::num_rows($rs_coaches) > 0){
while ($row_coaches = Database::fetch_row($rs_coaches)) {
$coaches_course_session[] = $row_coaches[0];
}
}
$id_coaches= $_POST['id_coach'];
$id_coaches= $_POST['id_coach'];
if (is_array($id_coaches) && count($id_coaches) > 0) {
if (is_array($id_coaches) && count($id_coaches) > 0) {
foreach ($id_coaches as $id_coach) {
$id_coach = intval($id_coach);
foreach ($id_coaches as $id_coach) {
$id_coach = intval($id_coach);
$rs1 = SessionManager::set_coach_to_course_session(
$id_coach,
$id_session,
$courseId
);
}
}
// set status to 0 other tutors from multiple list
$array_intersect = array_diff($coaches_course_session,$id_coaches);
// set status to 0 other tutors from multiple list
$array_intersect = array_diff($coaches_course_session,$id_coaches);
foreach ($array_intersect as $no_coach_user_id) {
$rs2 = SessionManager::set_coach_to_course_session(
$no_coach_user_id,
$id_session,
foreach ($array_intersect as $no_coach_user_id) {
$rs2 = SessionManager::set_coach_to_course_session(
$no_coach_user_id,
$id_session,
$courseId,
true
);
}
true
);
}
header('Location: '.Security::remove_XSS($_GET['page']).'?id_session='.$id_session);
exit();
}
header('Location: '.Security::remove_XSS($_GET['page']).'?id_session='.$id_session);
exit();
}
} else {
$sql = "SELECT user_id
$sql = "SELECT user_id
FROM $tbl_session_rel_course_rel_user
WHERE
session_id = '$id_session' AND
c_id = '".$courseId."' AND
status = 2 ";
$rs = Database::query($sql);
$rs = Database::query($sql);
if (Database::num_rows($rs) > 0) {
while ($infos = Database::fetch_array($rs)) {
$arr_infos[] = $infos['user_id'];
}
}
if (Database::num_rows($rs) > 0) {
while ($infos = Database::fetch_array($rs)) {
$arr_infos[] = $infos['user_id'];
}
}
}
$order_clause = api_sort_by_first_name() ? ' ORDER BY firstname, lastname, username' : ' ORDER BY lastname, firstname, username';

@ -30,26 +30,26 @@ $sort = in_array($_GET['sort'],array('title','nbr_users'))?$_GET['sort']:'titl
$result = Database::query("SELECT name FROM $tbl_session WHERE id='$id_session'");
if (!list($session_name)=Database::fetch_row($result)) {
header('Location: session_list.php');
exit;
header('Location: session_list.php');
exit;
}
if ($action == 'delete') {
$idChecked = $_REQUEST['idChecked'];
if (is_array($idChecked) && count($idChecked)>0) {
$my_temp = array();
foreach ($idChecked as $id){
$my_temp[]= Database::escape_string($id);// forcing the escape_string
}
$idChecked = $my_temp;
$idChecked="'".implode("','", $idChecked)."'";
$result = Database::query("DELETE FROM $tbl_session_rel_course WHERE session_id='$id_session' AND c_id IN($idChecked)");
$nbr_affected_rows=Database::affected_rows($result);
Database::query("DELETE FROM $tbl_session_rel_course_rel_user WHERE session_id='$id_session' AND c_id IN($idChecked)");
Database::query("UPDATE $tbl_session SET nbr_courses=nbr_courses-$nbr_affected_rows WHERE id='$id_session'");
}
header('Location: '.api_get_self().'?id_session='.$id_session.'&sort='.$sort);
exit();
$idChecked = $_REQUEST['idChecked'];
if (is_array($idChecked) && count($idChecked)>0) {
$my_temp = array();
foreach ($idChecked as $id){
$my_temp[]= Database::escape_string($id);// forcing the escape_string
}
$idChecked = $my_temp;
$idChecked="'".implode("','", $idChecked)."'";
$result = Database::query("DELETE FROM $tbl_session_rel_course WHERE session_id='$id_session' AND c_id IN($idChecked)");
$nbr_affected_rows=Database::affected_rows($result);
Database::query("DELETE FROM $tbl_session_rel_course_rel_user WHERE session_id='$id_session' AND c_id IN($idChecked)");
Database::query("UPDATE $tbl_session SET nbr_courses=nbr_courses-$nbr_affected_rows WHERE id='$id_session'");
}
header('Location: '.api_get_self().'?id_session='.$id_session.'&sort='.$sort);
exit();
}
$limit = 20;
@ -82,17 +82,17 @@ $tableHeader[] = array(get_lang('Actions'));
$tableCourses = array();
foreach ($Courses as $key=>$enreg) {
$course = array();
$course[] = '<input type="checkbox" name="idChecked[]" value="'.$enreg['id'].'">';
$course[] = api_htmlentities($enreg['title'],ENT_QUOTES,$charset);
$course[] = '<a href="session_course_user_list.php?id_session='.$id_session.'&course_code='.$enreg['code'].'">'.$enreg['nbr_users'].' '.get_lang('Users').'</a>';
$course[] = '<a href="'.api_get_path(WEB_COURSE_PATH).$enreg['code'].'/?id_session='.$id_session.'">'.
Display::return_icon('course_home.gif', get_lang('Course')).'</a>
$course = array();
$course[] = '<input type="checkbox" name="idChecked[]" value="'.$enreg['id'].'">';
$course[] = api_htmlentities($enreg['title'],ENT_QUOTES,$charset);
$course[] = '<a href="session_course_user_list.php?id_session='.$id_session.'&course_code='.$enreg['code'].'">'.$enreg['nbr_users'].' '.get_lang('Users').'</a>';
$course[] = '<a href="'.api_get_path(WEB_COURSE_PATH).$enreg['code'].'/?id_session='.$id_session.'">'.
Display::return_icon('course_home.gif', get_lang('Course')).'</a>
<a href="session_course_edit.php?id_session='.$id_session.'&page=session_course_list.php&course_code='.$enreg['code'].'">'.
Display::return_icon('edit.png', get_lang('Edit')).'</a>
Display::return_icon('edit.png', get_lang('Edit')).'</a>
<a href="'.api_get_self().'?id_session='.$id_session.'&sort='.$sort.'&action=delete&idChecked[]='.$enreg['id'].'" onclick="javascript:if(!confirm(\''.addslashes(api_htmlentities(get_lang("ConfirmYourChoice"),ENT_QUOTES,$charset)).'\')) return false;">'.
Display::return_icon('delete.png', get_lang('Delete')).'</a>';
$tableCourses[] = $course;
Display::return_icon('delete.png', get_lang('Delete')).'</a>';
$tableCourses[] = $course;
}
echo '<form method="post" action="'.api_get_self().'">';
Display :: display_sortable_table($tableHeader, $tableCourses, array (), array ());

@ -50,8 +50,8 @@ $sql = "SELECT s.name, c.title
$result = Database::query($sql);
if (!list($session_name,$course_title) = Database::fetch_row($result)) {
header('Location: session_course_list.php?id_session='.$id_session);
exit();
header('Location: session_course_list.php?id_session='.$id_session);
exit();
}
switch ($action) {
@ -122,7 +122,7 @@ if($page) {
<a href="<?php echo api_get_self(); ?>?id_session=<?php echo $id_session; ?>&course_code=<?php echo urlencode($course_code); ?>&page=<?php echo $page-1; ?>&sort=<?php echo $sort; ?>"><?php echo get_lang('Previous');?></a>
<?php
} else {
echo get_lang('Previous');
echo get_lang('Previous');
}
?>
|
@ -132,7 +132,7 @@ if($nbr_results > $limit) {
<a href="<?php echo api_get_self(); ?>?id_session=<?php echo $id_session; ?>&course_code=<?php echo urlencode($course_code); ?>&page=<?php echo $page+1; ?>&sort=<?php echo $sort; ?>"><?php echo get_lang('Next');?></a>
<?php
} else {
echo get_lang('Next');
echo get_lang('Next');
}
?>
</div>
@ -154,9 +154,9 @@ if($nbr_results > $limit) {
$i=0;
foreach ($users as $key => $enreg) {
if ($key == $limit) {
break;
}
if ($key == $limit) {
break;
}
?>
<tr class="<?php echo $i?'row_odd':'row_even'; ?>">
<td><input type="checkbox" name="idChecked[]" value="<?php echo $enreg['user_id']; ?>"></td>

@ -14,7 +14,7 @@ use JeroenDesloovere\VCard\VCard;
api_block_anonymous_users();
if (isset($_REQUEST['userId'])) {
$userId = intval($_REQUEST['userId']);
$userId = intval($_REQUEST['userId']);
} else {
api_not_allowed();
}

@ -88,15 +88,15 @@ $isDrhOfCourse = CourseManager::isUserSubscribedInCourseAsDrh(
/** @todo this has to be moved to a more appropriate place (after the display_header of the code)*/
if (!api_is_allowed_to_edit(false, true) || $isDrhOfCourse) {
Display :: display_header(get_lang('ToolSurvey'));
Display :: display_header(get_lang('ToolSurvey'));
// Show error message if the survey can be seen only by tutors
if ($survey_data['visible_results'] != SURVEY_VISIBLE_TUTOR) {
SurveyUtil::handle_reporting_actions($survey_data, $people_filled);
} else {
Display :: display_error_message(get_lang('NotAllowed'), false);
}
Display :: display_footer();
exit;
Display :: display_footer();
exit;
}
// Database table definitions

@ -1184,16 +1184,16 @@ class SurveyManager
}
/**
* This function saves the question in the shared database
*
* @param array $form_content all the information of the form
* @param array $survey_data all the information of the survey
*
* @author Patrick Cool <patrick.cool@UGent.be>, Ghent University
* @version February 2007
*
* @todo editing of a shared question
*/
* This function saves the question in the shared database
*
* @param array $form_content all the information of the form
* @param array $survey_data all the information of the survey
*
* @author Patrick Cool <patrick.cool@UGent.be>, Ghent University
* @version February 2007
*
* @todo editing of a shared question
*/
public function save_shared_question($form_content, $survey_data)
{
$_course = api_get_course_info();

@ -48,7 +48,7 @@ $columns = array(get_lang('Name'), get_lang('Actions'));
$column_model = array(
array('name'=>'name', 'index'=>'name', 'width'=>'120', 'align'=>'left'),
array('name'=>'actions', 'index'=>'actions', 'width'=>'100', 'align'=>'left', 'sortable'=>'false')
);
);
//Autowidth
$extra_params['autowidth'] = 'true';
//height auto

@ -51,7 +51,7 @@ class Connector
'root_sys' => api_get_path(SYS_PATH),
'sys_root' => api_get_path(SYS_PATH), // just an alias
'sys_course_path' => api_get_path(SYS_COURSE_PATH),
// 'sys_config_path' => $app['path.config'],
// 'sys_config_path' => $app['path.config'],
'path.temp' => api_get_path(SYS_ARCHIVE_PATH),
//'sys_log_path' => $app['path.logs']
);
@ -326,9 +326,9 @@ class Connector
**/
public function access($attr, $path, $data, $volume)
{
return strpos(basename($path), '.') === 0 // if file/folder begins with '.' (dot)
? !($attr == 'read' || $attr == 'write') // set read+write to false, other (locked+hidden) set to true
: null; // else elFinder decide it itself
return strpos(basename($path), '.') === 0 // if file/folder begins with '.' (dot)
? !($attr == 'read' || $attr == 'write') // set read+write to false, other (locked+hidden) set to true
: null; // else elFinder decide it itself
}
/**

@ -633,8 +633,8 @@ class DropBoxDriver extends \elFinderVolumeMySQL implements DriverInterface
}
/**
* {@inheritdoc}
*/
* {@inheritdoc}
*/
protected function _archive($dir, $files, $name, $arc) {
return false;
}

@ -22,8 +22,8 @@ class Basic extends Toolbar
"searchreplace wordcount visualblocks visualchars code fullscreen insertdatetime media nonbreaking",
"save table contextmenu directionality emoticons template paste textcolor"
),
'content_css'=> "css/content.css",
'toolbar' => "insertfile undo redo | styleselect | bold italic | alignleft aligncenter alignright alignjustify | bullist numlist outdent indent | l ink image | print preview media fullpage | forecolor backcolor emoticons",
'content_css'=> "css/content.css",
'toolbar' => "insertfile undo redo | styleselect | bold italic | alignleft aligncenter alignright alignjustify | bullist numlist outdent indent | l ink image | print preview media fullpage | forecolor backcolor emoticons",
'file_browser_callback' => 'elFinderBrowser'
);

@ -86,13 +86,13 @@ class Data
return $this->get($file);
}
/**
* Gets a file from the data/courses/MATHS/scorm directory
* @param string $courseCode
* @param string $file
*
* @return SplFileInfo
*/
/**
* Gets a file from the data/courses/MATHS/scorm directory
* @param string $courseCode
* @param string $file
*
* @return SplFileInfo
*/
public function getCourseScormDocument($courseCode, $file)
{
$file = 'courses/'.$courseCode.'/scorm/'.$file;

@ -26,7 +26,6 @@ class AccessUrlRelUserGroup
* @var integer
*
* @ORM\Column(name="access_url_id", type="integer")
*/
private $accessUrlId;

@ -42,11 +42,11 @@ class ExtraFieldOptionRelFieldOption
*/
protected $relatedFieldOptionId;
/**
* @var integer
*
* @ORM\Column(name="role_id", type="integer", precision=0, scale=0, nullable=true, unique=false)
*/
/**
* @var integer
*
* @ORM\Column(name="role_id", type="integer", precision=0, scale=0, nullable=true, unique=false)
*/
protected $roleId;
/**
@ -128,12 +128,12 @@ class ExtraFieldOptionRelFieldOption
return $this->relatedFieldOptionId;
}
/**
* Set roleId
*
* @param integer $roleId
* @return ExtraFieldOptionRelFieldOption
*/
/**
* Set roleId
*
* @param integer $roleId
* @return ExtraFieldOptionRelFieldOption
*/
public function setRoleId($roleId)
{
$this->roleId = $roleId;

@ -158,13 +158,13 @@ class ExtraFieldValues extends BaseAttributeValue
return $this;
}
/**
* Set comment
*
* @param string $comment
*
* @return ExtraFieldValues
*/
/**
* Set comment
*
* @param string $comment
*
* @return ExtraFieldValues
*/
public function setComment($comment)
{
$this->comment = $comment;

@ -25,7 +25,7 @@ class SequenceRepository extends EntityRepository
*/
public function findRequirementForResource($resourceId, $type)
{
/* $criteria = Criteria::create()
/* $criteria = Criteria::create()
->where(Criteria::expr()->eq("resourceId", $resourceId))
->andWhere(Criteria::expr()->eq("type", $type));
*/

Loading…
Cancel
Save