* The compiled templates are cached per user, lang, inherit context values * ir.ui.fields: attributes method return an dict, and record_to_html return only the content value of the field * all rendered text use build_text and all attributes use build_attribute * t-esc-options is removed and replace by format_value method * AssetsBundle receive the list files and remains
92 lines
4.5 KiB
XML
92 lines
4.5 KiB
XML
<?xml version="1.0" encoding="utf-8"?>
|
|
<odoo>
|
|
<template id="report_partnerledger">
|
|
<t t-call="report.html_container">
|
|
<t t-set="data_report_margin_top" t-value="12"/>
|
|
<t t-set="data_report_header_spacing" t-value="9"/>
|
|
<t t-set="data_report_dpi" t-value="110"/>
|
|
<t t-foreach="docs" t-as="o">
|
|
<t t-call="report.internal_layout">
|
|
<div class="page">
|
|
<h2>Partner Ledger</h2>
|
|
|
|
<div class="row">
|
|
<div class="col-xs-3">
|
|
<strong>Company:</strong>
|
|
<p t-esc="res_company.name"/>
|
|
</div>
|
|
<div class="col-xs-3">
|
|
<t t-if="data['form']['date_from']"><strong>Date from :</strong> <span t-esc="data['form']['date_from']"/><br/></t>
|
|
<t t-if="data['form']['date_to']"><strong>Date to :</strong> <span t-esc="data['form']['date_to']"/></t>
|
|
</div>
|
|
<div class="col-xs-3">
|
|
<strong>Target Moves:</strong>
|
|
<p t-if="data['form']['target_move'] == 'all'">All Entries</p>
|
|
<p t-if="data['form']['target_move'] == 'posted'">All Posted Entries</p>
|
|
</div>
|
|
</div>
|
|
|
|
<table class="table table-condensed">
|
|
<thead>
|
|
<tr>
|
|
<th>Date</th>
|
|
<th>JRNL</th>
|
|
<th>Account</th>
|
|
<th>Ref</th>
|
|
<th>Debit</th>
|
|
<th>Credit</th>
|
|
<th>Balance</th>
|
|
<th t-if="amount_currency">Currency</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
<tr>
|
|
<td colspan="4">
|
|
<strong t-esc="o.ref"/>
|
|
- <strong t-esc="o.name"/>
|
|
</td>
|
|
<td class="text-right">
|
|
<strong t-esc="format(sum_partner(data, o, 'debit'), 'monetary', res_company.currency_id)"/>
|
|
</td>
|
|
<td class="text-right">
|
|
<strong t-esc="format(sum_partner(data, o, 'credit'), 'monetary', res_company.currency_id)"/>
|
|
</td>
|
|
<td class="text-right">
|
|
<strong t-esc="format(sum_partner(data, o, 'debit - credit'), 'monetary', res_company.currency_id)"/>
|
|
</td>
|
|
</tr>
|
|
<tr t-foreach="lines(data, o)" t-as="line">
|
|
<td>
|
|
<span t-esc="line['date']"/>
|
|
</td>
|
|
<td>
|
|
<span t-esc="line['code']"/>
|
|
</td>
|
|
<td>
|
|
<span t-esc="line['a_code']"/>
|
|
</td>
|
|
<td>
|
|
<span t-esc="line['displayed_name']"/>
|
|
</td>
|
|
<td class="text-right">
|
|
<span t-esc="format(line['debit'], 'monetary', res_company.currency_id)"/>
|
|
</td>
|
|
<td class="text-right">
|
|
<span t-esc="format(line['credit'], 'monetary', res_company.currency_id)"/>
|
|
</td>
|
|
<td class="text-right">
|
|
<span t-esc="format(line['progress'], 'monetary', res_company.currency_id)"/>
|
|
</td>
|
|
<td t-if="amount_currency">
|
|
<span t-esc="format(line['amount_currency'], 'monetary', line['currency_id'])"/>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</t>
|
|
</t>
|
|
</t>
|
|
</template>
|
|
</odoo>
|