|
|
@ -78,10 +78,10 @@ class Exercise |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* Constructor of the class |
|
|
|
* Constructor of the class |
|
|
|
* |
|
|
|
* @param int $courseId |
|
|
|
* @author Olivier Brouckaert |
|
|
|
* @author Olivier Brouckaert |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public function __construct($course_id = null) |
|
|
|
public function __construct($courseId = 0) |
|
|
|
{ |
|
|
|
{ |
|
|
|
$this->id = 0; |
|
|
|
$this->id = 0; |
|
|
|
$this->exercise = ''; |
|
|
|
$this->exercise = ''; |
|
|
@ -110,8 +110,8 @@ class Exercise |
|
|
|
$this->scoreTypeModel = 0; |
|
|
|
$this->scoreTypeModel = 0; |
|
|
|
$this->globalCategoryId = null; |
|
|
|
$this->globalCategoryId = null; |
|
|
|
|
|
|
|
|
|
|
|
if (!empty($course_id)) { |
|
|
|
if (!empty($courseId)) { |
|
|
|
$course_info = api_get_course_info_by_id($course_id); |
|
|
|
$course_info = api_get_course_info_by_id($courseId); |
|
|
|
} else { |
|
|
|
} else { |
|
|
|
$course_info = api_get_course_info(); |
|
|
|
$course_info = api_get_course_info(); |
|
|
|
} |
|
|
|
} |
|
|
|