Files
thetool/db/migrations/20240123132303_address_add_fibu_supplier_paymentblock.php
2024-01-23 15:12:31 +01:00

32 lines
883 B
PHP

<?php
declare(strict_types=1);
use Phinx\Migration\AbstractMigration;
final class AddressAddFibuSupplierPaymentblock extends AbstractMigration
{
public function up(): void
{
if($this->getEnvironment() == "thetool") {
$table = $this->table("Address");
$table->addColumn("fibu_supplier_paymentblock", "integer", ["null" => false, "default" => 0, "limit" => \Phinx\Db\Adapter\MysqlAdapter::INT_TINY, "after" => "fibu_supplier_skonto_rate"]);
$table->update();
}
if($this->getEnvironment() == "addressdb") {
}
}
public function down(): void
{
if($this->getEnvironment() == "thetool") {
$this->table("Address")->removeColumn("fibu_supplier_paymentblock")->save();
}
if($this->getEnvironment() == "addressdb") {
}
}
}