Order (multiple voicenumbers) and Contract changes

This commit is contained in:
Frank Schubert
2024-08-06 19:22:18 +02:00
parent cdf8050a5f
commit b654f1ba18
10 changed files with 343 additions and 108 deletions
@@ -0,0 +1,31 @@
<?php
declare(strict_types=1);
use Phinx\Migration\AbstractMigration;
final class OrderProductAddVoiceplanId extends AbstractMigration
{
public function up(): void
{
if($this->getEnvironment() == "thetool") {
$table = $this->table("OrderProduct");
$table->addColumn("voiceplan_id", "integer", ["null" => true, "default" => null, "after" => "voicenumber"]);
$table->update();
}
if($this->getEnvironment() == "addressdb") {
}
}
public function down(): void
{
if($this->getEnvironment() == "thetool") {
$this->table("OrderProduct")->removeColumn("voiceplan_id")->save();
}
if($this->getEnvironment() == "addressdb") {
}
}
}