Merge 1.10.x

remotes/angel/1.11.x
jmontoyaa 9 years ago
commit 4d9e96c841
  1. 14
      documentation/optimization.html
  2. 2
      main/admin/add_users_to_usergroup.php
  3. 17
      main/auth/external_login/newUser.ldap.php
  4. 98
      main/coursecopy/classes/Announcement.class.php
  5. 26
      main/coursecopy/classes/Attendance.class.php
  6. 69
      main/coursecopy/classes/CourseDescription.class.php
  7. 2
      main/coursecopy/classes/CourseSelectForm.class.php
  8. 37
      main/coursecopy/classes/CourseSession.class.php
  9. 3
      main/coursecopy/classes/DummyCourseCreator.class.php
  10. 2
      main/coursecopy/classes/Event.class.php
  11. 5
      main/coursecopy/classes/Forum.class.php
  12. 2
      main/coursecopy/classes/ForumCategory.class.php
  13. 4
      main/coursecopy/classes/ForumTopic.class.php
  14. 50
      main/coursecopy/classes/Glossary.class.php
  15. 73
      main/coursecopy/classes/Link.class.php
  16. 66
      main/coursecopy/classes/LinkCategory.class.php
  17. 4
      main/coursecopy/classes/Quiz.class.php
  18. 53
      main/coursecopy/classes/Resource.class.php
  19. 22
      main/coursecopy/classes/ScormDocument.class.php
  20. 206
      main/coursecopy/classes/Survey.class.php
  21. 92
      main/coursecopy/classes/SurveyInvitation.class.php
  22. 175
      main/coursecopy/classes/SurveyQuestion.class.php
  23. 2
      main/coursecopy/classes/Thematic.class.php
  24. 150
      main/coursecopy/classes/ToolIntro.class.php
  25. 2
      main/coursecopy/classes/Work.class.php
  26. 84
      main/coursecopy/classes/wiki.class.php
  27. 34
      main/inc/lib/message.lib.php
  28. 24
      main/inc/lib/usermanager.lib.php
  29. 4
      main/inc/local.inc.php
  30. 216
      main/lang/english/trad4all.inc.php
  31. 13
      main/template/default/mail/new_user_mail_to_admin.tpl
  32. 20
      src/Chamilo/CoreBundle/Entity/Tag.php
  33. 19
      src/Chamilo/CoreBundle/Entity/TrackECourseAccess.php
  34. 1
      src/Chamilo/CoreBundle/Entity/TrackEUploads.php
  35. 23
      src/Chamilo/CoreBundle/Entity/TrackStoredValuesStack.php
  36. 20
      src/Chamilo/CoreBundle/Entity/UserApiKey.php
  37. 20
      src/Chamilo/CoreBundle/Entity/UserCourseCategory.php
  38. 1
      src/Chamilo/CoreBundle/Entity/UserGroupRelUserGroup.php
  39. 1
      src/Chamilo/CoreBundle/Entity/UserRelCourseVote.php
  40. 21
      src/Chamilo/CoreBundle/Entity/UserRelEventType.php
  41. 20
      src/Chamilo/CoreBundle/Entity/UserRelUser.php
  42. 2
      src/Chamilo/CoreBundle/Entity/Usergroup.php
  43. 19
      src/Chamilo/CoreBundle/Entity/UsergroupRelCourse.php
  44. 21
      src/Chamilo/CoreBundle/Entity/UsergroupRelQuestion.php
  45. 19
      src/Chamilo/CoreBundle/Entity/UsergroupRelSession.php
  46. 8
      src/Chamilo/CoreBundle/Entity/UsergroupRelUser.php

@ -342,7 +342,7 @@ ALTER TABLE user_rel_tag ADD INDEX idx_user_rel_tag_user (user_id);
In Chamilo 1.10.0 (the first version of the serie), many indexes were forgotten, so you can boost your database by adding the following indexes:<br />
<pre>
alter table extra_field_values add index idx_extra_field_values (field_id, item_id);
alter table usergroup_rel_user add index idx_usergroup_ru (group_id);
alter table usergroup_rel_user add index idx_usergroup_ru (usergroup_id);
alter table usergroup_rel_user add index idx_usergroup_ru_u (user_id);
alter table c_student_publication add index idxstudpub_cid (c_id);
alter table c_student_publication add index idxstudpub_uid (user_id);
@ -558,23 +558,23 @@ This is easy, doesn't require a server reload and you should see the results pre
you should avoid using this technique.
</p>
<p>
You can also mitigate the risk by disabling permissions check only
You can also mitigate the risk by disabling permissions check only
for some static resource like css,js and fonts files.
<br/>
For that is required to load header module
For that is required to load header module
in apache (check with a2enmod in your favorite root terminal)<br />
add theses line after RewriteBase /courses/:
<pre>
&lt;IfModule mod_headers.c&gt;
# all file name ended with these extensions names will bypass the permission check (and also served by the browser cache at the next request)
&lt;FilesMatch &quot;\.(gif|jpg|jpeg|png|js|pdf|ico|icon|css|swf|avi|mp3|ogg|wav|ttf|otf|eot|woff)$&quot;&gt;
Header unset Cache-Control
Header set Cache-Control &quot;public, max-age=29030400&quot;
RequestHeader unset Cookie
Header unset Cache-Control
Header set Cache-Control &quot;public, max-age=29030400&quot;
RequestHeader unset Cookie
Header unset ETag
&lt;/FilesMatch&gt;
&lt;/IfModule&gt;
# also adjust files here
# also adjust files here
RewriteRule (\.(html|gif|jpg|jpeg|png|js|pdf|ico|icon|css|swf|avi|mp3|ogg|wav|ttf|otf|eot|woff))$ - [L]
</pre>
</p>

@ -177,7 +177,7 @@ if ($use_extra_fields) {
if (count($extra_field_result)>1) {
for ($i=0; $i<count($extra_field_result)-1; $i++) {
if (is_array($extra_field_result[$i+1])) {
$final_result = array_intersect($extra_field_result[$i], $extra_field_result[$i+1]);
$final_result = array_intersect($extra_field_result[$i], $extra_field_result[$i+1]);
}
}
} else {

@ -44,26 +44,31 @@ require_once dirname(__FILE__) . '/functions.inc.php';
$ldap_user = extldap_authenticate($login, $password);
if ($ldap_user !== false) {
$em = Database::getManager();
$chamilo_user = extldap_get_chamilo_user($ldap_user);
//username is not on the ldap, we have to use $login variable
$chamilo_user['username'] = $login;
$chamilo_uid = external_add_user($chamilo_user);
if ($chamilo_uid !== false) {
$chamiloUser = $em->find('ChamiloUserBundle:User', $chamilo_uid);
if ($chamiloUser) {
$loginFailed = false;
$_user['user_id'] = $chamilo_uid;
$_user['status'] = (isset($chamilo_user['status']) ? $chamilo_user['status'] : 5);
$_user['user_id'] = $chamiloUser->getId();
$_user['status'] = $chamiloUser->getStatus();
$_user['uidReset'] = true;
Session::write('_user', $_user);
$uidReset = true;
// Is user admin?
if ($chamilo_user['admin'] === true) {
$is_platformAdmin = true;
Database::query("INSERT INTO admin values ('$chamilo_uid')");
Database::query("INSERT INTO admin values ('{$chamiloUser->getId()}')");
}
Event::event_login($chamilo_uid);
Event::event_login($chamiloUser->getId());
MessageManager::sendNotificationByRegisteredUser($chamiloUser);
}
} else {
$loginFailed = true;
$uidReset = false;
unset($_user['user_id']);
}

@ -10,25 +10,25 @@ require_once 'Resource.class.php';
*/
class Announcement extends Coursecopy\Resource
{
/**
* The title of the announcement
*/
/**
* The title of the announcement
*/
public $title;
/**
* The content of the announcement
*/
/**
* The content of the announcement
*/
public $content;
/**
* The date on which this announcement was made
*/
/**
* The date on which this announcement was made
*/
public $date;
/**
* The display order of this announcement
*/
/**
* The display order of this announcement
*/
public $display_order;
/**
* Has the e-mail been sent?
*/
/**
* Has the e-mail been sent?
*/
public $email_sent;
public $attachment_path;
@ -39,36 +39,46 @@ class Announcement extends Coursecopy\Resource
public $attachment_comment;
/**
* Create a new announcement
* @param int $id
* @param string $title
* @param string $content
* @param string $date
* @param int display_order
*/
function __construct($id, $title, $content, $date, $display_order, $email_sent, $path, $filename, $size, $comment)
{
parent::__construct($id,RESOURCE_ANNOUNCEMENT);
/**
* Create a new announcement
* @param int $id
* @param string $title
* @param string $content
* @param string $date
* @param int display_order
*/
public function __construct(
$id,
$title,
$content,
$date,
$display_order,
$email_sent,
$path,
$filename,
$size,
$comment
) {
parent::__construct($id,RESOURCE_ANNOUNCEMENT);
$this->content = $content;
$this->title = $title;
$this->date = $date;
$this->display_order = $display_order;
$this->email_sent = $email_sent;
$this->content = $content;
$this->title = $title;
$this->date = $date;
$this->display_order = $display_order;
$this->email_sent = $email_sent;
$this->attachment_path = $path;
$this->attachment_filename = $filename;
$this->attachment_size = $size;
$this->attachment_comment = $comment;
}
$this->attachment_path = $path;
$this->attachment_filename = $filename;
$this->attachment_size = $size;
$this->attachment_comment = $comment;
}
/**
* Show this announcement
*/
function show()
{
parent::show();
echo $this->date.': '.$this->title;
}
/**
* Show this announcement
*/
function show()
{
parent::show();
echo $this->date.': '.$this->title;
}
}

@ -13,28 +13,28 @@ class Attendance extends Coursecopy\Resource
public $params = array();
public $attendance_calendar = array();
/**
* Create a new Thematic
*
* @param array parameters
*/
/**
* Create a new Thematic
*
* @param array parameters
*/
public function __construct($params)
{
parent::__construct($params['id'], RESOURCE_ATTENDANCE);
$this->params = $params;
}
parent::__construct($params['id'], RESOURCE_ATTENDANCE);
$this->params = $params;
}
/**
* @inheritdoc
*/
public function show()
{
parent::show();
echo $this->params['name'];
}
parent::show();
echo $this->params['name'];
}
public function add_attendance_calendar($data)
{
$this->attendance_calendar[] = $data;
}
$this->attendance_calendar[] = $data;
}
}

@ -1,6 +1,7 @@
<?php
/* For licensing terms, see /license.txt */
namespace Coursecopy;
require_once 'Resource.class.php';
/**
@ -10,39 +11,41 @@ require_once 'Resource.class.php';
*/
class CourseDescription extends Resource
{
/**
* The title
*/
public $title;
/**
* The content
*/
public $content;
/**
* The description type
*/
public $description_type;
/**
* The title
*/
public $title;
/**
* The content
*/
public $content;
/**
* The description type
*/
public $description_type;
/**
* Create a new course description
* @param int $id
* @param string $title
* @param string $content
*/
public function __construct($id,$title,$content,$description_type)
{
parent::__construct($id,RESOURCE_COURSEDESCRIPTION);
$this->title = $title;
$this->content = $content;
$this->description_type = $description_type;
}
/**
* Create a new course description
* @param int $id
* @param string $title
* @param string $content
*/
public function __construct($id, $title, $content, $description_type)
{
parent::__construct($id, RESOURCE_COURSEDESCRIPTION);
$this->title = $title;
$this->content = $content;
$this->description_type = $description_type;
}
/**
* Show this Event
*/
function show()
{
parent::show();
echo $this->title;
}
/**
* Show this Event
*/
public function show()
{
parent::show();
echo $this->title;
}
}

@ -16,7 +16,7 @@ class CourseSelectForm
* @param array $hidden_fields Hidden fields to add to the form.
* @param boolean the document array will be serialize. This is used in the course_copy.php file
*/
static function display_form($course, $hidden_fields = null, $avoid_serialize = false)
public static function display_form($course, $hidden_fields = null, $avoid_serialize = false)
{
global $charset;
$resource_titles[RESOURCE_GRADEBOOK] = get_lang('Gradebook');

@ -11,24 +11,25 @@ require_once 'Resource.class.php';
class CourseSession extends Coursecopy\Resource
{
// The title session
public $title;
public $title;
/**
* Create a new Session
* @param int $id
* @param string $title
*/
public function __construct($id,$title)
{
parent::__construct($id, RESOURCE_SESSION_COURSE);
$this->title = $title;
}
/**
* Create a new Session
* @param int $id
* @param string $title
*/
public function __construct($id,$title)
{
parent::__construct($id, RESOURCE_SESSION_COURSE);
$this->title = $title;
}
/**
* Show this Event
*/
function show() {
parent::show();
echo $this->title;
}
/**
* Show this Event
*/
public function show()
{
parent::show();
echo $this->title;
}
}

@ -60,10 +60,11 @@ class DummyCourseCreator
$cr->restore($course_code);
rmdirr($tmp_path);
}
/**
* Create dummy documents
*/
function create_dummy_documents()
public function create_dummy_documents()
{
$course = api_get_course_info();
$course_doc_path = $this->course->backup_path.'/document/';

@ -80,7 +80,7 @@ class CalendarEvent extends Coursecopy\Resource
/**
* Show this Event
*/
function show()
public function show()
{
parent::show();
echo $this->title.' ('.$this->start_date.' -> '.$this->end_date.')';

@ -103,7 +103,7 @@ class Forum extends Coursecopy\Resource
/**
* Create a new Forum
*/
function __construct($obj)
public function __construct($obj)
{
parent::__construct($obj->forum_id, RESOURCE_FORUM);
$this->obj = $obj;
@ -112,7 +112,8 @@ class Forum extends Coursecopy\Resource
/**
* Show this resource
*/
function show() {
public function show()
{
parent::show();
echo $this->obj->forum_title;
}

@ -22,7 +22,7 @@ class ForumCategory extends Coursecopy\Resource
/**
* Show this resource
*/
function show()
public function show()
{
parent::show();
echo $this->obj->cat_title;

@ -15,7 +15,7 @@ class ForumTopic extends Coursecopy\Resource
*/
/* function ForumTopic($id, $title, $time, $topic_poster_id, $topic_poster_name, $forum_id, $last_post, $replies, $views = 0, $sticky = 0, $locked = 0,
$time_closed = null, $weight = 0, $title_qualify = null, $qualify_max = 0) */
function __construct($obj)
public function __construct($obj)
{
parent::__construct($obj->thread_id, RESOURCE_FORUMTOPIC);
$this->obj = $obj;
@ -39,7 +39,7 @@ class ForumTopic extends Coursecopy\Resource
/**
* Show this resource
*/
function show()
public function show()
{
parent::show();
$extra = api_convert_and_format_date($this->obj->thread_date);

@ -10,33 +10,33 @@ require_once 'Resource.class.php';
*/
class Glossary extends Coursecopy\Resource
{
public $glossary_id;
public $name;
public $description;
public $display_order;
public $glossary_id;
public $name;
public $description;
public $display_order;
/**
* Create a new Glossary
* @param int $id
* @param string $name
* @param string $description
* @param int $display_order
*/
/**
* Create a new Glossary
* @param int $id
* @param string $name
* @param string $description
* @param int $display_order
*/
public function __construct($id,$name,$description,$display_order)
{
parent::__construct($id,RESOURCE_GLOSSARY);
$this->glossary_id = $id;
$this->name = $name;
$this->description = $description;
$this->display_order = $display_order;
}
{
parent::__construct($id,RESOURCE_GLOSSARY);
$this->glossary_id = $id;
$this->name = $name;
$this->description = $description;
$this->display_order = $display_order;
}
/**
* Show this glossary
*/
public function show()
/**
* Show this glossary
*/
public function show()
{
parent::show();
echo $this->name;
}
parent::show();
echo $this->name;
}
}

@ -11,33 +11,33 @@ require_once 'Resource.class.php';
*/
class Link extends Coursecopy\Resource
{
/**
* The title
*/
/**
* The title
*/
public $title;
/**
* The URL
*/
/**
* The URL
*/
public $url;
/**
* The description
*/
/**
* The description
*/
public $description;
/**
* Id of this links category
*/
/**
* Id of this links category
*/
public $category_id;
/**
* Display link on course homepage
*/
/**
* Display link on course homepage
*/
public $on_homepage;
/**
* Create a new Link
* @param int $id The id of this link in the Chamilo-course
* @param string $title
* @param string $url
* @param string $description
*/
/**
* Create a new Link
* @param int $id The id of this link in the Chamilo-course
* @param string $title
* @param string $url
* @param string $description
*/
public function __construct(
$id,
$title,
@ -45,22 +45,21 @@ class Link extends Coursecopy\Resource
$description,
$category_id,
$on_homepage
)
{
parent::__construct($id,RESOURCE_LINK);
$this->title = $title;
$this->url = $url;
$this->description = $description;
$this->category_id = $category_id;
$this->on_homepage = $on_homepage;
}
) {
parent::__construct($id,RESOURCE_LINK);
$this->title = $title;
$this->url = $url;
$this->description = $description;
$this->category_id = $category_id;
$this->on_homepage = $on_homepage;
}
/**
* Show this resource
*/
* Show this resource
*/
public function show()
{
parent::show();
echo $this->title.' ('.$this->url.')';
}
{
parent::show();
echo $this->title.' ('.$this->url.')';
}
}

@ -10,39 +10,39 @@ require_once 'Resource.class.php';
*/
class LinkCategory extends Coursecopy\Resource
{
/**
* The title
*/
public $title;
/**
* The description
*/
public $description;
/**
* The display order
*/
public $display_order;
/**
* The title
*/
public $title;
/**
* The description
*/
public $description;
/**
* The display order
*/
public $display_order;
/**
* Create a new LinkCategory
* @param int $id
* @param string $title
* @param string $description
*/
function __construct($id,$title,$description,$display_order)
{
parent::__construct($id,RESOURCE_LINKCATEGORY);
$this->title = $title;
$this->description = $description;
$this->display_order = $display_order;
}
/**
* Create a new LinkCategory
* @param int $id
* @param string $title
* @param string $description
*/
public function __construct($id,$title,$description,$display_order)
{
parent::__construct($id,RESOURCE_LINKCATEGORY);
$this->title = $title;
$this->description = $description;
$this->display_order = $display_order;
}
/**
* Show this LinkCategory
*/
function show()
{
parent::show();
echo $this->title.' '.$this->description.'<br />';
}
/**
* Show this LinkCategory
*/
public function show()
{
parent::show();
echo $this->title.' '.$this->description.'<br />';
}
}

@ -21,6 +21,10 @@ class Quiz extends Coursecopy\Resource
*/
public $obj; //question
/**
* Quiz constructor.
* @param int $obj
*/
public function __construct($obj)
{
$this->obj = $obj;

@ -233,28 +233,49 @@ class Resource
}
/**
* Fix objects coming from 1.9.x to 1.10.x
* Fix objects coming from 1.9.x to 1.10.x
* Example class Event to CalendarEvent
*
* @param Resource $resource
*/
public static function setClassType(&$resource)
{
if (get_class($resource) == 'Event') {
/** @var $resource CalendarEvent */
$newResource = new CalendarEvent(
$resource->source_id,
$resource->title,
$resource->content,
$resource->start_date,
$resource->end_date,
$resource->attachment_path,
$resource->attachment_filename,
$resource->attachment_size,
$resource->attachment_comment,
$resource->all_day
);
$resource = $newResource;
$class = get_class($resource);
switch ($class) {
case 'Event':
/** @var $resource \CalendarEvent */
$newResource = new \CalendarEvent(
$resource->source_id,
$resource->title,
$resource->content,
$resource->start_date,
$resource->end_date,
$resource->attachment_path,
$resource->attachment_filename,
$resource->attachment_size,
$resource->attachment_comment,
$resource->all_day
);
$resource = $newResource;
break;
case 'CourseDescription':
if (!method_exists($resource, 'show')) {
$resource = (array) $resource;
$newResource = new CourseDescription(
isset($resource['id']) ? $resource['id'] : '',
$resource['title'],
$resource['content'],
$resource['description_type']
);
$newResource->source_id = $resource['source_id'];
$newResource->destination_id = $resource['source_id'];
$newResource->linked_resources = $resource['source_id'];
$newResource->item_properties = $resource['source_id'];
$newResource->obj = $resource['obj'];
$resource = $newResource;
}
break;
}
}
}

@ -13,18 +13,18 @@ class ScormDocument extends Coursecopy\Resource
public $path;
public $title;
/**
* Create a new Scorm Document
* @param int $id
* @param string $path
* @param string $title
*/
/**
* Create a new Scorm Document
* @param int $id
* @param string $path
* @param string $title
*/
public function __construct($id, $path, $title)
{
parent::__construct($id,RESOURCE_SCORM);
$this->path = 'scorm'.$path;
$this->title = $title;
}
{
parent::__construct($id,RESOURCE_SCORM);
$this->path = 'scorm'.$path;
$this->title = $title;
}
/**
* Show this document

@ -10,86 +10,86 @@ require_once 'Resource.class.php';
*/
class Survey extends Coursecopy\Resource
{
/**
* The survey code
*/
/**
* The survey code
*/
public $code;
/**
* The title and subtitle
*/
/**
* The title and subtitle
*/
public $title;
public $subtitle;
/**
* The author's name
*/
/**
* The author's name
*/
public $author;
/**
* The survey's language
*/
/**
* The survey's language
*/
public $lang;
/**
* The availability period
*/
/**
* The availability period
*/
public $avail_from;
public $avail_till;
/**
* Flag for shared status
*/
/**
* Flag for shared status
*/
public $is_shared;
/**
* Template used
*/
/**
* Template used
*/
public $template;
/**
* Introduction text
*/
/**
* Introduction text
*/
public $intro;
/**
* Thanks text
*/
/**
* Thanks text
*/
public $surveythanks;
/**
* Creation date
*/
/**
* Creation date
*/
public $creation_date;
/**
* Invitation status
*/
/**
* Invitation status
*/
public $invited;
/**
* Answer status
*/
/**
* Answer status
*/
public $answered;
/**
* Invitation and reminder mail contents
*/
/**
* Invitation and reminder mail contents
*/
public $invite_mail;
public $reminder_mail;
/**
* Questions and invitations lists
*/
/**
* Questions and invitations lists
*/
public $question_ids;
public $invitation_ids;
/**
* Create a new Survey
* @param string $code
* @param string $title
* @param string $subtitle
* @param string $author
* @param string $lang
* @param string $avail_from
* @param string $avail_till
* @param char $is_shared
* @param string $template
* @param string $intro
* @param string $surveythanks
* @param string $creation_date
* @param int $invited
* @param int $answered
* @param string $invite_mail
* @param string $reminder_mail
*/
/**
* Create a new Survey
* @param string $code
* @param string $title
* @param string $subtitle
* @param string $author
* @param string $lang
* @param string $avail_from
* @param string $avail_till
* @param char $is_shared
* @param string $template
* @param string $intro
* @param string $surveythanks
* @param string $creation_date
* @param int $invited
* @param int $answered
* @param string $invite_mail
* @param string $reminder_mail
*/
public function __construct(
$id,
$code,
@ -109,49 +109,49 @@ class Survey extends Coursecopy\Resource
$invite_mail,
$reminder_mail
) {
parent::__construct($id,RESOURCE_SURVEY);
$this->code = $code;
$this->title = $title;
$this->subtitle = $subtitle;
$this->author = $author;
$this->lang = $lang;
$this->avail_from = $avail_from;
$this->avail_till = $avail_till;
$this->is_shared = $is_shared;
$this->template = $template;
$this->intro = $intro;
$this->surveythanks = $surveythanks;
$this->creation_date = $creation_date;
$this->invited = $invited;
$this->answered = $answered;
$this->invite_mail = $invite_mail;
$this->reminder_mail = $reminder_mail;
$this->question_ids = array();
$this->invitation_ids = array();
}
parent::__construct($id, RESOURCE_SURVEY);
$this->code = $code;
$this->title = $title;
$this->subtitle = $subtitle;
$this->author = $author;
$this->lang = $lang;
$this->avail_from = $avail_from;
$this->avail_till = $avail_till;
$this->is_shared = $is_shared;
$this->template = $template;
$this->intro = $intro;
$this->surveythanks = $surveythanks;
$this->creation_date = $creation_date;
$this->invited = $invited;
$this->answered = $answered;
$this->invite_mail = $invite_mail;
$this->reminder_mail = $reminder_mail;
$this->question_ids = array();
$this->invitation_ids = array();
}
/**
* Add a question to this survey
*/
function add_question($id)
{
$this->question_ids[] = $id;
}
/**
* Add a question to this survey
*/
public function add_question($id)
{
$this->question_ids[] = $id;
}
/**
* Add an invitation to this survey
*/
function add_invitation($id)
{
$this->invitation_ids[] = $id;
}
/**
* Add an invitation to this survey
*/
public function add_invitation($id)
{
$this->invitation_ids[] = $id;
}
/**
* Show this survey
*/
function show()
{
parent::show();
echo $this->code.' - '.$this->title;
}
/**
* Show this survey
*/
public function show()
{
parent::show();
echo $this->code.' - '.$this->title;
}
}

@ -10,52 +10,52 @@ require_once 'Resource.class.php';
*/
class SurveyInvitation extends Coursecopy\Resource
{
/**
* Survey code
*/
public $code;
/**
* User info
*/
public $user;
/**
* Invitation code
*/
public $invitation_code;
/**
* Invitation date
*/
public $invitation_date;
/**
* Reminder date
*/
public $reminder_date;
/**
* Survey code
*/
public $code;
/**
* User info
*/
public $user;
/**
* Invitation code
*/
public $invitation_code;
/**
* Invitation date
*/
public $invitation_date;
/**
* Reminder date
*/
public $reminder_date;
/**
* Create a new SurveyInvitation
* @param int $id
* @param string $code
* @param string $user
* @param string $invitation_code
* @param string $invitation_date
* @param string $reminder_date
*/
public function __construct($id,$code,$user,$invitation_code,$invitation_date,$reminder_date)
{
parent::__construct($id, RESOURCE_SURVEYINVITATION);
$this->code = $code;
$this->user = $user;
$this->invitation_code = $invitation_code;
$this->invitation_date = $invitation_date;
$this->reminder_date = $reminder_date;
}
/**
* Create a new SurveyInvitation
* @param int $id
* @param string $code
* @param string $user
* @param string $invitation_code
* @param string $invitation_date
* @param string $reminder_date
*/
public function __construct($id, $code, $user, $invitation_code, $invitation_date, $reminder_date)
{
parent::__construct($id, RESOURCE_SURVEYINVITATION);
$this->code = $code;
$this->user = $user;
$this->invitation_code = $invitation_code;
$this->invitation_date = $invitation_date;
$this->reminder_date = $reminder_date;
}
/**
* Show this invitation
*/
function show()
{
parent::show();
echo $this->invitation_code;
}
/**
* Show this invitation
*/
public function show()
{
parent::show();
echo $this->invitation_code;
}
}

@ -10,93 +10,94 @@ require_once 'Resource.class.php';
*/
class SurveyQuestion extends Coursecopy\Resource
{
/**
* Survey ID
*/
public $survey_id;
/**
* Question and question comment
*/
public $survey_question;
public $survey_question_comment;
/**
* Question type
*/
public $survey_question_type;
/**
* Display ?
*/
public $display;
/**
* Sorting order
*/
public $sort;
/**
* Shared question ID
*/
public $shared_question_id;
/**
* Maximum value for the vote
*/
public $max_value;
/**
* Survey ID
*/
public $survey_id;
/**
* Question and question comment
*/
public $survey_question;
public $survey_question_comment;
/**
* Question type
*/
public $survey_question_type;
/**
* Display ?
*/
public $display;
/**
* Sorting order
*/
public $sort;
/**
* Shared question ID
*/
public $shared_question_id;
/**
* Maximum value for the vote
*/
public $max_value;
/**
* Question's options
*/
public $options;
/**
* Question's options
*/
public $options;
/**
* Create a new SurveyQuestion
* @param int $id
* @param int $survey_id
* @param string $survey_question
* @param string $survey_question_comment
* @param string $type
* @param string $display
* @param int $sort
* @param int $shared_question_id
* @param int $max_value
*/
function __construct(
$id,
$survey_id,
$survey_question,
$survey_question_comment,
$type,
$display,
$sort,
$shared_question_id,
$max_value
) {
parent::__construct($id,RESOURCE_SURVEYQUESTION);
$this->survey_id = $survey_id;
$this->survey_question = $survey_question;
$this->survey_question_comment = $survey_question_comment;
$this->survey_question_type = $type;
$this->display = $display;
$this->sort = $sort;
$this->shared_question_id = $shared_question_id;
$this->max_value = $max_value;
$this->answers = array();
}
/**
* Add an answer option to this SurveyQuestion
* @param string $option_text
* @param int $sort
*/
function add_answer($option_text,$sort)
{
$answer = array();
$answer['option_text'] = $option_text;
$answer['sort'] = $sort;
$this->answers[] = $answer;
}
/**
* Show this question
*/
function show()
{
parent::show();
echo $this->survey_question;
}
/**
* Create a new SurveyQuestion
* @param int $id
* @param int $survey_id
* @param string $survey_question
* @param string $survey_question_comment
* @param string $type
* @param string $display
* @param int $sort
* @param int $shared_question_id
* @param int $max_value
*/
public function __construct(
$id,
$survey_id,
$survey_question,
$survey_question_comment,
$type,
$display,
$sort,
$shared_question_id,
$max_value
) {
parent::__construct($id, RESOURCE_SURVEYQUESTION);
$this->survey_id = $survey_id;
$this->survey_question = $survey_question;
$this->survey_question_comment = $survey_question_comment;
$this->survey_question_type = $type;
$this->display = $display;
$this->sort = $sort;
$this->shared_question_id = $shared_question_id;
$this->max_value = $max_value;
$this->answers = array();
}
/**
* Add an answer option to this SurveyQuestion
* @param string $option_text
* @param int $sort
*/
public function add_answer($option_text,$sort)
{
$answer = array();
$answer['option_text'] = $option_text;
$answer['sort'] = $sort;
$this->answers[] = $answer;
}
/**
* Show this question
*/
public function show()
{
parent::show();
echo $this->survey_question;
}
}

@ -16,7 +16,7 @@ class Thematic extends Coursecopy\Resource
/**
* Create a new Thematic
*
* @param array parameters
* @param array $params
*/
public function __construct($params)
{

@ -10,82 +10,82 @@ require_once 'Resource.class.php';
*/
class ToolIntro extends Coursecopy\Resource
{
public $id;
public $id;
/**
* intro text
*/
public $intro_text;
/**
* intro text
*/
public $intro_text;
/**
* Create a new text introduction
* @param int $id The id of this tool introduction in the Chamilo-course
* @param string $intro_text
*/
public function __construct($id, $intro_text)
{
parent::__construct($id, RESOURCE_TOOL_INTRO);
$this->id = $id;
$this->intro_text = $intro_text;
}
/**
* Create a new text introduction
* @param int $id The id of this tool introduction in the Chamilo-course
* @param string $intro_text
*/
public function __construct($id, $intro_text)
{
parent::__construct($id, RESOURCE_TOOL_INTRO);
$this->id = $id;
$this->intro_text = $intro_text;
}
/**
* Show this resource
*/
function show()
{
parent::show();
switch ($this->id)
{
case TOOL_DOCUMENT:
$lang_id = 'Documents';
break;
case TOOL_CALENDAR_EVENT:
$lang_id = 'Agenda';
break;
case TOOL_LINK:
$lang_id = 'Links';
break;
case TOOL_LEARNPATH:
$lang_id = 'LearningPath';
break;
case TOOL_ANNOUNCEMENT:
$lang_id = 'Announcements';
break;
case TOOL_FORUM:
$lang_id = 'Forums';
break;
case TOOL_DROPBOX:
$lang_id = 'Dropbox';
break;
case TOOL_QUIZ:
$lang_id = 'Exercises';
break;
case TOOL_USER:
$lang_id = 'Users';
break;
case TOOL_GROUP:
$lang_id = 'Group';
break;
case TOOL_WIKI:
$lang_id = 'Wiki';
break;
case TOOL_STUDENTPUBLICATION:
$lang_id = 'StudentPublications';
break;
case TOOL_COURSE_HOMEPAGE:
$lang_id = 'CourseHomepageLink';
break;
case TOOL_GLOSSARY:
$lang_id = 'Glossary';
break;
case TOOL_NOTEBOOK:
$lang_id = 'Notebook';
break;
default:
$lang_id = ucfirst($this->id); // This is a wild guess.
}
echo '<strong>'.get_lang($lang_id, '').':</strong><br />';
echo $this->intro_text;
}
/**
* Show this resource
*/
public function show()
{
parent::show();
switch ($this->id)
{
case TOOL_DOCUMENT:
$lang_id = 'Documents';
break;
case TOOL_CALENDAR_EVENT:
$lang_id = 'Agenda';
break;
case TOOL_LINK:
$lang_id = 'Links';
break;
case TOOL_LEARNPATH:
$lang_id = 'LearningPath';
break;
case TOOL_ANNOUNCEMENT:
$lang_id = 'Announcements';
break;
case TOOL_FORUM:
$lang_id = 'Forums';
break;
case TOOL_DROPBOX:
$lang_id = 'Dropbox';
break;
case TOOL_QUIZ:
$lang_id = 'Exercises';
break;
case TOOL_USER:
$lang_id = 'Users';
break;
case TOOL_GROUP:
$lang_id = 'Group';
break;
case TOOL_WIKI:
$lang_id = 'Wiki';
break;
case TOOL_STUDENTPUBLICATION:
$lang_id = 'StudentPublications';
break;
case TOOL_COURSE_HOMEPAGE:
$lang_id = 'CourseHomepageLink';
break;
case TOOL_GLOSSARY:
$lang_id = 'Glossary';
break;
case TOOL_NOTEBOOK:
$lang_id = 'Notebook';
break;
default:
$lang_id = ucfirst($this->id); // This is a wild guess.
}
echo '<strong>'.get_lang($lang_id, '').':</strong><br />';
echo $this->intro_text;
}
}

@ -15,7 +15,7 @@ class Work extends Coursecopy\Resource
/**
* Create a new Work
*
* @param array parameters
* @param array $params
*/
public function __construct($params)
{

@ -9,43 +9,43 @@
*/
class Wiki extends Coursecopy\Resource
{
public $id;
public $page_id;
public $reflink;
public $title;
public $content;
public $user_id;
public $group_id;
public $timestamp;
public $progress;
public $version;
public $id;
public $page_id;
public $reflink;
public $title;
public $content;
public $user_id;
public $group_id;
public $timestamp;
public $progress;
public $version;
/**
* Wiki constructor.
* @param int $id
* @param int $page_id
* @param $reflink
* @param $title
* @param $content
* @param $user_id
* @param $group_id
* @param $timestamp
* @param $progress
* @param $version
*/
public function __construct(
$id,
$page_id,
$reflink,
$title,
$content,
$user_id,
$group_id,
$timestamp,
$progress,
$version
) {
parent::__construct($id,RESOURCE_WIKI);
/**
* Wiki constructor.
* @param int $id
* @param int $page_id
* @param $reflink
* @param $title
* @param $content
* @param $user_id
* @param $group_id
* @param $timestamp
* @param $progress
* @param $version
*/
public function __construct(
$id,
$page_id,
$reflink,
$title,
$content,
$user_id,
$group_id,
$timestamp,
$progress,
$version
) {
parent::__construct($id,RESOURCE_WIKI);
$this->id = $id;
$this->page_id = $page_id;
$this->reflink = $reflink;
@ -56,11 +56,11 @@ class Wiki extends Coursecopy\Resource
$this->dtime = $timestamp;
$this->progress = $progress;
$this->version = $version;
}
}
public function show()
{
parent::show();
echo $this->reflink.' ('. (empty($this->group_id) ? get_lang('Everyone') : get_lang('Group') . ' ' . $this->group_id) .') ' . '<i>(' . $this->dtime . ')</i>';
}
public function show()
{
parent::show();
echo $this->reflink.' ('. (empty($this->group_id) ? get_lang('Everyone') : get_lang('Group') . ' ' . $this->group_id) .') ' . '<i>(' . $this->dtime . ')</i>';
}
}

@ -1856,4 +1856,38 @@ class MessageManager
return $form;
}
/**
* Send a notification to all amdinistrators when a new user is registered
* @param \Chamilo\UserBundle\Entity\User $user
*/
public static function sendNotificationByRegisteredUser(\Chamilo\UserBundle\Entity\User $user)
{
$tplMailBody = new Template(null, false, false, false, false, false, false);
$tplMailBody->assign('user', $user);
$tplMailBody->assign('is_western_name_order', api_is_western_name_order());
$tplMailBody->assign('manageUrl', api_get_path(WEB_CODE_PATH) . 'admin/user_edit.php?user_id=' . $user->getId());
$layoutContent = $tplMailBody->get_template('mail/new_user_mail_to_admin.tpl');
$emailsubject = '[' . get_lang('UserRegistered') . '] ' . $user->getUsername();
$emailbody = $tplMailBody->fetch($layoutContent);
$admins = UserManager::get_all_administrators();
foreach ($admins as $admin_info) {
MessageManager::send_message(
$admin_info['user_id'],
$emailsubject,
$emailbody,
[],
[],
null,
null,
null,
null,
$user->getId()
);
}
}
}

@ -2284,24 +2284,28 @@ class UserManager
}
/** Get extra user data by value
* @param string the internal variable name of the field
* @param string the internal value of the field
* @param string $field_variable the internal variable name of the field
* @param string $field_value the internal value of the field
* @param bool $all_visibility
*
* @return array with extra data info of a user i.e array('field_variable'=>'value');
*/
public static function get_extra_user_data_by_value($field_variable, $field_value)
public static function get_extra_user_data_by_value($field_variable, $field_value, $all_visibility = true)
{
$extraField = new ExtraFieldValue('user');
$data = $extraField->get_item_id_from_field_variable_and_field_value(
$data = $extraField->get_values_by_handler_and_field_variable(
$field_variable,
$field_value,
true
null,
true,
intval($all_visibility)
);
$result = [];
if (!empty($data)) {
foreach ($data as $data) {
$result[] = $data;
$result[] = $data['item_id'];
}
}
@ -3617,7 +3621,7 @@ class UserManager
$finalResult = array();
if (count($extraFieldResult)>1) {
for ($i=0; $i < count($extraFieldResult) -1; $i++) {
if (is_array($extraFieldResult[$i+1])) {
if (is_array($extraFieldResult[$i]) && is_array($extraFieldResult[$i+1])) {
$finalResult = array_intersect($extraFieldResult[$i], $extraFieldResult[$i+1]);
}
}
@ -3641,7 +3645,7 @@ class UserManager
* @param string $query the value of the search box
* @return string HTML form
*/
public static function get_search_form($query)
public static function get_search_form($query, $defaultParams = [])
{
$searchType = isset($_GET['search_type']) ? $_GET['search_type'] : null;
$form = new FormValidator(
@ -3693,6 +3697,10 @@ class UserManager
$defaults['search_type'] = intval($searchType);
$defaults['q'] = api_htmlentities(Security::remove_XSS($query));
if (!empty($defaultParams)) {
$defaults = array_merge($defaults, $defaultParams);
}
$form->setDefaults($defaults);
$form->addButtonSearch(get_lang('Search'));

@ -559,11 +559,11 @@ if (!empty($_SESSION['_user']['user_id']) && !($login || $logout)) {
if (isset($extAuthSource) && is_array($extAuthSource)) {
foreach ($extAuthSource as $thisAuthSource) {
if (!empty($thisAuthSource['newUser']) && file_exists($thisAuthSource['newUser'])) {
if (isset($thisAuthSource['newUser']) && file_exists($thisAuthSource['newUser'])) {
include_once($thisAuthSource['newUser']);
} else {
error_log(
'Chamilo Authentication file '. $thisAuthSource['newUser'].
'Chamilo Authentication external file' .
' could not be found - this might prevent your system from using'.
' the authentication process in the user creation process',
0

@ -325,18 +325,18 @@ $DeleteUsersNotInList = "Unsubscribe students which are not in the imported list
$IfSessionExistsUpdate = "If a session exists, update it";
$CreatedByXYOnZ = "Create by <a href=\"%s\">%s</a> on %s";
$LoginWithExternalAccount = "Login without an institutional account";
$ImportAikenQuizExplanationExample = "This is the text for question 1
A. Answer 1
B. Answer 2
C. Answer 3
ANSWER: B
This is the text for question 2
A. Answer 1
B. Answer 2
C. Answer 3
D. Answer 4
ANSWER: D
$ImportAikenQuizExplanationExample = "This is the text for question 1
A. Answer 1
B. Answer 2
C. Answer 3
ANSWER: B
This is the text for question 2
A. Answer 1
B. Answer 2
C. Answer 3
D. Answer 4
ANSWER: D
ANSWER_EXPLANATION: this is an optional feedback comment that will appear next to the correct answer.";
$ImportAikenQuizExplanation = "The Aiken format comes in a simple text (.txt) file, with several question blocks, each separated by a blank line. The first line is the question, the answer lines are prefixed by a letter and a dot, and the correct answer comes next with the ANSWER: prefix. See example below.";
$ExerciseAikenErrorNoAnswerOptionGiven = "The imported file has at least one question without any answer (or the answers do not include the required prefix letter). Please make sure each question has at least one answer and that it is prefixed by a letter and a dot or a parenthesis, like this: A. answer one";
@ -425,18 +425,18 @@ $VersionUpToDate = "Your version is up-to-date";
$LatestVersionIs = "The latest version is";
$YourVersionNotUpToDate = "Your version is not up-to-date";
$Hotpotatoes = "Hotpotatoes";
$ZeroMeansNoQuestionWillBeSelectedMinusOneMeansThatAllQuestionsWillBeSelected = "-1 = All questions will be selected.
$ZeroMeansNoQuestionWillBeSelectedMinusOneMeansThatAllQuestionsWillBeSelected = "-1 = All questions will be selected.
0 = No questions will be selected.";
$EmailNotificationTemplateDescription = "You can customize the email sent to users when they finished the exercise. You can use tags like these:
1. {{ student.username }}
2. {{ student.firstname }}
3. {{ student.lastname }}
4. {{ student.official_code }}
5. {{ exercise.title }}
6. {{ exercise.start_time }}
7. {{ exercise.end_time }}
8. {{ course.title }}
$EmailNotificationTemplateDescription = "You can customize the email sent to users when they finished the exercise. You can use tags like these:
1. {{ student.username }}
2. {{ student.firstname }}
3. {{ student.lastname }}
4. {{ student.official_code }}
5. {{ exercise.title }}
6. {{ exercise.start_time }}
7. {{ exercise.end_time }}
8. {{ course.title }}
9. {{ course.code }}";
$EmailNotificationTemplate = "Email notification template";
$ExerciseEndButtonDisconnect = "Logout";
@ -844,10 +844,10 @@ $AllowVisitors = "Allow visitors";
$EnableIframeInclusionComment = "Allowing arbitrary iframes in the HTML Editor will enhance the edition capabilities of the users, but it can represent a security risk. Please make sure you can rely on your users (i.e. you know who they are) before enabling this feature.";
$AddedToLPCannotBeAccessed = "This exercise has been included in a learning path, so it cannot be accessed by students directly from here. If you want to put the same exercise available through the exercises tool, please make a copy of the current exercise using the copy icon.";
$EnableIframeInclusionTitle = "Allow iframes in HTML Editor";
$MailTemplateRegistrationMessage = "Dear ((firstname)) ((lastname)),\n\nYou are registered on
((sitename)) with the following settings:\n\nUsername :
((username))\nPass : ((password))\n\nThe address of ((sitename)) is :
((url))\n\nIn case of trouble, contact us.\n\nYours sincerely
$MailTemplateRegistrationMessage = "Dear ((firstname)) ((lastname)),\n\nYou are registered on
((sitename)) with the following settings:\n\nUsername :
((username))\nPass : ((password))\n\nThe address of ((sitename)) is :
((url))\n\nIn case of trouble, contact us.\n\nYours sincerely
\n((admin_name)) ((admin_surname)).";
$Explanation = "Once you click on \"Create a course\", a course is created with a section for Tests, Project based learning, Assessments, Courses, Dropbox, Agenda and much more. Logging in as teacher provides you with editing privileges for this course.";
$CodeTaken = "This course code is already in use.<br>Use the <b>Back</b> button on your browser and try again.";
@ -2640,16 +2640,16 @@ $NoPosts = "No posts";
$WithoutAchievedSkills = "Without achieved skills";
$TypeMessage = "Please type your message!";
$ConfirmReset = "Do you really want to delete all messages?";
$MailCronCourseExpirationReminderBody = "Dear %s,
It has come to our attention that you have not completed the course %s although its expiration date had been set on %s, remaining %s days to finish it.
We remind you that you have only the possibility to follow this course once a year, that is why we invite you insistently to complete your course on time.
You can return to the course connecting to the platform through this address: %s
Best Regards,
$MailCronCourseExpirationReminderBody = "Dear %s,
It has come to our attention that you have not completed the course %s although its expiration date had been set on %s, remaining %s days to finish it.
We remind you that you have only the possibility to follow this course once a year, that is why we invite you insistently to complete your course on time.
You can return to the course connecting to the platform through this address: %s
Best Regards,
%s Team";
$MailCronCourseExpirationReminderSubject = "Urgent: %s course expiration reminder";
$ExerciseAndLearningPath = "Exercise and learning path";
@ -5778,8 +5778,8 @@ $CheckThatYouHaveEnoughQuestionsInYourCategories = "Make sure you have enough qu
$PortalCoursesLimitReached = "Sorry, this installation has a courses limit, which has now been reached. To increase the number of courses allowed on this Chamilo installation, please contact your hosting provider or, if available, upgrade to a superior hosting plan.";
$PortalTeachersLimitReached = "Sorry, this installation has a teachers limit, which has now been reached. To increase the number of teachers allowed on this Chamilo installation, please contact your hosting provider or, if available, upgrade to a superior hosting plan.";
$PortalUsersLimitReached = "Sorry, this installation has a users limit, which has now been reached. To increase the number of users allowed on this Chamilo installation, please contact your hosting provider or, if available, upgrade to a superior hosting plan.";
$GenerateSurveyAccessLinkExplanation = "By copying the link below and pasting it in an e-mail or on a website, you will allow any anonymous person to enter and answer this survey.
You can test this feature by clicking the link above and answering the survey.
$GenerateSurveyAccessLinkExplanation = "By copying the link below and pasting it in an e-mail or on a website, you will allow any anonymous person to enter and answer this survey.
You can test this feature by clicking the link above and answering the survey.
This is particularly useful if you want to allow anyone on a forum to answer you survey and you don't know their e-mail addresses.";
$LinkOpenSelf = "Open self";
$LinkOpenBlank = "Open blank";
@ -5832,8 +5832,8 @@ $Item = "Item";
$ConfigureDashboardPlugin = "Configure Dashboard Plugin";
$EditBlocks = "Edit blocks";
$Never = "Never";
$YourAccountIsActiveYouCanLoginAndCheckYourCourses = "Dear user,
$YourAccountIsActiveYouCanLoginAndCheckYourCourses = "Dear user,
Your account has now been activated on the platform. Please login and enjoy your courses.";
$SessionFields = "Session fields";
$CopyLabelSuffix = "Copy";
@ -5895,7 +5895,7 @@ $CourseSettingsRegisterDirectLink = "If your course is public or open, you can u
$DirectLink = "Direct link";
$here = "here";
$GoAheadAndBrowseOurCourseCatalogXOnceRegisteredYouWillSeeTheCourseHereX = "<p>Go ahead and browse our course catalog %s to register to any course you like. Once registered, you will see the course appear right %s, instead of this message.</p>";
$HelloXAsYouCanSeeYourCourseListIsEmpty = "<p>Hello <strong>%s</strong> and welcome,</p>
$HelloXAsYouCanSeeYourCourseListIsEmpty = "<p>Hello <strong>%s</strong> and welcome,</p>
<p>As you can see, your courses list is still empty. That's because you are not registered to any course yet! </p>";
$UnsubscribeUsersAlreadyAddedInCourse = "Unsubscribe users already added";
$ImportUsers = "Import users";
@ -6159,7 +6159,7 @@ $AverageScore = "Average score";
$LastConnexionDate = "Last connexion date";
$ToolVideoconference = "Videoconference";
$BigBlueButtonEnableTitle = "BigBlueButton videoconference tool";
$BigBlueButtonEnableComment = "Choose whether you want to enable the BigBlueButton videoconference tool. Once enabled, it will show as an additional course tool in all courses' homepage, and teachers will be able to launch a conference at any time. Learners will not be able to launch a conference, only join one. If you don't have a BigBlueButton server, please <a href=\"http://bigbluebutton.org/\" target=\"_blank\">set one up</a> or ask the <a href=\"http://www.chamilo.org/en/providers\" target=\"_blank\">Chamilo official providers</a> for a quote.
$BigBlueButtonEnableComment = "Choose whether you want to enable the BigBlueButton videoconference tool. Once enabled, it will show as an additional course tool in all courses' homepage, and teachers will be able to launch a conference at any time. Learners will not be able to launch a conference, only join one. If you don't have a BigBlueButton server, please <a href=\"http://bigbluebutton.org/\" target=\"_blank\">set one up</a> or ask the <a href=\"http://www.chamilo.org/en/providers\" target=\"_blank\">Chamilo official providers</a> for a quote.
BigBlueButton is a free (as in freedom *and* beer), but its installation requires a set of technical skills that might not be immediately available to all. You can install it on your own or seek professional help to assist you or do it for you. This help, however, will generate a certain cost. In the pure logic of the free software, we offer you the tools to make your work easier and recommend professionals (the Chamilo Official Providers) that will be able to help you if this were too difficult.";
$BigBlueButtonHostTitle = "BigBlueButton server host";
$BigBlueButtonHostComment = "This is the name of the server where your BigBlueButton server is running. Might be <i>localhost</i>, an IP address (e.g. 192.168.13.54) or a domain name (e.g. my.video.com).";
@ -6170,14 +6170,14 @@ $OnlyAccessFromYourGroup = "Only accessible from your group";
$CreateAssignmentPage = "This will create a special wiki page in which the teacher can describe the task and which will be automatically linked to the wiki pages where learners perform the task. Both the teacher's and the learners' pages are created automatically. In these tasks, learners can only edit and view theirs pages, but this can be changed easily if you need to.";
$UserFolders = "Folders of users";
$UserFolder = "User folder";
$HelpUsersFolder = "INFORMATION VISIBLE TO THE TEACHER ONLY:\nThe users folder contains a folder for each user who has accessed it through the documents tool, or when any file has been sent in the course through the online editor. If neither circumstances has occurred, then no user folder will have been created. In the case of groups, files that are sent through the editor will be added in the folder of each group, which is only accessible by students from this group.
<br /><br />
The users folder and each of the included folders will be hidden by default in for all students, but each student can see the contents of his/her directory through the online editor. However, if a student knows the address of a file or folder of another student, he may be able to access it.
<br /><br />
If the folder of a student is visible, other students can see what it contains. In this case, the student that owns the folder can also (from the documents tool and only in his/her folder): create and edit web documents, convert a document into a template for personal use, create and edit drawings in SVG and PNG formats, record audio files in WAV format, make audio files in MP3 from a text, make snapshops from a webcam, send documents, create folders, move folders and files, delete folders and files, and download backup of his/her folder.
<br /><br />
Moreover, the documents tool is synchronized with the file manager of the online editor, so changes in the documents triggered in any one of these will affect both.
<br /><br />
$HelpUsersFolder = "INFORMATION VISIBLE TO THE TEACHER ONLY:\nThe users folder contains a folder for each user who has accessed it through the documents tool, or when any file has been sent in the course through the online editor. If neither circumstances has occurred, then no user folder will have been created. In the case of groups, files that are sent through the editor will be added in the folder of each group, which is only accessible by students from this group.
<br /><br />
The users folder and each of the included folders will be hidden by default in for all students, but each student can see the contents of his/her directory through the online editor. However, if a student knows the address of a file or folder of another student, he may be able to access it.
<br /><br />
If the folder of a student is visible, other students can see what it contains. In this case, the student that owns the folder can also (from the documents tool and only in his/her folder): create and edit web documents, convert a document into a template for personal use, create and edit drawings in SVG and PNG formats, record audio files in WAV format, make audio files in MP3 from a text, make snapshops from a webcam, send documents, create folders, move folders and files, delete folders and files, and download backup of his/her folder.
<br /><br />
Moreover, the documents tool is synchronized with the file manager of the online editor, so changes in the documents triggered in any one of these will affect both.
<br /><br />
As such, the user folder is not only a place to deposit files, it becomes a complete manager of the documents students use during the course. Also, remember that any user can copy a file that is visible from any folder in the documents tool (whether or not he is the owner) to his/her portfolios or personal documents area of social network, which will be available to him/her for use in other courses.";
$HelpFolderChat = "INFORMATION VISIBLE TO THE TEACHER ONLY:\nThis folder contains all sessions that have been opened in the chat. Although the chat sessions can often be trivial, others can be really interesting and worthy of being incorporated as an additional work document. To do this without changing the visibility of this folder, make the file visible and link it from where you deem appropriate. It is not recommended to make this folder visible to all.";
$HelpFolderCertificates = "INFORMATION VISIBLE TO THE TEACHER ONLY:\nThis folder contains the various certificates templates that have been created for the rating tool. It is not recommended to make this folder visible to all.";
@ -6226,8 +6226,8 @@ $Pediaphon = "Use Pediaphon audio services";
$HelpPediaphon = "Supports text with several thousands characters, in various types of male and female voices (depending on the language). Audio files will be generated and automatically saved to the Chamilo directory in which you are.";
$FirstSelectALanguage = "Please select a language";
$MoveUserStats = "Move users results from/to a session";
$CompareUserResultsBetweenCoursesAndCoursesInASession = "This advanced tool allows you to manually improve the tracking of users results when moving from courses methodology to sessions methodology. In most cases, you won't need to use it.<br />
On this screen, you can compare results of users between the context of a standalone course, and the context of the same course inside a session.<br />
$CompareUserResultsBetweenCoursesAndCoursesInASession = "This advanced tool allows you to manually improve the tracking of users results when moving from courses methodology to sessions methodology. In most cases, you won't need to use it.<br />
On this screen, you can compare results of users between the context of a standalone course, and the context of the same course inside a session.<br />
Once you are sure about what to do, you can choose to move the tracking data of the students (exercises results and learning paths tracking) from a course to a session.";
$PDFExportWatermarkEnableTitle = "Enable watermark in PDF export";
$PDFExportWatermarkEnableComment = "By enabling this option, you can upload an image or a text that will be automatically added as watermark to all PDF exports of documents on the system.";
@ -6362,8 +6362,8 @@ $MailNotifyInvitation = "Notify by mail on new invitation received";
$MailNotifyMessage = "Notify by mail on new personal message received";
$MailNotifyGroupMessage = "Notify by mail on new message received in group";
$SearchEnabledTitle = "Fulltext search";
$SearchEnabledComment = "This feature allows you to index most of the documents uploaded to your portal, then provide a search feature for users.<br />
This feature will not index documents that have already been uploaded, so it is important to enable (if wanted) at the beginning of your implementation.<br />
$SearchEnabledComment = "This feature allows you to index most of the documents uploaded to your portal, then provide a search feature for users.<br />
This feature will not index documents that have already been uploaded, so it is important to enable (if wanted) at the beginning of your implementation.<br />
Once enabled, a search box will appear in the courses list of every user. Searching for a specific term will bring a list of corresponding documents, exercises or forum topics, filtered depending on the availability of these contents to the user.";
$SpecificSearchFieldsAvailable = "Available custom search fields";
$XapianModuleInstalled = "Xapian module installed";
@ -7009,45 +7009,45 @@ $ResourceLockedByGradebook = "This option is not available because this activity
$GradebookLockedAlert = "This assessment has been locked. You cannot unlock it. If you really need to unlock it, please contact the platform administrator, explaining the reason why you would need to do that (it might otherwise be considered as fraud attempt).";
$GradebookEnableLockingTitle = "Enable locking of assessments by teachers";
$GradebookEnableLockingComment = "Once enabled, this option will enable locking of any assessment by the teachers of the corresponding course. This, in turn, will prevent any modification of results by the teacher inside the resources used in the assessment: exams, learning paths, tasks, etc. The only role authorized to unlock a locked assessment is the administrator. The teacher will be informed of this possibility. The locking and unlocking of gradebooks will be registered in the system's report of important activities";
$LdapDescriptionComment = " <div class=\"alert alert-info\">
<ul>
<li>LDAP authentication : <br>
See I. below to configure LDAP <br>
See II. below to activate LDAP authentication
</li>
<li>Update user attributes, with LDAP data, after CAS authentication(see <a href=\"settings.php?category=CAS\">CAS configuration </a>) : <br>
See I. below to configure LDAP <br>
CAS manage user authentication, LDAP activation isn't required.
</li>
</ul>
</div>
<h4>I. LDAP configuration</h4>
<h5>Edit file app/config/auth.conf.php </h5>
<p>-&gt; Edit values of array <code>\$extldap_config</code></p>
<ul>
<li>base domain string (ex : 'base_dn' =&gt; 'DC=cblue,DC=be')</li>
<li>admin distinguished name (ex : 'admin_dn' =&gt;'CN=admin,dc=cblue,dc=be')</li>
<li>admin password (ex : 'admin_password' =&gt; '123456') </li>
<li>ldap host (ex : 'host' =&gt; array('1.2.3.4', '2.3.4.5', '3.4.5.6'))</li>
<li>filter (ex : 'filter' =&gt; '') </li>
<li>port (ex : 'port' =&gt; 389) </li>
<li>protocol version (2 or 3) (ex : 'protocol_version' =&gt; 3)</li>
<li>user_search (ex : 'user_search' =&gt; 'sAMAccountName=%username%') </li>
<li>encoding (ex : 'encoding' =&gt; 'UTF-8')</li>
<li>update_userinfo (ex : 'update_userinfo' =&gt; true) </li>
</ul>
<p>-&gt; To update correspondences between user and LDAP attributes, edit array <code>\$extldap_user_correspondance</code></p>
<p>Array values are &lt;chamilo_field&gt; =&gt; &gt;ldap_field&gt;</p><p>
</p>
<h4>II. Activate LDAP authentication </h4>
<h5>Edit file main/inc/conf/configuration.php </h5>
<p>-&gt; Uncomment lines:</p>
<ul>
<li>
\$extAuthSource[\"extldap\"][\"login\"] = \$_configuration['root_sys'].\"main/auth/external_login/login.ldap.php\";</li>
<li>\$extAuthSource[\"extldap\"][\"newUser\"] = \$_configuration['root_sys'].\"main/auth/external_login/newUser.ldap.php\";</li>
</ul>
<p>N.B.: LDAP users use same fields than platform users to login. <br>
$LdapDescriptionComment = " <div class=\"alert alert-info\">
<ul>
<li>LDAP authentication : <br>
See I. below to configure LDAP <br>
See II. below to activate LDAP authentication
</li>
<li>Update user attributes, with LDAP data, after CAS authentication(see <a href=\"settings.php?category=CAS\">CAS configuration </a>) : <br>
See I. below to configure LDAP <br>
CAS manage user authentication, LDAP activation isn't required.
</li>
</ul>
</div>
<h4>I. LDAP configuration</h4>
<h5>Edit file app/config/auth.conf.php </h5>
<p>-&gt; Edit values of array <code>\$extldap_config</code></p>
<ul>
<li>base domain string (ex : 'base_dn' =&gt; 'DC=cblue,DC=be')</li>
<li>admin distinguished name (ex : 'admin_dn' =&gt;'CN=admin,dc=cblue,dc=be')</li>
<li>admin password (ex : 'admin_password' =&gt; '123456') </li>
<li>ldap host (ex : 'host' =&gt; array('1.2.3.4', '2.3.4.5', '3.4.5.6'))</li>
<li>filter (ex : 'filter' =&gt; '') </li>
<li>port (ex : 'port' =&gt; 389) </li>
<li>protocol version (2 or 3) (ex : 'protocol_version' =&gt; 3)</li>
<li>user_search (ex : 'user_search' =&gt; 'sAMAccountName=%username%') </li>
<li>encoding (ex : 'encoding' =&gt; 'UTF-8')</li>
<li>update_userinfo (ex : 'update_userinfo' =&gt; true) </li>
</ul>
<p>-&gt; To update correspondences between user and LDAP attributes, edit array <code>\$extldap_user_correspondance</code></p>
<p>Array values are &lt;chamilo_field&gt; =&gt; &gt;ldap_field&gt;</p><p>
</p>
<h4>II. Activate LDAP authentication </h4>
<h5>Edit file main/inc/conf/configuration.php </h5>
<p>-&gt; Uncomment lines:</p>
<ul>
<li>
\$extAuthSource[\"extldap\"][\"login\"] = \$_configuration['root_sys'].\"main/auth/external_login/login.ldap.php\";</li>
<li>\$extAuthSource[\"extldap\"][\"newUser\"] = \$_configuration['root_sys'].\"main/auth/external_login/newUser.ldap.php\";</li>
</ul>
<p>N.B.: LDAP users use same fields than platform users to login. <br>
N.B.: LDAP activation adds a menu External authentication [LDAP] in \"add or modify\" user pages.</p>";
$ShibbolethMainActivateTitle = "<h3>Shibboleth authentication</h3>";
$ShibbolethMainActivateComment = "<p>First of all, you have to configure Shibboleth for your web server.</p>To configure it for Chamilo<h5>edit file main/auth/shibboleth/config/aai.class.php</h5><p>Modify object &#36;result values with the name of your Shibboleth attributes</p><ul><li>&#36;result-&gt;unique_id = 'mail';</li><li>&#36;result-&gt;firstname = 'cn';</li><li>&#36;result-&gt;lastname = 'uid';</li><li>&#36;result-&gt;email = 'mail';</li><li>&#36;result-&gt;language = '-';</li><li>&#36;result-&gt;gender = '-';</li><li>&#36;result-&gt;address = '-';</li><li>&#36;result-&gt;staff_category = '-';</li><li>&#36;result-&gt;home_organization_type = '-'; </li><li>&#36;result-&gt;home_organization = '-';</li><li>&#36;result-&gt;affiliation = '-';</li><li>&#36;result-&gt;persistent_id = '-';</li><li>...</li></ul><br/>Go to <a href='settings.php?category=Shibboleth'>Plugin</a> to add a configurable 'Shibboleth Login' button for your Chamilo campus.";
@ -7478,12 +7478,12 @@ $AreYouSureToSubscribe = "Are you sure to subscribe?";
$CheckYourEmailAndFollowInstructions = "Check your email and follow the instructions.";
$LinkExpired = "Link expired, please try again.";
$ResetPasswordInstructions = "Instructions for the password change procedure";
$ResetPasswordCommentWithUrl = "You are receiving this message because you (or someone pretending to be you) have requested a new password to be generated for you.
To set a the new password you need to activate it. To do this, please click this link:
%s
$ResetPasswordCommentWithUrl = "You are receiving this message because you (or someone pretending to be you) have requested a new password to be generated for you.
To set a the new password you need to activate it. To do this, please click this link:
%s
If you did not request this procedure, then please ignore this message. If you keep receiving it, please contact the portal administrator.";
$CronRemindCourseExpirationActivateTitle = "Remind Course Expiration cron";
$CronRemindCourseExpirationActivateComment = "Enable the Remind Course Expiration cron";
@ -7492,14 +7492,14 @@ $CronRemindCourseExpirationFrequencyComment = "Number of days before the expirat
$CronCourseFinishedActivateText = "Course Finished cron";
$CronCourseFinishedActivateComment = "Activate the Course Finished cron";
$MailCronCourseFinishedSubject = "End of course %s";
$MailCronCourseFinishedBody = "Dear %s,
Thank you for your participation to course %s. We hope you've acquired new relevant knowledge and enjoyed the course.
You can check your performance in the course through the My Progress section.
Best regards,
$MailCronCourseFinishedBody = "Dear %s,
Thank you for your participation to course %s. We hope you've acquired new relevant knowledge and enjoyed the course.
You can check your performance in the course through the My Progress section.
Best regards,
%s Team";
$GenerateDefaultContent = "Generate default content";
$ThanksForYourSubscription = "Thanks for your subscription";

@ -0,0 +1,13 @@
<h4>{{ 'UserRegistered'|get_lang }}</h4>
<ul>
{% if is_western_name_order %}
<li>{{ 'FirstName'|get_lang }}: {{ user.getFirstName() }}</li>
<li>{{ 'LastName' }}: {{ user.getLastName() }}</li>
{% else %}
<li>{{ 'LastName' }}: {{ user.getLastName() }}</li>
<li>{{ 'FirstName' }}: {{ user.getFirstName() }}</li>
{% endif %}
<li>{{ 'Email'|get_lang }}: {{ user.getEmail() }}</li>
<li>{{ 'Status'|get_lang }}: {{ user.getStatus() }}</li>
</ul>
<p>{{ 'ManageUser'|get_lang }}: <a href="{{ manageUrl }}">{{ manageUrl }}</a></p>

@ -13,6 +13,15 @@ use Doctrine\ORM\Mapping as ORM;
*/
class Tag
{
/**
* @var integer
*
* @ORM\Column(name="id", type="integer")
* @ORM\Id
* @ORM\GeneratedValue
*/
private $id;
/**
* @var string
*
@ -34,17 +43,6 @@ class Tag
*/
private $count;
/**
* @var integer
*
* @ORM\Column(name="id", type="integer")
* @ORM\Id
* @ORM\GeneratedValue(strategy="IDENTITY")
*/
private $id;
/**
* Set tag
*

@ -21,6 +21,15 @@ use Doctrine\ORM\Mapping as ORM;
*/
class TrackECourseAccess
{
/**
* @var integer
*
* @ORM\Column(name="course_access_id", type="integer")
* @ORM\Id
* @ORM\GeneratedValue
*/
private $courseAccessId;
/**
* @var integer
*
@ -70,16 +79,6 @@ class TrackECourseAccess
*/
private $userIp;
/**
* @var integer
*
* @ORM\Column(name="course_access_id", type="integer")
* @ORM\Id
* @ORM\GeneratedValue(strategy="IDENTITY")
*/
private $courseAccessId;
/**
* Set cId
*

@ -1,4 +1,5 @@
<?php
/* For licensing terms, see /license.txt */
namespace Chamilo\CoreBundle\Entity;

@ -1,4 +1,5 @@
<?php
/* For licensing terms, see /license.txt */
namespace Chamilo\CoreBundle\Entity;
@ -19,7 +20,16 @@ use Doctrine\ORM\Mapping as ORM;
* @ORM\Entity
*/
class TrackStoredValuesStack
{
{
/**
* @var integer
*
* @ORM\Column(name="id", type="integer")
* @ORM\Id
* @ORM\GeneratedValue
*/
private $id;
/**
* @var integer
*
@ -62,17 +72,6 @@ class TrackStoredValuesStack
*/
private $svValue;
/**
* @var integer
*
* @ORM\Column(name="id", type="integer")
* @ORM\Id
* @ORM\GeneratedValue(strategy="IDENTITY")
*/
private $id;
/**
* Set userId
*

@ -13,6 +13,15 @@ use Doctrine\ORM\Mapping as ORM;
*/
class UserApiKey
{
/**
* @var integer
*
* @ORM\Column(name="id", type="integer")
* @ORM\Id
* @ORM\GeneratedValue
*/
private $id;
/**
* @var integer
*
@ -69,17 +78,6 @@ class UserApiKey
*/
private $description;
/**
* @var integer
*
* @ORM\Column(name="id", type="integer")
* @ORM\Id
* @ORM\GeneratedValue(strategy="IDENTITY")
*/
private $id;
/**
* Set userId
*

@ -13,6 +13,15 @@ use Doctrine\ORM\Mapping as ORM;
*/
class UserCourseCategory
{
/**
* @var integer
*
* @ORM\Column(name="id", type="integer")
* @ORM\Id
* @ORM\GeneratedValue
*/
private $id;
/**
* @var integer
*
@ -34,17 +43,6 @@ class UserCourseCategory
*/
private $sort;
/**
* @var integer
*
* @ORM\Column(name="id", type="integer")
* @ORM\Id
* @ORM\GeneratedValue(strategy="IDENTITY")
*/
private $id;
/**
* Set userId
*

@ -1,4 +1,5 @@
<?php
/* For licensing terms, see /license.txt */
namespace Chamilo\CoreBundle\Entity;

@ -1,4 +1,5 @@
<?php
/* For licensing terms, see /license.txt */
namespace Chamilo\CoreBundle\Entity;

@ -1,4 +1,5 @@
<?php
/* For licensing terms, see /license.txt */
namespace Chamilo\CoreBundle\Entity;
@ -12,6 +13,15 @@ use Doctrine\ORM\Mapping as ORM;
*/
class UserRelEventType
{
/**
* @var integer
*
* @ORM\Column(name="id", type="integer")
* @ORM\Id
* @ORM\GeneratedValue
*/
private $id;
/**
* @var integer
*
@ -26,17 +36,6 @@ class UserRelEventType
*/
private $eventTypeName;
/**
* @var integer
*
* @ORM\Column(name="id", type="integer")
* @ORM\Id
* @ORM\GeneratedValue(strategy="IDENTITY")
*/
private $id;
/**
* Set userId
*

@ -13,6 +13,15 @@ use Doctrine\ORM\Mapping as ORM;
*/
class UserRelUser
{
/**
* @var integer
*
* @ORM\Column(name="id", type="bigint")
* @ORM\Id
* @ORM\GeneratedValue
*/
private $id;
/**
* @var integer
*
@ -41,17 +50,6 @@ class UserRelUser
*/
private $lastEdit;
/**
* @var integer
*
* @ORM\Column(name="id", type="bigint")
* @ORM\Id
* @ORM\GeneratedValue(strategy="IDENTITY")
*/
private $id;
/**
* Set userId
*

@ -20,7 +20,7 @@ class Usergroup
*
* @ORM\Column(name="id", type="integer", nullable=false)
* @ORM\Id
* @ORM\GeneratedValue()
* @ORM\GeneratedValue
*/
protected $id;

@ -1,4 +1,5 @@
<?php
/* For licensing terms, see /license.txt */
namespace Chamilo\CoreBundle\Entity;
@ -15,27 +16,25 @@ class UsergroupRelCourse
/**
* @var integer
*
* @ORM\Column(name="usergroup_id", type="integer", nullable=false)
* @ORM\Column(name="id", type="integer")
* @ORM\Id
* @ORM\GeneratedValue
*/
private $usergroupId;
private $id;
/**
* @var integer
*
* @ORM\Column(name="course_id", type="integer", nullable=false)
* @ORM\Column(name="usergroup_id", type="integer", nullable=false)
*/
private $courseId;
private $usergroupId;
/**
* @var integer
*
* @ORM\Column(name="id", type="integer")
* @ORM\Id
* @ORM\GeneratedValue(strategy="IDENTITY")
* @ORM\Column(name="course_id", type="integer", nullable=false)
*/
private $id;
private $courseId;
/**
* Set usergroupId

@ -1,4 +1,5 @@
<?php
/* For licensing terms, see /license.txt */
namespace Chamilo\CoreBundle\Entity;
@ -12,6 +13,15 @@ use Doctrine\ORM\Mapping as ORM;
*/
class UsergroupRelQuestion
{
/**
* @var integer
*
* @ORM\Column(name="id", type="integer")
* @ORM\Id
* @ORM\GeneratedValue
*/
private $id;
/**
* @var integer
*
@ -40,17 +50,6 @@ class UsergroupRelQuestion
*/
private $coefficient;
/**
* @var integer
*
* @ORM\Column(name="id", type="integer")
* @ORM\Id
* @ORM\GeneratedValue(strategy="IDENTITY")
*/
private $id;
/**
* Set cId
*

@ -1,4 +1,5 @@
<?php
/* For licensing terms, see /license.txt */
namespace Chamilo\CoreBundle\Entity;
@ -15,27 +16,25 @@ class UsergroupRelSession
/**
* @var integer
*
* @ORM\Column(name="usergroup_id", type="integer", nullable=false)
* @ORM\Column(name="id", type="integer")
* @ORM\Id
* @ORM\GeneratedValue
*/
private $usergroupId;
private $id;
/**
* @var integer
*
* @ORM\Column(name="session_id", type="integer", nullable=false)
* @ORM\Column(name="usergroup_id", type="integer", nullable=false)
*/
private $sessionId;
private $usergroupId;
/**
* @var integer
*
* @ORM\Column(name="id", type="integer")
* @ORM\Id
* @ORM\GeneratedValue(strategy="IDENTITY")
* @ORM\Column(name="session_id", type="integer", nullable=false)
*/
private $id;
private $sessionId;
/**
* Set usergroupId

@ -6,14 +6,6 @@ namespace Chamilo\CoreBundle\Entity;
use Chamilo\UserBundle\Entity\User;
use Doctrine\ORM\Mapping as ORM;
/**
* ,
* indexes={
// * @ORM\Index(name="IDX_739515A9A76ED395", columns={"user_id"}),
// * @ORM\Index(name="IDX_739515A9D2112630", columns={"usergroup_id"})
* }
*/
/**
* Class UsergroupRelUser
*

Loading…
Cancel
Save