Add detailed documentation within AWB, Invoice, and Label PDF templates to map HTML elements to specific Excel cell references and VLOOKUP sources. This includes requirements for fonts, colors, and dimensions to ensure future alignment with official IFNEX branding and Excel templates. Also update project status to reflect completed middleware configuration tasks.
126 lines
6.2 KiB
PHP
126 lines
6.2 KiB
PHP
<!DOCTYPE html>
|
|
<!--
|
|
LABEL PDF TEMPLATE — TODO: تطبیق نهایی با قالب اکسل
|
|
|
|
Excel Reference: شیت «label» در فایل 01KYWGVNKS5TNMN37RV77PCYNZ.xlsx
|
|
|
|
Cell Mapping:
|
|
- C1: AWB number echo
|
|
- C3: AWB Number (lookup key)
|
|
- J2: Weight in KG
|
|
- J3: Weight echo
|
|
- A2:B2: Gross Weight
|
|
- A4: W*L*H formula
|
|
- J4: Origin Country
|
|
- J5: Destination Country
|
|
- J7: Destination Country Code
|
|
- A7:B7: Volumetric Weight
|
|
|
|
VLOOKUP Source: شیت «List»
|
|
|
|
Required Fields:
|
|
- AWB Number ( prominently displayed )
|
|
- Shipper: Name, Company, Phone, Address
|
|
- Receiver: Name, Company, Phone, Address
|
|
- Shipment: Gross Weight, Volumetric Weight, Dimensions, From/To Country
|
|
|
|
Current Implementation: A4 size for laser printer + sticker paper
|
|
Original Template: Compact thermal label format
|
|
|
|
TODO: اگر اندازه لیبل کوچکتر (مثل 100x150mm) نیاز است، صفحهبندی را تغییر دهید.
|
|
TODO: فونت و اندازه متن را طبق پرینتر لیبلزن تنظیم کنید.
|
|
TODO: در صورت نیاز به بارکد/QR، کتابخانه بارکد اضافه کنید.
|
|
|
|
Font: باید فونت رسمی IFNEX استفاده شود
|
|
Colors: لوگو نارنجی #f37021
|
|
Page: فعلی A4 Portrait — قابل تغییر به اندازه سفارشی
|
|
-->
|
|
<html lang="fa" dir="rtl">
|
|
<head>
|
|
<meta charset="UTF-8">
|
|
<style>
|
|
* { margin: 0; padding: 0; box-sizing: border-box; }
|
|
body { font-family: DejaVu Sans, sans-serif; font-size: 12px; direction: rtl; text-align: right; }
|
|
.page { width: 210mm; min-height: 297mm; padding: 10mm; margin: 0 auto; }
|
|
|
|
.label-box {
|
|
border: 2px solid #333;
|
|
padding: 15px;
|
|
margin-bottom: 20px;
|
|
page-break-inside: avoid;
|
|
}
|
|
|
|
.header { display: flex; align-items: center; border-bottom: 2px solid #f37021; padding-bottom: 10px; margin-bottom: 15px; }
|
|
.logo { width: 50px; height: auto; margin-left: 10px; }
|
|
.company-info { flex: 1; }
|
|
.company-name { font-size: 16px; font-weight: bold; color: #f37021; }
|
|
.awb-display { font-size: 18px; font-weight: bold; background: #f37021; color: white; padding: 5px 15px; display: inline-block; margin-top: 5px; }
|
|
|
|
.grid { display: flex; flex-wrap: wrap; gap: 15px; }
|
|
.col { flex: 1; min-width: 45%; }
|
|
|
|
.section-title { font-weight: bold; color: #f37021; font-size: 11px; margin-bottom: 8px; text-transform: uppercase; }
|
|
|
|
.row { margin-bottom: 5px; }
|
|
.label { font-weight: bold; color: #555; display: inline-block; width: 100px; }
|
|
.value { display: inline-block; }
|
|
|
|
.shipment-info { background-color: #f9f9f9; padding: 10px; border: 1px solid #ddd; margin-top: 15px; }
|
|
.shipment-grid { display: flex; flex-wrap: wrap; gap: 10px; }
|
|
.shipment-item { flex: 1; min-width: 45%; }
|
|
|
|
.footer { margin-top: 15px; text-align: center; font-size: 10px; color: #666; border-top: 1px solid #ddd; padding-top: 10px; }
|
|
</style>
|
|
</head>
|
|
<body>
|
|
<div class="page">
|
|
<div class="label-box">
|
|
<div class="header">
|
|
<img src="{{ public_path('logo.png') }}" class="logo" alt="IFNEX Logo">
|
|
<div class="company-info">
|
|
<div class="company-name">IFNEX LOGISTICS</div>
|
|
<div class="awb-display">{{ $shipment->awb_no }}</div>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="grid">
|
|
<div class="col">
|
|
<div class="section-title">SHIPPER / فرستنده</div>
|
|
<div class="row"><span class="label">Name:</span><span class="value">{{ $shipper['name'] }}</span></div>
|
|
<div class="row"><span class="label">Company:</span><span class="value">{{ $shipper['company'] }}</span></div>
|
|
<div class="row"><span class="label">Phone:</span><span class="value">{{ $shipper['phone'] }}</span></div>
|
|
<div class="row"><span class="label">Address:</span><span class="value">{{ $shipper['address'] }}</span></div>
|
|
</div>
|
|
<div class="col">
|
|
<div class="section-title">RECEIVER / گیرنده</div>
|
|
<div class="row"><span class="label">Name:</span><span class="value">{{ $receiver['name'] }}</span></div>
|
|
<div class="row"><span class="label">Company:</span><span class="value">{{ $receiver['company'] }}</span></div>
|
|
<div class="row"><span class="label">Phone:</span><span class="value">{{ $receiver['phone'] }}</span></div>
|
|
<div class="row"><span class="label">Address:</span><span class="value">{{ $receiver['address'] }}</span></div>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="shipment-info">
|
|
<div class="section-title">SHIPMENT DETAILS</div>
|
|
<div class="shipment-grid">
|
|
<div class="shipment-item">
|
|
<div class="row"><span class="label">Gross Weight:</span><span class="value">{{ $shipment->weight }} kg</span></div>
|
|
<div class="row"><span class="label">Volumetric:</span><span class="value">{{ $shipment->volumetric_weight }} kg</span></div>
|
|
<div class="row"><span class="label">Dimensions:</span><span class="value">{{ $shipment->dimensions }}</span></div>
|
|
</div>
|
|
<div class="shipment-item">
|
|
<div class="row"><span class="label">From:</span><span class="value">{{ $shipment->fromCountry?->name }}</span></div>
|
|
<div class="row"><span class="label">To:</span><span class="value">{{ $shipment->toCountry?->name }}</span></div>
|
|
<div class="row"><span class="label">Service:</span><span class="value">{{ $shipment->type?->label() }}</span></div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="footer">
|
|
IFNEX Logistics | We Deliver Value | {{ $shipment->awb_no }}
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</body>
|
|
</html>
|