@extends('layouts.bootstrap') @section('title', 'Investment Details') @section('content')

Investment Details

Back to List @if(auth()->user()->canManageInvestments()) Edit @endif
{{ $investment->title }}
{{ ucfirst($investment->status) }}
Investment Amount

${{ number_format($investment->amount, 2) }}

Outstanding Balance

${{ number_format($investment->outstanding_balance, 2) }}

Investment Date

{{ $investment->start_date->format('F d, Y') }}

Total Paid

${{ number_format($investment->total_paid, 2) }}

@if($investment->description)
Description

{{ $investment->description }}

@endif
Type
{{ $investment->type_display_name }}
@if($investment->source)
Source/Institution

{{ $investment->source }}

@endif
@if($investment->reference_number)
Reference Number

{{ $investment->reference_number }}

@endif @if($investment->interest_rate || $investment->term_months)
@if($investment->interest_rate)
Interest Rate

{{ $investment->interest_rate }}% APR

@endif @if($investment->term_months)
Term

{{ $investment->term_months }} months

@endif
@endif @if($investment->contract_file)
Contract/Agreement
View Document
@endif
@if($investment->outstanding_balance > 0 && auth()->user()->canManageInvestments())
Record Payment
@csrf
$ @error('payment_amount')
{{ $message }}
@enderror
@error('payment_date')
{{ $message }}
@enderror
@error('payment_notes')
{{ $message }}
@enderror
@endif
Record Information
Created By

{{ $investment->creator->name }}

Created Date

{{ $investment->created_at->format('M d, Y g:i A') }}

@if($investment->updated_at != $investment->created_at)
Last Updated

{{ $investment->updated_at->format('M d, Y g:i A') }}

by {{ $investment->updater->name }}
@endif
@if($investment->interest_rate && $investment->term_months && $investment->outstanding_balance > 0)
Payment Calculator
@php $monthlyRate = $investment->interest_rate / 100 / 12; $remainingMonths = $investment->term_months - floor($investment->total_paid / ($investment->amount / $investment->term_months)); if ($remainingMonths > 0 && $monthlyRate > 0) { $monthlyPayment = $investment->outstanding_balance * ($monthlyRate * pow(1 + $monthlyRate, $remainingMonths)) / (pow(1 + $monthlyRate, $remainingMonths) - 1); } else { $monthlyPayment = $investment->outstanding_balance / max(1, $remainingMonths); } @endphp
Suggested Monthly Payment: ${{ number_format($monthlyPayment, 2) }}
Remaining Term: {{ max(0, $remainingMonths) }} months
Progress: {{ number_format(($investment->total_paid / $investment->amount) * 100, 1) }}%
@endif @if(auth()->user()->canManageInvestments())
Actions
Edit Investment
@csrf @method('DELETE')
@endif
Quick Stats
${{ number_format(\App\Models\Investment::sum('amount'), 0) }}
Total Investments
{{ \App\Models\Investment::active()->count() }}
Active
@endsection