WIP 2025-07-31 Citycom OAN Api WIP
This commit is contained in:
40
db/migrations/20250722143248_create_preorder_ctag.php
Normal file
40
db/migrations/20250722143248_create_preorder_ctag.php
Normal file
@@ -0,0 +1,40 @@
|
||||
<?php
|
||||
declare(strict_types=1);
|
||||
|
||||
use Phinx\Migration\AbstractMigration;
|
||||
|
||||
final class CreatePreorderCtag extends AbstractMigration
|
||||
{
|
||||
public function up(): void
|
||||
{
|
||||
if($this->getEnvironment() == "thetool") {
|
||||
$table = $this->table("PreorderCtag");
|
||||
$table->addColumn("preorder_id", "integer", ["null" => false]);
|
||||
$table->addColumn("network", "string", ["null" => false, "length" => 64]);
|
||||
$table->addColumn("stag", "integer", ["null" => false]);
|
||||
$table->addColumn("ctag", "integer", ["null" => false]);
|
||||
$table->addColumn("service_type", "enum", ["null" => true, "default" => null, "values" => ["inet", "voice", "iptv", "prio", "mgmt"]]);
|
||||
$table->addColumn("deleted", "integer", ["null" => true, "default" => null]);
|
||||
$table->addColumn("create_by", "integer", ["null" => false]);
|
||||
$table->addColumn("edit_by", "integer", ["null" => false]);
|
||||
$table->addColumn("create", "integer", ["null" => false]);
|
||||
$table->addColumn("edit", "integer", ["null" => false]);
|
||||
$table->create();
|
||||
}
|
||||
|
||||
if($this->getEnvironment() == "addressdb") {
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
public function down(): void
|
||||
{
|
||||
if($this->getEnvironment() == "thetool") {
|
||||
$this->table("PreorderCtag")->drop()->save();
|
||||
}
|
||||
|
||||
if($this->getEnvironment() == "addressdb") {
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
42
db/migrations/20250729120645_create_preorder_citycom_oan.php
Normal file
42
db/migrations/20250729120645_create_preorder_citycom_oan.php
Normal file
@@ -0,0 +1,42 @@
|
||||
<?php
|
||||
declare(strict_types=1);
|
||||
|
||||
use Phinx\Migration\AbstractMigration;
|
||||
|
||||
final class CreatePreorderCitycomOan extends AbstractMigration
|
||||
{
|
||||
public function up(): void
|
||||
{
|
||||
if($this->getEnvironment() == "thetool") {
|
||||
$table = $this->table("PreorderCitycomOan");
|
||||
$table->addColumn("preorder_id", "integer", ["null" => false]);
|
||||
$table->addColumn("ont_id", "string", ["null" => true]);
|
||||
$table->addColumn("ont_sn", "string", ["null" => true]);
|
||||
$table->addColumn("ont_gpid", "string", ["null" => true]);
|
||||
$table->addColumn("ont_mac", "string", ["null" => true]);
|
||||
|
||||
$table->addColumn("create_by", "integer", ["null" => false]);
|
||||
$table->addColumn("edit_by", "integer", ["null" => false]);
|
||||
$table->addColumn("create", "integer", ["null" => false]);
|
||||
$table->addColumn("edit", "integer", ["null" => false]);
|
||||
|
||||
$table->create();
|
||||
|
||||
}
|
||||
|
||||
if($this->getEnvironment() == "addressdb") {
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
public function down(): void
|
||||
{
|
||||
if($this->getEnvironment() == "thetool") {
|
||||
$this->table("PreorderCitycomOan")->drop()->save();
|
||||
}
|
||||
|
||||
if($this->getEnvironment() == "addressdb") {
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user