Commit Graph
32 Commits
Author SHA1 Message Date
Cédric Krier ebed93c61a Define index using COALESCE for nullable Char fields
Closes #14909
(grafted from 525198c97acdd19820d581411b3af0f5bb6e4237)

--HG--
branch : 8.0
2026-07-14 21:14:05 +02:00
Nicolas Évrard 502e2d5ecb Create a hook to compute the reverse tax and amount from the tax type
Closes #14681
2026-03-16 15:54:38 +01:00
Cédric Krier 70701c14e4 Add depends on methods of TaxableMixin 2026-01-17 12:54:09 +01:00
Cédric Krier f8b3b9ce3a Replace starting/ending date by start/end date
These are the most frequent terms used.
2025-12-08 10:29:42 +01:00
Cédric Krier 73b5bd429f Do not delete on cascade parts of a chart of account
Closes #14399
2025-11-27 15:12:45 +01:00
Cédric Krier c8f3df9390 Do not restrict deleting template of chart of account
Closes #14398
2025-11-27 15:10:27 +01:00
Cédric Krier 6ebc55a14e Add missing depends on currency to the TaxableMixin._round_taxes method
Closes #14348
2025-11-04 10:28:04 +01:00
Cédric Krier b0f7d45254 Manage readonly wizard
readonly wizards do not check for write access on the active model.

Closes #13989
2025-04-29 09:31:05 +02:00
Cédric Krier a4a655b05e Use explicit key when computing taxes and object instead of dict
This defines explicitly the available attribute and unify the use the values as
tax line instead of the keys.
2025-05-30 21:35:55 +02:00
Cédric Krier cc8901276e Round only the tax amount of the line when rounding per line
If we round the tax amount already added to the other line, the result may vary
depending on the order of the lines.
This is because round half even is used so the result may depend on the already
summed tax amounts.

Closes #14047
2025-05-30 18:10:27 +02:00
Cédric Krier 275248478a Ensure the contextual company is not None and positive before using it
Closes #13868
2025-03-10 23:43:49 +01:00
Cédric Krier 5aeff66acd Use ModelStorage hooks instead of extending create/write/delete 2025-04-06 00:14:17 +02:00
Nicolas Évrard cbdad75620 Remove old-style of super() calls 2025-04-04 00:45:18 +02:00
Cédric Krier eda1f8e7de Merge tax line with the same key but computed separately
Closes #13777
2024-12-24 14:54:47 +01:00
Cédric Krier c833195650 Set default integer digits to None 2024-11-25 23:47:12 +01:00
Cédric Krier d86eeeb5c5 Retrieve tax rounding configuration using the company of the taxable
Closes #13688
2024-11-15 18:06:45 +01:00
Cédric Krier e9104be1ee Round together only taxable lines with the same taxes and sign
The rounding error must not be distributed between taxable lines having
different taxes otherwise the tax amount is not stable for the same base
amount.

Closes #13673
2024-11-12 17:39:42 +01:00
Udo Spallek 8b252472c4 Replace usage of docstring of Model by __string__ attribute
Closes #8402
2024-11-19 10:09:52 +01:00
Cédric Krier 2612aced12 Fix missing target field in operand of domain 2024-11-01 09:00:07 +01:00
Cédric Krier e5658ccf92 Fix missing target field in operand of domain 2024-10-30 11:24:15 +01:00
Cédric Krier aafa890c5c Add depends on periods when changing company of tax code context
Since fa8f759f834b there is an assert to ensure that changing values of
xxx2Many can be done only if the field had a initial value.

Closes #13535
2024-09-30 17:22:37 +02:00
Nicolas Évrard 6907ea5b7b Add warning when using implicit rec_name target for relational domain 2024-09-07 00:39:55 +02:00
Cédric Krier 5823bce6cf Add tools to apply types to SQLite select queries 2024-07-04 08:45:19 +02:00
Cédric Krier 06270e6a7a Use decimal 0 without digits as default value
If the digits of the field is 0, than using '0.0' trigger the validation error
introduced by 2be02f249a1d.

Closes #13197
2024-04-30 19:15:44 +02:00
Cédric Krier cee75c14a1 Do not distribute residual rounding to tax with 0 amount
Closes #13098
2024-03-15 13:16:33 +01:00
Cédric Krier 10a5cb783e Return list of instance as result of test tax wizard
Since 0db956eb2505 the on_change_with for xxx2Many must return a list of
instances.

Closes #12852
2023-12-23 01:47:24 +01:00
Cédric Krier c6335a368c Update trees of chart of accounts with 2 passes
When a new parent is added to a tree template like types, taxes or tax codes,
the corresponding record of the new template parent is not yet created.
So we need to use a default value for the parent and update again the tree
after creating the new records.

Closes #12755
2023-11-16 16:32:43 +01:00
Cédric Krier b9c4b8230d Return instance in on_change_with methods 2023-03-26 09:49:00 +02:00
Cédric Krier 641cb7c9a4 Always raise exception when fiscal year or period are not found 2023-03-09 00:28:11 +01:00
Cédric Krier 45bbfa8fb5 Add cache to account period find and return instance
Closes #7705
2023-02-10 23:36:18 +01:00
Nicolas Évrard 2da82e2b94 Accrue and allocate rounding errors when there are multiple taxes
Closes #11317
2022-12-25 18:55:17 +01:00
Cédric Krier fb14b53030 Prepare migration to monorepo 2022-12-16 21:09:21 +01:00