Compare commits
6 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 921ac28ba7 | |||
| 2b099b3156 | |||
| ee7668df6f | |||
| a882b5aadb | |||
| bad82fb41b | |||
| 5aca9008cb |
@@ -0,0 +1,4 @@
|
|||||||
|
This file was added by Shift #157267 in order to open a
|
||||||
|
Pull Request since no other commits were made.
|
||||||
|
|
||||||
|
You should remove this file.
|
||||||
@@ -21,9 +21,9 @@ class HoldingController extends Controller
|
|||||||
$query->where('transactions.symbol', $symbol);
|
$query->where('transactions.symbol', $symbol);
|
||||||
},
|
},
|
||||||
])
|
])
|
||||||
->symbol($symbol)
|
->symbol($symbol)
|
||||||
->portfolio($portfolio->id)
|
->portfolio($portfolio->id)
|
||||||
->firstOrFail();
|
->firstOrFail();
|
||||||
|
|
||||||
$formattedTransactions = $holding->getFormattedTransactions();
|
$formattedTransactions = $holding->getFormattedTransactions();
|
||||||
|
|
||||||
|
|||||||
@@ -5,9 +5,8 @@ declare(strict_types=1);
|
|||||||
namespace App\Rules;
|
namespace App\Rules;
|
||||||
|
|
||||||
use App\Models\Portfolio;
|
use App\Models\Portfolio;
|
||||||
use App\Models\Transaction;
|
|
||||||
use Illuminate\Support\Carbon;
|
|
||||||
use Illuminate\Contracts\Validation\ValidationRule;
|
use Illuminate\Contracts\Validation\ValidationRule;
|
||||||
|
use Illuminate\Support\Carbon;
|
||||||
|
|
||||||
class QuantityValidationRule implements ValidationRule
|
class QuantityValidationRule implements ValidationRule
|
||||||
{
|
{
|
||||||
@@ -21,7 +20,7 @@ class QuantityValidationRule implements ValidationRule
|
|||||||
protected ?string $symbol,
|
protected ?string $symbol,
|
||||||
protected ?string $transactionType,
|
protected ?string $transactionType,
|
||||||
protected string|Carbon|null $date
|
protected string|Carbon|null $date
|
||||||
) { }
|
) {}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Validate the attribute.
|
* Validate the attribute.
|
||||||
|
|||||||
@@ -1,16 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
declare(strict_types=1);
|
|
||||||
|
|
||||||
use App\Models\Currency;
|
|
||||||
|
|
||||||
if (! function_exists('currency')) {
|
|
||||||
|
|
||||||
// /**
|
|
||||||
// * Returns an instance of the currency model
|
|
||||||
// * */
|
|
||||||
// function currency(): Currency
|
|
||||||
// {
|
|
||||||
// return new Currency;
|
|
||||||
// }
|
|
||||||
}
|
|
||||||
@@ -55,9 +55,6 @@
|
|||||||
}
|
}
|
||||||
],
|
],
|
||||||
"autoload": {
|
"autoload": {
|
||||||
"files": [
|
|
||||||
"app/Support/Helpers.php"
|
|
||||||
],
|
|
||||||
"psr-4": {
|
"psr-4": {
|
||||||
"App\\": "app/",
|
"App\\": "app/",
|
||||||
"Database\\Factories\\": "database/factories/",
|
"Database\\Factories\\": "database/factories/",
|
||||||
|
|||||||
+1
-1
@@ -40,7 +40,7 @@ return [
|
|||||||
*/
|
*/
|
||||||
'components' => [
|
'components' => [
|
||||||
'spotlight' => [
|
'spotlight' => [
|
||||||
'class' => 'App\Support\Spotlight',
|
'class' => App\Support\Spotlight::class,
|
||||||
],
|
],
|
||||||
],
|
],
|
||||||
];
|
];
|
||||||
|
|||||||
@@ -83,7 +83,7 @@ new class extends Component
|
|||||||
|
|
||||||
<x-menu-item title="{{ __('Log Out') }}" icon="o-power" onclick="event.preventDefault(); document.getElementById('logout').submit();" />
|
<x-menu-item title="{{ __('Log Out') }}" icon="o-power" onclick="event.preventDefault(); document.getElementById('logout').submit();" />
|
||||||
<form id="logout" action="{{ route('logout') }}" method="POST" style="display: none;">
|
<form id="logout" action="{{ route('logout') }}" method="POST" style="display: none;">
|
||||||
{{ csrf_field() }}
|
@csrf
|
||||||
</form>
|
</form>
|
||||||
|
|
||||||
</x-dropdown>
|
</x-dropdown>
|
||||||
|
|||||||
@@ -52,10 +52,10 @@ new class extends Component
|
|||||||
{{ Number::currency($holding->dividends_earned ?? 0, $holding->market_data->currency) }}
|
{{ Number::currency($holding->dividends_earned ?? 0, $holding->market_data->currency) }}
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
<p class="pt-2 text-sm" title="{{ \Carbon\Carbon::parse($holding->market_data->updated_at)->toIso8601String() }}">
|
<p class="pt-2 text-sm" title="{{ \Illuminate\Support\Carbon::parse($holding->market_data->updated_at)->toIso8601String() }}">
|
||||||
{{ __('Last Refreshed') }}:
|
{{ __('Last Refreshed') }}:
|
||||||
{{ !is_null($holding->market_data->updated_at)
|
{{ !is_null($holding->market_data->updated_at)
|
||||||
? \Carbon\Carbon::parse($holding->market_data->updated_at)->diffForHumans()
|
? \Illuminate\Support\Carbon::parse($holding->market_data->updated_at)->diffForHumans()
|
||||||
: '' }}
|
: '' }}
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
@@ -98,6 +98,6 @@ new class extends Component
|
|||||||
{{ Number::currency($row->dividends_earned ?? 0, $row->market_data->currency) }}
|
{{ Number::currency($row->dividends_earned ?? 0, $row->market_data->currency) }}
|
||||||
@endscope
|
@endscope
|
||||||
@scope('cell_market_data_updated_at', $row)
|
@scope('cell_market_data_updated_at', $row)
|
||||||
{{ \Carbon\Carbon::parse($row->market_data_updated_at)->diffForHumans() }}
|
{{ \Illuminate\Support\Carbon::parse($row->market_data_updated_at)->diffForHumans() }}
|
||||||
@endscope
|
@endscope
|
||||||
</x-table>
|
</x-table>
|
||||||
|
|||||||
Reference in New Issue
Block a user