Nevar pievienot vairāk kā 25 tēmas Tēmai ir jāsākas ar burtu vai ciparu, tā var saturēt domu zīmes ('-') un var būt līdz 35 simboliem gara.

income-statement.blade.php 3.5KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283
  1. <x-filament-panels::page>
  2. <x-filament::section>
  3. <div class="flex flex-col md:flex-row items-start md:items-center justify-between gap-4 md:gap-8">
  4. <!-- Form Container -->
  5. @if(method_exists($this, 'filtersForm'))
  6. {{ $this->filtersForm }}
  7. @endif
  8. <!-- Grouping Button and Column Toggle -->
  9. <div class="flex flex-col md:flex-row items-start md:items-center gap-4 md:gap-8 flex-shrink-0">
  10. @if($this->hasToggleableColumns())
  11. <x-filament-tables::column-toggle.dropdown
  12. :form="$this->toggleTableColumnForm"
  13. :trigger-action="$this->toggleColumnsAction"
  14. />
  15. @endif
  16. </div>
  17. <div class="inline-flex items-center flex-shrink-0 min-w-[8.5rem] justify-end">
  18. {{ $this->applyFiltersAction }}
  19. </div>
  20. </div>
  21. </x-filament::section>
  22. <x-filament::section>
  23. <!-- Summary Section -->
  24. @if($this->reportLoaded)
  25. <div
  26. class="flex flex-col md:flex-row items-center md:items-end text-center justify-center gap-4 md:gap-8">
  27. @foreach($this->report->getSummary() as $summary)
  28. <div class="text-sm">
  29. <div class="text-gray-600 font-medium mb-2">{{ $summary['label'] }}</div>
  30. @php
  31. $isNetEarnings = $summary['label'] === 'Net Earnings';
  32. $isPositive = money($summary['value'], \App\Utilities\Currency\CurrencyAccessor::getDefaultCurrency())->isPositive();
  33. @endphp
  34. <strong
  35. @class([
  36. 'text-lg',
  37. 'text-green-700' => $isNetEarnings && $isPositive,
  38. 'text-danger-700' => $isNetEarnings && ! $isPositive,
  39. ])
  40. >
  41. {{ $summary['value'] }}
  42. </strong>
  43. </div>
  44. @if(! $loop->last)
  45. <div class="flex items-center justify-center px-2">
  46. <strong class="text-lg">
  47. {{ $loop->remaining === 1 ? '=' : '-' }}
  48. </strong>
  49. </div>
  50. @endif
  51. @endforeach
  52. </div>
  53. @endif
  54. </x-filament::section>
  55. <x-filament-tables::container>
  56. <div class="es-table__header-ctn"></div>
  57. <div
  58. class="relative divide-y divide-gray-200 overflow-x-auto dark:divide-white/10 dark:border-t-white/10 min-h-64">
  59. <div wire:init="applyFilters" class="flex items-center justify-center w-full h-full absolute">
  60. <div wire:loading wire:target="applyFilters">
  61. <x-filament::loading-indicator class="p-6 text-primary-700 dark:text-primary-300"/>
  62. </div>
  63. </div>
  64. @if($this->reportLoaded)
  65. <div wire:loading.remove wire:target="applyFilters">
  66. @if($this->report)
  67. <x-company.tables.reports.detailed-report :report="$this->report"/>
  68. @endif
  69. </div>
  70. @endif
  71. </div>
  72. <div class="es-table__footer-ctn border-t border-gray-200"></div>
  73. </x-filament-tables::container>
  74. </x-filament-panels::page>