odoo / o-spreadsheet

Other
180 stars 39 forks source link

[FW][FIX] pivot: do not allow date dimension without granularity #4500

Closed fw-bot closed 1 month ago

fw-bot commented 1 month ago

When a date dimension is used in a pivot view, the granularity must be specified. Before this commit, it automatically defaulted to 'month_number'. With the experience of the odoo pivot, it's not a good idea to have a default granularity, as it's not easily migrable. In addition, supported a date dimension without granularity leads to lots of "if-else" in the code to handle this.

So, we prefer to avoid this situation and raise an error when a date dimension is used without a granularity.

Description:

description of this task, what is implemented and why it is implemented that way.

Task: : TASK_ID

review checklist

Forward-Port-Of: odoo/o-spreadsheet#4499

robodoo commented 1 month ago

Pull request status dashboard

fw-bot commented 1 month ago

@pro-odoo @LucasLefevre this PR targets master and is the last of the forward-port chain.

To merge the full chain, use

@robodoo r+

More info at https://github.com/odoo/odoo/wiki/Mergebot#forward-port

pro-odoo commented 1 month ago

robodoo r+