4 include_once
'./Services/DidacticTemplate/classes/class.ilDidacticTemplateAction.php';
22 parent::__construct($a_action_id);
31 return self::TYPE_LOCAL_ROLE;
40 $this->role_template_id = $a_role_template_id;
59 $rbacreview = $DIC[
'rbacreview'];
60 $rbacadmin = $DIC[
'rbacadmin'];
68 include_once
'./Services/AccessControl/classes/class.ilObjRole.php';
73 $rbacadmin->assignRoleToFolder($role->getId(),
$source->getRefId(),
"y");
80 'Copy role template permissions ' .
82 'parent: ' . ROLE_FOLDER_ID .
' ' .
83 'role_id: ' . $role->getId() .
' ' .
84 'role_parent: ' .
$source->getRefId()
88 $rbacadmin->copyRoleTemplatePermissions(
97 $ops = $rbacreview->getOperationsOfRole($role->getId(),
$source->getType(),
$source->getRefId());
98 $rbacadmin->grantPermission($role->getId(), $ops,
$source->getRefId());
120 $ilDB = $DIC[
'ilDB'];
124 $query =
'INSERT INTO didactic_tpl_alr (action_id,role_template_id) ' .
139 public function delete()
143 $ilDB = $DIC[
'ilDB'];
147 $query =
'DELETE FROM didactic_tpl_alr ' .
172 include_once
'./Services/AccessControl/classes/class.ilRoleXmlExport.php';
177 $writer->
appendXML($exp->xmlDumpMem(
false));
191 $ilDB = $DIC[
'ilDB'];
195 $query =
'SELECT * FROM didactic_tpl_alr ' .
xmlStartTag($tag, $attrs=null, $empty=false, $encode=true, $escape=true)
Writes a starttag.
static _lookupTitle($a_id)
lookup object title
getRoleTemplateId()
get role template id
xmlEndTag($tag)
Writes an endtag.
foreach($_POST as $key=> $value) $res
toXml(ilXmlWriter $writer)
Write xml of template action.
static _lookupDescription($a_id)
lookup object description
__construct($a_action_id=0)
Constructor.
read()
Read db entry ilDB $ilDB.
getRefId()
Get ref id of target object.
static _lookupType($a_id, $a_reference=false)
lookup object type
initSourceObject()
Init the source object.
setRoleTemplateId($a_role_template_id)
Set role template id.
represents a creation of local roles action
Abstract class for template actions.
Xml export of roles and role templates.
appendXML($a_str)
append xml string to document
static getLogger($a_component_id)
Get component logger.
getType()
Get action type.
getActionId()
Get action id.