Skip to Content
Menu
This question has been flagged
1 Reply
4152 Views

Hello all,

I'm working with report creation in Odoo 10 and find it interesting that reusing child account lines is not promoted when creating new reports through the UI.  I was wondering if someone in the community might have some insight into the decision to customize reports by creating new versions of some of the same lines rather than referencing the lines if they already exist.

For example, to create a Working Capital Report, maybe I'd set up something like this:

WORKING CAPITAL (balance = WC_CA.balance - WC_CL.balance)
    CURRENT ASSETS (WC_CA) # compute value with child lines or domain expression
    CURRENT LIABILITIES (WC_CL) # compute with child lines or domain expression

Where WC_CA and WC_CL are new child lines that I create by hand or duplicating.

Meanwhile, the Balance Sheet Report that ships with Odoo assumes this hierarchy for the first two levels:

BALANCE SHEET
    ASSETS (TA)
        Current Assets (CA)
        Plus Fixed Assets (FA)
        Plus Non Current Assets (PNCA)
    LIABILITIES (L)
        Current Liabilities (CL)
        Plus Non Current Liabilities (NL)
    EQUITY (EQ)
        CURRENT YEAR EARNINGS (UNAFFECTED_EARNINGS)
        RETAINED EARNINGS (RETAINED_EARNINGS)

In this example, it seems like it could be easier and potentially less error prone to re-use Current Assets and Current Liabilities from the Balance Sheet, rather than recompute these lines and their child lines again.

Any insights would be welcomed, 

Zach


Avatar
Discard
Author Best Answer

Upon further investigation, it seems that I can re-use lines from other reports. To do this, you must open the reference report, drill down to the formula for computing the line, copy the formula, return to the new report and paste it into the new line formula. Or, instead of copying the formula, you can reference directly once you've identified the code you're looking for. The best way to do this is probably to export all of the reports and child lines to a spreadsheet and use that to figure out the code. In my example above, I might have Current Assets for the Working Capital report have this formula:

WC_CA = CA.balance

So, it  seems that you can re-use report lines, it's just a few more clicks than I thought at first. Hope this helps someone else.

Avatar
Discard
Related Posts Replies Views Activity
2
May 24
455
5
Mar 24
2273
0
Aug 23
422
0
Jul 23
1478
1
Jun 23
1333