odoo-addon-account-financial-report 16.0.1.3.2__py3-none-any.whl → 16.0.1.3.4__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.
- odoo/addons/account_financial_report/__manifest__.py +2 -5
- odoo/addons/account_financial_report/report/general_ledger.py +2 -1
- odoo/addons/account_financial_report/report/templates/general_ledger.xml +4 -4
- odoo/addons/account_financial_report/report/templates/journal_ledger.xml +2 -2
- odoo/addons/account_financial_report/report/templates/open_items.xml +3 -3
- odoo/addons/account_financial_report/report/templates/trial_balance.xml +27 -27
- odoo/addons/account_financial_report/report/templates/vat_report.xml +9 -9
- odoo/addons/account_financial_report/static/src/js/report.esm.js +73 -0
- odoo/addons/account_financial_report/static/src/js/report_action.esm.js +2 -0
- {odoo_addon_account_financial_report-16.0.1.3.2.dist-info → odoo_addon_account_financial_report-16.0.1.3.4.dist-info}/METADATA +1 -1
- {odoo_addon_account_financial_report-16.0.1.3.2.dist-info → odoo_addon_account_financial_report-16.0.1.3.4.dist-info}/RECORD +13 -13
- odoo/addons/account_financial_report/static/src/js/report.js +0 -58
- {odoo_addon_account_financial_report-16.0.1.3.2.dist-info → odoo_addon_account_financial_report-16.0.1.3.4.dist-info}/WHEEL +0 -0
- {odoo_addon_account_financial_report-16.0.1.3.2.dist-info → odoo_addon_account_financial_report-16.0.1.3.4.dist-info}/top_level.txt +0 -0
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
|
|
7
7
|
{
|
|
8
8
|
"name": "Account Financial Reports",
|
|
9
|
-
"version": "16.0.1.3.
|
|
9
|
+
"version": "16.0.1.3.4",
|
|
10
10
|
"category": "Reporting",
|
|
11
11
|
"summary": "OCA Financial Reports",
|
|
12
12
|
"author": "Camptocamp SA,"
|
|
@@ -43,12 +43,9 @@
|
|
|
43
43
|
],
|
|
44
44
|
"assets": {
|
|
45
45
|
"web.assets_backend": [
|
|
46
|
-
"account_financial_report/static/src/js
|
|
46
|
+
"account_financial_report/static/src/js/*",
|
|
47
47
|
"account_financial_report/static/src/xml/**/*",
|
|
48
48
|
],
|
|
49
|
-
"web.report_assets_common": [
|
|
50
|
-
"account_financial_report/static/src/js/report.js",
|
|
51
|
-
],
|
|
52
49
|
},
|
|
53
50
|
"installable": True,
|
|
54
51
|
"application": True,
|
|
@@ -312,7 +312,7 @@ class GeneralLedgerReport(models.AbstractModel):
|
|
|
312
312
|
move_line_data = {
|
|
313
313
|
"id": move_line["id"],
|
|
314
314
|
"date": move_line["date"],
|
|
315
|
-
"entry": move_line["
|
|
315
|
+
"entry": move_line["move_name"],
|
|
316
316
|
"entry_id": move_line["move_id"][0],
|
|
317
317
|
"journal_id": move_line["journal_id"][0],
|
|
318
318
|
"account_id": move_line["account_id"][0],
|
|
@@ -873,4 +873,5 @@ class GeneralLedgerReport(models.AbstractModel):
|
|
|
873
873
|
"amount_currency",
|
|
874
874
|
"balance",
|
|
875
875
|
"tax_ids",
|
|
876
|
+
"move_name",
|
|
876
877
|
]
|
|
@@ -325,7 +325,7 @@
|
|
|
325
325
|
res-model="account.move.line"
|
|
326
326
|
>
|
|
327
327
|
<t
|
|
328
|
-
t-
|
|
328
|
+
t-out="account_or_group_item_object['init_bal']['bal_curr']"
|
|
329
329
|
t-options="{'widget': 'monetary', 'display_currency': account['currency_id']}"
|
|
330
330
|
/>
|
|
331
331
|
</span>
|
|
@@ -338,7 +338,7 @@
|
|
|
338
338
|
res-model="account.move.line"
|
|
339
339
|
>
|
|
340
340
|
<t
|
|
341
|
-
t-
|
|
341
|
+
t-out="account_or_group_item_object['init_bal']['bal_curr']"
|
|
342
342
|
t-options="{'widget': 'monetary', 'display_currency': account['currency_id']}"
|
|
343
343
|
/>
|
|
344
344
|
</span>
|
|
@@ -724,7 +724,7 @@
|
|
|
724
724
|
style="color: black;"
|
|
725
725
|
>
|
|
726
726
|
<t
|
|
727
|
-
t-
|
|
727
|
+
t-out="account_or_group_item_object['fin_bal']['bal_curr']"
|
|
728
728
|
t-options="{'widget': 'monetary', 'display_currency': account['currency_id']}"
|
|
729
729
|
/>
|
|
730
730
|
</a>
|
|
@@ -741,7 +741,7 @@
|
|
|
741
741
|
style="color: black;"
|
|
742
742
|
>
|
|
743
743
|
<t
|
|
744
|
-
t-
|
|
744
|
+
t-out="account_or_group_item_object['fin_bal']['bal_curr']"
|
|
745
745
|
t-options="{'widget': 'monetary', 'display_currency': account['currency_id']}"
|
|
746
746
|
/>
|
|
747
747
|
</a>
|
|
@@ -17,9 +17,9 @@
|
|
|
17
17
|
<t t-set="display_account_name" t-value="with_account_name" />
|
|
18
18
|
<t t-set="title">
|
|
19
19
|
Journal Ledger -
|
|
20
|
-
<t t-
|
|
20
|
+
<t t-out="company_name" />
|
|
21
21
|
-
|
|
22
|
-
<t t-
|
|
22
|
+
<t t-out="currency_name" />
|
|
23
23
|
</t>
|
|
24
24
|
<t t-set="company_name" t-value="Company_Name" />
|
|
25
25
|
<div class="page">
|
|
@@ -15,9 +15,9 @@
|
|
|
15
15
|
<!-- Defines global variables used by internal layout -->
|
|
16
16
|
<t t-set="title">
|
|
17
17
|
Open Items -
|
|
18
|
-
<t t-
|
|
18
|
+
<t t-out="company_name" />
|
|
19
19
|
-
|
|
20
|
-
<t t-
|
|
20
|
+
<t t-out="currency_name" />
|
|
21
21
|
</t>
|
|
22
22
|
<t t-set="company_name" t-value="Company_Name" />
|
|
23
23
|
<div class="page">
|
|
@@ -174,7 +174,7 @@
|
|
|
174
174
|
<div class="act_as_row lines">
|
|
175
175
|
<!--## date-->
|
|
176
176
|
<div class="act_as_cell left">
|
|
177
|
-
<span t-
|
|
177
|
+
<span t-out="line['date'].strftime('%d/%m/%Y')" />
|
|
178
178
|
</div>
|
|
179
179
|
<!--## move-->
|
|
180
180
|
<div class="act_as_cell left">
|
|
@@ -18,9 +18,9 @@
|
|
|
18
18
|
<!-- Defines global variables used by internal layout -->
|
|
19
19
|
<t t-set="title">
|
|
20
20
|
Trial Balance -
|
|
21
|
-
<t t-
|
|
21
|
+
<t t-out="company_name" />
|
|
22
22
|
-
|
|
23
|
-
<t t-
|
|
23
|
+
<t t-out="currency_name" />
|
|
24
24
|
</t>
|
|
25
25
|
<t t-set="company_name" t-value="Company_Name" />
|
|
26
26
|
<!-- <t t-set="res_company" t-value="company_id"/>-->
|
|
@@ -92,8 +92,8 @@
|
|
|
92
92
|
view-type="form"
|
|
93
93
|
>
|
|
94
94
|
<t
|
|
95
|
-
t-
|
|
96
|
-
/> - <t t-
|
|
95
|
+
t-out="accounts_data[account_id]['code']"
|
|
96
|
+
/> - <t t-out="accounts_data[account_id]['name']" />
|
|
97
97
|
</span>
|
|
98
98
|
</div>
|
|
99
99
|
<div class="act_as_table data_table" style="width: 100%;">
|
|
@@ -242,7 +242,7 @@
|
|
|
242
242
|
res-model="account.group"
|
|
243
243
|
view-type="form"
|
|
244
244
|
>
|
|
245
|
-
<t t-
|
|
245
|
+
<t t-out="balance['code']" />
|
|
246
246
|
</span>
|
|
247
247
|
</div>
|
|
248
248
|
<div class="act_as_cell left" t-att-style="style">
|
|
@@ -299,7 +299,7 @@
|
|
|
299
299
|
res-model="account.move.line"
|
|
300
300
|
>
|
|
301
301
|
<t
|
|
302
|
-
t-
|
|
302
|
+
t-out="balance['initial_balance']"
|
|
303
303
|
t-options="{'widget': 'monetary', 'display_currency': res_company.currency_id}"
|
|
304
304
|
/>
|
|
305
305
|
</span>
|
|
@@ -317,7 +317,7 @@
|
|
|
317
317
|
res-model="account.move.line"
|
|
318
318
|
>
|
|
319
319
|
<t
|
|
320
|
-
t-
|
|
320
|
+
t-out="total_amount[account_id][partner_id]['initial_balance']"
|
|
321
321
|
t-options="{'widget': 'monetary', 'display_currency': res_company.currency_id}"
|
|
322
322
|
/>
|
|
323
323
|
</span>
|
|
@@ -357,7 +357,7 @@
|
|
|
357
357
|
res-model="account.move.line"
|
|
358
358
|
>
|
|
359
359
|
<t
|
|
360
|
-
t-
|
|
360
|
+
t-out="balance['debit']"
|
|
361
361
|
t-options="{'widget': 'monetary', 'display_currency': res_company.currency_id}"
|
|
362
362
|
/>
|
|
363
363
|
</span>
|
|
@@ -377,7 +377,7 @@
|
|
|
377
377
|
res-model="account.move.line"
|
|
378
378
|
>
|
|
379
379
|
<t
|
|
380
|
-
t-
|
|
380
|
+
t-out="total_amount[account_id][partner_id]['debit']"
|
|
381
381
|
t-options="{'widget': 'monetary', 'display_currency': res_company.currency_id}"
|
|
382
382
|
/>
|
|
383
383
|
</span>
|
|
@@ -417,7 +417,7 @@
|
|
|
417
417
|
res-model="account.move.line"
|
|
418
418
|
>
|
|
419
419
|
<t
|
|
420
|
-
t-
|
|
420
|
+
t-out="balance['credit']"
|
|
421
421
|
t-options="{'widget': 'monetary', 'display_currency': res_company.currency_id}"
|
|
422
422
|
/>
|
|
423
423
|
</span>
|
|
@@ -437,7 +437,7 @@
|
|
|
437
437
|
res-model="account.move.line"
|
|
438
438
|
>
|
|
439
439
|
<t
|
|
440
|
-
t-
|
|
440
|
+
t-out="total_amount[account_id][partner_id]['credit']"
|
|
441
441
|
t-options="{'widget': 'monetary', 'display_currency': res_company.currency_id}"
|
|
442
442
|
/>
|
|
443
443
|
</span>
|
|
@@ -476,7 +476,7 @@
|
|
|
476
476
|
res-model="account.move.line"
|
|
477
477
|
>
|
|
478
478
|
<t
|
|
479
|
-
t-
|
|
479
|
+
t-out="balance['balance']"
|
|
480
480
|
t-options="{'widget': 'monetary', 'display_currency': res_company.currency_id}"
|
|
481
481
|
/>
|
|
482
482
|
</span>
|
|
@@ -496,7 +496,7 @@
|
|
|
496
496
|
res-model="account.move.line"
|
|
497
497
|
>
|
|
498
498
|
<t
|
|
499
|
-
t-
|
|
499
|
+
t-out="total_amount[account_id][partner_id]['balance']"
|
|
500
500
|
t-options="{'widget': 'monetary', 'display_currency': res_company.currency_id}"
|
|
501
501
|
/>
|
|
502
502
|
</span>
|
|
@@ -531,7 +531,7 @@
|
|
|
531
531
|
res-model="account.move.line"
|
|
532
532
|
>
|
|
533
533
|
<t
|
|
534
|
-
t-
|
|
534
|
+
t-out="balance['ending_balance']"
|
|
535
535
|
t-options="{'widget': 'monetary', 'display_currency': res_company.currency_id}"
|
|
536
536
|
/>
|
|
537
537
|
</span>
|
|
@@ -582,7 +582,7 @@
|
|
|
582
582
|
<!-- t-att-data-res-model="'account.move.line'"-->
|
|
583
583
|
<!-- class="o_account_financial_reports_web_action_monetary_multi"-->
|
|
584
584
|
<!-- t-att-style="style">-->
|
|
585
|
-
<!-- <t t-att-style="style" t-
|
|
585
|
+
<!-- <t t-att-style="style" t-out="line.initial_balance_foreign_currency" t-options="{'widget': 'monetary', 'display_currency': line.currency_id}"/></a>-->
|
|
586
586
|
<!-- </span>-->
|
|
587
587
|
<!-- </t>-->
|
|
588
588
|
</div>
|
|
@@ -603,7 +603,7 @@
|
|
|
603
603
|
res-model="account.move.line"
|
|
604
604
|
>
|
|
605
605
|
<t
|
|
606
|
-
t-
|
|
606
|
+
t-out="total_amount[account_id][partner_id]['initial_currency_balance']"
|
|
607
607
|
t-options="{'widget': 'monetary', 'display_currency': total_amount[account_id]['currency_id']}"
|
|
608
608
|
/>
|
|
609
609
|
</span>
|
|
@@ -625,7 +625,7 @@
|
|
|
625
625
|
res-model="account.move.line"
|
|
626
626
|
>
|
|
627
627
|
<t
|
|
628
|
-
t-
|
|
628
|
+
t-out="balance['ending_currency_balance']"
|
|
629
629
|
t-options="{'widget': 'monetary', 'display_currency': balance['currency_id']}"
|
|
630
630
|
/>
|
|
631
631
|
</span>
|
|
@@ -637,7 +637,7 @@
|
|
|
637
637
|
<!-- t-att-data-res-model="'account.move.line'"-->
|
|
638
638
|
<!-- class="o_account_financial_reports_web_action_monetary_multi"-->
|
|
639
639
|
<!-- t-att-style="style">-->
|
|
640
|
-
<!-- <t t-att-style="style" t-
|
|
640
|
+
<!-- <t t-att-style="style" t-out="line.final_balance_foreign_currency" t-options="{'widget': 'monetary', 'display_currency': line.currency_id}"/></a>-->
|
|
641
641
|
<!-- </span>-->
|
|
642
642
|
<!-- </t>-->
|
|
643
643
|
</div>
|
|
@@ -658,7 +658,7 @@
|
|
|
658
658
|
res-model="account.move.line"
|
|
659
659
|
>
|
|
660
660
|
<t
|
|
661
|
-
t-
|
|
661
|
+
t-out="total_amount[account_id][partner_id]['ending_currency_balance']"
|
|
662
662
|
t-options="{'widget': 'monetary', 'display_currency': total_amount[account_id]['currency_id']}"
|
|
663
663
|
/>
|
|
664
664
|
</span>
|
|
@@ -702,7 +702,7 @@
|
|
|
702
702
|
<!-- t-att-data-res-model="res_model"-->
|
|
703
703
|
<!-- class="o_account_financial_reports_web_action"-->
|
|
704
704
|
<!-- t-att-style="style">-->
|
|
705
|
-
<!-- <t t-att-style="style" t-
|
|
705
|
+
<!-- <t t-att-style="style" t-out="account.code"/> - <t t-att-style="style" t-out="account.name"/></a>-->
|
|
706
706
|
<!-- </span>-->
|
|
707
707
|
<!-- </div>-->
|
|
708
708
|
<!-- <!–## Initial balance–>-->
|
|
@@ -715,7 +715,7 @@
|
|
|
715
715
|
<!-- t-att-data-res-model="'account.move.line'"-->
|
|
716
716
|
<!-- class="o_account_financial_reports_web_action_monetary_multi"-->
|
|
717
717
|
<!-- t-att-style="style">-->
|
|
718
|
-
<!-- <t t-att-style="style" t-
|
|
718
|
+
<!-- <t t-att-style="style" t-out="account.initial_balance" t-options="{'widget': 'monetary', 'display_currency': res_company.currency_id}"/></a>-->
|
|
719
719
|
<!-- </span>-->
|
|
720
720
|
<!-- </div>-->
|
|
721
721
|
<!-- <!–## Debit–>-->
|
|
@@ -730,7 +730,7 @@
|
|
|
730
730
|
<!-- t-att-data-res-model="'account.move.line'"-->
|
|
731
731
|
<!-- class="o_account_financial_reports_web_action_monetary_multi"-->
|
|
732
732
|
<!-- t-att-style="style">-->
|
|
733
|
-
<!-- <t t-att-style="style" t-
|
|
733
|
+
<!-- <t t-att-style="style" t-out="account.debit" t-options="{'widget': 'monetary', 'display_currency': res_company.currency_id}"/></a>-->
|
|
734
734
|
<!-- </span>-->
|
|
735
735
|
<!-- </div>-->
|
|
736
736
|
<!-- <!–## Credit–>-->
|
|
@@ -745,7 +745,7 @@
|
|
|
745
745
|
<!-- t-att-data-res-model="'account.move.line'"-->
|
|
746
746
|
<!-- class="o_account_financial_reports_web_action_monetary_multi"-->
|
|
747
747
|
<!-- t-att-style="style">-->
|
|
748
|
-
<!-- <t t-att-style="style" t-
|
|
748
|
+
<!-- <t t-att-style="style" t-out="account.credit" t-options="{'widget': 'monetary', 'display_currency': res_company.currency_id}"/></a>-->
|
|
749
749
|
<!-- </span>-->
|
|
750
750
|
<!-- </div>-->
|
|
751
751
|
<!-- <!–## Period Balance –>-->
|
|
@@ -760,7 +760,7 @@
|
|
|
760
760
|
<!-- t-att-data-res-model="'account.move.line'"-->
|
|
761
761
|
<!-- class="o_account_financial_reports_web_action_monetary_multi"-->
|
|
762
762
|
<!-- t-att-style="style">-->
|
|
763
|
-
<!-- <t t-att-style="style" t-
|
|
763
|
+
<!-- <t t-att-style="style" t-out="account.period_balance" t-options="{'widget': 'monetary', 'display_currency': res_company.currency_id}"/></a>-->
|
|
764
764
|
<!-- </span>-->
|
|
765
765
|
<!-- </div>-->
|
|
766
766
|
<!-- <!–## Ending balance–>-->
|
|
@@ -772,7 +772,7 @@
|
|
|
772
772
|
<!-- t-att-data-res-model="'account.move.line'"-->
|
|
773
773
|
<!-- class="o_account_financial_reports_web_action_monetary_multi"-->
|
|
774
774
|
<!-- t-att-style="style" >-->
|
|
775
|
-
<!-- <t t-att-style="style" t-
|
|
775
|
+
<!-- <t t-att-style="style" t-out="account.final_balance" t-options="{'widget': 'monetary', 'display_currency': res_company.currency_id}"/></a>-->
|
|
776
776
|
<!-- </span>-->
|
|
777
777
|
<!-- </div>-->
|
|
778
778
|
<!-- <t t-if="foreign_currency">-->
|
|
@@ -793,7 +793,7 @@
|
|
|
793
793
|
<!-- t-att-data-res-model="'account.move.line'"-->
|
|
794
794
|
<!-- class="o_account_financial_reports_web_action_monetary_multi"-->
|
|
795
795
|
<!-- t-att-style="style">-->
|
|
796
|
-
<!-- <t t-att-style="style" t-
|
|
796
|
+
<!-- <t t-att-style="style" t-out="account.initial_balance_foreign_currency" t-options="{'widget': 'monetary', 'display_currency': account.account_id.currency_id}"/></a>-->
|
|
797
797
|
<!-- </span>-->
|
|
798
798
|
<!-- </div>-->
|
|
799
799
|
<!-- <div class="act_as_cell amount" style="width: 8.86%;">-->
|
|
@@ -804,7 +804,7 @@
|
|
|
804
804
|
<!-- t-att-data-res-model="'account.move.line'"-->
|
|
805
805
|
<!-- class="o_account_financial_reports_web_action_monetary_multi"-->
|
|
806
806
|
<!-- t-att-style="style" >-->
|
|
807
|
-
<!-- <t t-att-style="style" t-
|
|
807
|
+
<!-- <t t-att-style="style" t-out="account.final_balance_foreign_currency" t-options="{'widget': 'monetary', 'display_currency': account.account_id.currency_id}"/></a>-->
|
|
808
808
|
<!-- </span>-->
|
|
809
809
|
<!-- </div>-->
|
|
810
810
|
<!-- </t>-->
|
|
@@ -12,9 +12,9 @@
|
|
|
12
12
|
<template id="account_financial_report.report_vat_report_base">
|
|
13
13
|
<t t-set="title">
|
|
14
14
|
VAT Report -
|
|
15
|
-
<t t-
|
|
15
|
+
<t t-out="company_name" />
|
|
16
16
|
-
|
|
17
|
-
<t t-
|
|
17
|
+
<t t-out="currency_name" />
|
|
18
18
|
</t>
|
|
19
19
|
<t t-set="company_name" t-value="company_name" />
|
|
20
20
|
<div class="page">
|
|
@@ -55,7 +55,7 @@
|
|
|
55
55
|
t-att-res-model="res_model"
|
|
56
56
|
view-type="form"
|
|
57
57
|
>
|
|
58
|
-
<t t-att-style="style" t-
|
|
58
|
+
<t t-att-style="style" t-out="tag_or_group['code']" />
|
|
59
59
|
</span>
|
|
60
60
|
</div>
|
|
61
61
|
<div
|
|
@@ -67,20 +67,20 @@
|
|
|
67
67
|
t-att-res-model="res_model"
|
|
68
68
|
view-type="form"
|
|
69
69
|
>
|
|
70
|
-
<t t-att-style="style" t-
|
|
70
|
+
<t t-att-style="style" t-out="tag_or_group['name']" />
|
|
71
71
|
</span>
|
|
72
72
|
</div>
|
|
73
73
|
<div class="act_as_cell amount" style="width: 15%;">
|
|
74
74
|
<t
|
|
75
75
|
t-att-style="style"
|
|
76
|
-
t-
|
|
76
|
+
t-out="tag_or_group['net']"
|
|
77
77
|
t-options="{'widget': 'monetary', 'display_currency': res_company.currency_id}"
|
|
78
78
|
/>
|
|
79
79
|
</div>
|
|
80
80
|
<div class="act_as_cell amount" style="width: 15%;">
|
|
81
81
|
<t
|
|
82
82
|
t-att-style="style"
|
|
83
|
-
t-
|
|
83
|
+
t-out="tag_or_group['tax']"
|
|
84
84
|
t-options="{'widget': 'monetary', 'display_currency': res_company.currency_id}"
|
|
85
85
|
/>
|
|
86
86
|
</div>
|
|
@@ -98,7 +98,7 @@
|
|
|
98
98
|
t-att-res-model="res_model"
|
|
99
99
|
view-type="form"
|
|
100
100
|
>
|
|
101
|
-
<t t-att-style="style" t-
|
|
101
|
+
<t t-att-style="style" t-out="tax['name']" />
|
|
102
102
|
</span>
|
|
103
103
|
</div>
|
|
104
104
|
<div class="act_as_cell amount" style="width: 15%;">
|
|
@@ -114,7 +114,7 @@
|
|
|
114
114
|
>
|
|
115
115
|
<t
|
|
116
116
|
t-att-style="style"
|
|
117
|
-
t-
|
|
117
|
+
t-out="tax['net']"
|
|
118
118
|
t-options="{'widget': 'monetary', 'display_currency': res_company.currency_id}"
|
|
119
119
|
/>
|
|
120
120
|
</span>
|
|
@@ -132,7 +132,7 @@
|
|
|
132
132
|
>
|
|
133
133
|
<t
|
|
134
134
|
t-att-style="style"
|
|
135
|
-
t-
|
|
135
|
+
t-out="tax['tax']"
|
|
136
136
|
t-options="{'widget': 'monetary', 'display_currency': res_company.currency_id}"
|
|
137
137
|
/>
|
|
138
138
|
</span>
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
/** @odoo-module */
|
|
2
|
+
|
|
3
|
+
import {useComponent, useEffect} from "@odoo/owl";
|
|
4
|
+
|
|
5
|
+
function toTitleCase(str) {
|
|
6
|
+
return str
|
|
7
|
+
.replaceAll(".", " ")
|
|
8
|
+
.replace(
|
|
9
|
+
/\w\S*/g,
|
|
10
|
+
(txt) => `${txt.charAt(0).toUpperCase()}${txt.substr(1).toLowerCase()}`
|
|
11
|
+
);
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
function enrich(component, targetElement, selector, isIFrame = false) {
|
|
15
|
+
let doc = window.document;
|
|
16
|
+
let contentDocument = targetElement;
|
|
17
|
+
|
|
18
|
+
// If we are in an iframe, we need to take the right document
|
|
19
|
+
// both for the element and the doc
|
|
20
|
+
if (isIFrame) {
|
|
21
|
+
contentDocument = targetElement.contentDocument;
|
|
22
|
+
doc = contentDocument;
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
// If there are selector, we may have multiple blocks of code to enrich
|
|
26
|
+
const targets = [];
|
|
27
|
+
if (selector) {
|
|
28
|
+
targets.push(...contentDocument.querySelectorAll(selector));
|
|
29
|
+
} else {
|
|
30
|
+
targets.push(contentDocument);
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
// Search the elements with the selector, update them and bind an action.
|
|
34
|
+
for (const currentTarget of targets) {
|
|
35
|
+
const elementsToWrap = currentTarget.querySelectorAll("[res-model][domain]");
|
|
36
|
+
for (const element of elementsToWrap.values()) {
|
|
37
|
+
const wrapper = doc.createElement("a");
|
|
38
|
+
wrapper.setAttribute("href", "#");
|
|
39
|
+
wrapper.addEventListener("click", (ev) => {
|
|
40
|
+
ev.preventDefault();
|
|
41
|
+
component.env.services.action.doAction({
|
|
42
|
+
type: "ir.actions.act_window",
|
|
43
|
+
res_model: element.getAttribute("res-model"),
|
|
44
|
+
domain: element.getAttribute("domain"),
|
|
45
|
+
name: toTitleCase(element.getAttribute("res-model")),
|
|
46
|
+
views: [
|
|
47
|
+
[false, "list"],
|
|
48
|
+
[false, "form"],
|
|
49
|
+
],
|
|
50
|
+
});
|
|
51
|
+
});
|
|
52
|
+
element.parentNode.insertBefore(wrapper, element);
|
|
53
|
+
wrapper.appendChild(element);
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
export function useEnrichWithActionLinks(ref, selector = null) {
|
|
59
|
+
const comp = useComponent();
|
|
60
|
+
useEffect(
|
|
61
|
+
(element) => {
|
|
62
|
+
// If we get an iframe, we need to wait until everything is loaded
|
|
63
|
+
if (element.matches("iframe")) {
|
|
64
|
+
element.addEventListener("load", () =>
|
|
65
|
+
enrich(comp, element, selector, true)
|
|
66
|
+
);
|
|
67
|
+
} else {
|
|
68
|
+
enrich(comp, element, selector);
|
|
69
|
+
}
|
|
70
|
+
},
|
|
71
|
+
() => [ref.el]
|
|
72
|
+
);
|
|
73
|
+
}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
/** @odoo-module **/
|
|
2
2
|
import {ReportAction} from "@web/webclient/actions/reports/report_action";
|
|
3
3
|
import {patch} from "web.utils";
|
|
4
|
+
import {useEnrichWithActionLinks} from "./report.esm";
|
|
4
5
|
|
|
5
6
|
const MODULE_NAME = "account_financial_report";
|
|
6
7
|
|
|
@@ -10,6 +11,7 @@ patch(ReportAction.prototype, "account_financial_report.ReportAction", {
|
|
|
10
11
|
this.isAccountFinancialReport = this.props.report_name.startsWith(
|
|
11
12
|
`${MODULE_NAME}.`
|
|
12
13
|
);
|
|
14
|
+
useEnrichWithActionLinks(this.iframe);
|
|
13
15
|
},
|
|
14
16
|
|
|
15
17
|
export() {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: odoo-addon-account-financial-report
|
|
3
|
-
Version: 16.0.1.3.
|
|
3
|
+
Version: 16.0.1.3.4
|
|
4
4
|
Summary: OCA Financial Reports
|
|
5
5
|
Home-page: https://github.com/OCA/account-financial-reporting
|
|
6
6
|
Author: Camptocamp SA,initOS GmbH,redCOR AG,ForgeFlow,Odoo Community Association (OCA)
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
odoo/addons/account_financial_report/README.rst,sha256=OUoixTNZD7NlSufdSEggAXXL5e_9a0lUIuFIXci_NqU,5536
|
|
2
2
|
odoo/addons/account_financial_report/__init__.py,sha256=YoL8hk5QxSifbFJL7gPzpOSk-3zB1OSHJBXyZK25G6Q,187
|
|
3
|
-
odoo/addons/account_financial_report/__manifest__.py,sha256=
|
|
3
|
+
odoo/addons/account_financial_report/__manifest__.py,sha256=phFJ-uLa3KVuObCIbuw2l5VgWNu7OMC8M-oKJMhJCeE,1926
|
|
4
4
|
odoo/addons/account_financial_report/menuitems.xml,sha256=k20N6cNRlDsnPhc378MVs7jwzJhbbJQ2k-P3WdsmF_M,1206
|
|
5
5
|
odoo/addons/account_financial_report/reports.xml,sha256=c2KamS250rNzHUInjNwC0G2dhwiIqtYgbked51PtmVw,9254
|
|
6
6
|
odoo/addons/account_financial_report/i18n/account_financial_report.pot,sha256=Cjh1EiAacCAHkrSNMNGKavN8_DQ6D6wNQID1536mij8,77347
|
|
@@ -37,7 +37,7 @@ odoo/addons/account_financial_report/report/abstract_report.py,sha256=fyg8uk_FCr
|
|
|
37
37
|
odoo/addons/account_financial_report/report/abstract_report_xlsx.py,sha256=sDrhRI5Ko_QFaWGLZivCHpAhUSh7q_mTfP3LtxzpBLw,29697
|
|
38
38
|
odoo/addons/account_financial_report/report/aged_partner_balance.py,sha256=EcsLbWzZY1HEIA0LvezULg0mKC2HzQq9x8y6Unc6A4s,16271
|
|
39
39
|
odoo/addons/account_financial_report/report/aged_partner_balance_xlsx.py,sha256=pDtYtdoF8UVb0LJrM5cc0zSnwRnKa0O_AUqsSGZRZKk,12312
|
|
40
|
-
odoo/addons/account_financial_report/report/general_ledger.py,sha256=
|
|
40
|
+
odoo/addons/account_financial_report/report/general_ledger.py,sha256=C_Nk3VfYOlyI00mB5ejoKHpLiJGEJqMnZmDX7NlXEfo,34822
|
|
41
41
|
odoo/addons/account_financial_report/report/general_ledger_xlsx.py,sha256=d_dxB9N_xRoDECUY5cyILn-10nA7jmPay9sK3YtFC0Q,16224
|
|
42
42
|
odoo/addons/account_financial_report/report/journal_ledger.py,sha256=5_w9CmKy_eZNgJsSL1TFTTe5b3DBBEY1qmseI1RuGPI,15424
|
|
43
43
|
odoo/addons/account_financial_report/report/journal_ledger_xlsx.py,sha256=Pp7iDkBjSk0BqZkSPAiKI2hBHNcjKYjZoBxuL_ENz5E,10126
|
|
@@ -48,18 +48,18 @@ odoo/addons/account_financial_report/report/trial_balance_xlsx.py,sha256=phPDqy4
|
|
|
48
48
|
odoo/addons/account_financial_report/report/vat_report.py,sha256=H0k2uhDK_X3el1gVXA_lBUoj2dO1u104rjaWBcWLpnk,10131
|
|
49
49
|
odoo/addons/account_financial_report/report/vat_report_xlsx.py,sha256=aa0dLzYdywjmO63ONRYUBTpSGmsPfEjX60CkUbULuo8,2317
|
|
50
50
|
odoo/addons/account_financial_report/report/templates/aged_partner_balance.xml,sha256=S-434PFf2m_2Nt_bHNLxwRfw7WZ_6RIFPU90LPWhqvU,34728
|
|
51
|
-
odoo/addons/account_financial_report/report/templates/general_ledger.xml,sha256=
|
|
52
|
-
odoo/addons/account_financial_report/report/templates/journal_ledger.xml,sha256=
|
|
51
|
+
odoo/addons/account_financial_report/report/templates/general_ledger.xml,sha256=aE9nlj2jBGAKiEi8xJ2aZ6QrUrQZMHWDEJWi-_LBd3Y,38771
|
|
52
|
+
odoo/addons/account_financial_report/report/templates/journal_ledger.xml,sha256=HcM-2KxISeTbH1Xeer_pe__N6jQ90yzq5Zar419MCdU,21493
|
|
53
53
|
odoo/addons/account_financial_report/report/templates/layouts.xml,sha256=-IK2mtO4D6GqnOWUG_pToTlirdjd4v5r1UxaJuUpSTE,1181
|
|
54
|
-
odoo/addons/account_financial_report/report/templates/open_items.xml,sha256=
|
|
55
|
-
odoo/addons/account_financial_report/report/templates/trial_balance.xml,sha256=
|
|
56
|
-
odoo/addons/account_financial_report/report/templates/vat_report.xml,sha256=
|
|
54
|
+
odoo/addons/account_financial_report/report/templates/open_items.xml,sha256=k6rrHbDV8UHrfafH0VEDbB4GyBBn25YAh2p1e1io6gw,14813
|
|
55
|
+
odoo/addons/account_financial_report/report/templates/trial_balance.xml,sha256=kSQqE-w22a4swtR61D7i8xw6Mguzo-B-0n4kHavQs7Y,47147
|
|
56
|
+
odoo/addons/account_financial_report/report/templates/vat_report.xml,sha256=HRKoEUsj_GnG0Qz6rFMEUpYGapc2WmEJpt6pxIFtTAc,8107
|
|
57
57
|
odoo/addons/account_financial_report/security/ir.model.access.csv,sha256=To-PgtH3iQl6TcR9pRwvkSdG25S50xRjEIu4oyiBqrM,833
|
|
58
58
|
odoo/addons/account_financial_report/static/description/icon.png,sha256=WW-eOIjW5-jo7tgBieNv6K2DUKMoHFSVctnp0htstHI,15230
|
|
59
59
|
odoo/addons/account_financial_report/static/description/index.html,sha256=ZL0XeajnuEQgE2ah249KMdaIVPpEUzmKsLOZWFztvvw,17747
|
|
60
60
|
odoo/addons/account_financial_report/static/src/css/report.css,sha256=Cu4VmyY5tVXIddaojFDsg0Ute2qPCvKbLiimak_X9ik,2361
|
|
61
|
-
odoo/addons/account_financial_report/static/src/js/report.js,sha256=
|
|
62
|
-
odoo/addons/account_financial_report/static/src/js/report_action.esm.js,sha256=
|
|
61
|
+
odoo/addons/account_financial_report/static/src/js/report.esm.js,sha256=He488vLRaLv6IIuVaNSnNl8kJMIwJmMIv7GkmXyPJZs,2475
|
|
62
|
+
odoo/addons/account_financial_report/static/src/js/report_action.esm.js,sha256=eZkRVYzZIekvMJLO9maUDrTRpSZfz6VoXzsFcuGEXQ8,1212
|
|
63
63
|
odoo/addons/account_financial_report/static/src/xml/report.xml,sha256=m_YNhVgnMa3DmG0UyKhyJIWG1p1loLhGBbYQsx7QQUg,512
|
|
64
64
|
odoo/addons/account_financial_report/tests/__init__.py,sha256=Bkff-GzBDdNQ-EuHOd9SAIQAVC4uMKDl_JWwvkzRvOM,307
|
|
65
65
|
odoo/addons/account_financial_report/tests/test_aged_partner_balance.py,sha256=eheTOodIeq4Eagi_gwouW01jcbYC73ObZtrSKWmr7lg,1214
|
|
@@ -89,7 +89,7 @@ odoo/addons/account_financial_report/wizard/trial_balance_wizard.py,sha256=8Fjyw
|
|
|
89
89
|
odoo/addons/account_financial_report/wizard/trial_balance_wizard_view.xml,sha256=7oNGPs3s8DVw3movVGe2ryRUNl1MtN7O76UH8zaFFtI,7048
|
|
90
90
|
odoo/addons/account_financial_report/wizard/vat_report_wizard.py,sha256=pJATDNWLcEWvctby5e5yvv4Kz7YDfCTi7YZP7slA8a4,3424
|
|
91
91
|
odoo/addons/account_financial_report/wizard/vat_report_wizard_view.xml,sha256=T3P81O4csDGP7Jmf7eAtmbIIldja3IoXbBmweMMt8vA,2330
|
|
92
|
-
odoo_addon_account_financial_report-16.0.1.3.
|
|
93
|
-
odoo_addon_account_financial_report-16.0.1.3.
|
|
94
|
-
odoo_addon_account_financial_report-16.0.1.3.
|
|
95
|
-
odoo_addon_account_financial_report-16.0.1.3.
|
|
92
|
+
odoo_addon_account_financial_report-16.0.1.3.4.dist-info/METADATA,sha256=gNLHyLFhMOguZqmeOrlpQvqQrtOqVflFdwwciFtQTxs,6245
|
|
93
|
+
odoo_addon_account_financial_report-16.0.1.3.4.dist-info/WHEEL,sha256=2wepM1nk4DS4eFpYrW1TTqPcoGNfHhhO_i5m4cOimbo,92
|
|
94
|
+
odoo_addon_account_financial_report-16.0.1.3.4.dist-info/top_level.txt,sha256=qBj40grFkGOfDZ2WDSw3y1RnDlgG0u8rP8pvGNdbz4w,5
|
|
95
|
+
odoo_addon_account_financial_report-16.0.1.3.4.dist-info/RECORD,,
|
|
@@ -1,58 +0,0 @@
|
|
|
1
|
-
odoo.define("account_financial_report.report", function (require) {
|
|
2
|
-
"use strict";
|
|
3
|
-
|
|
4
|
-
require("web.dom_ready");
|
|
5
|
-
const utils = require("report.utils");
|
|
6
|
-
|
|
7
|
-
if (window.self === window.top) {
|
|
8
|
-
return;
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
const web_base_url = $("html").attr("web-base-url");
|
|
12
|
-
const trusted_host = utils.get_host_from_url(web_base_url);
|
|
13
|
-
const trusted_protocol = utils.get_protocol_from_url(web_base_url);
|
|
14
|
-
const trusted_origin = utils.build_origin(trusted_protocol, trusted_host);
|
|
15
|
-
|
|
16
|
-
/**
|
|
17
|
-
* Convert a model name to a capitalized title style
|
|
18
|
-
* Example: account.mode.line --> Account Move Line
|
|
19
|
-
*
|
|
20
|
-
* @param {String} str
|
|
21
|
-
* @returns {String}
|
|
22
|
-
*/
|
|
23
|
-
function toTitleCase(str) {
|
|
24
|
-
return str
|
|
25
|
-
.replaceAll(".", " ")
|
|
26
|
-
.replace(
|
|
27
|
-
/\w\S*/g,
|
|
28
|
-
(txt) => `${txt.charAt(0).toUpperCase()}${txt.substr(1).toLowerCase()}`
|
|
29
|
-
);
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
// Allow sending commands to the webclient
|
|
33
|
-
// `do_action` command with domain
|
|
34
|
-
$("[res-model][domain]")
|
|
35
|
-
.wrap("<a/>")
|
|
36
|
-
.attr("href", "#")
|
|
37
|
-
.on("click", function (ev) {
|
|
38
|
-
ev.preventDefault();
|
|
39
|
-
const res_model = $(this).attr("res-model");
|
|
40
|
-
const action = {
|
|
41
|
-
type: "ir.actions.act_window",
|
|
42
|
-
res_model: res_model,
|
|
43
|
-
domain: $(this).attr("domain"),
|
|
44
|
-
name: toTitleCase(res_model),
|
|
45
|
-
views: [
|
|
46
|
-
[false, "list"],
|
|
47
|
-
[false, "form"],
|
|
48
|
-
],
|
|
49
|
-
};
|
|
50
|
-
window.parent.postMessage(
|
|
51
|
-
{
|
|
52
|
-
message: "report:do_action",
|
|
53
|
-
action: action,
|
|
54
|
-
},
|
|
55
|
-
trusted_origin
|
|
56
|
-
);
|
|
57
|
-
});
|
|
58
|
-
});
|
|
File without changes
|