Skip to content

Commit

Permalink
Remove Southampton Ground (#110)
Browse files Browse the repository at this point in the history
  • Loading branch information
AndyTWF authored Mar 30, 2020
1 parent fca30e5 commit 00e317a
Showing 1 changed file with 42 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
<?php

use App\Models\Airfield\Airfield;
use App\Services\AirfieldService;
use Carbon\Carbon;
use Illuminate\Database\Migrations\Migration;
use Illuminate\Support\Facades\DB;

class RemoveSouthamptonGround extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
AirfieldService::removeFromTopDownsOrder('EGHI', 'EGHI_GND');
DB::table('controller_positions')
->where('callsign', 'EGHI_GND')
->delete();
}

/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
DB::table('controller_positions')
->insert(
[
'callsign' => 'EGHI_GND',
'frequency' => 121.770,
'created_at' => Carbon::now(),
]
);

AirfieldService::insertIntoOrderBefore('EGHI', 'EGHI_GND', 'EGHI_TWR');
}
}

0 comments on commit 00e317a

Please sign in to comment.