Added Preorderbilling permissions
This commit is contained in:
@@ -0,0 +1,37 @@
|
||||
<?php
|
||||
declare(strict_types=1);
|
||||
|
||||
use Phinx\Migration\AbstractMigration;
|
||||
|
||||
final class AddPreorderbillingPermissions extends AbstractMigration
|
||||
{
|
||||
public function up(): void
|
||||
{
|
||||
if($this->getEnvironment() == "thetool") {
|
||||
$table = $this->table("WorkerPermission");
|
||||
$table->addColumn("canPreorderpricing", "enum", ["values" => 'false,true', "default" => "false", "after" => "canPreorder"]);
|
||||
$table->addColumn("canPreorderpricingReadonly", "enum", ["values" => 'false,true', "default" => "false", "after" => "canPreorderpricing"]);
|
||||
$table->addColumn("canPreorderbilling", "enum", ["values" => 'false,true', "default" => "false", "after" => "canPreorderpricingReadonly"]);
|
||||
$table->addColumn("canPreorderbillingReadonly", "enum", ["values" => 'false,true', "default" => "false", "after" => "canPreorderbilling"]);
|
||||
$table->update();
|
||||
}
|
||||
|
||||
if($this->getEnvironment() == "addressdb") {
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
public function down(): void
|
||||
{
|
||||
if($this->getEnvironment() == "thetool") {
|
||||
$this->table("WorkerPermission")->removeColumn("canPreorderpricing")->update();
|
||||
$this->table("WorkerPermission")->removeColumn("canPreorderpricingReadonly")->update();
|
||||
$this->table("WorkerPermission")->removeColumn("canPreorderbilling")->update();
|
||||
$this->table("WorkerPermission")->removeColumn("canPreorderbillingReadonly")->update();
|
||||
}
|
||||
|
||||
if($this->getEnvironment() == "addressdb") {
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user