5 require_once(
"./Modules/Scorm2004/classes/class.ilSCORM2004Asset.php");
30 $this->db = $DIC->database();
31 parent::__construct($a_slm_object, $a_id);
40 $this->hide_obj_page = $a_val;
54 public function create($a_upload =
false, $a_template =
false)
58 parent::create($a_upload, $a_template);
62 $obj->setId(
"local_obj_" . $this->getID() .
"_0");
65 $ilDB->manipulate(
"INSERT INTO sahs_sc13_sco " .
66 "(id, hide_obj_page) VALUES (" .
67 $ilDB->quote($this->getId(),
"integer") .
"," .
68 $ilDB->quote($this->getHideObjectivePage(),
"integer") .
83 "SELECT * FROM sahs_sc13_sco WHERE " .
84 " id = " .
$ilDB->quote($this->getId(),
"integer")
86 $rec =
$ilDB->fetchAssoc($set);
99 "UPDATE sahs_sc13_sco SET " .
100 " hide_obj_page = " .
$ilDB->quote($this->getHideObjectivePage(),
"integer") .
101 " WHERE id = " .
$ilDB->quote($this->getId(),
"integer")
108 public function delete($a_delete_meta_data =
true)
112 parent::delete($a_delete_meta_data);
114 "DELETE FROM sahs_sc13_sco WHERE " 115 .
" id = " .
$ilDB->quote($this->getId(),
"integer")
122 public function copy($a_target_slm)
127 if ($this->
getSLMId() != $a_target_slm->getId()) {
128 $sco->setImportId(
"il__sco_" . $this->
getId());
130 $sco->setSLMId($a_target_slm->getId());
131 $sco->setType($this->
getType());
134 $a_copied_nodes[$this->
getId()] = $sco->getId();
137 include_once(
"Services/MetaData/classes/class.ilMD.php");
139 $new_md = $md->cloneMD($a_target_slm->getId(), $sco->getId(), $this->
getType());
153 foreach ($objectives as $ob) {
155 $mappings = $ob->getMappings();
157 foreach ($mappings as
$map) {
158 $mapinfo .= $map->getTargetObjectiveID();
161 if ($mapinfo == null) {
164 $mapinfo =
"global to " . $mapinfo;
167 if ($mapinfo ==
"local") {
168 return $ob->getObjectiveID();
getMainObjectiveText()
Get main objective.
getSLMId()
Get ID of parent Scorm Learning Module Object.
create($a_upload=false, $a_template=false)
Create sco.
getDescription()
Get description.
__construct($a_slm_object, $a_id=0)
Constructor.
copy($a_target_slm)
Copy sco.
update($pash, $contents, Config $config)
setHideObjectivePage($a_val)
Set hide objective page.
read()
Read data from database.
getHideObjectivePage()
Get hide objective page.
setType($a_type)
Set type.
Class ilSCORM2004Objective.