empty jump bridges service command
This commit is contained in:
@@ -17,8 +17,6 @@ use Seat\Eseye\Exceptions\RequestFailedException;
|
||||
|
||||
//Models
|
||||
use App\Models\Jobs\JobProcessAsset;
|
||||
use App\Models\Esi\EsiScope;
|
||||
use App\Models\Esi\EsiToken;
|
||||
|
||||
class GetAssetsCommand extends Command
|
||||
{
|
||||
|
||||
61
app/Console/Commands/Data/EmptyJumpBridges.php
Normal file
61
app/Console/Commands/Data/EmptyJumpBridges.php
Normal file
@@ -0,0 +1,61 @@
|
||||
<?php
|
||||
|
||||
namespace App\Console\Commands;
|
||||
|
||||
//Internal Library
|
||||
use Illuminate\Console\Command;
|
||||
|
||||
//Library
|
||||
use Commands\Library\CommandHelper;
|
||||
|
||||
//Models
|
||||
use App\Models\Lookups\Structure;
|
||||
use App\Models\Lookups\Services;
|
||||
use App\Models\Stock\Asset;
|
||||
|
||||
class EmptyJumpBridges extends Command
|
||||
{
|
||||
/**
|
||||
* The name and signature of the console command.
|
||||
*
|
||||
* @var string
|
||||
*/
|
||||
protected $signature = 'services:EmptyJumpBridges';
|
||||
|
||||
/**
|
||||
* The console command description.
|
||||
*
|
||||
* @var string
|
||||
*/
|
||||
protected $description = 'Reset the jump bridge fuel related tables.';
|
||||
|
||||
/**
|
||||
* Create a new command instance.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
parent::__construct();
|
||||
}
|
||||
|
||||
/**
|
||||
* Execute the console command.
|
||||
*
|
||||
* @return mixed
|
||||
*/
|
||||
public function handle()
|
||||
{
|
||||
$task = new CommandHelper('EmptyJumpBridges');
|
||||
|
||||
//Add entry into the table saying the job is starting
|
||||
$task->SetStartStatus();
|
||||
|
||||
Structure::delete();
|
||||
Services::delete();
|
||||
Assets::delete();
|
||||
|
||||
//Mark the job as finished
|
||||
$task->SetStopStatus();
|
||||
}
|
||||
}
|
||||
@@ -15,8 +15,6 @@ use Seat\Eseye\Exceptions\RequestFailedException;
|
||||
use App\Models\Jobs\JobProcessAsset;
|
||||
use App\Models\Jobs\JobStatus;
|
||||
use App\Models\Stock\Asset;
|
||||
use App\Models\Esi\EsiToken;
|
||||
use App\Models\Esi\EsiScope;
|
||||
|
||||
class AssetHelper {
|
||||
|
||||
|
||||
Reference in New Issue
Block a user