<!DOCTYPE html>
<html lang="<?php echo e(app()->getLocale()); ?>" dir="<?php echo e(html_dir()); ?>">
<head>
<meta charset="utf-8"><title><?php echo e($invoice->invoice_number); ?></title>
<style>
body{width:80mm;font-family:<?php echo e(is_rtl() ? "'Cairo'" : "monospace"); ?>,sans-serif;font-size:12px;margin:0;padding:8px;}
h1,h2,p{margin:4px 0;text-align:center}
table{width:100%;border-collapse:collapse} td{padding:2px 0}
@media print {.no-print{display:none}}
</style>
</head>
<body>
<?php
    $hideName = request()->boolean('hide_name');
    $paidMonths = $invoice->items->map(fn ($item) => $item->billingPeriod?->label())->filter()->unique()->values();
?>
<button class="no-print" onclick="window.print()"><?php echo e(__('messages.print')); ?></button>
<?php if(company_logo_url()): ?>
<p><img src="<?php echo e(company_logo_url()); ?>" alt="<?php echo e(setting('company_name')); ?>" style="max-height:40px;max-width:140px;object-fit:contain"></p>
<?php endif; ?>
<h1><?php echo e(setting('company_name')); ?></h1>
<p><?php echo e($invoice->invoice_number); ?></p>
<p><?php echo e(__('messages.line')); ?>: <?php echo e($invoice->line?->phone_number); ?></p>
<?php if(! $hideName && $invoice->customer?->name): ?>
<p><?php echo e($invoice->customer->name); ?></p>
<?php endif; ?>
<?php if($paidMonths->isNotEmpty()): ?>
<p><?php echo e(__('messages.paid_months')); ?>: <?php echo e($paidMonths->join('، ')); ?></p>
<?php endif; ?>
<table>
<?php $__currentLoopData = $invoice->items; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $item): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?><tr><td><?php echo e($item->billingPeriod?->label() ?: $item->description); ?></td><td><?php echo e(money($item->total)); ?></td></tr><?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
<tr><td><strong><?php echo e(__('messages.total')); ?></strong></td><td><strong><?php echo e(money($invoice->total)); ?></strong></td></tr>
</table>
</body></html>
<?php /**PATH D:\laragon\www\esim\resources\views/invoices/thermal.blade.php ENDPATH**/ ?>