5 require_once(
"./Modules/ScormAicc/classes/SCORM/class.ilSCORMObject.php");
36 parent::__construct($a_id);
47 $this->import_id = $a_import_id;
57 $this->identifierref = $a_id_ref;
67 $this->isvisible = $a_visible;
77 $this->parameters = $a_par;
87 $this->prereq_type = $a_p_type;
97 $this->prerequisites = $a_pre;
107 $this->maxtimeallowed = $a_max;
117 $this->timelimitaction = $a_lim_act;
127 $this->datafromlms = $a_data;
137 $this->masteryscore = $a_score;
146 $obj_set = $ilDB->queryF(
147 'SELECT * FROM sc_item WHERE obj_id = %s',
151 $obj_rec = $ilDB->fetchAssoc($obj_set);
155 if (strtolower($obj_rec[
"isvisible"]) ==
"false") {
175 $str_visible = ($this->
getVisible()) ?
'true' :
'false';
177 $ilDB->insert(
'sc_item',
array(
181 'isvisible' =>
array(
'text', $str_visible),
198 $str_visible = ($this->
getVisible()) ?
'true' :
'false';
205 'isvisible' =>
array(
'text', $str_visible),
229 if ($a_user_id == 0) {
230 $a_user_id = $ilUser->getId();
233 $track_set = $ilDB->queryF(
235 SELECT lvalue, rvalue FROM scorm_tracking 239 array(
'integer',
'integer',
'integer'),
244 while ($track_rec = $ilDB->fetchAssoc($track_set)) {
245 $trdata[$track_rec[
"lvalue"]] = $track_rec[
"rvalue"];
255 if ($a_user_id == 0) {
256 $a_user_id = $ilUser->getId();
259 $track_set = $ilDB->queryF(
261 SELECT lvalue, rvalue FROM scorm_tracking 265 array(
'integer',
'integer',
'integer'),
266 array($a_item_id, $a_user_id, $a_obj_id)
270 while ($track_rec = $ilDB->fetchAssoc($track_set)) {
271 $trdata[$track_rec[
"lvalue"]] = $track_rec[
"rvalue"];
277 public function delete()
284 'DELETE FROM sc_item WHERE obj_id = %s',
289 $ilLog->write(
"SAHS Delete(ScormItem): " .
290 'DELETE FROM scorm_tracking WHERE sco_id = ' . $this->
getId() .
' AND obj_id = ' . $this->
getSLMId());
292 'DELETE FROM scorm_tracking WHERE sco_id = %s AND obj_id = %s',
293 array(
'integer',
'integer'),
297 include_once(
"./Services/Tracking/classes/class.ilLPStatusWrapper.php");
304 require_once(
"./Modules/ScormAicc/classes/SCORM/class.ilObjSCORMTracking.php");
314 $res = $ilDB->queryF(
316 SELECT obj_id FROM scorm_object 319 array(
'integer',
'text'),
320 array($a_obj_id,
'sit')
322 while (
$row = $ilDB->fetchObject(
$res)) {
323 $item_ids[] =
$row->obj_id;
325 return $item_ids ? $item_ids :
array();
332 $res = $ilDB->queryF(
333 'SELECT title FROM scorm_object WHERE obj_id = %s',
338 while (
$row = $ilDB->fetchObject(
$res)) {
setTimeLimitAction($a_lim_act)
static _getItems($a_obj_id)
setMasteryScore($a_score)
static _refreshStatus($a_obj_id, $a_users=null)
Set dirty.
__construct($a_id=0)
Constructor.
static _lookupTitle($a_obj_id)
foreach($_POST as $key=> $value) $res
Parent object for all SCORM objects, that are stored in table scorm_object.
Create styles array
The data for the language used.
setImportId($a_import_id)
static _insertTrackData($a_sahs_id, $a_lval, $a_rval, $a_obj_id)
update($pash, $contents, Config $config)
setIdentifierRef($a_id_ref)
insertTrackData($a_lval, $a_rval, $a_obj_id)
getTrackingDataOfUser($a_user_id=0)
get tracking data of specified or current user
static _lookupTrackingDataOfUser($a_item_id, $a_user_id=0, $a_obj_id=0)
setMaxTimeAllowed($a_max)