@extends('layouts.trading') @section('content')
{{-- Portfolio Card --}}
Portfolio
Total Equity
₹{{ number_format($data['total_equity'], 2) }}
{{ $data['broker_label'] }} Available: ₹{{ number_format($data['available_balance'], 2) }} @if ($data['last_synced_at']) · synced {{ $data['last_synced_at']->diffForHumans() }} @endif
Unrealized P&L
{{ $data['unrealized_pnl'] >= 0 ? '+' : '' }}₹{{ number_format($data['unrealized_pnl'], 2) }}
Open positions
Today Realized P&L
{{ $data['realized_pnl'] >= 0 ? '+' : '' }}₹{{ number_format($data['realized_pnl'], 2) }}
Closed today
Open Positions
{{ $data['open_positions_count'] }}
@csrf
Auto Trade {{ $data['bot_settings']->bot_enabled ? 'ON' : 'OFF' }}
{{-- Live Market Card --}}
Live Market
@if ($data['nifty'] || $data['vix']) @foreach (array_filter(['nifty' => $data['nifty'], 'vix' => $data['vix']]) as $key => $index)
{{ $index['name'] }}
{{ number_format($index['ltp'], 2) }}
{{ $index['change'] >= 0 ? '+' : '' }}{{ number_format($index['change'], 2) }}
({{ $index['change_pct'] >= 0 ? '+' : '' }}{{ number_format($index['change_pct'], 2) }}%)
O {{ number_format($index['open'], 2) }}
H {{ number_format($index['high'], 2) }}
L {{ number_format($index['low'], 2) }}
C {{ number_format($index['close'], 2) }}
@endforeach @else

Connect admin FlatTrade credentials and run sync to load live NIFTY / VIX quotes.

@endif
{{-- Bot Controls --}}
Auto Trade Engine

Bot will enter/exit automatically during market hours.

Status: {{ strtoupper($data['bot_settings']->bot_status) }}

@csrf
@csrf
{{-- Quick nav tabs --}}
Holdings P&L report Watchlist Full agent log
{{-- Scan Watch --}} @include('trading.partials.scan-watch', ['instruments' => $data['scan_instruments']]) @endsection