odoo-addon-account-financial-report 18.0.1.2.6.1__py3-none-any.whl → 18.0.1.3.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of odoo-addon-account-financial-report might be problematic. Click here for more details.

@@ -927,6 +927,7 @@ msgstr "Agrupar por"
927
927
 
928
928
  #. module: account_financial_report
929
929
  #: model:ir.model.fields,field_description:account_financial_report.field_general_ledger_report_wizard__grouped_by
930
+ #: model:ir.model.fields,field_description:account_financial_report.field_open_items_report_wizard__grouped_by
930
931
  #: model:ir.model.fields,field_description:account_financial_report.field_trial_balance_report_wizard__grouped_by
931
932
  msgid "Grouped By"
932
933
  msgstr "Agrupado por"
@@ -1150,7 +1151,13 @@ msgstr "Línea"
1150
1151
  #: code:addons/account_financial_report/report/open_items.py:0
1151
1152
  #: code:addons/account_financial_report/report/trial_balance.py:0
1152
1153
  msgid "Missing Partner"
1153
- msgstr "Falta el Socio"
1154
+ msgstr "Falta la empresa"
1155
+
1156
+ #. module: account_financial_report
1157
+ #: code:addons/account_financial_report/report/open_items.py:0
1158
+ #, python-format
1159
+ msgid "Missing Salesperson"
1160
+ msgstr "Sin comercial"
1154
1161
 
1155
1162
  #. module: account_financial_report
1156
1163
  #: model:ir.model,name:account_financial_report.model_account_age_report_configuration_line
@@ -1348,6 +1355,12 @@ msgstr ""
1348
1355
  msgid "Partner Initial balance"
1349
1356
  msgstr "Saldo Inicial de empresa"
1350
1357
 
1358
+ #. module: account_financial_report
1359
+ #. odoo-python
1360
+ #: model:ir.model.fields.selection,name:account_financial_report.selection__open_items_report_wizard__grouped_by__salesperson
1361
+ msgid "Partner Salesperson"
1362
+ msgstr "Comercial de la empresa"
1363
+
1351
1364
  #. module: account_financial_report
1352
1365
  #. odoo-python
1353
1366
  #: code:addons/account_financial_report/report/aged_partner_balance_xlsx.py:0
@@ -1370,6 +1383,7 @@ msgstr "Saldo inicial de empresa"
1370
1383
 
1371
1384
  #. module: account_financial_report
1372
1385
  #: model:ir.model.fields.selection,name:account_financial_report.selection__general_ledger_report_wizard__grouped_by__partners
1386
+ #: model:ir.model.fields.selection,name:account_financial_report.selection__open_items_report_wizard__grouped_by__partners
1373
1387
  msgid "Partners"
1374
1388
  msgstr "Empresas"
1375
1389
 
@@ -1,5 +1,6 @@
1
1
  # © 2016 Julien Coux (Camptocamp)
2
2
  # Copyright 2020 ForgeFlow S.L. (https://www.forgeflow.com)
3
+ # Copyright 2024 Tecnativa - Carolina Fernandez
3
4
  # License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
4
5
 
5
6
  import operator
@@ -66,6 +67,7 @@ class OpenItemsReport(models.AbstractModel):
66
67
  only_posted_moves,
67
68
  company_id,
68
69
  date_from,
70
+ grouped_by,
69
71
  ):
70
72
  domain = self._get_move_lines_domain_not_reconciled(
71
73
  company_id, account_ids, partner_ids, only_posted_moves, date_from
@@ -75,7 +77,7 @@ class OpenItemsReport(models.AbstractModel):
75
77
  domain=domain, fields=ml_fields
76
78
  )
77
79
  journals_ids = set()
78
- partners_ids = set()
80
+ group_ids = set()
79
81
  partners_data = {}
80
82
  if date_at_object < date.today():
81
83
  (
@@ -119,29 +121,27 @@ class OpenItemsReport(models.AbstractModel):
119
121
  journals_ids.add(move_line["journal_id"][0])
120
122
  acc_id = move_line["account_id"][0]
121
123
  # Partners data
122
- if move_line["partner_id"]:
123
- prt_id = move_line["partner_id"][0]
124
- prt_name = move_line["partner_id"][1]
124
+ partner = self.env["res.partner"]
125
+ if move_line.get("partner_id"):
126
+ partner = self.env["res.partner"].browse(move_line["partner_id"][0])
127
+ if grouped_by == "salesperson":
128
+ user = partner.user_id
129
+ group_id = user.id or 0
130
+ group_name = user.name or _("Missing Salesperson")
125
131
  else:
126
- prt_id = 0
127
- prt_name = _("Missing Partner")
128
- if prt_id not in partners_ids:
129
- partners_data.update({prt_id: {"id": prt_id, "name": prt_name}})
130
- partners_ids.add(prt_id)
131
-
132
+ group_id = partner.id or 0
133
+ group_name = partner.name or _("Missing Partner")
134
+ if group_id not in group_ids:
135
+ partners_data.update({group_id: {"id": group_id, "name": group_name}})
136
+ group_ids.add(group_id)
132
137
  # Move line update
133
- original = 0
134
-
135
138
  if not float_is_zero(move_line["credit"], precision_digits=2):
136
139
  original = move_line["credit"] * (-1)
137
- if not float_is_zero(move_line["debit"], precision_digits=2):
140
+ else:
138
141
  original = move_line["debit"]
139
142
 
140
143
  if move_line["ref"] == move_line["name"]:
141
- if move_line["ref"]:
142
- ref_label = move_line["ref"]
143
- else:
144
- ref_label = ""
144
+ ref_label = move_line["ref"] or ""
145
145
  elif not move_line["ref"]:
146
146
  ref_label = move_line["name"]
147
147
  elif not move_line["name"]:
@@ -155,8 +155,8 @@ class OpenItemsReport(models.AbstractModel):
155
155
  "date_maturity": move_line["date_maturity"]
156
156
  and move_line["date_maturity"].strftime("%d/%m/%Y"),
157
157
  "original": original,
158
- "partner_id": prt_id,
159
- "partner_name": prt_name,
158
+ "partner_id": partner.id or 0,
159
+ "partner_name": partner.name or "",
160
160
  "ref_label": ref_label,
161
161
  "journal_id": move_line["journal_id"][0],
162
162
  "move_name": move_line["move_id"][1],
@@ -172,12 +172,12 @@ class OpenItemsReport(models.AbstractModel):
172
172
 
173
173
  # Open Items Move Lines Data
174
174
  if acc_id not in open_items_move_lines_data.keys():
175
- open_items_move_lines_data[acc_id] = {prt_id: [move_line]}
175
+ open_items_move_lines_data[acc_id] = {group_id: [move_line]}
176
176
  else:
177
- if prt_id not in open_items_move_lines_data[acc_id].keys():
178
- open_items_move_lines_data[acc_id][prt_id] = [move_line]
177
+ if group_id not in open_items_move_lines_data[acc_id].keys():
178
+ open_items_move_lines_data[acc_id][group_id] = [move_line]
179
179
  else:
180
- open_items_move_lines_data[acc_id][prt_id].append(move_line)
180
+ open_items_move_lines_data[acc_id][group_id].append(move_line)
181
181
  journals_data = self._get_journals_data(list(journals_ids))
182
182
  accounts_data = self._get_accounts_data(open_items_move_lines_data.keys())
183
183
  return (
@@ -236,7 +236,9 @@ class OpenItemsReport(models.AbstractModel):
236
236
  move_lines = []
237
237
  for move_line in open_items_move_lines_data[acc_id][prt_id]:
238
238
  move_lines += [move_line]
239
- move_lines = sorted(move_lines, key=lambda k: (k["date"]))
239
+ move_lines = sorted(
240
+ move_lines, key=lambda k: (k["date"], k["partner_id"])
241
+ )
240
242
  new_open_items[acc_id][prt_id] = move_lines
241
243
  return new_open_items
242
244
 
@@ -251,7 +253,7 @@ class OpenItemsReport(models.AbstractModel):
251
253
  date_from = data["date_from"]
252
254
  only_posted_moves = data["only_posted_moves"]
253
255
  show_partner_details = data["show_partner_details"]
254
-
256
+ grouped_by = data["grouped_by"]
255
257
  (
256
258
  move_lines_data,
257
259
  partners_data,
@@ -265,6 +267,7 @@ class OpenItemsReport(models.AbstractModel):
265
267
  only_posted_moves,
266
268
  company_id,
267
269
  date_from,
270
+ grouped_by,
268
271
  )
269
272
 
270
273
  total_amount = self._calculate_amounts(open_items_move_lines_data)
@@ -290,6 +293,7 @@ class OpenItemsReport(models.AbstractModel):
290
293
  "accounts_data": accounts_data,
291
294
  "total_amount": total_amount,
292
295
  "Open_Items": open_items_move_lines_data,
296
+ "grouped_by": grouped_by,
293
297
  }
294
298
 
295
299
  def _get_ml_fields(self):
@@ -101,11 +101,126 @@ class OpenItemsXslx(models.AbstractModel):
101
101
  def _get_col_pos_final_balance_label(self):
102
102
  return 5
103
103
 
104
- def _generate_report_content(self, workbook, report, data, report_data):
105
- res_data = self.env[
106
- "report.account_financial_report.open_items"
107
- ]._get_report_values(report, data)
108
- # For each account
104
+ def _calculate_amounts_by_partner(self, account_id, open_items_move_lines_data):
105
+ total_amount = {}
106
+ for line in open_items_move_lines_data:
107
+ partner_id_key = line["partner_id"]
108
+ if account_id not in total_amount:
109
+ total_amount[account_id] = {}
110
+ if partner_id_key not in total_amount[account_id]:
111
+ total_amount[account_id][partner_id_key] = {"residual": 0.0}
112
+ total_amount[account_id][partner_id_key]["residual"] += line[
113
+ "amount_residual"
114
+ ]
115
+ return total_amount
116
+
117
+ def _generate_report_content_by_salesperson(
118
+ self, workbook, report, data, report_data, res_data
119
+ ):
120
+ Open_items = res_data["Open_Items"]
121
+ accounts_data = res_data["accounts_data"]
122
+ partners_data = res_data["partners_data"]
123
+ journals_data = res_data["journals_data"]
124
+ total_amount = res_data["total_amount"]
125
+
126
+ for partner_id in partners_data.keys():
127
+ # Create a new sheet for each partner
128
+ partner_totals = {}
129
+ partner_name = partners_data[partner_id]["name"]
130
+ new_sheet = workbook.add_worksheet(partner_name[:31])
131
+ report_data["sheet"] = new_sheet
132
+ report_data["row_pos"] = 0
133
+
134
+ for account_id in Open_items.keys():
135
+ if partner_id in Open_items[account_id]:
136
+ self.write_array_title(
137
+ accounts_data[account_id]["code"]
138
+ + " - "
139
+ + accounts_data[account_id]["name"],
140
+ report_data,
141
+ )
142
+
143
+ # For each partner
144
+ if Open_items[account_id]:
145
+ type_object = "partner"
146
+ # Write partner title
147
+ self.write_array_title(
148
+ partners_data[partner_id]["name"], report_data
149
+ )
150
+
151
+ # Calculate totals by partner_id
152
+ partner_totals = self._calculate_amounts_by_partner(
153
+ account_id, Open_items[account_id][partner_id]
154
+ )
155
+ # Display array header for move lines
156
+ self.write_array_header(report_data)
157
+ # Display account move lines
158
+ has_lines = False
159
+ for partner_id_key, total_amount_dict in partner_totals.get(
160
+ account_id, {}
161
+ ).items():
162
+ for line in Open_items[account_id][partner_id]:
163
+ if line["partner_id"] == partner_id_key:
164
+ line.update(
165
+ {
166
+ "account": accounts_data[account_id][
167
+ "code"
168
+ ],
169
+ "journal": journals_data[
170
+ line["journal_id"]
171
+ ]["code"],
172
+ }
173
+ )
174
+ self.write_line_from_dict(line, report_data)
175
+ has_lines = True
176
+ if has_lines:
177
+ partner = self.env["res.partner"].browse(partner_id_key)
178
+ # Display ending balance line for partner
179
+ partner_data = {
180
+ "id": partner_id_key,
181
+ "name": partner.name
182
+ if partner
183
+ else _("Missing Partner"),
184
+ "currency_id": accounts_data[account_id][
185
+ "currency_id"
186
+ ],
187
+ "currency_name": accounts_data[account_id][
188
+ "currency_name"
189
+ ],
190
+ "residual": total_amount_dict,
191
+ }
192
+ self.write_ending_balance_from_dict(
193
+ partner_data,
194
+ "partner_subtotal",
195
+ partner_totals,
196
+ report_data,
197
+ account_id=account_id,
198
+ partner_id=partner_id_key,
199
+ )
200
+ has_lines = False
201
+ # Display ending balance line for salesperson
202
+ partners_data[partner_id].update(
203
+ {
204
+ "currency_id": accounts_data[account_id]["currency_id"],
205
+ "currency_name": accounts_data[account_id][
206
+ "currency_name"
207
+ ],
208
+ }
209
+ )
210
+ self.write_ending_balance_from_dict(
211
+ partners_data[partner_id],
212
+ type_object,
213
+ total_amount,
214
+ report_data,
215
+ account_id=account_id,
216
+ partner_id=partner_id,
217
+ )
218
+ # Line break
219
+ report_data["row_pos"] += 1
220
+
221
+ def _generate_report_content_by_partner(
222
+ self, workbook, report, data, report_data, res_data
223
+ ):
109
224
  Open_items = res_data["Open_Items"]
110
225
  accounts_data = res_data["accounts_data"]
111
226
  partners_data = res_data["partners_data"]
@@ -120,7 +235,6 @@ class OpenItemsXslx(models.AbstractModel):
120
235
  + accounts_data[account_id]["name"],
121
236
  report_data,
122
237
  )
123
-
124
238
  # For each partner
125
239
  if Open_items[account_id]:
126
240
  if show_partner_details:
@@ -180,18 +294,33 @@ class OpenItemsXslx(models.AbstractModel):
180
294
  )
181
295
  self.write_line_from_dict(line, report_data)
182
296
 
183
- # Display ending balance line for account
184
- type_object = "account"
185
- self.write_ending_balance_from_dict(
186
- accounts_data[account_id],
187
- type_object,
188
- total_amount,
189
- report_data,
190
- account_id=account_id,
191
- )
297
+ # Display ending balance line for account
298
+ type_object = "account"
299
+ self.write_ending_balance_from_dict(
300
+ accounts_data[account_id],
301
+ type_object,
302
+ total_amount,
303
+ report_data,
304
+ account_id=account_id,
305
+ )
306
+
307
+ # 2 lines break
308
+ report_data["row_pos"] += 2
192
309
 
193
- # 2 lines break
194
- report_data["row_pos"] += 2
310
+ def _generate_report_content(self, workbook, report, data, report_data):
311
+ res_data = self.env[
312
+ "report.account_financial_report.open_items"
313
+ ]._get_report_values(report, data)
314
+ show_partner_details = res_data["show_partner_details"]
315
+ grouped_by = res_data["grouped_by"]
316
+ if grouped_by == "salesperson" and show_partner_details:
317
+ return self._generate_report_content_by_salesperson(
318
+ workbook, report, data, report_data, res_data
319
+ )
320
+ else:
321
+ return self._generate_report_content_by_partner(
322
+ workbook, report, data, report_data, res_data
323
+ )
195
324
 
196
325
  def write_ending_balance_from_dict(
197
326
  self,
@@ -211,6 +340,10 @@ class OpenItemsXslx(models.AbstractModel):
211
340
  name = my_object["code"] + " - " + my_object["name"]
212
341
  my_object["residual"] = total_amount[account_id]["residual"]
213
342
  label = _("Ending balance")
343
+ elif type_object == "partner_subtotal":
344
+ name = my_object["name"]
345
+ my_object["residual"] = total_amount[account_id][partner_id]["residual"]
346
+ label = _("Ending balance")
214
347
  return super().write_ending_balance_from_dict(
215
348
  my_object, name, label, report_data
216
349
  )
@@ -9,6 +9,7 @@
9
9
  </t>
10
10
  </t>
11
11
  </template>
12
+
12
13
  <template id="account_financial_report.report_open_items_base">
13
14
  <!-- Saved flag fields into variables, used to define columns display -->
14
15
  <t t-set="foreign_currency" t-value="foreign_currency" />
@@ -28,51 +29,87 @@
28
29
  style="text-align: center;"
29
30
  />
30
31
  </div>
31
- <!-- Display filters -->
32
- <t t-call="account_financial_report.report_open_items_filters" />
33
- <t t-foreach="Open_Items.keys()" t-as="account_id">
34
- <!-- Display account header -->
35
- <div class="act_as_table list_table" style="margin-top: 10px;" />
36
- <div class="account_title" style="width: 100%;">
37
- <span t-esc="accounts_data[account_id]['code']" />
38
- -
39
- <span t-esc="accounts_data[account_id]['name']" />
40
- </div>
41
- <t t-if="not show_partner_details">
42
- <div class="act_as_table data_table" style="width: 100%;">
43
- <t
44
- t-call="account_financial_report.report_open_items_lines_header"
45
- />
46
- <!-- Display account move lines -->
47
- <t t-foreach="Open_Items[account_id]" t-as="line">
48
- <t
49
- t-call="account_financial_report.report_open_items_lines"
50
- />
51
- </t>
32
+ <t t-if="grouped_by == 'salesperson' and show_partner_details">
33
+ <t t-foreach="partners_data.keys()" t-as="partner_id">
34
+ <t t-call="account_financial_report.report_open_items_filters" />
35
+ <div class="act_as_caption account_title">
36
+ <span t-esc="partners_data[partner_id]['name']" />
52
37
  </div>
53
- </t>
54
- <t t-if="show_partner_details">
55
- <div class="page_break">
56
- <!-- Display account partners -->
57
- <t t-foreach="Open_Items[account_id]" t-as="partner_id">
58
- <div class="act_as_caption account_title">
59
- <span t-esc="partners_data[partner_id]['name']" />
38
+ <t t-foreach="Open_Items.keys()" t-as="account_id">
39
+ <t t-if="partner_id in Open_Items[account_id]">
40
+ <div
41
+ class="act_as_table list_table"
42
+ style="margin-top: 10px;"
43
+ />
44
+ <div class="account_title" style="width: 100%;">
45
+ <span t-esc="accounts_data[account_id]['code']" />
46
+ -
47
+ <span t-esc="accounts_data[account_id]['name']" />
60
48
  </div>
61
- <div class="act_as_table data_table" style="width: 100%;">
62
- <!-- Display partner header -->
49
+
50
+ <t t-if="Open_Items[account_id]">
63
51
  <t
64
- t-call="account_financial_report.report_open_items_lines_header"
52
+ t-set="partner_totals"
53
+ t-value="o._calculate_amounts_by_partner(account_id,Open_Items[account_id][partner_id])"
65
54
  />
66
- <!-- Display partner move lines -->
67
55
  <t
68
- t-foreach="Open_Items[account_id][partner_id]"
69
- t-as="line"
56
+ t-foreach="partner_totals.get(account_id, {})"
57
+ t-as="partner_id_key"
70
58
  >
71
- <t
72
- t-call="account_financial_report.report_open_items_lines"
73
- />
59
+ <t t-set="has_lines" t-value="False" />
60
+ <div
61
+ class="act_as_table data_table"
62
+ style="width: 100%;"
63
+ >
64
+ <t
65
+ t-foreach="Open_Items[account_id][partner_id]"
66
+ t-as="line"
67
+ >
68
+ <t
69
+ t-if="line['partner_id'] == partner_id_key"
70
+ >
71
+ <t t-set="has_lines" t-value="True" />
72
+ </t>
73
+ </t>
74
+ <t t-if="has_lines">
75
+ <!-- Display partner header -->
76
+ <t
77
+ t-call="account_financial_report.report_open_items_lines_header"
78
+ />
79
+ </t>
80
+ <t
81
+ t-foreach="Open_Items[account_id][partner_id]"
82
+ t-as="line"
83
+ >
84
+ <t
85
+ t-if="line['partner_id'] == partner_id_key"
86
+ >
87
+ <!-- Display partner move lines -->
88
+ <t
89
+ t-call="account_financial_report.report_open_items_lines"
90
+ />
91
+ </t>
92
+ </t>
93
+ </div>
94
+ <!-- Check if there were any lines displayed for the partner -->
95
+ <t t-if="has_lines">
96
+ <!-- Calculate and display subtotal for current partner_id -->
97
+ <t
98
+ t-call="account_financial_report.report_open_items_ending_cumul"
99
+ >
100
+ <t
101
+ t-set="currency_id"
102
+ t-value="accounts_data[account_id]['currency_name']"
103
+ />
104
+ <t
105
+ t-set="type"
106
+ t-value="'partner_subtotal_type'"
107
+ />
108
+ </t>
109
+ </t>
74
110
  </t>
75
- </div>
111
+ </t>
112
+ <!-- Display account footer -->
76
113
  <t
77
114
  t-call="account_financial_report.report_open_items_ending_cumul"
78
115
  >
@@ -87,23 +124,92 @@
87
124
  <t t-set="type" t-value='"partner_type"' />
88
125
  </t>
89
126
  </t>
90
- </div>
127
+ </t>
128
+ <div style="page-break-after: always;" />
91
129
  </t>
92
- <!-- Display account footer -->
93
- <t t-call="account_financial_report.report_open_items_ending_cumul">
94
- <t
95
- t-set="account_or_partner_id"
96
- t-value="accounts_data[account_id]"
97
- />
98
- <t
99
- t-set="currency_id"
100
- t-value="accounts_data[account_id]['currency_name']"
101
- />
102
- <t t-set="type" t-value='"account_type"' />
130
+ </t>
131
+ <t t-else="">
132
+ <!-- Display filters -->
133
+ <t t-call="account_financial_report.report_open_items_filters" />
134
+ <t t-foreach="Open_Items.keys()" t-as="account_id">
135
+ <!-- Display account header -->
136
+ <div class="act_as_table list_table" style="margin-top: 10px;" />
137
+ <div class="account_title" style="width: 100%;">
138
+ <span t-esc="accounts_data[account_id]['code']" />
139
+ -
140
+ <span t-esc="accounts_data[account_id]['name']" />
141
+ </div>
142
+ <t t-if="not show_partner_details">
143
+ <div class="act_as_table data_table" style="width: 100%;">
144
+ <t
145
+ t-call="account_financial_report.report_open_items_lines_header"
146
+ />
147
+ <!-- Display account move lines -->
148
+ <t t-foreach="Open_Items[account_id]" t-as="line">
149
+ <t
150
+ t-call="account_financial_report.report_open_items_lines"
151
+ />
152
+ </t>
153
+ </div>
154
+ </t>
155
+ <t t-if="show_partner_details">
156
+ <div class="page_break">
157
+ <!-- Display account partners -->
158
+ <t t-foreach="Open_Items[account_id]" t-as="partner_id">
159
+ <div class="act_as_caption account_title">
160
+ <span t-esc="partners_data[partner_id]['name']" />
161
+ </div>
162
+ <div
163
+ class="act_as_table data_table"
164
+ style="width: 100%;"
165
+ >
166
+ <!-- Display partner header -->
167
+ <t
168
+ t-call="account_financial_report.report_open_items_lines_header"
169
+ />
170
+ <!-- Display partner move lines -->
171
+ <t
172
+ t-foreach="Open_Items[account_id][partner_id]"
173
+ t-as="line"
174
+ >
175
+ <t
176
+ t-call="account_financial_report.report_open_items_lines"
177
+ />
178
+ </t>
179
+ </div>
180
+ <t
181
+ t-call="account_financial_report.report_open_items_ending_cumul"
182
+ >
183
+ <t
184
+ t-set="account_or_partner_id"
185
+ t-value="partners_data[partner_id]"
186
+ />
187
+ <t
188
+ t-set="currency_id"
189
+ t-value="accounts_data[account_id]['currency_name']"
190
+ />
191
+ <t t-set="type" t-value='"partner_type"' />
192
+ </t>
193
+ </t>
194
+ </div>
195
+ </t>
196
+ <!-- Display account footer -->
197
+ <t t-call="account_financial_report.report_open_items_ending_cumul">
198
+ <t
199
+ t-set="account_or_partner_id"
200
+ t-value="accounts_data[account_id]"
201
+ />
202
+ <t
203
+ t-set="currency_id"
204
+ t-value="accounts_data[account_id]['currency_name']"
205
+ />
206
+ <t t-set="type" t-value='"account_type"' />
207
+ </t>
103
208
  </t>
104
209
  </t>
105
210
  </div>
106
211
  </template>
212
+
107
213
  <template id="account_financial_report.report_open_items_filters">
108
214
  <div class="act_as_table data_table" style="width: 100%;">
109
215
  <div class="act_as_row labels">
@@ -294,6 +400,20 @@
294
400
  Partner ending balance
295
401
  </div>
296
402
  </t>
403
+ <t t-if='type == "partner_subtotal_type"'>
404
+ <div class="act_as_cell first_column" style="width: 36.34%;" />
405
+ <t
406
+ t-set="partner"
407
+ t-value="env['res.partner'].browse(partner_id_key)"
408
+ />
409
+ <t t-if="partner">
410
+ <span t-esc="partner.name" />
411
+ </t>
412
+ <div class="act_as_cell right" style="width: 28.66%;">
413
+ Ending
414
+ balance
415
+ </div>
416
+ </t>
297
417
  <!--## date_due-->
298
418
  <div class="act_as_cell" style="width: 6.47%;" />
299
419
  <!--## amount_total_due-->
@@ -312,6 +432,12 @@
312
432
  t-options="{'widget': 'monetary', 'display_currency': res_company.currency_id}"
313
433
  />
314
434
  </t>
435
+ <t t-if='type == "partner_subtotal_type"'>
436
+ <span
437
+ t-esc="partner_totals[account_id][partner_id_key]['residual']"
438
+ t-options="{'widget': 'monetary', 'display_currency': res_company.currency_id}"
439
+ />
440
+ </t>
315
441
  </div>
316
442
  <!--## amount_total_due_currency + amount_residual_currency -->
317
443
  <t t-if="foreign_currency">
@@ -372,7 +372,7 @@ ul.auto-toc {
372
372
  !! This file is generated by oca-gen-addon-readme !!
373
373
  !! changes will be overwritten. !!
374
374
  !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
375
- !! source digest: sha256:4c8dd71b140619ff57e872835ca14c50beb3ddda9bde30205ce9456304884adb
375
+ !! source digest: sha256:ecc9aa27354484eb81b4932dca2dd1cda89b3be41d684259fb8826b9098b61cf
376
376
  !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->
377
377
  <p><a class="reference external image-reference" href="https://odoo-community.org/page/development-status"><img alt="Beta" src="https://img.shields.io/badge/maturity-Beta-yellow.png" /></a> <a class="reference external image-reference" href="http://www.gnu.org/licenses/agpl-3.0-standalone.html"><img alt="License: AGPL-3" src="https://img.shields.io/badge/license-AGPL--3-blue.png" /></a> <a class="reference external image-reference" href="https://github.com/OCA/account-financial-reporting/tree/18.0/account_financial_report"><img alt="OCA/account-financial-reporting" src="https://img.shields.io/badge/github-OCA%2Faccount--financial--reporting-lightgray.png?logo=github" /></a> <a class="reference external image-reference" href="https://translation.odoo-community.org/projects/account-financial-reporting-18-0/account-financial-reporting-18-0-account_financial_report"><img alt="Translate me on Weblate" src="https://img.shields.io/badge/weblate-Translate%20me-F47D42.png" /></a> <a class="reference external image-reference" href="https://runboat.odoo-community.org/builds?repo=OCA/account-financial-reporting&amp;target_branch=18.0"><img alt="Try me on Runboat" src="https://img.shields.io/badge/runboat-Try%20me-875A7B.png" /></a></p>
378
378
  <p>This module adds a set of financial reports. They are accessible under