Files
thetool/db/migrations/20250826143629_poprack_module_add_side.php
Daniel Spitzer 75e9ac6dbb Pop Update
* Rückseite der Pop-Racks können nun auch mit HEs bestückt werden
2025-08-27 12:54:09 +02:00

32 lines
807 B
PHP

<?php
declare(strict_types=1);
use Phinx\Migration\AbstractMigration;
final class PoprackModuleAddSide extends AbstractMigration
{
public function up(): void
{
if($this->getEnvironment() == "thetool") {
$table = $this->table("Poprackmodule");
$table->addColumn("side", "enum", ['values' => ['front', 'back'],'null' => false,'default' => 'front', "after" => "position"]);
$table->update();
}
if($this->getEnvironment() == "addressdb") {
}
}
public function down(): void
{
if($this->getEnvironment() == "thetool") {
$this->table("Poprackmodule")->removeColumn("side")->save();
}
if($this->getEnvironment() == "addressdb") {
}
}
}