32 include_once
'class.ilMDBase.php';
38 $subs[
'Contribute'] =
'meta_contribute';
46 include_once
'Services/MetaData/classes/class.ilMDContribute.php';
52 include_once
'Services/MetaData/classes/class.ilMDContribute.php';
54 if (!$a_contribute_id) {
58 $con->setMetaId($a_contribute_id);
64 include_once
'Services/MetaData/classes/class.ilMDContribute.php';
68 $con->setParentType(
'meta_lifecycle');
82 $this->status = $a_status;
95 $this->version = $a_version;
103 if (is_object($lng_obj)) {
104 $this->version_language =&$lng_obj;
109 return $this->version_language;
113 if (is_object($this->version_language)) {
114 return $this->version_language->getLanguageCode();
124 $fields[
'meta_lifecycle_id'] =
array(
'integer',$next_id = $ilDB->nextId(
'il_meta_lifecycle'));
126 if ($this->db->insert(
'il_meta_lifecycle', $fields)) {
138 if ($this->db->update(
140 $this->__getFields(),
149 public function delete()
161 $query =
"DELETE FROM il_meta_lifecycle " .
162 "WHERE meta_lifecycle_id = " . $ilDB->quote($this->
getMetaId(),
'integer');
184 include_once
'Services/MetaData/classes/class.ilMDLanguageItem.php';
187 $query =
"SELECT * FROM il_meta_lifecycle " .
188 "WHERE meta_lifecycle_id = " . $ilDB->quote($this->
getMetaId(),
'integer');
210 $writer->xmlStartTag(
'Lifecycle',
array(
'Status' => $this->
getStatus()
223 foreach ($contributes as
$id) {
225 $con->toXML($writer);
227 if (!count($contributes)) {
228 include_once
'Services/MetaData/classes/class.ilMDContribute.php';
230 $con->toXML($writer);
232 $writer->xmlEndTag(
'Lifecycle');
238 public static function _getId($a_rbac_id, $a_obj_id)
242 $query =
"SELECT meta_lifecycle_id FROM il_meta_lifecycle " .
243 "WHERE rbac_id = " . $ilDB->quote($a_rbac_id,
'integer') .
" " .
244 "AND obj_id = " . $ilDB->quote($a_obj_id,
'integer');
249 return $row->meta_lifecycle_id;
static _getIds($a_rbac_id, $a_obj_id, $a_parent_id, $a_parent_type)
if(!array_key_exists('StateId', $_REQUEST)) $id
static _getId($a_rbac_id, $a_obj_id)
& getContribute($a_contribute_id)
setMetaId($a_meta_id, $a_read_data=true)
foreach($_POST as $key=> $value) $res
Create styles array
The data for the language used.
setVersionLanguage($lng_obj)