33 require_once
"./classes/class.ilObject.php";
48 $this->
ilObject($a_id,$a_call_by_reference);
50 $this->styles = array();
60 $this->styles[$a_style_id] =
61 array(
"id" => $a_style_id,
85 if (!parent::update())
91 $q =
"DELETE FROM style_folder_styles WHERE folder_id = ".
92 $ilDB->quote($this->
getId());
94 foreach($this->styles as $style)
96 $q =
"INSERT INTO style_folder_styles (folder_id, style_id) VALUES".
97 "(".$ilDB->quote($this->
getId()).
", ".
98 $ilDB->quote($style[
"id"]).
")";
115 $q =
"SELECT * FROM style_folder_styles, object_data as obj, style_data WHERE folder_id = ".
116 $ilDB->quote($this->
getId()).
117 " AND style_id = obj.obj_id".
118 " AND style_data.id = obj.obj_id";
120 $style_set = $ilDB->query($q);
123 $this->styles[$style_rec[
"style_id"]] =
124 array(
"id" => $style_rec[
"style_id"],
125 "title" => $style_rec[
"title"],
126 "category" => $style_rec[
"category"]);
138 $q =
"SELECT count(*) AS cnt FROM settings_deactivated_styles".
139 " WHERE skin = ".$ilDB->quote($a_skin).
140 " AND style = ".$ilDB->quote($a_style);
142 $cnt_set = $ilDB->query($q);
145 if ($cnt_rec[
"cnt"] > 0)
162 $q =
"REPLACE into settings_deactivated_styles".
163 " (skin, style) VALUES ".
164 " (".$ilDB->quote($a_skin).
",".
165 " ".$ilDB->quote($a_style).
")";
177 $q =
"DELETE FROM settings_deactivated_styles".
178 " WHERE skin = ".$ilDB->quote($a_skin).
179 " AND style = ".$ilDB->quote($a_style);
204 if (!parent::delete())
237 return $roles ? $roles : array();
253 function notify($a_event,$a_ref_id,$a_parent_non_rbac_id,$a_node_id,$a_params = 0)
293 if ($a_node_id==
$_GET[
"ref_id"])
295 $parent_obj =& $this->ilias->obj_factory->getInstanceByRefId($a_node_id);
296 $parent_type = $parent_obj->getType();
297 if($parent_type == $this->
getType())
299 $a_node_id = (int) $tree->getParentId($a_node_id);
303 parent::notify($a_event,$a_ref_id,$a_parent_non_rbac_id,$a_node_id,$a_params);