@extends('layouts.app') @section('title', 'Sourcing Channel Report') @section('page-title', 'Sourcing Channel Report') @section('content')
Sourcing Channel Report
Lead volume breakdown by sourcing channel
{{-- Summary cards --}}
{{ $totals['properties'] }}
Total Properties
{{ $totals['clients'] }}
Total Clients
{{ $totals['leads'] }}
Active Leads (CRM)
{{-- Bar chart --}} @if($channels->isNotEmpty())
Volume per Channel
@php $maxVal = max($channels->max('properties_count'), $channels->max('clients_count'), $channels->max('leads_count'), 1); @endphp @foreach($channels as $channel)
{{ $channel->name }} @unless($channel->is_active) Inactive @endunless {{ $channel->leads_count }} leads
@if($channel->properties_count > 0)
@endif @if($channel->clients_count > 0)
@endif @if($channel->leads_count > 0)
@endif @if($channel->properties_count === 0 && $channel->clients_count === 0 && $channel->leads_count === 0)
@endif
@endforeach
Properties
Clients
Leads
@endif {{-- Data table --}}
@forelse($channels as $channel) @empty @endforelse @if($channels->isNotEmpty()) @endif
Channel Properties Clients Active Leads Status
{{ $channel->name }} {{ $channel->properties_count }} {{ $channel->clients_count }} {{ $channel->leads_count }} @if($channel->is_active) Active @else Inactive @endif
No data available.
Total {{ $totals['properties'] }} {{ $totals['clients'] }} {{ $totals['leads'] }}
@endsection