Commit fdaf42a
committed
[IMP] account_ux: prevent tax changes when used in accounting entries
Prevent changes to critical tax fields such as amount, amount type, and base configuration
once the tax has been used in accounting entries (account.move.line).
Modifying these fields after the tax has already been applied could lead to inconsistent
financial data or miscalculations. To ensure data integrity, a constraint was added to
block changes to the following fields:
- amount_type
- price_include_override
- include_base_amount
- is_base_affected
- amount
If the tax is found in any existing move line, a ValidationError is raised to prevent the update.
closes #734
Signed-off-by: Filoquin adhoc <maq@adhoc.com.ar>1 parent d9d6037 commit fdaf42a
2 files changed
Lines changed: 17 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
12 | 12 | | |
13 | 13 | | |
14 | 14 | | |
| 15 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
0 commit comments