Commit Graph
25 Commits
Author SHA1 Message Date
Cédric Krier 6d7daac2a8 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
(grafted from e1e376f91bc1e111cdef39ddcbbfd92d201ea6c9)

--HG--
branch : 7.0
2025-05-30 18:10:27 +02:00
Cédric Krier 32ca3ceab6 Merge tax line with the same key but computed separately
Closes #13777
(grafted from 0a04ac7cc66be0e4afad66f71746ed34ca5f13b7)

--HG--
branch : 7.0
2024-12-24 14:54:47 +01:00
Cédric Krier 6e030c62ee 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
(grafted from 09294cc144f08088547eee0b5f47f36e5ad61926)

--HG--
branch : 7.0
2024-11-12 17:39:42 +01:00
Cédric Krier b7adb7ba77 Sort posted lines to reconcile at last by party
The lines may or may not have a party depending on the account.
So the order key must avoid compare party instance with None value.

Closes #13268
(grafted from 97e730164485c038de7744ea0a3fb189fd7426fa)

--HG--
branch : 7.0
2024-05-21 10:12:46 +02:00
Cédric Krier c2091befaa 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
(grafted from 979cd092ea24f04328af5f4ff315c418e1c5b3e6)

--HG--
branch : 7.0
2024-04-30 19:15:44 +02:00
Cédric Krier 544ce5494b Set default value from account move using line field name
Some Function fields has the move as prefix which is removed when applied to
the move. But when setting default value for the line, the move prefix must
not be removed.

Closes #12967
(grafted from bce77308e529f2e96c46da2296546f047af48161)

--HG--
branch : 7.0
2024-04-27 18:36:49 +02:00
Cédric Krier 3b29353565 Do not fail on leap day to create next fiscal year
Replace the year of a date is not safe, it is better to use relativedelta.

Closes #13064
(grafted from 4b19fb0bc801a784139c0c6245d8649480e13280)

--HG--
branch : 7.0
2024-02-29 15:36:16 +01:00
Cédric Krier 701670f0e3 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
(grafted from 561f9c7dbdc2a2c39c1fe5f6bf7274d01ee9ebd6)

--HG--
branch : 7.0
2023-11-16 16:32:43 +01:00
Cédric Krier e64dbbefa9 Test account reconcile scenario without party required 2023-10-11 18:35:03 +02:00
Cédric Krier 590fbe3aa8 Use origin description as fallback description for account move and line
Closes #12571
2023-09-16 10:30:44 +02:00
Cédric Krier 5ce06c7d69 Post write-off and exchange moves when reconcile posted lines
Closes #12439
2023-07-29 15:10:59 +02:00
Cédric Krier e16444665f Rename close state to closed 2023-06-20 10:13:56 +02:00
Christophe Crier 8b52a5b6ac Ask for date when creating account move from template
Closes #8725
2023-06-21 21:57:18 +02:00
Cédric Krier 84d83120c5 Add receivable/payable to company 2023-04-07 18:24:09 +02:00
Cédric Krier 5092923d0d Support reconcile lines with currency exchange 2023-04-05 17:46:53 +02:00
Cédric Krier c48e7b36c6 Add reconcile and unreconcile from general ledger lines
Closes #7360
2023-03-13 23:52:18 +01:00
Cédric Krier 9c85f825f9 Add and remove empty lines in scenario 2023-03-13 23:52:02 +01:00
Nicolas Évrard ab020a78e8 Reconcile the zero lines after saving moves 2023-01-23 17:05:55 +01:00
Cédric Krier cb59e11ad4 Add reversal option when cancelling move
Closes #5180
2023-01-27 01:06:15 +01:00
Cédric Krier b48e4966d5 Add functions and attribute to handle check access and active records
Closes #11863
2022-12-30 13:56:10 +01:00
Sergi Almacellas Abellana 0287507f85 Update parent and replaced_by when template has no taxes
Closes #11891
2023-01-09 14:34:21 +01:00
Cédric Krier 4683fde7ac Make scenario independent of the current day
The fiscal years are created centered on the passed date such that if the
current day change during the execution, the fiscal year is still usable.
Also fiscal year can be created for a range of dates such that it is guarantee
that the dates are in the fiscal year.
And finally remove datetime and dateutil import when they are not used.

Closes #9977
2023-01-01 10:36:03 +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 f36318178e Do not use closed account in test tools
Closes #11932
2022-12-24 17:49:47 +01:00
Cédric Krier fb14b53030 Prepare migration to monorepo 2022-12-16 21:09:21 +01:00