@extends('layouts.layout-2') @section('content')

{{ __('abo.team_subscriptions') }} / {{ __('navigation.overview') }}

{{-- Gesamtübersicht (aktueller Bestand) --}} @php($totals = $overview['totals'])
{{ __('abo.team_total_abos') }}
{{ $totals['total_abos'] }}
{{ __('abo.team_own_abos') }}
{{ $totals['own_abos'] }}
+{{ $totals['own_abos_new'] }} {{ __('abo.new_this_month') }}
{{ __('abo.team_customer_abos') }}
{{ $totals['customer_abos'] }}
+{{ $totals['customer_abos_new'] }} {{ __('abo.new_this_month') }}
{{-- Abo-Umsatz in der Payline (Soll/Ist, Live) --}} @if (isset($paylineAboTurnover))
{{ __('abo.payline_abo_turnover') }} Live
@if (($paylineAboTurnover['paylines'] ?? 0) > 0)
{{ __('abo.payline_target_label') }}
{{ \App\Services\Util::formatNumber($paylineAboTurnover['target']) }}
{{ __('abo.payline_actual_label') }}
{{ \App\Services\Util::formatNumber($paylineAboTurnover['actual']) }}
{{ __('abo.payline_hint', ['lines' => $paylineAboTurnover['paylines'], 'members' => $paylineAboTurnover['members']]) }}
@php($paylineTeamAbos = (int) ($paylineAboTurnover['team_abo_count'] ?? 0)) @php($paylineCustomerAbos = (int) ($paylineAboTurnover['team_customer_abo_count'] ?? 0)) {{ __('abo.payline_abo_counts', [ 'team_abos' => $paylineTeamAbos, 'customer_abos' => $paylineCustomerAbos, 'total' => $paylineTeamAbos + $paylineCustomerAbos, ]) }}
@else

{{ __('abo.payline_none') }}

@endif
@endif {{-- Linien-/Ebenen-Tabelle --}}
{{ __('abo.team_by_level') }}
@forelse($overview['lines'] as $line) @php($collapseId = 'team-line-'.$line['line']) @empty @endforelse @if(!empty($overview['lines'])) @endif
{{ __('abo.level') }} {{ __('abo.consultants') }} {{ __('abo.team_own_abos') }} {{ __('abo.team_customer_abos') }} {{ __('abo.new_this_month') }} ({{ $currentMonthName }}) {{ __('abo.team_total') }} {{ __('abo.abo_points_per_cycle') }} {{ __('abo.abo_points_billed', ['month' => $currentMonthName]) }} {{ __('abo.abo_points_expected') }}
{{ $line['label'] }} {{ $line['consultants'] }} {{ $line['own_abos'] }} @if($line['own_abos_new'] > 0)+{{ $line['own_abos_new'] }}@endif {{ $line['customer_abos'] }} @if($line['customer_abos_new'] > 0)+{{ $line['customer_abos_new'] }}@endif +{{ $line['own_abos_new'] + $line['customer_abos_new'] }} {{ $line['total_abos'] }} {{ \App\Services\Util::formatNumber($line['own_abo_points'] + $line['customer_abo_points']) }} {{ \App\Services\Util::formatNumber($line['abo_points_billed'] ?? 0) }} {{ \App\Services\Util::formatNumber($line['abo_points_expected'] ?? 0) }}
@foreach($line['members'] as $member) @endforeach
{{ __('tables.adviser') }} {{ __('abo.career_level') }} {{ __('abo.own_abo') }} {{ __('abo.customer_abos_count') }} {{ __('navigation.points') }}
{{ $member['name'] }} {{ $member['career_level'] }} @if($member['has_own_abo']) {{ __('abo.yes') }} @else {{ __('abo.no') }} @endif {{ $member['customer_abo_count'] }} {{ \App\Services\Util::formatNumber($member['own_abo_points'] + $member['customer_abo_points']) }} Pkt.
{{ __('tables.no_data_available') }}
{{ $totals['label'] }} {{ $totals['consultants'] }} {{ $totals['own_abos'] }} {{ $totals['customer_abos'] }} +{{ $totals['own_abos_new'] + $totals['customer_abos_new'] }} {{ $totals['total_abos'] }} {{ \App\Services\Util::formatNumber($totals['own_abo_points'] + $totals['customer_abo_points']) }} {{ \App\Services\Util::formatNumber($totals['abo_points_billed'] ?? 0) }} {{ \App\Services\Util::formatNumber($totals['abo_points_expected'] ?? 0) }}
{{-- Wachstum: neue Abos je Monat im gewählten Jahr --}}
{{ __('abo.team_growth') }}
@foreach($growth['months'] as $row) @endforeach
{{ __('abo.month') }} {{ __('abo.new_own_abos') }} {{ __('abo.new_customer_abos') }} {{ __('abo.new_total') }}
{{ $row['label'] }} {{ $row['own_new'] }} {{ $row['customer_new'] }} {{ $row['total_new'] }}
{{ __('abo.team_total') }} {{ $growth['year'] }} {{ $growth['totals']['own_new'] }} {{ $growth['totals']['customer_new'] }} {{ $growth['totals']['total_new'] }}
{{-- Wachstums-Diagramm: zwei Kurven (neue Eigen-/Kunden-Abos je Monat) --}}
{{ __('abo.team_growth') }} {{ $growth['year'] }}

@endsection