Files
thetool/db/migrations/20240203192437_timerecording_rename_field.php
2024-02-04 11:49:57 +01:00

34 lines
782 B
PHP

<?php
declare(strict_types=1);
use Phinx\Migration\AbstractMigration;
final class TimerecordingRenameField extends AbstractMigration
{
public function up(): void
{
if($this->getEnvironment() == "thetool") {
$table = $this->table("Timerecording");
$table->renameColumn('commend', 'comment')
->save();
}
if($this->getEnvironment() == "addressdb") {
}
}
public function down(): void
{
if($this->getEnvironment() == "thetool") {
$table = $this->table("Timerecording");
$table->renameColumn('comment', 'commend')
->save();
}
if($this->getEnvironment() == "addressdb") {
}
}
}