excel nutzfläche ok

This commit is contained in:
salam committed 2025-11-17 12:16:09 +01:00
1 parent b3e720983a
commit ebb51923a6
9 files changed
+572 -4588

No files matched your search

+121 -181
View File
@@ -2,9 +2,13 @@
namespace App\Actions\Generate;
use App\Actions\Generate\Tabellen\LadeProjekt;
use App\Models\Auftraggeber;
use App\Models\Gutachter;
use App\Models\Projekt;
use Illuminate\Support\Facades\DB;
use App\Models\Projekte;
use Illuminate\Support\Facades\File;
use Illuminate\Support\Facades\Response;
use Illuminate\Support\Facades\Storage;
use PhpOffice\PhpSpreadsheet\IOFactory;
use PhpOffice\PhpSpreadsheet\Spreadsheet;
use PhpOffice\PhpSpreadsheet\Style\Border;
@@ -12,42 +16,53 @@ use PhpOffice\PhpSpreadsheet\Style\Fill;
class Excel
{
public static function make($projekte_id, $type)
public static $projekt;
public static $gutachter;
public static $auftraggeber;
public static function make($projekte_id, $part)
{
$projekt = Projekt::where('id', $projekts_id)->get()->first();
$gutachter = Gutachter::where('id', $projekt->gutachters_id)->get()->first();
$auftraggeber = Auftraggeber::where('id', $projekt->auftraggebers_id)->get()->first();
self::$projekt = Projekte::where('id', $projekte_id)->first();
$projektname = str_replace(',', '', $projekt->name);
$projektname = preg_replace("'\W, '", '', $projektname);
$_headers = self::header();
self::$gutachter = Gutachter::where('id', self::$projekt->gutachter_id)->first();
self::$auftraggeber = Auftraggeber::where('id', self::$projekt->auftraggeber_id)->first();
$filepath = Storage::disk('public')->path("/download/$projekte_id/");
$filename = \ucfirst($part).' '.preg_replace("'[^0-9a-zA-Z]'", '', self::$projekt->interner_name).'.xlsx';
if (! File::isDirectory($filepath)) {
File::makeDirectory($filepath, 0777, true, true);
}
$file = $filepath.$filename;
// SPREADSHEET start
$spreadsheet = new Spreadsheet;
$spreadsheet->getProperties()->setCreator('Hermann Telser Nutzwertberechnung')
->setLastModifiedBy('Hermann Telser Nutzwertberechnung')
->setTitle('Nutzwertberechnung')
->setDescription('Nutzwertberechnung v5.0.1, © Hermann Telser 2007 - '.date('Y'));
$spreadsheet->getProperties()->setCreator(self::$gutachter->company)
->setLastModifiedBy(self::$gutachter->name)
->setTitle(self::$projekt->offizieller_name)
->setDescription(self::$projekt->interner_name.' - '.date('d-m-Y H:i:s'));
$_rot = [2, 3, 4, 5, 6, 7, 9, 10, 11, 12, 13, 14, 20, 21, 22, 23, 24, 25, 26, 27, 28, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 51, 52, 53, 54, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 91, 92, 93, 94];
$_gelb = [8, 19, 29];
$_farbe_1 = [2, 3, 4, 5, 6, 7, 9, 10, 11, 12, 13, 14, 20, 21, 22, 23, 24, 25, 26, 27, 28, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 51, 52, 53, 54, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 91, 92, 93, 94];
$_farbe_2 = [8, 19, 29];
$row = '1';
$coll = 'A';
$_headers = self::title_reihe();
$spreadsheet->setActiveSheetIndex(0);
foreach ($_headers as $key => $value) {
$cell = $coll.$row;
$sheet = $spreadsheet->getActiveSheet();
$sheet->setCellValue($cell, $value);
if (\in_array($key, $_rot)) {
$spreadsheet->getActiveSheet()->getStyle($cell)->getFill()->setFillType(Fill::FILL_SOLID)->getStartColor()->setARGB('FDE8E8');
} elseif (\in_array($key, $_gelb)) {
$spreadsheet->getActiveSheet()->getStyle($cell)->getFill()->setFillType(Fill::FILL_SOLID)->getStartColor()->setARGB('FDF6B2');
if (\in_array($key, $_farbe_1)) {
$spreadsheet->getActiveSheet()->getStyle($cell)->getFill()->setFillType(Fill::FILL_SOLID)->getStartColor()->setARGB('dbeafe');
} elseif (\in_array($key, $_farbe_2)) {
$spreadsheet->getActiveSheet()->getStyle($cell)->getFill()->setFillType(Fill::FILL_SOLID)->getStartColor()->setARGB('fef9c2');
}
$sheet->getStyle($cell)
->getBorders()
@@ -62,90 +77,95 @@ class Excel
$sheet->getColumnDimension($column->getColumnIndex())->setAutoSize(true);
}
$_raumorientierung = DB::table('raumorientierung')
->join('orientierungs', 'raumorientierung.orientierungs_id', '=', 'orientierungs.id')
->select(
'raumorientierung.id',
'raumorientierung.top_nr',
'raumorientierung.qm_m1',
'raumorientierung.qm_m1',
'raumorientierung.factor',
'raumorientierung.nicht_in_orientierung',
'raumorientierung.nutzwert_summe',
'orientierungs.name as orientierung',
)
->where('raumorientierung.projekts_id', $projekts_id)
->groupBy('raumorientierung.id')
->orderBy('raumorientierung.top_nr', 'ASC')
->get();
$spalten = [];
$letter = 'A';
while ($letter !== 'HU') {
$key = $letter++;
$spalten[$key] = '';
}
$_projekt = LadeProjekt::project($projekte_id, false);
$row = 2;
$_data = [];
foreach ($_raumorientierung as $key => $raumorientierung) {
$activeWorksheet = $spreadsheet->getActiveSheet();
foreach ($_projekt as $objekt) {
$_data[$key] = $spalten;
$_data[$key]['B'] = $raumorientierung->top_nr;
$activeWorksheet->setCellValue("B$row", $objekt[1][0]['top_nummer']);
/**
* Normale Wohnnutzflächen
*/
$flaeche = array_sum(array_column($objekt[1], 'flaeche'));
$beschreibung = array_column($objekt[1], 'raumart');
$faktor = (100 + $objekt[1][0]['objekt_nutzwert']) / 100;
$summe_nutzwert = $flaeche * $faktor;
if ($raumorientierung->nicht_in_orientierung == 0) {
/**
* Wintergarten, Loggien, unter Stiegen
*/
$loggien_flaeche = 0;
$loggien_sum = [];
if (isset($objekt[2])) {
foreach ($objekt[2] as $value) {
$loggien_sum[] = $value['raumart'].' '.$value['flaeche'].'m²';
$loggien_flaeche += $value['flaeche'];
$nutzwert = $value['flaeche'] * $value['faktor'];
$summe_nutzwert += $nutzwert;
}
}
$summe_nutzwert = round($summe_nutzwert);
$_data[$key]['C'] = $raumorientierung->nutzwert_summe;
$_data[$key]['D'] = $raumorientierung->qm_m1;
$zunutzwert = self::zunutzwert($raumorientierung->id);
if ($zunutzwert > 0) {
$_data[$key]['E'] = $zunutzwert;
/**
* Terasse, Balkon
*/
$balkon_sum = [];
if (isset($objekt[3])) {
foreach ($objekt[3] as $value) {
$balkon_sum[] = $value['raumart'].' '.$value['flaeche'].'m²';
$nutzwert = $value['flaeche'] * $value['faktor'];
$nutzwert = round($nutzwert) < 1 ? 1 : round($nutzwert);
$summe_nutzwert += $nutzwert;
}
}
$_data[$key]['F'] = $raumorientierung->qm_m1 + $zunutzwert;
} else {
$_data[$key]['I'] = $raumorientierung->nutzwert_summe;
$res = self::raumalles($raumorientierung->id, [5]);
$qm = 0;
$raum = '';
foreach ($res as $value) {
$qm += (float) $value->qm;
$raum = $value->raum;
/**
* Keller, Garten
*/
$keller_sum = [];
if (isset($objekt[4])) {
foreach ($objekt[4] as $value) {
$keller_sum[] = $value['raumart'].' '.$value['flaeche'].'m²';
$nutzwert = $value['flaeche'] * $value['faktor'];
$nutzwert = round($nutzwert) < 1 ? 1 : round($nutzwert);
$summe_nutzwert += $nutzwert;
}
}
$_data[$key]['L'] = number_format($qm, 2, ',', '');
$_data[$key]['AT'] = $raum;
$activeWorksheet->setCellValue("C$row", $summe_nutzwert);
$activeWorksheet->setCellValue("D$row", $flaeche);
$activeWorksheet->setCellValue("E$row", $loggien_flaeche);
$activeWorksheet->setCellValue("F$row", $loggien_flaeche + $flaeche);
$activeWorksheet->setCellValue("AQ$row", $objekt[1][0]['geschoss']);
$activeWorksheet->setCellValue("AR$row", $objekt[1][0]['orientierung']);
$activeWorksheet->setCellValue("AT$row", \implode(', ', $beschreibung));
if (count($loggien_sum)) {
$activeWorksheet->setCellValue("AU$row", \implode(', ', $loggien_sum));
}
// Parifizierer
$_data[$key]['R'] = $gutachter->kennung;
// Lage
$_data[$key]['AQ'] = self::geschoss($raumorientierung->id);
// Orientierung
$raumorientierung->orientierung = $raumorientierung->orientierung == 'Ohne Zuordnung' ? '' : $raumorientierung->orientierung;
$_data[$key]['AR'] = $raumorientierung->orientierung;
// WOHNUNG
if ($raumorientierung->nicht_in_orientierung == 0) {
$_data[$key]['AT'] = self::beschreibung($raumorientierung->id, [1, 2, 8]);
// M2
$_data[$key]['AU'] = self::loggien_qm($raumorientierung->id, [2, 8]);
// M3
$_data[$key]['AV'] = self::beschreibung_qm($raumorientierung->id, [3, 7]);
// M4
$_data[$key]['AW'] = self::beschreibung_qm($raumorientierung->id, [3, 4]);
} else {
$_data[$key]['AT'] = self::beschreibung($raumorientierung->id, [6, 9]);
$_data[$key]['AV'] = self::beschreibung_qm($raumorientierung->id, [6, 9]);
if (count($balkon_sum)) {
$activeWorksheet->setCellValue("AV$row", \implode(', ', $balkon_sum));
}
if (count($keller_sum)) {
$activeWorksheet->setCellValue("AW$row", \implode(', ', $keller_sum));
}
$row++;
}
$sheet = $spreadsheet->getActiveSheet();
$sheet->fromArray($_data, null, 'A2');
/**
* Stelleplätze
*/
$_projekt = LadeProjekt::project($projekte_id, true);
foreach ($_projekt as $objekt) {
$objekt = $objekt[5][0];
$activeWorksheet->setCellValue("B$row", $objekt['top_nummer']);
$activeWorksheet->setCellValue("I$row", $objekt['nutzwert']);
$activeWorksheet->setCellValue("I$row", $objekt['nutzwert']);
$activeWorksheet->setCellValue("L$row", $objekt['flaeche']);
$activeWorksheet->setCellValue("AT$row", $objekt['raumart']);
$row++;
}
// Set active sheet index to the first sheet, so Excel opens this as the first sheet
$spreadsheet->setActiveSheetIndex(0);
@@ -154,99 +174,19 @@ class Excel
// output
$writer = IOFactory::createWriter($spreadsheet, 'Xlsx');
// $writer->save('php://output');
$writer->save($filepath);
$writer->save($file);
$headers = [
'Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet',
'Cache-Control: max-age=0',
'Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT',
'Cache-Control: cache, must-revalidate',
];
return Response::download($file, $filename, $headers);
}
private static function raumalles($raumorientierung_id, $methoden)
{
return DB::table('raumalles')
->select('*')
->where('raumorientierung_id', $raumorientierung_id)
->whereIn('methodes_id', $methoden)
->get();
}
private static function zunutzwert($raumorientierung_id)
{
$zunutzwert = 0;
$res = DB::table('raumalles')
->select('methodes_id', 'raum', 'factor', 'qm')
->where('raumorientierung_id', $raumorientierung_id)
->whereIn('methodes_id', [2, 8])
->get();
foreach ($res as $value) {
$zunutzwert += $value->qm;
}
return $zunutzwert;
}
private static function beschreibung_qm($raumorientierung_id, $methoden)
{
$res = DB::table('raumalles')
->select('*')
->where('raumorientierung_id', $raumorientierung_id)
->whereIn('methodes_id', $methoden)
->get();
$_tmp = [];
foreach ($res as $value) {
if (! in_array($value->raum, ['Loggia', 'Loggia 1', 'Loggia 2'])) {
$_tmp[] = $value->raum.': '.number_format($value->qm, 2, ',', '').' m²';
}
}
return implode(', ', $_tmp);
}
private static function loggien_qm($raumorientierung_id, $methoden)
{
$res = DB::table('raumalles')
->select('*')
->where('raumorientierung_id', $raumorientierung_id)
->whereIn('methodes_id', $methoden)
->get();
$_tmp = [];
foreach ($res as $value) {
if (in_array($value->raum, ['Loggia', 'Loggia 1', 'Loggia 2'])) {
$_tmp[] = $value->raum.': '.number_format($value->qm, 2, ',', '').' m²';
}
}
return implode(', ', $_tmp);
}
private static function beschreibung($raumorientierung_id, $methoden)
{
$res = DB::table('raumalles')
->select('*')
->where('raumorientierung_id', $raumorientierung_id)
->whereIn('methodes_id', $methoden)
->get();
$_tmp = [];
foreach ($res as $value) {
if (! in_array($value->raum, ['Loggia', 'Loggia 1', 'Loggia 2'])) {
$_tmp[] = $value->raum;
}
}
return implode(', ', $_tmp);
}
private static function geschoss($raumorientierung_id)
{
$res = DB::table('raumalles')
->select('geschoss')
->where('raumorientierung_id', $raumorientierung_id)
->where('methodes_id', '=', 1)
->get();
foreach ($res as $key => $value) {
return $value->geschoss;
}
return '';
}
private static function header()
private static function title_reihe()
{
return [
'Bautengruppe',
@@ -0,0 +1,72 @@
<?php
namespace App\Actions\Generate\Tabellen;
use App\Models\ProjektMethode;
use App\Models\ProjektObjekte;
use App\Models\ProjektObjekteImDetail;
class LadeProjekt
{
public static $methoden = [];
public static function project($projekte_id, $nicht_in_orientierung)
{
$objekte = ProjektObjekte::with('orientierung')
->where('projekte_id', $projekte_id)
->where('nicht_in_orientierung', $nicht_in_orientierung)
->orderBy('top_nummer')
->get();
$tmp = [];
foreach ($objekte as $objekt) {
$elemente = ProjektObjekteImDetail::where('projekt_objekte_id', $objekt->id)->get();
foreach ($elemente as $key => $element) {
$methode = self::laod_methode($projekte_id, $element['raumart']);
$methode_id = $methode['methode_id'];
$methode_faktor = $methode['faktor'];
$orientierung = $objekt['orientierung']['name'] ?? '';
if ($key > 0 && $methode_id == 1) {
$orientierung = '';
}
$geschoss = $element['geschoss'] ?? '';
if ($key > 0 && $methode_id <= 1) {
$geschoss = '';
}
$t = [];
$t['id'] = $objekt->id;
$t['type'] = ! $key ? $objekt->type : '';
$t['geschoss'] = $geschoss;
$t['orientierung'] = $orientierung;
$t['raumart'] = $element['raumart'];
$t['flaeche'] = $element['flaeche'];
$t['nutzwert'] = $element['nutzwert'];
$t['top_nummer'] = ! $key ? $objekt->top_nummer : '';
$t['objekt_nutzwert'] = $objekt->nutzwert;
$t['faktor'] = $methode_faktor;
$tmp[$objekt->top_nummer][$methode_id][] = $t;
}
}
return $tmp;
}
public static function laod_methode($projekte_id, $raumart)
{
if (! count(self::$methoden)) {
self::$methoden = ProjektMethode::where('projekte_id', $projekte_id)->get();
}
foreach (self::$methoden as $methode) {
if ($methode->raumart == $raumart) {
return $methode;
}
}
dd('Model ProjektMethode "raumart" '.$raumart.' missing'.__FILE__);
}
}
@@ -4,21 +4,16 @@ namespace App\Actions\Generate\Tabellen;
use App\Actions\Generate\PdfGenerator;
use App\Actions\Generate\Utilities\Html;
use App\Models\ProjektMethode;
use App\Models\ProjektObjekte;
use App\Models\ProjektObjekteImDetail;
class Nutzwertberechnung
{
public static $methoden = [];
public static $projekte_id = 0;
public static function load($projekte_id)
{
self::$projekte_id = $projekte_id;
$objekte = self::laod_project(false);
$objekte = LadeProjekt::project($projekte_id, false);
$html = '';
foreach ($objekte as $methoden) {
@@ -74,6 +69,7 @@ class Nutzwertberechnung
$html .= Html::td(number_format($komponente['faktor'], 3), 'center bl bb');
$html .= Html::td('=', 'center bl bb');
$nutzwert = $komponente['flaeche'] * $komponente['faktor'];
$summe_nutzwert += $nutzwert;
$html .= Html::td(number_format($nutzwert, 3, ',', '.'), 'right bl bb');
$html .= Html::td('', 'center bl bb br');
$html .= '</tr>';
@@ -81,11 +77,9 @@ class Nutzwertberechnung
$html .= '<tr>';
$html .= Html::td('', 'bl bb', 9);
$html .= Html::td(number_format($summe_nutzwert + $nutzwert, 3, ',', '.'), 'right bl bb');
$html .= Html::td(round($summe_nutzwert + $nutzwert), 'center bl bb');
$html .= Html::td(number_format($summe_nutzwert, 3, ',', '.'), 'right bl bb');
$html .= Html::td(round($summe_nutzwert), 'center bl bb');
$html .= '</tr>';
$summe_nutzwert += $nutzwert;
}
$summe_nutzwert = round($summe_nutzwert);
@@ -145,7 +139,7 @@ class Nutzwertberechnung
PdfGenerator::$zusammenstellung[$komponente['id']] = $summe_nutzwert;
}
$objekte = self::laod_project(true);
$objekte = LadeProjekt::project($projekte_id, true);
foreach ($objekte as $methoden) {
/**
@@ -180,64 +174,4 @@ class Nutzwertberechnung
return $html;
}
public static function laod_project($nicht_in_orientierung)
{
$objekte = ProjektObjekte::with('orientierung')
->where('projekte_id', self::$projekte_id)
->where('nicht_in_orientierung', $nicht_in_orientierung)
->orderBy('top_nummer')
->get();
$tmp = [];
foreach ($objekte as $objekt) {
$elemente = ProjektObjekteImDetail::where('projekt_objekte_id', $objekt->id)->get();
foreach ($elemente as $key => $element) {
$methode = self::laod_methode($element['raumart']);
$methode_id = $methode['methode_id'];
$methode_faktor = $methode['faktor'];
$orientierung = $objekt['orientierung']['name'] ?? '';
if ($key > 0 && $methode_id == 1) {
$orientierung = '';
}
$geschoss = $element['geschoss'] ?? '';
if ($key > 0 && $methode_id <= 1) {
$geschoss = '';
}
$t = [];
$t['id'] = $objekt->id;
$t['type'] = ! $key ? $objekt->type : '';
$t['geschoss'] = $geschoss;
$t['orientierung'] = $orientierung;
$t['raumart'] = $element['raumart'];
$t['flaeche'] = $element['flaeche'];
$t['nutzwert'] = $element['nutzwert'];
$t['top_nummer'] = ! $key ? $objekt->top_nummer : '';
$t['objekt_nutzwert'] = $objekt->nutzwert;
$t['faktor'] = $methode_faktor;
$tmp[$objekt->top_nummer][$methode_id][] = $t;
}
}
return $tmp;
}
public static function laod_methode($raumart)
{
if (! count(self::$methoden)) {
self::$methoden = ProjektMethode::where('projekte_id', self::$projekte_id)->get();
}
foreach (self::$methoden as $methode) {
if ($methode->raumart == $raumart) {
return $methode;
}
}
dd('Model ProjektMethode "raumart" '.$raumart.' missing'.__FILE__);
}
}
@@ -195,13 +195,13 @@ class EditProjekte extends EditRecord
Action::make('excel-nutzwerte')
->label('Nutzfläche & Nutzwerte')
->icon('icon-excel')
->url(fn ($record) => route('excel', ['record' => $record, 'part' => 'excel-nutzwerte']))
->url(fn ($record) => route('excel', ['record' => $record, 'part' => 'nutzwerte']))
->hidden(fn ($record): bool => (! $record->bezahlt_am || ! $record->evaluation_gutachten) ? true : false)
->openUrlInNewTab(),
Action::make('excel-aufstellung')
->label('Nutzflächen Aufstellung')
->icon('icon-excel')
->url(fn ($record) => route('excel', ['record' => $record, 'part' => 'excel-aufstellung']))
->url(fn ($record) => route('excel', ['record' => $record, 'part' => 'aufstellung']))
->hidden(fn ($record): bool => (! $record->bezahlt_am || ! $record->evaluation_gutachten) ? true : false)
->openUrlInNewTab(),
])->label('Excel')
-1161
View File
File diff suppressed because it is too large. Load diff
-3170
View File
File diff suppressed because it is too large. Load diff
+1
View File
@@ -22,6 +22,7 @@
"livewire/livewire": "^3.6",
"mallardduck/blade-lucide-icons": "^1.23",
"mpdf/mpdf": "^8.2.1",
"phpoffice/phpspreadsheet": "^5.2",
"spatie/laravel-login-link": "^1.6",
"swisnl/filament-backgrounds": "^2.0",
"ysfkaya/filament-phone-input": "^4.0"
Generated
+371 -1
View File
@@ -4,7 +4,7 @@
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
"This file is @generated automatically"
],
"content-hash": "171db8e3d77691713294b4902d97c8ec",
"content-hash": "e33da7257e7e1d28e862441011addcef",
"packages": [
{
"name": "agencetwogether/hookshelper",
@@ -899,6 +899,85 @@
],
"time": "2025-02-25T06:29:09+00:00"
},
{
"name": "composer/pcre",
"version": "3.3.2",
"source": {
"type": "git",
"url": "https://github.com/composer/pcre.git",
"reference": "b2bed4734f0cc156ee1fe9c0da2550420d99a21e"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/composer/pcre/zipball/b2bed4734f0cc156ee1fe9c0da2550420d99a21e",
"reference": "b2bed4734f0cc156ee1fe9c0da2550420d99a21e",
"shasum": ""
},
"require": {
"php": "^7.4 || ^8.0"
},
"conflict": {
"phpstan/phpstan": "<1.11.10"
},
"require-dev": {
"phpstan/phpstan": "^1.12 || ^2",
"phpstan/phpstan-strict-rules": "^1 || ^2",
"phpunit/phpunit": "^8 || ^9"
},
"type": "library",
"extra": {
"phpstan": {
"includes": [
"extension.neon"
]
},
"branch-alias": {
"dev-main": "3.x-dev"
}
},
"autoload": {
"psr-4": {
"Composer\\Pcre\\": "src"
}
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"MIT"
],
"authors": [
{
"name": "Jordi Boggiano",
"email": "j.boggiano@seld.be",
"homepage": "http://seld.be"
}
],
"description": "PCRE wrapping library that offers type-safe preg_* replacements.",
"keywords": [
"PCRE",
"preg",
"regex",
"regular expression"
],
"support": {
"issues": "https://github.com/composer/pcre/issues",
"source": "https://github.com/composer/pcre/tree/3.3.2"
},
"funding": [
{
"url": "https://packagist.com",
"type": "custom"
},
{
"url": "https://github.com/composer",
"type": "github"
},
{
"url": "https://tidelift.com/funding/github/packagist/composer/composer",
"type": "tidelift"
}
],
"time": "2024-11-12T16:29:46+00:00"
},
{
"name": "danharrin/date-format-converter",
"version": "v0.3.1",
@@ -3911,6 +3990,84 @@
],
"time": "2025-07-17T05:12:15+00:00"
},
{
"name": "maennchen/zipstream-php",
"version": "3.2.0",
"source": {
"type": "git",
"url": "https://github.com/maennchen/ZipStream-PHP.git",
"reference": "9712d8fa4cdf9240380b01eb4be55ad8dcf71416"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/maennchen/ZipStream-PHP/zipball/9712d8fa4cdf9240380b01eb4be55ad8dcf71416",
"reference": "9712d8fa4cdf9240380b01eb4be55ad8dcf71416",
"shasum": ""
},
"require": {
"ext-mbstring": "*",
"ext-zlib": "*",
"php-64bit": "^8.3"
},
"require-dev": {
"brianium/paratest": "^7.7",
"ext-zip": "*",
"friendsofphp/php-cs-fixer": "^3.16",
"guzzlehttp/guzzle": "^7.5",
"mikey179/vfsstream": "^1.6",
"php-coveralls/php-coveralls": "^2.5",
"phpunit/phpunit": "^12.0",
"vimeo/psalm": "^6.0"
},
"suggest": {
"guzzlehttp/psr7": "^2.4",
"psr/http-message": "^2.0"
},
"type": "library",
"autoload": {
"psr-4": {
"ZipStream\\": "src/"
}
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"MIT"
],
"authors": [
{
"name": "Paul Duncan",
"email": "pabs@pablotron.org"
},
{
"name": "Jonatan Männchen",
"email": "jonatan@maennchen.ch"
},
{
"name": "Jesse Donat",
"email": "donatj@gmail.com"
},
{
"name": "András Kolesár",
"email": "kolesar@kolesar.hu"
}
],
"description": "ZipStream is a library for dynamically streaming dynamic zip files from PHP without writing to the disk at all on the server.",
"keywords": [
"stream",
"zip"
],
"support": {
"issues": "https://github.com/maennchen/ZipStream-PHP/issues",
"source": "https://github.com/maennchen/ZipStream-PHP/tree/3.2.0"
},
"funding": [
{
"url": "https://github.com/maennchen",
"type": "github"
}
],
"time": "2025-07-17T11:15:13+00:00"
},
{
"name": "mallardduck/blade-lucide-icons",
"version": "1.24.0",
@@ -3971,6 +4128,113 @@
},
"time": "2025-11-13T04:23:15+00:00"
},
{
"name": "markbaker/complex",
"version": "3.0.2",
"source": {
"type": "git",
"url": "https://github.com/MarkBaker/PHPComplex.git",
"reference": "95c56caa1cf5c766ad6d65b6344b807c1e8405b9"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/MarkBaker/PHPComplex/zipball/95c56caa1cf5c766ad6d65b6344b807c1e8405b9",
"reference": "95c56caa1cf5c766ad6d65b6344b807c1e8405b9",
"shasum": ""
},
"require": {
"php": "^7.2 || ^8.0"
},
"require-dev": {
"dealerdirect/phpcodesniffer-composer-installer": "dev-master",
"phpcompatibility/php-compatibility": "^9.3",
"phpunit/phpunit": "^7.0 || ^8.0 || ^9.0",
"squizlabs/php_codesniffer": "^3.7"
},
"type": "library",
"autoload": {
"psr-4": {
"Complex\\": "classes/src/"
}
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"MIT"
],
"authors": [
{
"name": "Mark Baker",
"email": "mark@lange.demon.co.uk"
}
],
"description": "PHP Class for working with complex numbers",
"homepage": "https://github.com/MarkBaker/PHPComplex",
"keywords": [
"complex",
"mathematics"
],
"support": {
"issues": "https://github.com/MarkBaker/PHPComplex/issues",
"source": "https://github.com/MarkBaker/PHPComplex/tree/3.0.2"
},
"time": "2022-12-06T16:21:08+00:00"
},
{
"name": "markbaker/matrix",
"version": "3.0.1",
"source": {
"type": "git",
"url": "https://github.com/MarkBaker/PHPMatrix.git",
"reference": "728434227fe21be27ff6d86621a1b13107a2562c"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/MarkBaker/PHPMatrix/zipball/728434227fe21be27ff6d86621a1b13107a2562c",
"reference": "728434227fe21be27ff6d86621a1b13107a2562c",
"shasum": ""
},
"require": {
"php": "^7.1 || ^8.0"
},
"require-dev": {
"dealerdirect/phpcodesniffer-composer-installer": "dev-master",
"phpcompatibility/php-compatibility": "^9.3",
"phpdocumentor/phpdocumentor": "2.*",
"phploc/phploc": "^4.0",
"phpmd/phpmd": "2.*",
"phpunit/phpunit": "^7.0 || ^8.0 || ^9.0",
"sebastian/phpcpd": "^4.0",
"squizlabs/php_codesniffer": "^3.7"
},
"type": "library",
"autoload": {
"psr-4": {
"Matrix\\": "classes/src/"
}
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"MIT"
],
"authors": [
{
"name": "Mark Baker",
"email": "mark@demon-angel.eu"
}
],
"description": "PHP Class for working with matrices",
"homepage": "https://github.com/MarkBaker/PHPMatrix",
"keywords": [
"mathematics",
"matrix",
"vector"
],
"support": {
"issues": "https://github.com/MarkBaker/PHPMatrix/issues",
"source": "https://github.com/MarkBaker/PHPMatrix/tree/3.0.1"
},
"time": "2022-12-02T22:17:43+00:00"
},
{
"name": "masterminds/html5",
"version": "2.10.0",
@@ -5062,6 +5326,112 @@
},
"time": "2020-10-15T08:29:30+00:00"
},
{
"name": "phpoffice/phpspreadsheet",
"version": "5.2.0",
"source": {
"type": "git",
"url": "https://github.com/PHPOffice/PhpSpreadsheet.git",
"reference": "3b8994b3aac4b61018bc04fc8c441f4fd68c18eb"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/PHPOffice/PhpSpreadsheet/zipball/3b8994b3aac4b61018bc04fc8c441f4fd68c18eb",
"reference": "3b8994b3aac4b61018bc04fc8c441f4fd68c18eb",
"shasum": ""
},
"require": {
"composer/pcre": "^1||^2||^3",
"ext-ctype": "*",
"ext-dom": "*",
"ext-fileinfo": "*",
"ext-gd": "*",
"ext-iconv": "*",
"ext-libxml": "*",
"ext-mbstring": "*",
"ext-simplexml": "*",
"ext-xml": "*",
"ext-xmlreader": "*",
"ext-xmlwriter": "*",
"ext-zip": "*",
"ext-zlib": "*",
"maennchen/zipstream-php": "^2.1 || ^3.0",
"markbaker/complex": "^3.0",
"markbaker/matrix": "^3.0",
"php": "^8.1",
"psr/http-client": "^1.0",
"psr/http-factory": "^1.0",
"psr/simple-cache": "^1.0 || ^2.0 || ^3.0"
},
"require-dev": {
"dealerdirect/phpcodesniffer-composer-installer": "dev-main",
"dompdf/dompdf": "^2.0 || ^3.0",
"friendsofphp/php-cs-fixer": "^3.2",
"mitoteam/jpgraph": "^10.5",
"mpdf/mpdf": "^8.1.1",
"phpcompatibility/php-compatibility": "^9.3",
"phpstan/phpstan": "^1.1 || ^2.0",
"phpstan/phpstan-deprecation-rules": "^1.0 || ^2.0",
"phpstan/phpstan-phpunit": "^1.0 || ^2.0",
"phpunit/phpunit": "^10.5",
"squizlabs/php_codesniffer": "^3.7",
"tecnickcom/tcpdf": "^6.5"
},
"suggest": {
"dompdf/dompdf": "Option for rendering PDF with PDF Writer",
"ext-intl": "PHP Internationalization Functions, regquired for NumberFormat Wizard",
"mitoteam/jpgraph": "Option for rendering charts, or including charts with PDF or HTML Writers",
"mpdf/mpdf": "Option for rendering PDF with PDF Writer",
"tecnickcom/tcpdf": "Option for rendering PDF with PDF Writer"
},
"type": "library",
"autoload": {
"psr-4": {
"PhpOffice\\PhpSpreadsheet\\": "src/PhpSpreadsheet"
}
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"MIT"
],
"authors": [
{
"name": "Maarten Balliauw",
"homepage": "https://blog.maartenballiauw.be"
},
{
"name": "Mark Baker",
"homepage": "https://markbakeruk.net"
},
{
"name": "Franck Lefevre",
"homepage": "https://rootslabs.net"
},
{
"name": "Erik Tilt"
},
{
"name": "Adrien Crivelli"
}
],
"description": "PHPSpreadsheet - Read, Create and Write Spreadsheet documents in PHP - Spreadsheet engine",
"homepage": "https://github.com/PHPOffice/PhpSpreadsheet",
"keywords": [
"OpenXML",
"excel",
"gnumeric",
"ods",
"php",
"spreadsheet",
"xls",
"xlsx"
],
"support": {
"issues": "https://github.com/PHPOffice/PhpSpreadsheet/issues",
"source": "https://github.com/PHPOffice/PhpSpreadsheet/tree/5.2.0"
},
"time": "2025-10-26T15:54:22+00:00"
},
{
"name": "phpoption/phpoption",
"version": "1.9.4",
-2
View File
@@ -1,7 +1,6 @@
<?php
use App\Actions\Generate\Excel;
use App\Actions\Generate\Pdf;
use App\Actions\Generate\PdfGenerator;
use Filament\Http\Middleware\Authenticate;
use Illuminate\Support\Facades\Route;
@@ -19,6 +18,5 @@ Route::get('/impressum', function () {
return view('pages.impressum');
});
// Route::middleware(Authenticate::class)->get('/app/pdf/{record}/{part}', [Pdf::class, 'make'])->name('pdf');
Route::middleware(Authenticate::class)->get('/app/pdf/{record}/{part}', [PdfGenerator::class, 'make'])->name('pdf');
Route::middleware(Authenticate::class)->get('/app/excel/{record}/{part}', [Excel::class, 'make'])->name('excel');