fix: remove _get_display_grouped_section() call causing 500 error on portal

This commit is contained in:
2026-03-09 22:49:55 +00:00
parent d7657bb356
commit 85367747a6

View File

@@ -325,79 +325,51 @@
<tbody>
<t t-set="adp_total_cols" t-value="8 - (0 if display_taxes else 1)"/>
<t t-foreach="lines_to_report" t-as="line">
<t t-if="not line._get_display_grouped_section()">
<!-- Section Header -->
<tr t-if="line.display_type == 'line_section'" name="tr_section" class="bg-200 fw-bold">
<td t-att-colspan="adp_total_cols" name="td_section_line">
<span t-field="line.name"/>
</td>
</tr>
<!-- Note Line -->
<tr t-elif="line.display_type == 'line_note'" name="tr_note" class="fst-italic text-muted">
<td t-att-colspan="adp_total_cols" name="td_note_line">
<span t-field="line.name"/>
</td>
</tr>
<!-- Product Line -->
<tr t-elif="not line.display_type" name="tr_product">
<td class="text-center">
<span t-esc="line.product_id.x_fc_adp_device_code or ''"/>
</td>
<td name="td_product_name">
<span t-field="line.name"/>
</td>
<td name="td_product_quantity" class="text-end">
<div id="quote_qty">
<span t-field="line.product_uom_qty"/>
<span t-field="line.product_uom_id"/>
</div>
</td>
<td class="text-end d-none d-sm-table-cell">
<span t-field="line.price_unit"
t-options="{'widget': 'monetary', 'display_currency': line.currency_id}"/>
</td>
<td t-if="display_taxes" class="text-end d-none d-md-table-cell">
<span t-out="', '.join(map(lambda x: (x.name), line.tax_ids))"/>
</td>
<td class="text-end adp-col-bg">
<span t-field="line.x_fc_adp_portion"
t-options="{'widget': 'monetary', 'display_currency': sale_order.currency_id}"/>
</td>
<td class="text-end client-col-bg">
<span t-field="line.x_fc_client_portion"
t-options="{'widget': 'monetary', 'display_currency': sale_order.currency_id}"/>
</td>
<td t-if="not line.is_downpayment" name="td_product_subtotal" class="text-end">
<span t-field="line.price_subtotal"/>
</td>
</tr>
</t>
<t t-else="">
<!-- Grouped Section Display -->
<tr t-foreach="line._get_grouped_section_summary(display_taxes)"
t-as="section_line"
name="tr_section_group"
class="bg-200 fw-bold">
<td/>
<td name="td_section_group_name">
<span t-field="line.name"/>
</td>
<td class="text-end text-nowrap"/>
<td class="text-end text-nowrap d-none d-sm-table-cell">
<span t-out="section_line['price_subtotal']"
t-options="{'widget': 'monetary', 'display_currency': sale_order.currency_id}"/>
</td>
<td t-if="display_taxes" class="text-end d-none d-md-table-cell">
<span t-out="', '.join(section_line['tax_labels'])"/>
</td>
<td class="text-end adp-col-bg"/>
<td class="text-end client-col-bg"/>
<td name="td_section_group_total" class="text-end">
<span t-out="section_line['price_subtotal']"
t-options="{'widget': 'monetary', 'display_currency': sale_order.currency_id}"/>
</td>
</tr>
</t>
<!-- Section Header -->
<tr t-if="line.display_type == 'line_section'" name="tr_section" class="bg-200 fw-bold">
<td t-att-colspan="adp_total_cols" name="td_section_line">
<span t-field="line.name"/>
</td>
</tr>
<!-- Note Line -->
<tr t-elif="line.display_type == 'line_note'" name="tr_note" class="fst-italic text-muted">
<td t-att-colspan="adp_total_cols" name="td_note_line">
<span t-field="line.name"/>
</td>
</tr>
<!-- Product Line -->
<tr t-elif="not line.display_type" name="tr_product">
<td class="text-center">
<span t-esc="line.product_id.x_fc_adp_device_code or ''"/>
</td>
<td name="td_product_name">
<span t-field="line.name"/>
</td>
<td name="td_product_quantity" class="text-end">
<div id="quote_qty">
<span t-field="line.product_uom_qty"/>
<span t-field="line.product_uom_id"/>
</div>
</td>
<td class="text-end d-none d-sm-table-cell">
<span t-field="line.price_unit"
t-options="{'widget': 'monetary', 'display_currency': line.currency_id}"/>
</td>
<td t-if="display_taxes" class="text-end d-none d-md-table-cell">
<span t-out="', '.join(map(lambda x: (x.name), line.tax_ids))"/>
</td>
<td class="text-end adp-col-bg">
<span t-field="line.x_fc_adp_portion"
t-options="{'widget': 'monetary', 'display_currency': sale_order.currency_id}"/>
</td>
<td class="text-end client-col-bg">
<span t-field="line.x_fc_client_portion"
t-options="{'widget': 'monetary', 'display_currency': sale_order.currency_id}"/>
</td>
<td t-if="not line.is_downpayment" name="td_product_subtotal" class="text-end">
<span t-field="line.price_subtotal"/>
</td>
</tr>
</t>
</tbody>
</table>