financials

This commit is contained in:
2019-01-06 03:36:01 -06:00
parent 1026bf370a
commit 062939d2c8
16 changed files with 526 additions and 6 deletions
-4
View File
@@ -10,11 +10,7 @@ use Commands\Library\CommandHelper;
use App\Library\Finances\Helper\FinanceHelper;
use App\Library\Esi\Esi;
use App\Models\Esi\EsiScope;
use App\Models\Esi\EsiToken;
use App\Models\Corporation\Structure;
use App\Models\Corporation\CorpStructure;
use App\Models\ScheduledTask\ScheduleJob;
use Carbon\Carbon;
+56
View File
@@ -0,0 +1,56 @@
<?php
namespace App\Console\Commands;
use Illuminate\Console\Command;
use Commands\Library\CommandHelper;
use App\Library\Finances\Helper\FinanceHelper;
class holdingfinances extends Command
{
/**
* The name and signature of the console command.
*
* @var string
*/
protected $signature = 'services:holdingjournal';
/**
* The console command description.
*
* @var string
*/
protected $description = 'Command description';
/**
* Create a new command instance.
*
* @return void
*/
public function __construct()
{
parent::__construct();
}
/**
* Execute the console command.
*
* @return mixed
*/
public function handle()
{
//Create the command helper container
$task = new CommandHelper('HoldingFinances');
//Add the entry into the jobs table saying the job is starting
$task->SetStartStatus();
//Setup the Finances container
$finance = new FinanceHelper();
$finance->GetHoldingWalletJournal(1);
//Mark the job as finished
$task->SetStopStatus();
}
}
+4
View File
@@ -20,6 +20,7 @@ class Kernel extends ConsoleKernel
Commands\DumpFleets::class,
Commands\CalculateMarketTax::class,
//Commands\GetLogisticsContracts::class,
Commands\holdingfinances::class,
];
/**
@@ -45,6 +46,9 @@ class Kernel extends ConsoleKernel
$schedule->command('services:calculatemarkettax')
->monthlyOn(1, '08:00')
->withoutOverlapping();
$schedule->command('services:holdingjournal')
->hourly()
->withoutOverlapping();
}
/**