Skip to content

Conversation

@matho-odoo
Copy link

@matho-odoo matho-odoo commented Dec 1, 2025

Description:

prevent the override of existing pivots through ADD_PIVOT. command

Task: 5360591

review checklist

  • feature is organized in plugin, or UI components
  • support of duplicate sheet (deep copy)
  • in model/core: ranges are Range object, and can be adapted (adaptRanges)
  • in model/UI: ranges are strings (to show the user)
  • undo-able commands (uses this.history.update)
  • multiuser-able commands (has inverse commands and transformations where needed)
  • new/updated/removed commands are documented
  • exportable in excel
  • translations (_t("qmsdf %s", abc))
  • unit tested
  • clean commented code
  • track breaking changes
  • doc is rebuild (npm run doc)
  • status is correct in Odoo

@robodoo
Copy link
Collaborator

robodoo commented Dec 1, 2025

Pull request status dashboard

Spec :
Currently, one could dispatch the command ADD_PIVOT by specifying a pivotId which corresponds to an already existing pivot. This is quite error prone as it could lead to a situation where we erase an existing PIVOT by mistake. 
The goal is to prevent this kind of situation by adding a check in the allowDispatch of the core plugin Pivot which should reject the command ADD_PIVOT if it targets an already exisitng pivot (similarly to the check done for the command INSERT_PIVOT).

Task: 5360591
@matho-odoo matho-odoo force-pushed the master-allowdispatch-addpivot-matho branch from bd26a99 to a08d406 Compare December 4, 2025 08:10
Copy link
Collaborator

@pro-odoo pro-odoo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

robodoo r+

robodoo pushed a commit that referenced this pull request Dec 4, 2025
Spec :
Currently, one could dispatch the command ADD_PIVOT by specifying a pivotId which corresponds to an already existing pivot. This is quite error prone as it could lead to a situation where we erase an existing PIVOT by mistake. 
The goal is to prevent this kind of situation by adding a check in the allowDispatch of the core plugin Pivot which should reject the command ADD_PIVOT if it targets an already exisitng pivot (similarly to the check done for the command INSERT_PIVOT).

closes #7573

Task: 5360591
Signed-off-by: Pierre Rousseau (pro) <[email protected]>
@robodoo robodoo added the 19.1 label Dec 4, 2025
@robodoo robodoo closed this Dec 4, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants