Merge pull request #6267 from expsa/orphan-report-integr-customizations

modify orphan final report
This commit is contained in:
Tahir Hassan 2026-01-20 15:42:36 +04:00 committed by GitHub
commit 18ab652c97
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 361 additions and 289 deletions

View File

@ -17,315 +17,386 @@
<!-- Orphan Report Template -->
<template id="report_orphan_document">
<t t-call="web.html_container">
<t t-set="base_url" t-value="'http://%s' % request.httprequest.host"/>
<style>
@font-face {
font-family: 'Cairo';
src: url('<t t-esc="base_url"/>/odex_takaful/static/src/fonts/Cairo-Regular.ttf') format('truetype');
font-weight: 400;
font-style: normal;
}
@font-face {
font-family: 'Cairo';
src: url('<t t-esc="base_url"/>/odex_takaful/static/src/fonts/Cairo-SemiBold.ttf') format('truetype');
font-weight: 600;
font-style: normal;
}
@font-face {
font-family: 'Cairo';
src: url('<t t-esc="base_url"/>/odex_takaful/static/src/fonts/Cairo-Bold.ttf') format('truetype');
font-weight: 700;
font-style: normal;
}
@page {
size: A4 landscape;
margin: 0 !important;
}
body {
margin: 0 !important;
padding: 0 !important;
}
.orphan-page {
page-break-after: always !important;
page-break-inside: avoid !important;
direction: rtl !important;
font-family: 'Cairo', Arial, sans-serif !important;
width: 100% !important;
height: 210mm !important;
}
.orphan-page:last-child {
page-break-after: auto !important;
}
.orphan-page table {
direction: rtl !important;
border-collapse: collapse !important;
width: 100% !important;
table-layout: fixed !important;
}
.orphan-page td {
direction: rtl !important;
}
.orphan-page .data-items-row {
display: table-row !important;
width: 100% !important;
}
.orphan-page .data-item-col {
display: table-cell !important;
width: 50% !important;
vertical-align: top !important;
}
.orphan-page .data-item-spacer {
display: table-cell !important;
width: 4% !important;
}
.orphan-page .data-row-table {
box-shadow: 0 0 0 1px #136456 !important;
background-color: white !important;
border-radius: 30px !important;
overflow: hidden !important;
}
.orphan-page .label-cell {
background-color: #CCA761 !important;
color: white !important;
}
.orphan-page .label-cell-dark {
background-color: #136456 !important;
color: white !important;
}
</style>
<t t-foreach="docs" t-as="doc">
<div class="page">
<div class="orphan-page" dir="rtl" lang="ar">
<!-- Get donation line from donations_details_lines_mechanism_ids relationship -->
<!-- <t t-set="donation_line" t-value="doc.donations_details_lines_mechanism_ids[0] if doc.donations_details_lines_mechanism_ids else False"/>
<t t-set="benefit_member" t-value="donation_line.benefit_id if donation_line and donation_line.benefit_id else False"/>
<t t-set="family" t-value="benefit_member.benefit_id if benefit_member and benefit_member.benefit_id else False"/> -->
<!-- Main Container -->
<table style="background: linear-gradient(to bottom, #ACCFCB 0%, #E0EAE9 50%, #C4B179 100%); width: 297mm; min-height: 210mm; margin: 0 auto; box-shadow: 0 0 10px rgba(0, 0, 0, 0.1); padding: 20px 0px 40px; border-collapse: collapse;" cellpadding="0" cellspacing="0">
<tr>
<td>
<!-- Header Section -->
<table style="width: 100%; margin-bottom: 15px; padding: 0px 0px 0px 20px; border-collapse: collapse;" cellpadding="0" cellspacing="0">
<tr>
<td style="text-align: right; vertical-align: middle;">
<table style="background-color: #22B6B3; border-radius: 30px 0px 0px 30px; padding: 10px 15px; border-collapse: collapse;" cellpadding="0" cellspacing="0">
<tr>
<td style="text-align: center;">
<h1 style="font-size: 20px; font-weight: bold; color: white; margin: 0px; font-family: 'Cairo', Arial, sans-serif; padding: 5px 15px;">تقرير اليتيم</h1>
</td>
</tr>
</table>
</td>
<td style="width: 120px; vertical-align: middle;">
<img src="/odex_takaful/static/src/img/ensan-logo.png" alt="Logo" style="width: 100px; height: auto; max-height: 100px; display: block;"/>
</td>
</tr>
</table>
<table style="background: -webkit-linear-gradient(top, #ACCFCB 0%, #E0EAE9 50%, #C4B179 100%); background: linear-gradient(to bottom, #ACCFCB 0%, #E0EAE9 50%, #C4B179 100%); width: 100%; height: 210mm; margin: 0; padding: 20px 0px 20px; border-collapse: collapse; direction: rtl;" cellpadding="0" cellspacing="0">
<tr style="height: 100%;">
<td style="vertical-align: top; height: 100%;">
<!-- Header Section -->
<table style="width: 100%; margin-bottom: 30px; padding: 0px 40px; border-collapse: collapse; direction: rtl;" cellpadding="0" cellspacing="0">
<tr>
<td style="width: auto; text-align: right; vertical-align: middle; padding: 40px 0px 0px; white-space: nowrap;">
<h1 style="font-size: 20px; font-weight: bold; color: white; background-color: #22B6B3; padding: 10px 20px; margin: 0px; font-family: 'Cairo', Arial, sans-serif; white-space: nowrap; border-radius: 30px 0px 0px 30px;">تقرير اليتيم</h1>
</td>
<td style="width: 80%;"></td>
<td style="width: auto; text-align: left; vertical-align: middle; padding-top: 20px; padding-left: 10px;">
<img t-attf-src="http://{{request.httprequest.host}}/odex_takaful/static/src/img/ensan-logo.png" alt="Logo" style="width: 100px; height: auto; max-height: 100px; display: block;"/>
</td>
</tr>
</table>
<!-- Body Section -->
<table style="width: 100%; padding: 0px 40px; border-collapse: collapse;" cellpadding="0" cellspacing="0">
<tr>
<td>
<!-- Data Items Container -->
<table style="width: 100%; border-collapse: collapse;" cellpadding="0" cellspacing="0">
<!-- Row 1: اسم الكافل + رقم الجوال -->
<tr>
<td style="width: 48%; padding: 2.5px 40px; vertical-align: top;">
<table style="width: 100%; height: 40px; border-radius: 30px; outline: 1px solid #136456; background-color: white; border-collapse: collapse;" cellpadding="0" cellspacing="0">
<tr>
<td style="width: 50%; height: 40px; background-color: #CCA761; color: white; text-align: center; font-size: 16px; font-weight: bold; border-radius: 30px; padding: 0px 20px; font-family: 'Cairo', Arial, sans-serif;">اسم الكافل</td>
<td style="width: 50%; text-align: center; font-size: 16px; color: #136456; font-weight: bold; font-family: 'Cairo', Arial, sans-serif;"><t t-esc="doc.sponsor_related_id.name"/></td>
</tr>
</table>
</td>
<td style="width: 4%;"></td>
<td style="width: 48%; padding: 2.5px 40px; vertical-align: top;">
<table style="width: 100%; height: 40px; border-radius: 30px; outline: 1px solid #136456; background-color: white; border-collapse: collapse;" cellpadding="0" cellspacing="0">
<tr>
<td style="width: 50%; height: 40px; background-color: #CCA761; color: white; text-align: center; font-size: 16px; font-weight: bold; border-radius: 30px; padding: 0px 20px; font-family: 'Cairo', Arial, sans-serif;">رقم الجوال</td>
<td style="width: 50%; text-align: center; font-size: 16px; color: #136456; font-weight: bold; font-family: 'Cairo', Arial, sans-serif;"><t t-esc="doc.sponsor_related_id.mobile"/></td>
</tr>
</table>
</td>
</tr>
<!-- Body Section -->
<table style="width: 100%; height: 100%; padding: 0px 40px; border-collapse: collapse; direction: rtl; table-layout: fixed;" cellpadding="0" cellspacing="0">
<tr>
<td>
<!-- Data Items Container -->
<table style="width: 100%; border-collapse: collapse; direction: rtl; table-layout: fixed;" cellpadding="0" cellspacing="0">
<!-- Row 1: اسم الكافل + رقم الجوال -->
<tr class="data-items-row">
<td class="data-item-col" style="width: 50%; padding: 8px 35px; vertical-align: top;">
<table class="data-row-table" style="width: 100%; height: 40px; border-radius: 30px; box-shadow: 0 0 0 1px #136456; background-color: white !important; border-collapse: separate; border-spacing: 0; overflow: hidden; direction: rtl;" cellpadding="0" cellspacing="0">
<tr>
<td class="label-cell" style="width: 50%; height: 40px; background-color: #CCA761 !important; color: white !important; text-align: center; font-size: 16px; font-weight: bold; padding: 5px 15px; font-family: 'Cairo', Arial, sans-serif; border-radius: 30px 0px 0px 30px; overflow: hidden;">اسم الكافل</td>
<td style="width: 50%; text-align: center; font-size: 16px; color: #136456; font-weight: bold; font-family: 'Cairo', Arial, sans-serif; padding: 0px 10px;"><t t-esc="doc.sponsor_related_id.name if doc.sponsor_related_id else ''"/></td>
</tr>
</table>
</td>
<!-- <td class="data-item-spacer" style="width: 2%;"></td> -->
<td class="data-item-col" style="width: 50%; padding: 8px 35px; vertical-align: top;">
<table style="width: 100%; height: 40px; border-radius: 30px; box-shadow: 0 0 0 1px #136456; background-color: white; border-collapse: separate; border-spacing: 0; overflow: hidden; direction: rtl;" cellpadding="0" cellspacing="0">
<tr>
<td class="label-cell" style="width: 50%; height: 40px; background-color: #CCA761 !important; color: white !important; text-align: center; font-size: 16px; font-weight: bold; padding: 5px 15px; font-family: 'Cairo', Arial, sans-serif; border-radius: 30px 0px 0px 30px; overflow: hidden;">رقم الجوال</td>
<td style="width: 50%; text-align: center; font-size: 16px; color: #136456; font-weight: bold; font-family: 'Cairo', Arial, sans-serif;"><t t-esc="doc.sponsor_related_id.mobile"/></td>
</tr>
</table>
</td>
</tr>
<!-- Row 2: Description -->
<tr>
<td colspan="3" style="padding: 2.5px;">
<table style="width: 100%; border-collapse: collapse;" cellpadding="0" cellspacing="0">
<tr>
<td>
<p style="font-size: 16px; color: #136456; text-align: start; font-weight: bold; margin: 5px 0px 0px; padding: 0px 40px; font-family: 'Cairo', Arial, sans-serif;">حين يصبح الأثر إنسانًا له اسم وقصة وابتسامة.. <br/> نعلم أن الكفالة ليست نهاية، بل بداية لعطاء مستدام، وأثر يصنع الفرق.</p>
<span style="font-size: 16px; color: #136456; text-align: start; font-weight: normal; margin: 10px 0px; padding: 0px 40px; font-family: 'Cairo', Arial, sans-serif;">ما بين الصفوف الدراسية، والهوايات الصغيرة والأمنيات البسيطة، نرفق لكم تقرير مفصل عن اليتيم المكفول:</span>
</td>
</tr>
</table>
</td>
</tr>
<!-- Row 2: Description -->
<tr>
<td colspan="3" style="padding: 15px 0px;">
<table style="width: 100%; border-collapse: collapse; direction: rtl; table-layout: fixed;" cellpadding="0" cellspacing="0">
<tr>
<td>
<p style="font-size: 16px; color: #136456; text-align: start; font-weight: bold; margin: 5px 0px 0px; padding: 0px 40px; font-family: 'Cairo', Arial, sans-serif;">حين يصبح الأثر إنسانًا له اسم وقصة وابتسامة.. <br/> نعلم أن الكفالة ليست نهاية، بل بداية لعطاء مستدام، وأثر يصنع الفرق.</p>
<span style="font-size: 16px; color: #136456; text-align: start; font-weight: normal; margin: 10px 0px; padding: 0px 40px; font-family: 'Cairo', Arial, sans-serif;">ما بين الصفوف الدراسية، والهوايات الصغيرة والأمنيات البسيطة، نرفق لكم تقرير مفصل عن اليتيم المكفول:</span>
</td>
</tr>
</table>
</td>
</tr>
<!-- Row 3: اسم الأرملة + العمر -->
<tr>
<td style="width: 48%; padding: 2.5px 40px; vertical-align: top;">
<table style="width: 100%; height: 40px; border-radius: 30px; outline: 1px solid #136456; background-color: white; border-collapse: collapse;" cellpadding="0" cellspacing="0">
<tr>
<td style="width: 50%; height: 40px; background-color: #CCA761; color: white; text-align: center; font-size: 16px; font-weight: bold; border-radius: 30px; padding: 0px 20px; font-family: 'Cairo', Arial, sans-serif;">اسم اليتيم</td>
<td style="width: 50%; text-align: center; font-size: 16px; color: #136456; font-weight: bold; font-family: 'Cairo', Arial, sans-serif;"><t t-esc="doc.name"/></td>
</tr>
</table>
</td>
<td style="width: 4%;"></td>
<td style="width: 48%; padding: 2.5px 40px; vertical-align: top;">
<table style="width: 100%; height: 40px; border-radius: 30px; outline: 1px solid #136456; background-color: white; border-collapse: collapse;" cellpadding="0" cellspacing="0">
<tr>
<td style="width: 50%; height: 40px; background-color: #CCA761; color: white; text-align: center; font-size: 16px; font-weight: bold; border-radius: 30px; padding: 0px 20px; font-family: 'Cairo', Arial, sans-serif;">العمر</td>
<td style="width: 50%; text-align: center; font-size: 16px; color: #136456; font-weight: bold; font-family: 'Cairo', Arial, sans-serif;"><t t-esc="doc.age"/></td>
</tr>
</table>
</td>
</tr>
<!-- Row 3: اسم الأرملة + العمر -->
<tr class="data-items-row">
<td class="data-item-col" style="width: 50%; padding: 8px 35px; vertical-align: top;">
<table style="width: 100%; height: 40px; border-radius: 30px; box-shadow: 0 0 0 1px #136456; background-color: white; border-collapse: separate; border-spacing: 0; overflow: hidden; direction: rtl;" cellpadding="0" cellspacing="0">
<tr>
<td class="label-cell" style="width: 50%; height: 40px; background-color: #CCA761 !important; color: white !important; text-align: center; font-size: 16px; font-weight: bold; padding: 5px 15px; font-family: 'Cairo', Arial, sans-serif; border-radius: 30px 0px 0px 30px; overflow: hidden;">اسم اليتيم</td>
<td style="width: 50%; text-align: center; font-size: 16px; color: #136456; font-weight: bold; font-family: 'Cairo', Arial, sans-serif;"><t t-esc="doc.name"/></td>
</tr>
</table>
</td>
<!-- <td class="data-item-spacer" style="width: 2%;"></td> -->
<td class="data-item-col" style="width: 50%; padding: 8px 35px; vertical-align: top;">
<table class="data-row-table" style="width: 100%; height: 40px; box-shadow: 0 0 0 1px #136456; background-color: white !important; border-collapse: separate; border-spacing: 0; border-radius: 30px; overflow: hidden; direction: rtl; table-layout: fixed;" cellpadding="0" cellspacing="0">
<tr>
<td class="label-cell" style="width: 50%; height: 40px; background-color: #CCA761 !important; color: white !important; text-align: center; font-size: 16px; font-weight: bold; padding: 5px 15px; font-family: 'Cairo', Arial, sans-serif; border-radius: 30px 0px 0px 30px; overflow: hidden;">العمر</td>
<td style="width: 50%; text-align: center; font-size: 16px; color: #136456; font-weight: bold; font-family: 'Cairo', Arial, sans-serif;"><t t-esc="doc.age"/></td>
</tr>
</table>
</td>
</tr>
<!-- Row 4: رقم الملف + تم الالتحاق في إنسان عام -->
<tr>
<td style="width: 48%; padding: 2.5px 40px; vertical-align: top;">
<table style="width: 100%; height: 40px; border-radius: 30px; outline: 1px solid #136456; background-color: white; border-collapse: collapse;" cellpadding="0" cellspacing="0">
<tr>
<td style="width: 50%; height: 40px; background-color: #136456; color: white; text-align: center; font-size: 16px; font-weight: bold; border-radius: 30px; padding: 0px 20px; font-family: 'Cairo', Arial, sans-serif;">رقم الملف</td>
<td style="width: 50%; text-align: center; font-size: 16px; color: #136456; font-weight: bold; font-family: 'Cairo', Arial, sans-serif;"><t t-esc="doc.benefit_code"/></td>
</tr>
</table>
</td>
<td style="width: 4%;"></td>
<td style="width: 48%; padding: 2.5px 40px; vertical-align: top;">
<table style="width: 100%; height: 40px; border-radius: 30px; outline: 1px solid #136456; background-color: white; border-collapse: collapse;" cellpadding="0" cellspacing="0">
<tr>
<td style="width: 50%; height: 40px; background-color: #136456; color: white; text-align: center; font-size: 16px; font-weight: bold; border-radius: 30px; padding: 0px 20px; font-family: 'Cairo', Arial, sans-serif;">تم الالتحاق في إنسان عام</td>
<td style="width: 50%; text-align: center; font-size: 16px; color: #136456; font-weight: bold; font-family: 'Cairo', Arial, sans-serif;"><t t-esc="doc.create_date.strftime('%Y')"/></td>
</tr>
</table>
</td>
</tr>
<!-- Row 4: رقم الملف + تم الالتحاق في إنسان عام -->
<tr class="data-items-row">
<td class="data-item-col" style="width: 50%; padding: 8px 35px; vertical-align: top;">
<table class="data-row-table" style="width: 100%; height: 40px; box-shadow: 0 0 0 1px #136456; background-color: white !important; border-collapse: separate; border-spacing: 0; border-radius: 30px; overflow: hidden; direction: rtl; table-layout: fixed;" cellpadding="0" cellspacing="0">
<tr>
<td class="label-cell-dark" style="width: 50%; height: 40px; background-color: #136456 !important; color: white !important; text-align: center; font-size: 16px; font-weight: bold; padding: 5px 15px; font-family: 'Cairo', Arial, sans-serif; border-radius: 30px 0px 0px 30px; overflow: hidden;">رقم الملف</td>
<td style="width: 50%; text-align: center; font-size: 16px; color: #136456; font-weight: bold; font-family: 'Cairo', Arial, sans-serif;"><t t-esc="doc.benefit_code"/></td>
</tr>
</table>
</td>
<!-- <td class="data-item-spacer" style="width: 2%;"></td> -->
<td class="data-item-col" style="width: 50%; padding: 8px 35px; vertical-align: top;">
<table class="data-row-table" style="width: 100%; height: 40px; box-shadow: 0 0 0 1px #136456; background-color: white !important; border-collapse: separate; border-spacing: 0; border-radius: 30px; overflow: hidden; direction: rtl; table-layout: fixed;" cellpadding="0" cellspacing="0">
<tr>
<td class="label-cell-dark" style="width: 50%; height: 40px; background-color: #136456 !important; color: white !important; text-align: center; font-size: 16px; font-weight: bold; padding: 5px 15px; font-family: 'Cairo', Arial, sans-serif; border-radius: 30px 0px 0px 30px; overflow: hidden;">تم الالتحاق في إنسان عام</td>
<td style="width: 50%; text-align: center; font-size: 16px; color: #136456; font-weight: bold; font-family: 'Cairo', Arial, sans-serif;"><t t-esc="doc.create_date.strftime('%Y')"/></td>
</tr>
</table>
</td>
</tr>
<!-- Row 5: عدد أفراد الأسرة + الجنسية -->
<tr>
<td style="width: 48%; padding: 2.5px 40px; vertical-align: top;">
<table style="width: 100%; height: 40px; border-radius: 30px; outline: 1px solid #136456; background-color: white; border-collapse: collapse;" cellpadding="0" cellspacing="0">
<tr>
<td style="width: 50%; height: 40px; background-color: #136456; color: white; text-align: center; font-size: 16px; font-weight: bold; border-radius: 30px; padding: 0px 20px; font-family: 'Cairo', Arial, sans-serif;">عدد أفراد الأسرة</td>
<td style="width: 50%; text-align: center; font-size: 16px; color: #136456; font-weight: bold; font-family: 'Cairo', Arial, sans-serif;"><t t-esc="len(doc.benefit_id.member_ids)"/></td>
</tr>
</table>
</td>
<td style="width: 4%;"></td>
<td style="width: 48%; padding: 2.5px 40px; vertical-align: top;">
<table style="width: 100%; height: 40px; border-radius: 30px; outline: 1px solid #136456; background-color: white; border-collapse: collapse;" cellpadding="0" cellspacing="0">
<tr>
<td style="width: 50%; height: 40px; background-color: #136456; color: white; text-align: center; font-size: 16px; font-weight: bold; border-radius: 30px; padding: 0px 20px; font-family: 'Cairo', Arial, sans-serif;">الجنسية</td>
<td style="width: 50%; text-align: center; font-size: 16px; color: #136456; font-weight: bold; font-family: 'Cairo', Arial, sans-serif;"><t t-esc="doc.benefit_id.father_country_id.name"/></td>
</tr>
</table>
</td>
</tr>
<!-- Row 5: عدد أفراد الأسرة + الجنسية -->
<tr class="data-items-row">
<td class="data-item-col" style="width: 50%; padding: 8px 35px; vertical-align: top;">
<table class="data-row-table" style="width: 100%; height: 40px; box-shadow: 0 0 0 1px #136456; background-color: white !important; border-collapse: separate; border-spacing: 0; border-radius: 30px; overflow: hidden; direction: rtl; table-layout: fixed;" cellpadding="0" cellspacing="0">
<tr>
<td class="label-cell-dark" style="width: 50%; height: 40px; background-color: #136456 !important; color: white !important; text-align: center; font-size: 16px; font-weight: bold; padding: 5px 15px; font-family: 'Cairo', Arial, sans-serif; border-radius: 30px 0px 0px 30px; overflow: hidden;">عدد أفراد الأسرة</td>
<td style="width: 50%; text-align: center; font-size: 16px; color: #136456; font-weight: bold; font-family: 'Cairo', Arial, sans-serif;"><t t-esc="len(doc.benefit_id.member_ids)"/></td>
</tr>
</table>
</td>
<!-- <td class="data-item-spacer" style="width: 2%;"></td> -->
<td class="data-item-col" style="width: 50%; padding: 8px 35px; vertical-align: top;">
<table class="data-row-table" style="width: 100%; height: 40px; box-shadow: 0 0 0 1px #136456; background-color: white !important; border-collapse: separate; border-spacing: 0; border-radius: 30px; overflow: hidden; direction: rtl; table-layout: fixed;" cellpadding="0" cellspacing="0">
<tr>
<td class="label-cell-dark" style="width: 50%; height: 40px; background-color: #136456 !important; color: white !important; text-align: center; font-size: 16px; font-weight: bold; padding: 5px 15px; font-family: 'Cairo', Arial, sans-serif; border-radius: 30px 0px 0px 30px; overflow: hidden;">الجنسية</td>
<td style="width: 50%; text-align: center; font-size: 16px; color: #136456; font-weight: bold; font-family: 'Cairo', Arial, sans-serif;"><t t-esc="doc.benefit_id.father_country_id.name"/></td>
</tr>
</table>
</td>
</tr>
<!-- Row 6: المرحلة الدراسية + التقدير -->
<tr>
<td style="width: 48%; padding: 2.5px 40px; vertical-align: top;">
<table style="width: 100%; height: 40px; border-radius: 30px; outline: 1px solid #136456; background-color: white; border-collapse: collapse;" cellpadding="0" cellspacing="0">
<tr>
<td style="width: 50%; height: 40px; background-color: #136456; color: white; text-align: center; font-size: 16px; font-weight: bold; border-radius: 30px; padding: 0px 20px; font-family: 'Cairo', Arial, sans-serif;">المرحلة الدراسية</td>
<td style="width: 50%; text-align: center; font-size: 16px; color: #136456; font-weight: bold; font-family: 'Cairo', Arial, sans-serif;"><t t-esc="doc.last_education_levels.name if doc.last_education_levels else '-'"/></td>
</tr>
</table>
</td>
<td style="width: 4%;"></td>
<td style="width: 48%; padding: 2.5px 40px; vertical-align: top;">
<table style="width: 100%; height: 40px; border-radius: 30px; outline: 1px solid #136456; background-color: white; border-collapse: collapse;" cellpadding="0" cellspacing="0">
<tr>
<td style="width: 50%; height: 40px; background-color: #136456; color: white; text-align: center; font-size: 16px; font-weight: bold; border-radius: 30px; padding: 0px 20px; font-family: 'Cairo', Arial, sans-serif;">التقدير</td>
<td style="width: 50%; text-align: center; font-size: 16px; color: #136456; font-weight: bold; font-family: 'Cairo', Arial, sans-serif;"><t t-esc="doc.last_education_levels.degree if doc.last_education_levels and doc.last_education_levels.degree else '-'"/></td>
</tr>
</table>
</td>
</tr>
<!-- Row 6: المرحلة الدراسية + التقدير -->
<tr class="data-items-row">
<td class="data-item-col" style="width: 50%; padding: 8px 35px; vertical-align: top;">
<table class="data-row-table" style="width: 100%; height: 40px; box-shadow: 0 0 0 1px #136456; background-color: white !important; border-collapse: separate; border-spacing: 0; border-radius: 30px; overflow: hidden; direction: rtl; table-layout: fixed;" cellpadding="0" cellspacing="0">
<tr>
<td class="label-cell-dark" style="width: 50%; height: 40px; background-color: #136456 !important; color: white !important; text-align: center; font-size: 16px; font-weight: bold; padding: 5px 15px; font-family: 'Cairo', Arial, sans-serif; border-radius: 30px 0px 0px 30px; overflow: hidden;">المرحلة الدراسية</td>
<td style="width: 50%; text-align: center; font-size: 16px; color: #136456; font-weight: bold; font-family: 'Cairo', Arial, sans-serif;"><t t-esc="doc.last_education_levels.name if doc.last_education_levels else '-'"/></td>
</tr>
</table>
</td>
<!-- <td class="data-item-spacer" style="width: 2%;"></td> -->
<td class="data-item-col" style="width: 50%; padding: 8px 35px; vertical-align: top;">
<table class="data-row-table" style="width: 100%; height: 40px; box-shadow: 0 0 0 1px #136456; background-color: white !important; border-collapse: separate; border-spacing: 0; border-radius: 30px; overflow: hidden; direction: rtl; table-layout: fixed;" cellpadding="0" cellspacing="0">
<tr>
<td class="label-cell-dark" style="width: 50%; height: 40px; background-color: #136456 !important; color: white !important; text-align: center; font-size: 16px; font-weight: bold; padding: 5px 15px; font-family: 'Cairo', Arial, sans-serif; border-radius: 30px 0px 0px 30px; overflow: hidden;">التقدير</td>
<td style="width: 50%; text-align: center; font-size: 16px; color: #136456; font-weight: bold; font-family: 'Cairo', Arial, sans-serif;"><t t-esc="doc.last_education_levels.degree if doc.last_education_levels and doc.last_education_levels.degree else '-'"/></td>
</tr>
</table>
</td>
</tr>
<!-- Row 7: الحالة الصحية + نوع السكن -->
<tr>
<td style="width: 48%; padding: 2.5px 40px; vertical-align: top;">
<table style="width: 100%; height: 40px; border-radius: 30px; outline: 1px solid #136456; background-color: white; border-collapse: collapse;" cellpadding="0" cellspacing="0">
<tr>
<td style="width: 50%; height: 40px; background-color: #136456; color: white; text-align: center; font-size: 16px; font-weight: bold; border-radius: 30px; padding: 0px 20px; font-family: 'Cairo', Arial, sans-serif;">الحالة الصحية</td>
<td style="width: 50%; text-align: center; font-size: 16px; color: #136456; font-weight: bold; font-family: 'Cairo', Arial, sans-serif;"><t t-esc="'،'.join(doc.diseases_attachment_ids.mapped('diseases_id.name'))"/></td>
</tr>
</table>
</td>
<td style="width: 4%;"></td>
<td style="width: 48%; padding: 2.5px 40px; vertical-align: top;">
<table style="width: 100%; height: 40px; border-radius: 30px; outline: 1px solid #136456; background-color: white; border-collapse: collapse;" cellpadding="0" cellspacing="0">
<tr>
<td style="width: 50%; height: 40px; background-color: #136456; color: white; text-align: center; font-size: 16px; font-weight: bold; border-radius: 30px; padding: 0px 20px; font-family: 'Cairo', Arial, sans-serif;">نوع السكن</td>
<td style="width: 50%; text-align: center; font-size: 16px; color: #136456; font-weight: bold; font-family: 'Cairo', Arial, sans-serif;"><t t-esc="doc.benefit_id.property_type_id.name if doc.benefit_id.property_type_id else '-'"/></td>
</tr>
</table>
</td>
</tr>
<!-- Row 7: الحالة الصحية + نوع السكن -->
<tr class="data-items-row">
<td class="data-item-col" style="width: 50%; padding: 8px 35px; vertical-align: top;">
<table class="data-row-table" style="width: 100%; height: 40px; box-shadow: 0 0 0 1px #136456; background-color: white !important; border-collapse: separate; border-spacing: 0; border-radius: 30px; overflow: hidden; direction: rtl; table-layout: fixed;" cellpadding="0" cellspacing="0">
<tr>
<td class="label-cell-dark" style="width: 50%; height: 40px; background-color: #136456 !important; color: white !important; text-align: center; font-size: 16px; font-weight: bold; padding: 5px 15px; font-family: 'Cairo', Arial, sans-serif; border-radius: 30px 0px 0px 30px; overflow: hidden;">الحالة الصحية</td>
<td style="width: 50%; text-align: center; font-size: 16px; color: #136456; font-weight: bold; font-family: 'Cairo', Arial, sans-serif;"><t t-esc="'،'.join(doc.diseases_attachment_ids.mapped('diseases_id.name'))"/></td>
</tr>
</table>
</td>
<!-- <td class="data-item-spacer" style="width: 2%;"></td> -->
<td class="data-item-col" style="width: 50%; padding: 8px 35px; vertical-align: top;">
<table class="data-row-table" style="width: 100%; height: 40px; box-shadow: 0 0 0 1px #136456; background-color: white !important; border-collapse: separate; border-spacing: 0; border-radius: 30px; overflow: hidden; direction: rtl; table-layout: fixed;" cellpadding="0" cellspacing="0">
<tr>
<td class="label-cell-dark" style="width: 50%; height: 40px; background-color: #136456 !important; color: white !important; text-align: center; font-size: 16px; font-weight: bold; padding: 5px 15px; font-family: 'Cairo', Arial, sans-serif; border-radius: 30px 0px 0px 30px; overflow: hidden;">نوع السكن</td>
<td style="width: 50%; text-align: center; font-size: 16px; color: #136456; font-weight: bold; font-family: 'Cairo', Arial, sans-serif;"><t t-esc="doc.benefit_id.property_type_id.name if doc.benefit_id.property_type_id else '-'"/></td>
</tr>
</table>
</td>
</tr>
<!-- Row 8: عنوان الأسرة + مبلغ الإيجار -->
<tr>
<td style="width: 48%; padding: 2.5px 40px; vertical-align: top;">
<table style="width: 100%; height: 40px; border-radius: 30px; outline: 1px solid #136456; background-color: white; border-collapse: collapse;" cellpadding="0" cellspacing="0">
<tr>
<td style="width: 50%; height: 40px; background-color: #136456; color: white; text-align: center; font-size: 16px; font-weight: bold; border-radius: 30px; padding: 0px 20px; font-family: 'Cairo', Arial, sans-serif;">عنوان الأسرة</td>
<td style="width: 50%; text-align: center; font-size: 16px; color: #136456; font-weight: bold; font-family: 'Cairo', Arial, sans-serif;">
<t t-esc="' ، '.join(filter(None, [
doc.benefit_id.city_id.name,
doc.benefit_id.district_id.name,
doc.benefit_id.street,
doc.benefit_id.house_number,
doc.benefit_id.short_number,
doc.benefit_id.extra_code,
doc.benefit_id.zip
]))"/>
</td>
</tr>
</table>
</td>
<td style="width: 4%;"></td>
<td style="width: 48%; padding: 2.5px 40px; vertical-align: top;">
<table style="width: 100%; height: 40px; border-radius: 30px; outline: 1px solid #136456; background-color: white; border-collapse: collapse;" cellpadding="0" cellspacing="0">
<tr>
<td style="width: 50%; height: 40px; background-color: #136456; color: white; text-align: center; font-size: 16px; font-weight: bold; border-radius: 30px; padding: 0px 20px; font-family: 'Cairo', Arial, sans-serif;">مبلغ الإيجار</td>
<td style="width: 50%; text-align: center; font-size: 16px; color: #136456; font-weight: bold; font-family: 'Cairo', Arial, sans-serif;"><t t-esc="doc.benefit_id.rent_amount if doc.benefit_id.rent_amount else '0'"/></td>
</tr>
</table>
</td>
</tr>
<!-- Row 8: عنوان الأسرة + مبلغ الإيجار -->
<tr class="data-items-row">
<td class="data-item-col" style="width: 50%; padding: 8px 35px; vertical-align: top;">
<table class="data-row-table" style="width: 100%; height: 40px; box-shadow: 0 0 0 1px #136456; background-color: white !important; border-collapse: separate; border-spacing: 0; border-radius: 30px; overflow: hidden; direction: rtl; table-layout: fixed;" cellpadding="0" cellspacing="0">
<tr>
<td class="label-cell-dark" style="width: 50%; height: 40px; background-color: #136456 !important; color: white !important; text-align: center; font-size: 16px; font-weight: bold; padding: 5px 15px; font-family: 'Cairo', Arial, sans-serif; border-radius: 30px 0px 0px 30px; overflow: hidden;">عنوان الأسرة</td>
<td style="width: 50%; text-align: center; font-size: 16px; color: #136456; font-weight: bold; font-family: 'Cairo', Arial, sans-serif;">
<t t-esc="' ، '.join(filter(None, [
doc.benefit_id.city_id.name,
doc.benefit_id.district_id.name,
doc.benefit_id.street,
doc.benefit_id.house_number,
doc.benefit_id.short_number,
doc.benefit_id.extra_code,
doc.benefit_id.zip
]))"/>
</td>
</tr>
</table>
</td>
<!-- <td class="data-item-spacer" style="width: 2%;"></td> -->
<td class="data-item-col" style="width: 50%; padding: 8px 35px; vertical-align: top;">
<table class="data-row-table" style="width: 100%; height: 40px; box-shadow: 0 0 0 1px #136456; background-color: white !important; border-collapse: separate; border-spacing: 0; border-radius: 30px; overflow: hidden; direction: rtl; table-layout: fixed;" cellpadding="0" cellspacing="0">
<tr>
<td class="label-cell-dark" style="width: 50%; height: 40px; background-color: #136456 !important; color: white !important; text-align: center; font-size: 16px; font-weight: bold; padding: 5px 15px; font-family: 'Cairo', Arial, sans-serif; border-radius: 30px 0px 0px 30px; overflow: hidden;">مبلغ الإيجار</td>
<td style="width: 50%; text-align: center; font-size: 16px; color: #136456; font-weight: bold; font-family: 'Cairo', Arial, sans-serif;"><t t-esc="doc.benefit_id.rent_amount if doc.benefit_id.rent_amount else '0'"/></td>
</tr>
</table>
</td>
</tr>
<!-- Row 9: حالة الأسرة + تاريخ نهاية الكفالة -->
<tr>
<td style="width: 48%; padding: 2.5px 40px; vertical-align: top;">
<table style="width: 100%; height: 40px; border-radius: 30px; outline: 1px solid #136456; background-color: white; border-collapse: collapse;" cellpadding="0" cellspacing="0">
<tr>
<td style="width: 50%; height: 40px; background-color: #136456; color: white; text-align: center; font-size: 16px; font-weight: bold; border-radius: 30px; padding: 0px 20px; font-family: 'Cairo', Arial, sans-serif;">حالة الأسرة</td>
<td style="width: 50%; text-align: center; font-size: 16px; color: #136456; font-weight: bold; font-family: 'Cairo', Arial, sans-serif;"><t t-esc="doc.benefit_id.benefit_category_id.name if doc.benefit_id.benefit_category_id else '-'"/></td>
</tr>
</table>
</td>
<td style="width: 4%;"></td>
<td style="width: 48%; padding: 2.5px 40px; vertical-align: top;">
<table style="width: 100%; height: 40px; border-radius: 30px; outline: 1px solid #136456; background-color: white; border-collapse: collapse;" cellpadding="0" cellspacing="0">
<tr>
<td style="width: 50%; height: 40px; background-color: #CCA761; color: white; text-align: center; font-size: 16px; font-weight: bold; border-radius: 30px; padding: 0px 20px; font-family: 'Cairo', Arial, sans-serif;">تاريخ نهاية الكفالة</td>
<td style="width: 50%; text-align: center; font-size: 16px; color: #136456; font-weight: bold; font-family: 'Cairo', Arial, sans-serif;"><t t-esc="doc.sponsorship_end_date.strftime('%Y-%m-%d') if doc.sponsorship_end_date else '-'"/></td>
</tr>
</table>
</td>
</tr>
<!-- Row 9: حالة الأسرة + تاريخ نهاية الكفالة -->
<tr class="data-items-row">
<td class="data-item-col" style="width: 50%; padding: 8px 35px; vertical-align: top;">
<table class="data-row-table" style="width: 100%; height: 40px; box-shadow: 0 0 0 1px #136456; background-color: white !important; border-collapse: separate; border-spacing: 0; border-radius: 30px; overflow: hidden; direction: rtl; table-layout: fixed;" cellpadding="0" cellspacing="0">
<tr>
<td class="label-cell-dark" style="width: 50%; height: 40px; background-color: #136456 !important; color: white !important; text-align: center; font-size: 16px; font-weight: bold; padding: 5px 15px; font-family: 'Cairo', Arial, sans-serif; border-radius: 30px 0px 0px 30px; overflow: hidden;">حالة الأسرة</td>
<td style="width: 50%; text-align: center; font-size: 16px; color: #136456; font-weight: bold; font-family: 'Cairo', Arial, sans-serif;"><t t-esc="doc.benefit_id.benefit_category_id.name if doc.benefit_id.benefit_category_id else '-'"/></td>
</tr>
</table>
</td>
<!-- <td class="data-item-spacer" style="width: 2%;"></td> -->
<td class="data-item-col" style="width: 50%; padding: 8px 35px; vertical-align: top;">
<table class="data-row-table" style="width: 100%; height: 40px; box-shadow: 0 0 0 1px #136456; background-color: white !important; border-collapse: separate; border-spacing: 0; border-radius: 30px; overflow: hidden; direction: rtl; table-layout: fixed;" cellpadding="0" cellspacing="0">
<tr>
<td class="label-cell" style="width: 50%; height: 40px; background-color: #CCA761 !important; color: white !important; text-align: center; font-size: 16px; font-weight: bold; padding: 5px 15px; font-family: 'Cairo', Arial, sans-serif; border-radius: 30px 0px 0px 30px; overflow: hidden;">تاريخ نهاية الكفالة</td>
<td style="width: 50%; text-align: center; font-size: 16px; color: #136456; font-weight: bold; font-family: 'Cairo', Arial, sans-serif;"><t t-esc="doc.sponsorship_end_date.strftime('%Y-%m-%d') if doc.sponsorship_end_date else '-'"/></td>
</tr>
</table>
</td>
</tr>
<!-- Row 10: Section Title - مصادر دخل الأسرة -->
<tr>
<td colspan="3" style="padding: 2.5px 40px;">
<table style="width: 100%; height: 40px; background-color: #CCA761; border-radius: 30px; border-collapse: collapse;" cellpadding="0" cellspacing="0">
<tr>
<td style="font-size: 16px; color: white; text-align: start; padding: 0px 20px; font-weight: bold; font-family: 'Cairo', Arial, sans-serif;">مصادر دخل الأسرة</td>
</tr>
</table>
</td>
</tr>
<!-- Row 10: Section Title - مصادر دخل الأسرة -->
<tr>
<td colspan="3" style="padding: 8px 35px;">
<table style="width: 100%; height: 40px; background-color: #CCA761 !important; border-collapse: separate; border-spacing: 0; border-radius: 30px; overflow: hidden; direction: rtl; table-layout: fixed;" cellpadding="0" cellspacing="0">
<tr>
<td style="font-size: 16px; color: white; text-align: start; padding: 0px 20px; font-weight: bold; font-family: 'Cairo', Arial, sans-serif;">مصادر دخل الأسرة</td>
</tr>
</table>
</td>
</tr>
<!-- Row 11: Income Sources - Dynamic from salary_ids -->
<!-- Get salaries from benefit_id.benefit_id.salary_ids (family.salary_ids) -->
<t t-set="family_salaries" t-value="doc.benefit_id.salary_ids or []"/>
<t t-set="approved_salaries" t-value="family_salaries.filtered(lambda s: s.approved) if family_salaries else []"/>
<t t-set="social_security" t-value="approved_salaries.filtered(lambda s: s.income_type and ('ضمان' in s.income_type.name or 'اجتماعي' in s.income_type.name))"/>
<t t-set="mother_salary" t-value="approved_salaries.filtered(lambda s: s.is_mother_salary)"/>
<t t-set="retirement" t-value="approved_salaries.filtered(lambda s: s.income_type and 'تقاعد' in s.income_type.name)"/>
<t t-set="social_insurance" t-value="approved_salaries.filtered(lambda s: s.income_type and 'تأمين' in s.income_type.name)"/>
<t t-set="total_income" t-value="sum(approved_salaries.mapped('salary_amount')) if approved_salaries else (benefit_member.member_income if benefit_member and benefit_member.member_income else 0)"/>
<!-- Row 11: Income Sources - Dynamic from salary_ids -->
<!-- Get salaries from benefit_id.benefit_id.salary_ids (family.salary_ids) -->
<t t-set="family_salaries" t-value="doc.benefit_id.salary_ids or []"/>
<t t-set="approved_salaries" t-value="family_salaries.filtered(lambda s: s.approved) if family_salaries else []"/>
<t t-set="social_security" t-value="approved_salaries.filtered(lambda s: s.income_type and ('ضمان' in s.income_type.name or 'اجتماعي' in s.income_type.name))"/>
<t t-set="mother_salary" t-value="approved_salaries.filtered(lambda s: s.is_mother_salary)"/>
<t t-set="retirement" t-value="approved_salaries.filtered(lambda s: s.income_type and 'تقاعد' in s.income_type.name)"/>
<t t-set="social_insurance" t-value="approved_salaries.filtered(lambda s: s.income_type and 'تأمين' in s.income_type.name)"/>
<t t-set="total_income" t-value="sum(approved_salaries.mapped('salary_amount')) if approved_salaries else (benefit_member.member_income if benefit_member and benefit_member.member_income else 0)"/>
<tr>
<td style="width: 48%; padding: 2.5px 40px; vertical-align: top;">
<table style="width: 100%; height: 40px; border-radius: 30px; outline: 1px solid #136456; background-color: white; border-collapse: collapse;" cellpadding="0" cellspacing="0">
<tr>
<td style="width: 50%; height: 40px; background-color: #136456; color: white; text-align: center; font-size: 16px; font-weight: bold; border-radius: 30px; padding: 0px 20px; font-family: 'Cairo', Arial, sans-serif;">الضمان الاجتماعي</td>
<td style="width: 50%; text-align: center; font-size: 16px; color: #136456; font-weight: bold; font-family: 'Cairo', Arial, sans-serif;"><t t-esc="sum(social_security.mapped('salary_amount')) if social_security else '-'"/></td>
</tr>
</table>
</td>
<td style="width: 4%;"></td>
<td style="width: 48%; padding: 2.5px 40px; vertical-align: top;">
<table style="width: 100%; height: 40px; border-radius: 30px; outline: 1px solid #136456; background-color: white; border-collapse: collapse;" cellpadding="0" cellspacing="0">
<tr>
<td style="width: 50%; height: 40px; background-color: #136456; color: white; text-align: center; font-size: 16px; font-weight: bold; border-radius: 30px; padding: 0px 20px; font-family: 'Cairo', Arial, sans-serif;">راتب الأم</td>
<td style="width: 50%; text-align: center; font-size: 16px; color: #136456; font-weight: bold; font-family: 'Cairo', Arial, sans-serif;"><t t-esc="sum(mother_salary.mapped('salary_amount')) if mother_salary else '-'"/></td>
</tr>
</table>
</td>
</tr>
<tr class="data-items-row">
<td class="data-item-col" style="width: 50%; padding: 8px 35px; vertical-align: top;">
<table class="data-row-table" style="width: 100%; height: 40px; box-shadow: 0 0 0 1px #136456; background-color: white !important; border-collapse: separate; border-spacing: 0; border-radius: 30px; overflow: hidden; direction: rtl; table-layout: fixed;" cellpadding="0" cellspacing="0">
<tr>
<td class="label-cell-dark" style="width: 50%; height: 40px; background-color: #136456 !important; color: white !important; text-align: center; font-size: 16px; font-weight: bold; padding: 5px 15px; font-family: 'Cairo', Arial, sans-serif; border-radius: 30px 0px 0px 30px; overflow: hidden;">الضمان الاجتماعي</td>
<td style="width: 50%; text-align: center; font-size: 16px; color: #136456; font-weight: bold; font-family: 'Cairo', Arial, sans-serif;"><t t-esc="sum(social_security.mapped('salary_amount')) if social_security else '-'"/></td>
</tr>
</table>
</td>
<!-- <td class="data-item-spacer" style="width: 2%;"></td> -->
<td class="data-item-col" style="width: 50%; padding: 8px 35px; vertical-align: top;">
<table class="data-row-table" style="width: 100%; height: 40px; box-shadow: 0 0 0 1px #136456; background-color: white !important; border-collapse: separate; border-spacing: 0; border-radius: 30px; overflow: hidden; direction: rtl; table-layout: fixed;" cellpadding="0" cellspacing="0">
<tr>
<td class="label-cell-dark" style="width: 50%; height: 40px; background-color: #136456 !important; color: white !important; text-align: center; font-size: 16px; font-weight: bold; padding: 5px 15px; font-family: 'Cairo', Arial, sans-serif; border-radius: 30px 0px 0px 30px; overflow: hidden;">راتب الأم</td>
<td style="width: 50%; text-align: center; font-size: 16px; color: #136456; font-weight: bold; font-family: 'Cairo', Arial, sans-serif;"><t t-esc="sum(mother_salary.mapped('salary_amount')) if mother_salary else '-'"/></td>
</tr>
</table>
</td>
</tr>
<!-- Row 12: الراتب التقاعدي + التأمينات الاجتماعية -->
<tr>
<td style="width: 48%; padding: 2.5px 40px; vertical-align: top;">
<table style="width: 100%; height: 40px; border-radius: 30px; outline: 1px solid #136456; background-color: white; border-collapse: collapse;" cellpadding="0" cellspacing="0">
<tr>
<td style="width: 50%; height: 40px; background-color: #136456; color: white; text-align: center; font-size: 16px; font-weight: bold; border-radius: 30px; padding: 0px 20px; font-family: 'Cairo', Arial, sans-serif;">الراتب التقاعدي</td>
<td style="width: 50%; text-align: center; font-size: 16px; color: #136456; font-weight: bold; font-family: 'Cairo', Arial, sans-serif;"><t t-esc="sum(retirement.mapped('salary_amount')) if retirement else '-'"/></td>
</tr>
</table>
</td>
<td style="width: 4%;"></td>
<td style="width: 48%; padding: 2.5px 40px; vertical-align: top;">
<table style="width: 100%; height: 40px; border-radius: 30px; outline: 1px solid #136456; background-color: white; border-collapse: collapse;" cellpadding="0" cellspacing="0">
<tr>
<td style="width: 50%; height: 40px; background-color: #136456; color: white; text-align: center; font-size: 16px; font-weight: bold; border-radius: 30px; padding: 0px 20px; font-family: 'Cairo', Arial, sans-serif;">التأمينات الاجتماعية</td>
<td style="width: 50%; text-align: center; font-size: 16px; color: #136456; font-weight: bold; font-family: 'Cairo', Arial, sans-serif;"><t t-esc="sum(social_insurance.mapped('salary_amount')) if social_insurance else '-'"/></td>
</tr>
</table>
</td>
</tr>
<!-- Row 12: الراتب التقاعدي + التأمينات الاجتماعية -->
<tr class="data-items-row">
<td class="data-item-col" style="width: 50%; padding: 8px 35px; vertical-align: top;">
<table class="data-row-table" style="width: 100%; height: 40px; box-shadow: 0 0 0 1px #136456; background-color: white !important; border-collapse: separate; border-spacing: 0; border-radius: 30px; overflow: hidden; direction: rtl; table-layout: fixed;" cellpadding="0" cellspacing="0">
<tr>
<td class="label-cell-dark" style="width: 50%; height: 40px; background-color: #136456 !important; color: white !important; text-align: center; font-size: 16px; font-weight: bold; padding: 5px 15px; font-family: 'Cairo', Arial, sans-serif; border-radius: 30px 0px 0px 30px; overflow: hidden;">الراتب التقاعدي</td>
<td style="width: 50%; text-align: center; font-size: 16px; color: #136456; font-weight: bold; font-family: 'Cairo', Arial, sans-serif;"><t t-esc="sum(retirement.mapped('salary_amount')) if retirement else '-'"/></td>
</tr>
</table>
</td>
<!-- <td class="data-item-spacer" style="width: 2%;"></td> -->
<td class="data-item-col" style="width: 50%; padding: 8px 35px; vertical-align: top;">
<table class="data-row-table" style="width: 100%; height: 40px; box-shadow: 0 0 0 1px #136456; background-color: white !important; border-collapse: separate; border-spacing: 0; border-radius: 30px; overflow: hidden; direction: rtl; table-layout: fixed;" cellpadding="0" cellspacing="0">
<tr>
<td class="label-cell-dark" style="width: 50%; height: 40px; background-color: #136456 !important; color: white !important; text-align: center; font-size: 16px; font-weight: bold; padding: 5px 15px; font-family: 'Cairo', Arial, sans-serif; border-radius: 30px 0px 0px 30px; overflow: hidden;">التأمينات الاجتماعية</td>
<td style="width: 50%; text-align: center; font-size: 16px; color: #136456; font-weight: bold; font-family: 'Cairo', Arial, sans-serif;"><t t-esc="sum(social_insurance.mapped('salary_amount')) if social_insurance else '-'"/></td>
</tr>
</table>
</td>
</tr>
<!-- Row 13: المجموع (single item) -->
<tr>
<td style="width: 48%; padding: 2.5px 40px; vertical-align: top;">
<table style="width: 100%; height: 40px; border-radius: 30px; outline: 1px solid #136456; background-color: white; border-collapse: collapse;" cellpadding="0" cellspacing="0">
<tr>
<td style="width: 50%; height: 40px; background-color: #136456; color: white; text-align: center; font-size: 16px; font-weight: bold; border-radius: 30px; padding: 0px 20px; font-family: 'Cairo', Arial, sans-serif;">المجموع</td>
<td style="width: 50%; text-align: center; font-size: 16px; color: #136456; font-weight: bold; font-family: 'Cairo', Arial, sans-serif;"><t t-esc="total_income if total_income else '-'"/></td>
</tr>
</table>
</td>
<td style="width: 4%;"></td>
<td style="width: 48%; padding: 2.5px; vertical-align: top;"></td>
</tr>
<!-- Row 13: المجموع (single item) -->
<tr class="data-items-row">
<td class="data-item-col" style="width: 50%; padding: 8px 35px 35px; vertical-align: top;">
<table class="data-row-table" style="width: 100%; height: 40px; box-shadow: 0 0 0 1px #136456; background-color: white !important; border-collapse: separate; border-spacing: 0; border-radius: 30px; overflow: hidden; direction: rtl; table-layout: fixed;" cellpadding="0" cellspacing="0">
<tr>
<td class="label-cell-dark" style="width: 50%; height: 40px; background-color: #136456 !important; color: white !important; text-align: center; font-size: 16px; font-weight: bold; padding: 5px 15px; font-family: 'Cairo', Arial, sans-serif; border-radius: 30px 0px 0px 30px; overflow: hidden;">المجموع</td>
<td style="width: 50%; text-align: center; font-size: 16px; color: #136456; font-weight: bold; font-family: 'Cairo', Arial, sans-serif;"><t t-esc="total_income if total_income else '-'"/></td>
</tr>
</table>
</td>
<td style="width: 2%;"></td>
<td style="width: 50%; padding: 5px; vertical-align: top;"></td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</div>
</t>
</t>

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB

View File

@ -4,6 +4,7 @@
<template id="report_assets_common" inherit_id="web.report_assets_common">
<xpath expr="." position="inside">
<link rel="stylesheet" type="text/scss" href="/odex_takaful/static/src/scss/receipt_document.scss"/>
<link rel="stylesheet" type="text/scss" href="/odex_takaful/static/src/scss/orphan-fonts.scss"/>
</xpath>
</template>