added new signature action

This commit is contained in:
Luca Haid
2025-05-15 14:02:29 +02:00
parent 4716c3156a
commit 1b485aca83
7 changed files with 656 additions and 4 deletions
@@ -0,0 +1,31 @@
<?php
declare(strict_types=1);
use Phinx\Migration\AbstractMigration;
final class ConstrConsOwnerAddSignature extends AbstractMigration
{
public function up(): void
{
if($this->getEnvironment() == "addressdb") {
$ConstructionConsentOwner = $this->table("ConstructionConsentOwner");
$ConstructionConsentOwner->addColumn("signature", "text", ["null" => true]);
$ConstructionConsentOwner->addColumn("signature_name", "string", ["limit" => 255, "null" => true]);
$ConstructionConsentOwner->addColumn("signature_date", "integer", ["null" => true]);
$ConstructionConsentOwner->update();
}
}
public function down(): void
{
if($this->getEnvironment() == "addressdb") {
$ConstructionConsentOwner = $this->table("ConstructionConsentOwner");
$ConstructionConsentOwner->removeColumn("signature");
$ConstructionConsentOwner->removeColumn("signature_name");
$ConstructionConsentOwner->removeColumn("signature_date");
$ConstructionConsentOwner->update();
}
}
}