Files
investbrain/app/Http/Controllers/PortfolioController.php
T

33 lines
725 B
PHP
Raw Normal View History

2024-08-05 22:41:53 -05:00
<?php
namespace App\Http\Controllers;
use App\Models\Portfolio;
class PortfolioController extends Controller
{
/**
* Show the form for creating a new resource.
*/
public function create()
{
return view('portfolio.create');
}
/**
* Display the specified resource.
*/
public function show(Portfolio $portfolio)
{
2024-08-06 22:59:17 -05:00
$portfolio->marketGainLoss = rand(-200, 3999);
$portfolio->totalCostBasis = rand(-200, 3999);
$portfolio->totalMarketValue = rand(-200, 3999);
$portfolio->realizedGainLoss = rand(-200, 3999);
$portfolio->dividendsEarned = rand(-200, 3999);
2024-08-15 21:35:43 -05:00
return view('portfolio.show', compact(['portfolio']));
2024-08-05 22:41:53 -05:00
}
}