Show dashboard tiles only when information is available.

This commit is contained in:
2025-02-03 12:53:39 +01:00
parent 33c0a421c9
commit 2c32b51058

View File

@@ -15,6 +15,7 @@
<div class="py-12">
<div class="max-w-7xl mx-auto sm:px-6 lg:px-8 grid grid-cols-3 gap-4">
@if($sent_invoices->count() != 0)
<!-- Invoices not paid -->
<div class="bg-white dark:bg-gray-800 overflow-hidden shadow-sm sm:rounded-lg col-span-2">
<div class="p-6 text-gray-900 dark:text-gray-100">
@@ -30,7 +31,9 @@
@endforeach
</div>
</div>
@endif
@if($created_invoices->count() != 0)
<!-- Invoices not sent -->
<div class="bg-white dark:bg-gray-800 overflow-hidden shadow-sm sm:rounded-lg">
<div class="p-6 text-gray-900 dark:text-gray-100">
@@ -44,7 +47,9 @@
@endforeach
</div>
</div>
@endif
@if($customers->count() != 0)
<!-- Customers without address -->
<div class="bg-white dark:bg-gray-800 overflow-hidden shadow-sm sm:rounded-lg">
<div class="p-6 text-gray-900 dark:text-gray-100">
@@ -58,7 +63,9 @@
@endforeach
</div>
</div>
@endif
@if($unpaid_incoming->count() != 0)
<!-- Incoming invoices, that are not paid -->
<div class="bg-white dark:bg-gray-800 overflow-hidden shadow-sm sm:rounded-lg col-span-2">
<div class="p-6 text-gray-900 dark:text-gray-100">
@@ -74,6 +81,7 @@
@endforeach
</div>
</div>
@endif
</div>
</div>