32 lines
853 B
PHP
32 lines
853 B
PHP
<?php declare(strict_types=1);
|
|
|
|
use Phinx\Migration\AbstractMigration;
|
|
|
|
final class HistoricbillModify extends AbstractMigration
|
|
{
|
|
public function up(): void
|
|
{
|
|
if ($this->getEnvironment() == "thetool") {
|
|
$table = $this->table("HistoricBill");
|
|
|
|
$table->addColumn("brutto_sum", "decimal", ["null" => true, "precision" => 10, "scale" => 4])
|
|
->update();
|
|
|
|
$table->addColumn("fibu_number", "string", ["null" => true, "limit" => 255])
|
|
->update();
|
|
|
|
}
|
|
}
|
|
|
|
public function down(): void
|
|
{
|
|
if ($this->getEnvironment() == "thetool") {
|
|
$table = $this->table("HistoricBill");
|
|
$table->removeColumn("brutto_sum")
|
|
->update();
|
|
$table->removeColumn("fibu_number")
|
|
->update();
|
|
}
|
|
}
|
|
}
|