Calculated attributes are everyone's go-to tool. They enrich your repositories with dynamic or specific data. When creating a calculated attribute, it seamlessly integrates into the repositories, appearing as if it had always been there.
But we know that all of you are already familiar with the capabilities of calculated attributes. In case you need more information, check here:
Now lets skip to the point,
Starting with version 23, calculated attributes now fully support inheritance.
This new feature enables you to create calculated attributes in a base repository, and they will automatically extend to all its sub-repositories.
Say goodbye to redundant work
With inheritance in place, your calculated attributes seamlessly cascade through the repository hierarchy.
Let's see it in action.
Consider your workflow requiring a caluclated attribute that references the actual currency directory for today. The catch is, you need this attribute accross various document repositories such as SalesOrders, TransfersOrders, PurchaseInvoices.
And you'll end up creating 3 separate calculated attributes with the same name, each containing the same expressions, just because you need them for 3 different of document repositories. E.g.,
This redundant task not only wastes time but also introduces the risk of inconsistencies if changes are needed in the future. Managing multiple attributes across various repositories can be tedious and error-prone.
But no more!
Thanks to inheritance, you only need to create the calculated attribute once, and it will be available everywhere you need it.
The example use-case from above is now made possible this way:
Or you have just one calculated attribute, defined in the base repository for all documents - General.Documents. This way it will be available for each document.
But... you'll say, what if I need this calculated attribute to have a different expression (i.e. result), but only for one specific document repository?
Here's where inheritance shines again:
Just create your new calculated attribute with the same name, defining its different behavior, but for the specific document repository you need.
This way the inherited one will be overridden, but only for the targeted document repository.
More information is available in our official documentation: