added models for stock assets from structures

This commit is contained in:
2019-05-26 19:08:43 -05:00
parent 9526c6f9cc
commit 4650ca57fb
6 changed files with 173 additions and 0 deletions

View File

@@ -0,0 +1,10 @@
<?php
namespace App\Http\Controllers\Stocks;
use Illuminate\Http\Request;
class StockController extends Controller
{
//
}

View File

@@ -0,0 +1,34 @@
<?php
namespace App\Jobs;
use Illuminate\Bus\Queueable;
use Illuminate\Queue\SerializesModels;
use Illuminate\Queue\InteractsWithQueue;
use Illuminate\Contracts\Queue\ShouldQueue;
use Illuminate\Foundation\Bus\Dispatchable;
class ProcessStocksJob implements ShouldQueue
{
use Dispatchable, InteractsWithQueue, Queueable, SerializesModels;
/**
* Create a new job instance.
*
* @return void
*/
public function __construct()
{
//
}
/**
* Execute the job.
*
* @return void
*/
public function handle()
{
//
}
}

View File

@@ -0,0 +1,30 @@
<?php
/**
* W4RP Services
* GNU Public License
*/
namespace App\Library\Stock\Helper;
//Internal Library
use Illuminate\Http\Request;
use App\Http\Controllers\Controller;
use DB;
//Job
use App\Jobs\ProcessStocksJob;
//Library
use App\Library\Esi\Esi;
//Models
use App\Models\Stock\StructureStock;
class StructureStockHelper {
public function GetStructures() {
}
}
?>

View File

@@ -0,0 +1,35 @@
<?php
namespace App\Models\Stock;
use Illuminate\Database\Eloquent\Model;
class Asset extends Model
{
/**
* Required scope:
* esi-assets.read_corporation_assets.v1
*/
//Table Name
public $table = 'alliance_asset';
//Timestamps
public $timestamps = false;
/**
* The attributes that are mass assignable
*
* @var array
*/
protected $fillable = [
'is_blueprint_copy',
'is_singleton',
'item_id',
'location_flag',
'location_id',
'location_type',
'quantity',
'type_id',
];
}

View File

@@ -0,0 +1,34 @@
<?php
namespace App\Models\Stock;
use Illuminate\Database\Eloquent\Model;
class Structure extends Model
{
/**
* Requires the scope:
* esi-universe.read_structures.v1
*/
//Table Name
public $table = '';
//Timestamps
public $timestamps = false;
/**
* The attributes that are mass assignable
*
* @var array
*/
protected $fillable = [
'name',
'owner_id',
'position_x',
'position_y',
'position_z',
'solar_system_id',
'type_id',
];
}

View File

@@ -0,0 +1,30 @@
<?php
namespace App\Models\Stock;
use Illuminate\Database\Eloquent\Model;
class StructureStock extends Model
{
//Table Name
public $table = '';
//Timestamps
public $tiemestamps = false;
/**
* The attributes that are mass assignable
*
* @var array
*/
protected $fillable = [
'structure_name',
'structure_id',
'location_flag',
'location_id',
'location_type',
'item_id',
'type_id',
'quantity',
];
}