@props(['invoice'])
@if ($invoice->status != 'paid' && $invoice->periode === $invoice->customer_paket->invoices()->where('status', '!=','paid')->oldest()->first()->periode && $invoice->customer_paket->status != 'pending') {{ __('billing.button.pay') }} @endif
@if ($invoice->payments->count()) @endif @if ($invoice->status != 'paid') @if (!$invoice->payments()->where('refund_status', 'partial')->count() && $invoice->status != 'paid' && $invoice->periode === $invoice->customer_paket->invoices()->where('status', '!=','paid')->latest('periode')->first()->periode) @endif @else @if ($invoice->amount - $invoice->discount > 0) @endif @endif