create blade excel files

This commit is contained in:
2025-02-24 09:53:36 +03:30
parent a537a19faa
commit baab9196d7
11 changed files with 503 additions and 106 deletions

View File

@@ -0,0 +1,108 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>کشوری</title>
</head>
<body dir="rtl" style="text-align: center;">
<table>
<thead>
<tr>
<th colspan="9"
style="background-color: #DAEEF3;text-align: center;border-right: 1px solid black;font-weight:bolder;">
تاریخ دریافت گزارش: {{ verta()->now()->format('Y/m/d H:i') }}
</th>
</tr>
<tr>
<th colspan="9"
style="background-color: #DAEEF3;text-align: center;border-right:1px solid black;font-weight:bolder;">
</th>
</tr>
<tr>
<th colspan="9"
style="background-color: #DAEEF3;text-align: center;border-right:1px solid black;font-weight:bolder;font-size: 13;">
گزارش خسارات وارده به ابنیه فنی و تاسیسات راه از تاریخ
{{ verta($fromDate)->format('Y/n/j') }}
تا
تاریخ
{{ verta($ToDate)->format('Y/n/j') }}
</th>
</tr>
<tr class="headercolortable">
<th rowspan="2" style="border:1px solid black;text-align:center;background-color: #C4D79B;">
اداره کل
</th>
<th rowspan="2" style="border:1px solid black;text-align:center;background-color: #C4D79B;">
تعداد کل
</th>
<th colspan="2" style="border:1px solid black;text-align:center;background-color: #C4D79B;">
نحوه شناسایی خسارت
</th>
<th rowspan="2" style="border:1px solid black;text-align:center;background-color: #C4D79B;">
مبلغ کل خسارت ثبت شده (ریال)
</th>
<th rowspan="2" style="border:1px solid black;text-align:center;background-color: #C4D79B;">
کل مبلغ وصول شده (ریال)
</th>
<th colspan="3" style="border:1px solid black;text-align:center;background-color: #C4D79B;">
مبلغ وصول شده به تفکیک نوع پرداخت (ریال)
</th>
</tr>
<tr>
<th style="border:1px solid black;text-align:center;background-color: #EBF1DE;">
گزارش پلیس راه
</th>
<th style="border:1px solid black;text-align:center;background-color: #EBF1DE;">
گزارش گشت راهداری
</th>
<th style="border:1px solid black;text-align:center;background-color: #EBF1DE;">
بیمه
</th>
<th style="border:1px solid black;text-align:center;background-color: #EBF1DE;">
کسر داغی
</th>
<th style="border:1px solid black;text-align:center;background-color: #EBF1DE;">
شخص
</th>
</tr>
</thead>
<tbody>
@foreach ($data as $road)
<tr>
<td style="text-align: center;border:1px solid black;background-color: #DAEEF3;">
{{ $road['name'] }}</td>
<td style="text-align: center;border:1px solid black;background-color: #DAEEF3;">
{{ $road['tedade'] }}</td>
<td style="text-align: center;border:1px solid black;background-color: #DAEEF3;">
{{ $road['police_rah'] }}</td>
<td style="text-align: center;border:1px solid black;background-color: #DAEEF3;">
{{ $road['gozaresh_gasht'] }}</td>
<td style="text-align: center;border:1px solid black;background-color: #DAEEF3;">
{{ $road['kol_sabt_shode'] }}</td>
<td style="text-align: center;border:1px solid black;background-color: #DAEEF3;">
{{ $road['vasel_shode'] }}</td>
<td style="text-align: center;border:1px solid black;background-color: #DAEEF3;">
{{ $road['vasel_shode_bimeh'] }}</td>
<td style="text-align: center;border:1px solid black;background-color: #DAEEF3;">
{{ $road['vasel_shode_daghi'] }}</td>
<td style="text-align: center;border:1px solid black;background-color: #DAEEF3;">
{{ $road['vasel_shode_final'] }}</td>
</tr>
@endforeach
</tbody>
</table>
</body>
</html>

View File

@@ -0,0 +1,82 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>خسارات وارده به تفکیک استان</title>
</head>
<body>
<table>
<thead>
<tr>
<th colspan="16" style="background-color: #DAEEF3;text-align: center;border-right: 1px solid black;font-weight:bolder;text-align:center;">
تاریخ دریافت گزارش: {{verta()->now()->format('Y/m/d H:i')}}
</th>
</tr>
<tr>
<th colspan="16" style="background-color: #DAEEF3;text-align: center;border-right:1px solid black;font-weight:bolder;"></th>
</tr>
<tr>
<th colspan="16" style="background-color: #DAEEF3;text-align: center;border-right:1px solid black;font-weight:bolder;font-size: 13px;">گزارش کلی خسارات وارده</th>
</tr>
<tr>
<th style="border: 1px solid black;text-align: center;background-color: #EBF1DE;">شناسه ثبت در سامانه RMS</th>
<th style="border: 1px solid black;text-align: center;background-color: #EBF1DE;">تاریخ ثبت در سامانه</th>
<th style="border: 1px solid black;text-align: center;background-color: #EBF1DE;">نام استان</th>
<th style="border: 1px solid black;text-align: center;background-color: #EBF1DE;">نام شهرستان</th>
<th style="border: 1px solid black;text-align: center;background-color: #EBF1DE;">تاریخ تصادف</th>
<th style="border: 1px solid black;text-align: center;background-color: #EBF1DE;">ساعت تصادف</th>
<th style="border: 1px solid black;text-align: center;background-color: #EBF1DE;">نوع خسارت</th>
<th style="border: 1px solid black;text-align: center;background-color: #EBF1DE;">نوع تجهیزات خسارت دیده</th>
<th style="border: 1px solid black;text-align: center;background-color: #EBF1DE;">مبلغ برآورد اولیه</th>
<th style="botder: 1px solid black;text-align: center;background-color: #EBF1DE;">آخرین وضعیت</th>
<th style="border: 1px solid black;text-align: center;background-color: #EBF1DE;">مبلغ وصولی به حساب اداره</th>
<th style="border: 1px solid black;text-align: center;background-color: #EBF1DE;">میزان فرانشیز کسر شده</th>
<th style="border: 1px solid black;text-align: center;background-color: #EBF1DE;">میزان داغی تجهیزات خسارت دیده موجود انبار اداره</th>
<th style="border: 1px solid black;text-align: center;background-color: #EBF1DE;">مبلغ فیش</th>
<th style="border: 1px solid black;text-align: center;background-color: #EBF1DE;">مبلغ بیمه</th>
<th style="border: 1px solid black;text-align: center;background-color: #EBF1DE;">مبلغ داغی</th>
</tr>
</thead>
<tbody>
@foreach ($data as $item)
<tr>
<td style="border: 1px solid black;text-align: center;">{{$item->id}}</td>
<td style="border: 1px solid black;text-align: center;">{{Hekmatinasser\Verta\Verta::instance($item->created_at)->format('Y/n/j')}}</td>
<td style="border: 1px solid black;text-align: center;">{{$item->province_fa}}</td>
<td style="border: 1px solid black;text-align: center;">{{$item->city_fa}}</td>
<td style="border: 1px solid black;text-align: center;">{{Hekmatinasser\Verta\Verta::instance($item->accident_date)->format('Y/n/j')}}</td>
<td style="border: 1px solid black;text-align: center;">{{$item->accident_time}}</td>
<td style="border: 1px solid black;text-align: center;">{{$item->accident_type_fa}}</td>
@php
$temp = '';
@endphp
@foreach ($item->damages as $damage)
@php
$temp .= $damage->title." (".$damage->pivot->value." ".$damage->unit.") - ";
@endphp
@endforeach
<td style="border: 1px solid black;text-align: center;">{{$temp}}</td>
<td style="border: 1px solid black;text-align: center;">{{$item->sum ?? 0}}</td>
<td style="border: 1px solid black;text-align: center;">{{$item->status_fa}}</td>
<td style="border: 1px solid black;text-align: center;">{{$item->deposit_insurance_amount + $item->final_amount}}</td>
<td style="border: 1px solid black;text-align: center;"></td>
<td style="border: 1px solid black;text-align: center;"></td>
<td style="border: 1px solid black;text-align: center;">{{$item->final_amount}}</td>
<td style="border: 1px solid black;text-align: center;">{{$item->deposit_insurance_amount}}</td>
<td style="border: 1px solid black;text-align: center;">{{$item->deposit_daghi_amount}}</td>
</tr>
@endforeach
</tbody>
</table>
</body>
</html>

View File

@@ -0,0 +1,109 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>استانی</title>
</head>
<body dir="rtl" style="text-align: center;">
<table>
<thead>
<tr>
<th colspan="9"
style="background-color: #DAEEF3;text-align: center;border-right: 1px solid black;font-weight:bolder;">
تاریخ دریافت گزارش: {{ verta()->now()->format('Y/m/d H:i') }}
</th>
</tr>
<tr>
<th colspan="9"
style="background-color: #DAEEF3;text-align: center;border-right:1px solid black;font-weight:bolder;">
</th>
</tr>
<tr>
<th colspan="9"
style="background-color: #DAEEF3;text-align: center;border-right:1px solid black;font-weight:bolder;font-size: 13;">
گزارش خسارات وارده به ابنیه فنی و تاسیسات راه از تاریخ
{{ verta($fromDate)->format('Y/n/j') }}
تا
تاریخ
{{ verta($toDate)->format('Y/n/j') }}
</th>
</tr>
<tr class="headercolortable">
<th rowspan="2" style="border:1px solid black;text-align:center;background-color: #C4D79B;">
اداره کل
</th>
<th rowspan="2" style="border:1px solid black;text-align:center;background-color: #C4D79B;">
تعداد کل
</th>
<th colspan="2" style="border:1px solid black;text-align:center;background-color: #C4D79B;">
نحوه شناسایی خسارت
</th>
<th rowspan="2" style="border:1px solid black;text-align:center;background-color: #C4D79B;">
مبلغ کل خسارت ثبت شده (ریال)
</th>
<th rowspan="2" style="border:1px solid black;text-align:center;background-color: #C4D79B;">
کل مبلغ وصول شده (ریال)
</th>
<th colspan="3" style="border:1px solid black;text-align:center;background-color: #C4D79B;">
مبلغ وصول شده به تفکیک نوع پرداخت (ریال)
</th>
</tr>
<tr>
<th style="border:1px solid black;text-align:center;background-color: #EBF1DE;">
گزارش پلیس راه
</th>
<th style="border:1px solid black;text-align:center;background-color: #EBF1DE;">
گزارش گشت راهداری
</th>
<th style="border:1px solid black;text-align:center;background-color: #EBF1DE;">
بیمه
</th>
<th style="border:1px solid black;text-align:center;background-color: #EBF1DE;">
کسر داغی
</th>
<th style="border:1px solid black;text-align:center;background-color: #EBF1DE;">
شخص
</th>
</tr>
</thead>
<tbody>
@foreach ($data as $road)
<tr>
<td style="text-align: center;border:1px solid black;background-color: #DAEEF3;">
{{ $road['name'] }}</td>
<td style="text-align: center;border:1px solid black;background-color: #DAEEF3;">
{{ $road['tedade'] }}</td>
<td style="text-align: center;border:1px solid black;background-color: #DAEEF3;">
{{ $road['police_rah'] }}</td>
<td style="text-align: center;border:1px solid black;background-color: #DAEEF3;">
{{ $road['gozaresh_gasht'] }}</td>
<td style="text-align: center;border:1px solid black;background-color: #DAEEF3;">
{{ $road['kol_sabt_shode'] }}</td>
<td style="text-align: center;border:1px solid black;background-color: #DAEEF3;">
{{ $road['vasel_shode'] }}</td>
<td style="text-align: center;border:1px solid black;background-color: #DAEEF3;">
{{ $road['vasel_shode_bimeh'] }}</td>
<td style="text-align: center;border:1px solid black;background-color: #DAEEF3;">
{{ $road['vasel_shode_daghi'] }}</td>
<td style="text-align: center;border:1px solid black;background-color: #DAEEF3;">
{{ $road['vasel_shode_final'] }}</td>
</tr>
@endforeach
</tbody>
</table>
</body>
</html>