structure stuff
This commit is contained in:
@@ -43,6 +43,8 @@ class corpJournal extends Command
|
|||||||
{
|
{
|
||||||
//Setup the Finances Container
|
//Setup the Finances Container
|
||||||
$finance = new Finances();
|
$finance = new Finances();
|
||||||
|
//Get the corps with structures logged in the database
|
||||||
|
|
||||||
//Get the characters that have the esi-wallet.read_corporation_wallets.v1
|
//Get the characters that have the esi-wallet.read_corporation_wallets.v1
|
||||||
//esi wallet scope
|
//esi wallet scope
|
||||||
$characters = DB::table('EsiScopes')->where('scopes', 'esi-wallet.read_corporation_wallets.v1')->get();
|
$characters = DB::table('EsiScopes')->where('scopes', 'esi-wallet.read_corporation_wallets.v1')->get();
|
||||||
|
|||||||
@@ -31,7 +31,8 @@ class FinancesController extends Controller
|
|||||||
public function displayWallet() {
|
public function displayWallet() {
|
||||||
$helper = new Finances();
|
$helper = new Finances();
|
||||||
|
|
||||||
$data = $helper->GetWalletJournal(1, 92626011);
|
$helper->GetWalletJournal(1, 92626011);
|
||||||
|
dd($helper);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function displayTaxes() {
|
public function displayTaxes() {
|
||||||
|
|||||||
@@ -30,6 +30,7 @@ class RegisterStructure extends Controller
|
|||||||
]);
|
]);
|
||||||
|
|
||||||
$structure = new CorpStructure();
|
$structure = new CorpStructure();
|
||||||
|
$structure->character_id = Auth::user()->character_id;
|
||||||
$structure->corporation_id = $request->corporation_id;
|
$structure->corporation_id = $request->corporation_id;
|
||||||
$structure->corporation_name = $request->corporation_name;
|
$structure->corporation_name = $request->corporation_name;
|
||||||
$structure->region = $request->region;
|
$structure->region = $request->region;
|
||||||
|
|||||||
@@ -101,8 +101,6 @@ class Finances {
|
|||||||
//For each journal array, attempt to store in the database
|
//For each journal array, attempt to store in the database
|
||||||
foreach($journals as $entry) {
|
foreach($journals as $entry) {
|
||||||
if($entry['ref_type'] == 'brokers_fee' || $entry['ref_type'] == 'reprocessing_tax') {
|
if($entry['ref_type'] == 'brokers_fee' || $entry['ref_type'] == 'reprocessing_tax') {
|
||||||
printf("Found Entry");
|
|
||||||
dd($entry);
|
|
||||||
$this->PutWalletJournal($entry, $corpId, $divison);
|
$this->PutWalletJournal($entry, $corpId, $divison);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -22,6 +22,7 @@ class CorpStructure extends Model
|
|||||||
* @var array
|
* @var array
|
||||||
*/
|
*/
|
||||||
protected $fillable = [
|
protected $fillable = [
|
||||||
|
'character_id',
|
||||||
'corporation_id',
|
'corporation_id',
|
||||||
'corporation_name',
|
'corporation_name',
|
||||||
'region',
|
'region',
|
||||||
|
|||||||
@@ -16,6 +16,7 @@ class CreateCorpStructure extends Migration
|
|||||||
if(!Schema::hasTable('CorpStructures')) {
|
if(!Schema::hasTable('CorpStructures')) {
|
||||||
Schema::create('CorpStructures', function(Blueprint $table) {
|
Schema::create('CorpStructures', function(Blueprint $table) {
|
||||||
$table->increments('id');
|
$table->increments('id');
|
||||||
|
$table->integer('character_id');
|
||||||
$table->integer('corporation_id');
|
$table->integer('corporation_id');
|
||||||
$table->string('corporation_name');
|
$table->string('corporation_name');
|
||||||
$table->string('region');
|
$table->string('region');
|
||||||
|
|||||||
Reference in New Issue
Block a user