corp rental moons

This commit is contained in:
2020-04-26 01:26:11 -05:00
parent 6a26f4bc6e
commit 59c0de75c4
6 changed files with 119 additions and 115 deletions
+4 -1
View File
@@ -14,7 +14,10 @@
<a class="dropdown-item" href="/moons/display/form/worth">Moon Worth</a>
<a class="dropdown-item" href="/moons/display/request">Moon Reservation</a>
@if(auth()->user()->hasPermission('corp.lead') && auth()->user()->hasEsiScope('esi-industry.read_corporation_mining.v1'))
<a class="dropdown-item" href="/moons/ledger/display/select">Mining Ledger</a>
<a class="dropdown-item" href="/moons/ledger/display/moons">Mining Ledger</a>
@endif
@if(auth()->user()->isMoonRenter())
<a class="dropdown-item" href="/moons/ledger/display/rentals">Moon Rental Ledger</a>
@endif
</div>
</li>
@@ -1,34 +1,47 @@
@extends('layouts.b4')
@section('content')
<br>
<div class="container">
<div class="card">
<div class="card-header">
<h2>Moon Ledger</h2><br>
<p align="left">Shows mining from the last 30 days.</p>
</div>
<div class="card-body">
<table class="table table-bordered table-striped">
<thead>
<th>Character</th>
<th>Corp Ticker</th>
<th>Ore Name</th>
<th>Quantity</th>
<th>Date</th>
</thead>
<tbody>
@foreach($mining as $min)
<tr>
<td>{{ $min['character'] }}</td>
<td>{{ $min['corpTicker'] }}</td>
<td>{{ $min['ore'] }}</td>
<td>{{ $min['quantity'] }}</td>
<td>{{ $min['updated'] }}</td>
</tr>
@endforeach
</tbody>
</table>
<div class="container-fluid">
<div class="row">
<div class="container">
<h2>Moon Ledger</h2>
</div>
</div>
<br>
<ul class="nav nav-pills">
@foreach($structures as $key => $value)
<li class="nav-item">
<a class="nav-link" data-toggle="pill" href="#W4RP-{{str_replace(' ', '_', $value)}}">{{$value}}</a>
</li>
@endforeach
</ul>
<br>
<div class="tab-content">
@foreach($structures as $key => $value)
<div id="W4RP-{{str_replace(' ', '_', $value)}}" class="tab-pane fade">
<table class="table table-bordered">
<thead>
<th>Character</th>
<th>Corp Ticker</th>
<th>Ore Name</th>
<th>Quantity</th>
<th>Date</th>
</thead>
<tbody>
@foreach($miningLedgers as $ledger)
@if($ledger['structure'] == $value)
<tr>
<td>{{ $ledger['character'] }}</td>
<td>{{ $ledger['corpTicker'] }}</td>
<td>{{ $ledger['ore'] }}</td>
<td>{{ $ledger['quantity'] }}</td>
<td>{{ $ledger['updated'] }}</td>
</tr>
@endif
@endforeach
</tbody>
</table>
</div>
@endforeach
</div>
</div>
@endsection