Merge branch 'spidev' into 'master'
Faserplanung See merge request fronk/thetool!1908
This commit is contained in:
71
db/migrations/20251118185006_add_fiber_plan_fiber.php
Normal file
71
db/migrations/20251118185006_add_fiber_plan_fiber.php
Normal file
@@ -0,0 +1,71 @@
|
||||
<?php
|
||||
|
||||
use Phinx\Migration\AbstractMigration;
|
||||
|
||||
final class AddFiberPlanFiber extends AbstractMigration
|
||||
{
|
||||
public function up(): void
|
||||
{
|
||||
if ($this->getEnvironment() == "thetool") {
|
||||
$table = $this->table("FiberPlanFiber", ["signed" => true]);
|
||||
$table->addColumn("cable_id", "integer", ["null" => true]);
|
||||
$table->addColumn("sheet_range", "string", ['limit' => 255,"null" => true]);
|
||||
$table->addColumn("cable_route", "string", ['limit' => 255,"null" => true]);
|
||||
$table->addColumn("connector_nr", "string", ['limit' => 255,"null" => true]);
|
||||
$table->addColumn("fiber_nr_cable", "integer", ["null" => true]);
|
||||
$table->addColumn("bundle_nr", "string", ['limit' => 255,"null" => true]);
|
||||
$table->addColumn("fiber_nr_bundle", "string", ['limit' => 255,"null" => true]);
|
||||
$table->addColumn("fiber_color", "string", ['limit' => 255,"null" => true]);
|
||||
$table->addColumn("fiber_color_hex", "string", ['limit' => 255,"null" => true]);
|
||||
$table->addColumn("bundle_color", "string", ['limit' => 255,"null" => true]);
|
||||
$table->addColumn("bundle_color_hex", "string", ['limit' => 255,"null" => true]);
|
||||
$table->addColumn("branch_type", "string", ['limit' => 255,"null" => true]);
|
||||
$table->addColumn("branch_cable_nr", "string", ['limit' => 255,"null" => true]);
|
||||
$table->addColumn("branch_fiber_count", "string", ['limit' => 255,"null" => true]);
|
||||
$table->addColumn("branch_fiber_nr", "string", ['limit' => 255,"null" => true]);
|
||||
$table->addColumn("branch_bundle_nr", "string", ['limit' => 255,"null" => true]);
|
||||
$table->addColumn("branch_fiber_in_bundle", "string", ['limit' => 255,"null" => true]);
|
||||
$table->addColumn("branch_bundle_color", "string", ['limit' => 255,"null" => true]);
|
||||
$table->addColumn("branch_bundle_color_hex", "string", ['limit' => 255,"null" => true]);
|
||||
$table->addColumn("branch_from_location", "string", ['limit' => 255,"null" => true]);
|
||||
$table->addColumn("branch_to_location", "string", ['limit' => 255,"null" => true]);
|
||||
$table->addColumn("branch_gis_id", "string", ['limit' => 255,"null" => true]);
|
||||
$table->addColumn("address", "text", ["null" => true]);
|
||||
$table->addColumn("name", "string", ['limit' => 255,"null" => true]);
|
||||
$table->addColumn("home_id", "string", ['limit' => 255,"null" => true]);
|
||||
$table->addColumn("location", "string", ['limit' => 255,"null" => true]);
|
||||
$table->addColumn("rack_unit", "string", ['limit' => 255,"null" => true]);
|
||||
$table->addColumn("termination_type", "string", ['limit' => 255,"null" => true]);
|
||||
$table->addColumn("customer_cable_type", "string", ['limit' => 255,"null" => true]);
|
||||
$table->addColumn("customer_cable_fiber_nr", "string", ['limit' => 255,"null" => true]);
|
||||
$table->addColumn("customer_connector_type", "string", ['limit' => 255,"null" => true]);
|
||||
$table->addColumn("customer_cable_spec", "string", ['limit' => 255,"null" => true]);
|
||||
$table->addColumn("customer_fiber_range", "string", ['limit' => 255,"null" => true]);
|
||||
$table->addColumn("splitter_location", "string", ['limit' => 255,"null" => true]);
|
||||
$table->addColumn("splitter_factor", "string", ['limit' => 255,"null" => true]);
|
||||
$table->addColumn("uuid_qgis_kabel", "string", ['limit' => 255,"null" => true]);
|
||||
$table->addColumn("status", "string", ['limit' => 255,"null" => true]);
|
||||
$table->addColumn("comment", "text", ["null" => true]);
|
||||
$table->addColumn("edit_by", "integer", ["null" => false]);
|
||||
$table->addColumn("create_by", "integer", ["null" => false]);
|
||||
$table->addColumn("create", "integer", ["null" => false]);
|
||||
$table->addColumn("edit", "integer", ["null" => true]);
|
||||
$table->save();
|
||||
}
|
||||
|
||||
|
||||
if ($this->getEnvironment() == "addressdb") {
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
public function down(): void
|
||||
{
|
||||
if ($this->getEnvironment() == "thetool") {
|
||||
$this->table("FiberPlanFiber")->drop()->save();
|
||||
}
|
||||
if ($this->getEnvironment() == "addressdb") {
|
||||
}
|
||||
}
|
||||
}
|
||||
?>
|
||||
64
db/migrations/20251118190335_add_fiber_plan_cable.php
Normal file
64
db/migrations/20251118190335_add_fiber_plan_cable.php
Normal file
@@ -0,0 +1,64 @@
|
||||
<?php
|
||||
|
||||
use Phinx\Migration\AbstractMigration;
|
||||
|
||||
final class AddFiberPlanCable extends AbstractMigration
|
||||
{
|
||||
public function up(): void
|
||||
{
|
||||
if ($this->getEnvironment() == "thetool") {
|
||||
$this->table("FiberPlanCable")->drop()->save();
|
||||
$table = $this->table("FiberPlanCable", ["signed" => true]);
|
||||
$table->addColumn("description", "text", ["null" => false]);
|
||||
$table->addColumn("uuid", "string", [ 'limit' => 100,"null" => true]);
|
||||
$table->addColumn("fibers", "integer", ["null" => true]);
|
||||
$table->addColumn("diameter", "integer", ["null" => true]);
|
||||
$table->addColumn("network_id", "integer", ["null" => true]);
|
||||
$table->addColumn("lenght", "integer", ["null" => true]);
|
||||
$table->addColumn("state", "integer", ["null" => true]);
|
||||
$table->addColumn("responsible", "integer", ["null" => true]);
|
||||
$table->addColumn("responsible_text", "string", ['limit' => 100,"null" => true]);
|
||||
$table->addColumn("address_id", "integer", ["null" => true]);
|
||||
$table->addColumn("parent_cable_id", "integer", ["null" => true]);
|
||||
$table->addColumn("is_branch_cable", "integer", ["null" => true, "default" => "0"]);
|
||||
$table->addColumn("branch_from_location", "text", ["null" => true]);
|
||||
$table->addColumn("branch_to_location", "text", ["null" => true]);
|
||||
$table->addColumn("coordinates", "text", ["null" => true]);
|
||||
$table->addColumn("cable_type", "text", ["null" => true]);
|
||||
$table->addColumn("level", "text", ["null" => true]);
|
||||
$table->addColumn("connected_fcp", "text", ["null" => true]);
|
||||
$table->addColumn("used_fiber", "integer", ["null" => true]);
|
||||
$table->addColumn("status", "text", ["null" => true]);
|
||||
$table->addColumn("length_m", "text", ["null" => true]);
|
||||
$table->addColumn("offset", "text", ["null" => true]);
|
||||
$table->addColumn("source", "text", ["null" => true]);
|
||||
$table->addColumn("overlength", "text", ["null" => true]);
|
||||
$table->addColumn("otdr", "text", ["null" => true]);
|
||||
$table->addColumn("tube_number", "text", ["null" => true]);
|
||||
$table->addColumn("total_overlength", "text", ["null" => true]);
|
||||
$table->addColumn("length_with_overlength", "text", ["null" => true]);
|
||||
$table->addColumn("zis_unfinanced", "text", ["null" => true]);
|
||||
$table->addColumn("zis_financed", "text", ["null" => true]);
|
||||
$table->addColumn("comment", "text", ["null" => true]);
|
||||
$table->addColumn("edit_by", "integer", ["null" => true]);
|
||||
$table->addColumn("create_by", "integer", ["null" => true]);
|
||||
$table->addColumn("edit", "integer", ["null" => false]);
|
||||
$table->addColumn("create", "integer", ["null" => false]);
|
||||
$table->save();
|
||||
}
|
||||
|
||||
if ($this->getEnvironment() == "addressdb") {
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
public function down(): void
|
||||
{
|
||||
if ($this->getEnvironment() == "thetool") {
|
||||
$this->table("FiberPlanCable")->drop()->save();
|
||||
}
|
||||
if ($this->getEnvironment() == "addressdb") {
|
||||
}
|
||||
}
|
||||
}
|
||||
?>
|
||||
@@ -0,0 +1,37 @@
|
||||
<?php
|
||||
|
||||
use Phinx\Migration\AbstractMigration;
|
||||
|
||||
final class AddFiberPlanCableStation extends AbstractMigration
|
||||
{
|
||||
public function up(): void
|
||||
{
|
||||
if ($this->getEnvironment() == "thetool") {
|
||||
$table = $this->table("FiberPlanCableStation", ["signed" => true]);
|
||||
|
||||
$table->addColumn("cable_id", "integer", ["null" => false]);
|
||||
$table->addColumn("station_order", "integer", ["null" => false,'comment' => 'Reihenfolge der Station im Kabelverlauf (1, 2, 3...)']);
|
||||
$table->addColumn("station_type", "enum", ['values' => ['pop', 'dispatcher'],"null" => false,'comment' => 'Typ: pop oder dispatcher']);
|
||||
$table->addColumn("station_id", "integer", ["null" => false,'comment' => 'ID des Pop oder Dispatcher']);
|
||||
$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->save();
|
||||
}
|
||||
|
||||
if ($this->getEnvironment() == "addressdb") {
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
public function down(): void
|
||||
{
|
||||
if ($this->getEnvironment() == "thetool") {
|
||||
$this->table("FiberPlanCableStation")->drop()->save();
|
||||
}
|
||||
if ($this->getEnvironment() == "addressdb") {
|
||||
}
|
||||
}
|
||||
}
|
||||
?>
|
||||
63
db/migrations/20251130174326_add_fiber_plan_address.php
Normal file
63
db/migrations/20251130174326_add_fiber_plan_address.php
Normal file
@@ -0,0 +1,63 @@
|
||||
<?php
|
||||
|
||||
use Phinx\Migration\AbstractMigration;
|
||||
|
||||
final class AddFiberPlanAddress extends AbstractMigration
|
||||
{
|
||||
public function up(): void
|
||||
{
|
||||
if ($this->getEnvironment() == "thetool") {
|
||||
$table = $this->table("FiberPlanAddress", ["signed" => true]);
|
||||
$table->addColumn("network_id", "integer", ["null" => false, "default" => 90]);
|
||||
$table->addColumn("address", "string", ["limit" => 255, "null" => true]);
|
||||
$table->addColumn("ne", "integer", ["null" => true]);
|
||||
$table->addColumn("status", "string", ["limit" => 50, "null" => true]);
|
||||
$table->addColumn("branch_color", "string", ["limit" => 50, "null" => true]);
|
||||
$table->addColumn("branch_tube", "string", ["limit" => 50, "null" => true]);
|
||||
$table->addColumn("uuid", "string", ["limit" => 100, "null" => true]);
|
||||
$table->addColumn("connection_id", "string", ["limit" => 50, "null" => true]);
|
||||
$table->addColumn("district", "string", ["limit" => 50, "null" => true]);
|
||||
$table->addColumn("tt_object_id", "string", ["limit" => 100, "null" => true]);
|
||||
$table->addColumn("name", "string", ["limit" => 255, "null" => true]);
|
||||
$table->addColumn("phone", "string", ["limit" => 100, "null" => true]);
|
||||
$table->addColumn("comment", "text", ["null" => true]);
|
||||
$table->addColumn("funding", "string", ["limit" => 100, "null" => true]);
|
||||
$table->addColumn("branch_color2", "string", ["limit" => 50, "null" => true]);
|
||||
$table->addColumn("x_gkm34", "string", ["limit" => 50, "null" => true]);
|
||||
$table->addColumn("y_gkm34", "string", ["limit" => 50, "null" => true]);
|
||||
$table->addColumn("gps_long", "decimal", ["precision" => 11, "scale" => 8, "null" => true]);
|
||||
$table->addColumn("gps_lat", "decimal", ["precision" => 10, "scale" => 8, "null" => true]);
|
||||
$table->addColumn("tt_status", "string", ["limit" => 50, "null" => true]);
|
||||
$table->addColumn("ffg_plan", "string", ["limit" => 100, "null" => true]);
|
||||
$table->addColumn("ffg_plan_tg1", "string", ["limit" => 100, "null" => true]);
|
||||
$table->addColumn("ffg_plan_tg2", "string", ["limit" => 100, "null" => true]);
|
||||
$table->addColumn("ffg_plan_tg3", "string", ["limit" => 100, "null" => true]);
|
||||
$table->addColumn("construction_2025", "string", ["limit" => 100, "null" => true]);
|
||||
$table->addColumn("contract", "string", ["limit" => 100, "null" => true]);
|
||||
$table->addColumn("construction_approval", "string", ["limit" => 100, "null" => true]);
|
||||
$table->addColumn("created", "integer", ["null" => false]);
|
||||
$table->addColumn("created_by", "integer", ["null" => false]);
|
||||
$table->addColumn("edit", "integer", ["null" => true]);
|
||||
$table->addColumn("edit_by", "integer", ["null" => true]);
|
||||
$table->save();
|
||||
}
|
||||
|
||||
if ($this->getEnvironment() == "addressdb") {
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
public function down(): void
|
||||
{
|
||||
|
||||
if ($this->getEnvironment() == "thetool") {
|
||||
$this->table("FiberPlanAddress")->drop()->save();
|
||||
}
|
||||
|
||||
if ($this->getEnvironment() == "addressdb") {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
?>
|
||||
Reference in New Issue
Block a user