Example #1
0
    $view_lp = ilDBUpdateNewObjectType::addCustomRBACOperation('view_learning_progress', 'View learning progress from users in this orgu.', 'object', 270);
    $view_lp_rec = ilDBUpdateNewObjectType::addCustomRBACOperation('view_learning_progress_rec', 'View learning progress from users in this orgu and subsequent orgus.', 'object', 280);
    if ($view_lp && $view_lp_rec) {
        ilDBUpdateNewObjectType::addRBACOperation($orgu_type_id, $view_lp);
        ilDBUpdateNewObjectType::addRBACOperation($orgu_type_id, $view_lp_rec);
    }
}
?>

<#4034>
<?php 
require_once "./Services/Migration/DBUpdate_3560/classes/class.ilDBUpdateNewObjectType.php";
$orgu_type_id = ilDBUpdateNewObjectType::getObjectTypeId('orgu');
if ($orgu_type_id) {
    $view_lp = ilDBUpdateNewObjectType::addCustomRBACOperation('view_learning_progress', 'View learning progress from users in this orgu.', 'object', 270);
    $view_lp_rec = ilDBUpdateNewObjectType::addCustomRBACOperation('view_learning_progress_rec', 'View learning progress from users in this orgu and subsequent orgus.', 'object', 280);
    if ($view_lp && $view_lp_rec) {
        ilDBUpdateNewObjectType::addRBACOperation($orgu_type_id, $view_lp);
        ilDBUpdateNewObjectType::addRBACOperation($orgu_type_id, $view_lp_rec);
    }
}
?>
<#4035>
	<?php 
//ORGU TEMPLATES
$orgu_employee_contributor_tpl_id = $ilDB->nextId('object_data');
$ilDB->manipulateF("INSERT INTO object_data (obj_id, type, title, description," . " owner, create_date, last_update) VALUES (%s, %s, %s, %s, %s, %s, %s)", array("integer", "text", "text", "text", "integer", "timestamp", "timestamp"), array($orgu_employee_contributor_tpl_id, "rolt", "il_orgu_superior", "OrgUnit Superior Role Template", -1, ilUtil::now(), ilUtil::now()));
$query = 'SELECT ops_id FROM rbac_operations WHERE operation = ' . $ilDB->quote('view_learning_progress', 'text');
$rset = $ilDB->query($query);
$row = $ilDB->fetchAssoc($rset);
$view_lp = $row['ops_id'];
Example #2
0
<?php 
if (!$ilDB->tableExists('container_sorting_bl')) {
    $ilDB->createTable('container_sorting_bl', array('obj_id' => array('type' => 'integer', 'length' => 4, 'notnull' => true, 'default' => 0), 'block_ids' => array('type' => 'text', 'length' => 4000, 'notnull' => false)));
    $ilDB->addPrimaryKey('container_sorting_bl', array('obj_id'));
}
?>
<#4286>
<?php 
$ilCtrlStructureReader->getStructure();
?>
<#4287>
<?php 
include_once './Services/Migration/DBUpdate_3560/classes/class.ilDBUpdateNewObjectType.php';
$tgt_ops_id = ilDBUpdateNewObjectType::getCustomRBACOperationId("read_learning_progress");
if (!$tgt_ops_id) {
    $tgt_ops_id = ilDBUpdateNewObjectType::addCustomRBACOperation('read_learning_progress', 'Read Learning Progress', 'object', 2300);
}
$src_ops_id = ilDBUpdateNewObjectType::getCustomRBACOperationId('edit_learning_progress');
if ($src_ops_id && $tgt_ops_id) {
    // see ilObjectLP
    $lp_types = array("crs", "grp", "fold", "lm", "htlm", "sahs", "tst", "exc", "sess");
    foreach ($lp_types as $lp_type) {
        $lp_type_id = ilDBUpdateNewObjectType::getObjectTypeId($lp_type);
        if ($lp_type_id) {
            ilDBUpdateNewObjectType::addRBACOperation($lp_type_id, $tgt_ops_id);
            ilDBUpdateNewObjectType::cloneOperation($lp_type, $src_ops_id, $tgt_ops_id);
        }
    }
}
?>
<#4288>
if ($ilDB->sequenceExists('svy_inv_grp')) {
    $ilDB->dropSequence('svy_inv_grp');
}
?>
<#3789>
<?php 
if ($ilDB->sequenceExists('svy_qst_mat')) {
    $ilDB->dropSequence('svy_qst_mat');
}
?>
<#3790>
<?php 
include_once './Services/Migration/DBUpdate_3560/classes/class.ilDBUpdateNewObjectType.php';
$trac_type_id = ilDBUpdateNewObjectType::getObjectTypeId('trac');
if ($trac_type_id) {
    $ops_id = ilDBUpdateNewObjectType::addCustomRBACOperation('lp_other_users', 'See LP Data Of Other Users', 'object', 250);
    if ($ops_id) {
        ilDBUpdateNewObjectType::addRBACOperation($trac_type_id, $ops_id);
    }
}
?>

<#3791>
<?php 
if (!$ilDB->tableColumnExists('cal_categories', 'remote_sync')) {
    $ilDB->addTableColumn('cal_categories', 'remote_sync', array('type' => 'timestamp', 'notnull' => false));
}
?>

<#3792>
<?php