@extends('businessintelligence::layouts.app') @section('page_title', __('businessintelligence::lang.dashboard')) @section('page_subtitle', __('businessintelligence::lang.ai_powered_insights')) @section('bi_content')

@if($dateRange == 1) Showing data for today @else Showing last {{ $dateRange }} days of data @endif
@foreach($kpis as $key => $kpi)
@if(isset($kpi['percentage'])) {{ $kpi['percentage'] }}% @else @php $formatted_value = number_format($kpi['value'], session('business.currency_precision', 2), session('currency.decimal_separator', '.'), session('currency.thousand_separator', ',')); $currency_symbol = session('currency.symbol', '৳'); $symbol_placement = session('business.currency_symbol_placement', 'before'); @endphp @if($symbol_placement == 'before') {{ $currency_symbol }}{{ $formatted_value }} @else {{ $formatted_value }} {{ $currency_symbol }} @endif @endif
{{ $kpi['label'] }}
@if(isset($kpi['trend']))
{{ number_format($kpi['trend']['value'], 1) }}% vs last period
@endif
@endforeach
Sales Trend & Revenue @if($dateRange == 1) Today @else Last {{ $dateRange }} Days @endif
Daily sales performance and revenue trends
Revenue Sources
Revenue distribution by source
Profit vs Expenses
Monthly comparison of profit and expenses
Cash Flow Analysis
Income vs outgoing cash flow
Sales, Purchase & Expense Analytics Last 6 Months
Comprehensive monthly analysis of sales, purchases, and expenses
Profit & Loss Statement Complete Breakdown
Complete financial performance analysis with P&L breakdown
P&L Components
Revenue, COGS, Expenses & Profit breakdown
Top 10 Products
Best selling products by revenue
Inventory Status
Stock levels and inventory health

AI-Powered Insights & Recommendations

@if(count($insights) > 0) @foreach($insights as $insight)
@if($insight->priority == 'critical') @elseif($insight->priority == 'high') @elseif($insight->priority == 'medium') @else @endif
{{ $insight->title }}
{{ $insight->description }}
@endforeach @else

No insights generated yet. Click "Generate AI Insights" to analyze your business data.

@endif
Performance Summary
Revenue Growth {{ isset($kpis['revenue']['trend']) ? number_format($kpis['revenue']['trend']['value'], 1) : '0' }}%
vs previous period
Profit Margin {{ number_format($kpis['profit_margin']['value'] ?? 0, 1) }}%
current margin rate
Total Orders {{ number_format($kpis['orders']['value'] ?? 0) }}
in selected period
Active Customers {{ number_format($kpis['customers']['value'] ?? 0) }}
total customer base
Expense Categories
Breakdown of business expenses
Customer Growth
New customers over time
@endsection @section('javascript') @endsection