/** * Display a listing of the resource. * * @return Response */ public function index() { // $aportes = AporteFinanceiro::with('investidor')->get(); $aportes = AporteFinanceiro::all(); //with('investidor')->get(); $totalDeAportes = AporteFinanceiro::sum('valor'); return view('aporteFinanceiro.index', ['aportes' => $aportes, 'totalDeAportes' => $totalDeAportes]); }
/** * Display a listing of the resource. * * @return Response */ public function index() { $patrimonioTotal = AporteFinanceiro::sum('valor'); return view('dashboard.index'); }