Skip to content

Commit

Permalink
MDL-83985 tool_recyclebin: change module names to 1333 chars
Browse files Browse the repository at this point in the history
  • Loading branch information
lucaboesch committed Jan 31, 2025
1 parent 289d320 commit 467569f
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 3 deletions.
4 changes: 2 additions & 2 deletions admin/tool/recyclebin/db/install.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
<XMLDB PATH="admin/tool/recyclebin/db" VERSION="20241115" COMMENT="XMLDB file for Moodle tool/recyclebin"
<XMLDB PATH="admin/tool/recyclebin/db" VERSION="20241218" COMMENT="XMLDB file for Moodle tool/recyclebin"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="../../../../lib/xmldb/xmldb.xsd"
>
Expand All @@ -10,7 +10,7 @@
<FIELD NAME="courseid" TYPE="int" LENGTH="10" NOTNULL="true" SEQUENCE="false"/>
<FIELD NAME="section" TYPE="int" LENGTH="10" NOTNULL="true" SEQUENCE="false"/>
<FIELD NAME="module" TYPE="int" LENGTH="10" NOTNULL="true" SEQUENCE="false"/>
<FIELD NAME="name" TYPE="char" LENGTH="255" NOTNULL="false" SEQUENCE="false"/>
<FIELD NAME="name" TYPE="char" LENGTH="1333" NOTNULL="false" SEQUENCE="false"/>
<FIELD NAME="timecreated" TYPE="int" LENGTH="10" NOTNULL="true" DEFAULT="0" SEQUENCE="false"/>
</FIELDS>
<KEYS>
Expand Down
13 changes: 13 additions & 0 deletions admin/tool/recyclebin/db/upgrade.php
Original file line number Diff line number Diff line change
Expand Up @@ -58,5 +58,18 @@ function xmldb_tool_recyclebin_upgrade($oldversion) {
upgrade_plugin_savepoint(true, 2024111500, 'tool', 'recyclebin');
}

if ($oldversion < 2024121801) {

// Changing precision of field fullname on table tool_recyclebin_category to (255).
$table = new xmldb_table('tool_recyclebin_category');
$field = new xmldb_field('shortname', XMLDB_TYPE_CHAR, '1333', null, XMLDB_NOTNULL, null, null, 'fullname');

// Launch change of precision for field fullname.
$dbman->change_field_precision($table, $field);

// Recyclebin savepoint reached.
upgrade_plugin_savepoint(true, 2024121801, 'tool', 'recyclebin');
}

return true;
}
2 changes: 1 addition & 1 deletion admin/tool/recyclebin/version.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,6 @@

defined('MOODLE_INTERNAL') || die();

$plugin->version = 2024121800; // The current plugin version (Date: YYYYMMDDXX).
$plugin->version = 2024121801; // The current plugin version (Date: YYYYMMDDXX).
$plugin->requires = 2024100100; // Requires this Moodle version.
$plugin->component = 'tool_recyclebin'; // Full name of the plugin (used for diagnostics).

0 comments on commit 467569f

Please sign in to comment.