Skip to content

Commit

Permalink
Merge branch 'release-7.16.1'
Browse files Browse the repository at this point in the history
  • Loading branch information
github-actions committed Mar 25, 2022
2 parents bfdbc3a + 7542a49 commit 1d56f14
Show file tree
Hide file tree
Showing 7 changed files with 54 additions and 12 deletions.
47 changes: 47 additions & 0 deletions migrations/Version202203221239221465_qtiItemPci.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
<?php

declare(strict_types=1);

namespace oat\qtiItemPci\migrations;

use Doctrine\DBAL\Schema\Schema;
use oat\tao\scripts\tools\migrations\AbstractMigration;
use Doctrine\Migrations\Exception\IrreversibleMigration;
use oat\qtiItemPci\model\IMSPciModel;
use oat\qtiItemPci\scripts\install\RegisterPciMathEntry;

/**
* Auto-generated Migration: Please modify to your needs!
*/
final class Version202203221239221465_qtiItemPci extends AbstractMigration
{

public function getDescription(): string
{
return 'Register new version of Math Entry PCI';
}

public function up(Schema $schema): void
{
$registry = (new IMSPciModel())->getRegistry();
if ($registry->has('mathEntryInteraction')) {
/** @noinspection PhpUnhandledExceptionInspection */
$registry->removeAllVersions('mathEntryInteraction');
}

$this->addReport(
$this->propagate(
new RegisterPciMathEntry()
)(
['1.3.1']
)
);
}

public function down(Schema $schema): void
{
throw new IrreversibleMigration(
'In order to undo this migration, please revert the client-side changes and run ' . RegisterPciMathEntry::class
);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
"label": "Math entry",
"short": "Math entry",
"description": "Allow test taker to type math formulas",
"version": "1.3.0",
"version": "1.3.1",
"author": "Christophe Noël",
"email": "christophe@taotesting.com",
"tags": [
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 1d56f14

Please sign in to comment.