get_manager(); // loads ddl manager and xmldb classes
//D echo "./mod/nasatlx/db/upgrade.php: entrou xmldb_nasatlx_upgrade, oldversion=$oldversion
";
//D General form to update after new version
// if ($oldversion < YYYYMMDD00) { //New version in version.php
// }
// add_to_log() has been deprecated, please rewrite your code to the new events API
// line 50 of /lib/deprecatedlib.php: call to debugging()
// line 45 of /mod/nasatlx/view.php: call to add_to_log()
// The initial version of NASA-TLX does not defined capabilities, fix it with 'access.php'!
if ($oldversion < 2019030100) {
// get_records_sql
// get_recordset_sql
//DEBUG To test NASA-TLX capabilities in table '*_capabilities': id name captype contextlevel component riskbitmask
//D $list_nasalti_capabilities = $DB->get_records_sql("SELECT * FROM {capabilities} WHERE component='mod_nasatlx';");
//D $num_cap = sizeof($list_nasalti_capabilities);
//D echo "./mod/nasatlx/db/upgrade.php: #list_nasalti_capabilities=" . sizeof($list_nasalti_capabilities) . "
";
//D print_r($list_nasalti_capabilities); echo "
";
//D exit; // foreach ();
//D if ($num_cap == 0) {
//D $newentry = new stdClass();
// Final return of upgrade result (true, all went good) to Moodle.
return true;
} // if ($oldversion < 2019030400)
//D echo "./mod/nasatlx/db/upgrade.php: fim 'xmldb_nasatlx_upgrade(...)'
";
} // function xmldb_nasatlx_upgrade($oldversion)
// First this script is loaded, after it the 'xmldb_nasatlx_upgrade($oldversion)' is executed
//D echo "./mod/nasatlx/db/upgrade.php: fim
";