@php $contextoNome = \App\Support\CurrentCompany::model()?->nome ?? 'Empresa Padrão'; $brl = static fn ($v) => 'R$ ' . number_format((float) $v, 2, ',', '.'); $f = static fn ($d) => $d ? $d->format('d/m/Y') : '—'; if (! $empresa->ativo) { $statusClass = 'bg-gray-100 text-gray-800'; $statusLabel = 'Inativa'; } elseif ($empresa->billing_blocked) { $statusClass = 'bg-orange-100 text-orange-900'; $statusLabel = 'Bloqueada'; } else { $statusClass = 'bg-green-100 text-green-800'; $statusLabel = 'Ativa'; } @endphp

{{ $contextoNome }}

{{ $empresa->nome }}

Detalhes da empresa cliente

Resumo

Status
{{ $statusLabel }}
CNPJ
{{ $empresa->cnpj ?: '—' }}
E-mail
{{ $empresa->email ?: '—' }}
@if ($nextPending)
Próx. vencimento
{{ $f($nextPending->vencimento) }} · {{ $brl($nextPending->valor) }}
Plano (cobrança)
{{ $nextPending->saasPlan?->nome ?? '—' }}
@endif

Contato

Telefone
{{ $empresa->telefone ?: '—' }}
Endereço
{{ $empresa->endereco ?: '—' }}

Cobranças recentes

Até 50 registros, por vencimento

@forelse ($charges as $charge) @php $label = $charge->displayStatusLabel(); $badge = $label === 'Pago' ? 'bg-green-100 text-green-800' : ($label === 'Vencido' ? 'bg-red-100 text-red-800' : 'bg-amber-100 text-amber-900'); @endphp @empty @endforelse
Plano Valor Vencimento Pagamento Status
{{ $charge->saasPlan?->nome ?? '—' }} {{ $brl($charge->valor) }} {{ $f($charge->vencimento) }} {{ $f($charge->pagamento) }} {{ $label }}
Nenhuma cobrança para esta empresa.