Files
thetool/db/migrations/20240416144521_fiber_plan_pipe_manufacturer.php
Spitzer Daniel e3f8c2326e Faserplanung
* Schächte/Verteiler
 * Rohrplanung
2024-04-16 16:55:16 +02:00

33 lines
1.0 KiB
PHP

<?php
use Phinx\Migration\AbstractMigration;
final class FiberPlanPipeManufacturer extends AbstractMigration
{
public function up(): void
{
if ($this->getEnvironment() == "thetool") {
$table = $this->table("FiberPlanPipeManufacturer", ["signed" => true]);
$table->addColumn("name", "string", ["null" => false]);
$table->addColumn("colors", "text", ["null" => true]);
$table->addColumn("create_by", "integer", ["null" => false]);
$table->addColumn("edit_by", "integer", ["null" => false]);
$table->addColumn("create", "integer", ["null" => false]);
$table->addColumn("edit", "integer", ["null" => false]);
$table->save();
}
if ($this->getEnvironment() == "addressdb") {
}
}
public function down(): void
{
if ($this->getEnvironment() == "thetool") {
$this->table("FiberPlanPipeManufacturer")->drop()->save();
}
if ($this->getEnvironment() == "addressdb") {
}
}
}