Files
thetool/db/migrations/20251024091253_preorder_add_files.php
2025-10-24 09:30:48 +02:00

21 lines
575 B
PHP

<?php
declare(strict_types=1);
use Phinx\Migration\AbstractMigration;
final class PreorderAddFiles extends AbstractMigration {
public function up(): void {
if($this->getEnvironment() == "thetool") {
$Preorder = $this->table("Preorder");
$Preorder->addColumn("files", "text", ['null' => true, 'after' => 'notes']);
$Preorder->update();
}
}
public function down(): void {
if($this->getEnvironment() == "thetool") {
$this->table("Preorder")->removeColumn("files")->save();
}
}
}