Commit Graph
108 Commits
Author SHA1 Message Date
Cédric Krier 6a06579e13 Use Sphinx book theme for documentation 2023-09-01 09:44:09 +02:00
Cédric Krier 14bc5d2a6c Use selection widget for journal fields
It is expected to have only a small number of journals.
But also it is uncommon to create of a new journal from a form.
So it provides a better user experience to use a selection widget.
2023-08-06 00:34:16 +02:00
Cédric Krier 91fb1e7c24 Use OR-ed domain when composing clauses from exclusive join
When a searcher of a Function field compose a domain using mutually exclusive
joins, the boolean operator must always be OR because only one clause is not
NULL.

Closes #12291
2023-08-02 20:35:13 +02:00
Cédric Krier adc26533da Add .readthedocs.yaml configuration [skip ci]
This is required by Read the Docs service:
https://blog.readthedocs.com/migrate-configuration-v2/

Closes #12344
2023-08-06 11:06:08 +02:00
Cédric Krier 2be6515fa6 Start remainder with all lines for amount to pay invoice
This is the worst case before finding a better one with a lower remainder.

Closes #12403
2023-07-15 01:05:48 +02:00
Cédric Krier 852741ae54 Set overpayment by default when amount is greater than the amount to pay 2023-07-14 12:02:49 +02:00
Cédric Krier 03e0455e75 Do not allow overpayment of invoice when write-off amount is negative
When paying less than the amount to pay, there is no overpayment.
2023-07-14 12:01:05 +02:00
Cédric Krier c3da634f9f Require lines when paying invoice with write-off or overpayment
This is needed ensure that at least one line to pay of the invoice is
reconciled.
The lines and payment lines are also shown for overpayment.

Closes #12403
2023-07-14 11:59:19 +02:00
Cédric Krier 9f9620445d Align on bottom amount and state of invoice form 2023-07-15 16:13:28 +02:00
Cédric Krier e16444665f Rename close state to closed 2023-06-20 10:13:56 +02:00
Cédric Krier d9865ab943 Simplify tax identifier types of invoice
We do not need to be able to customize it for only the invoice so it can be
customized on party.
2023-06-27 15:06:34 +02:00
Cédric Krier d9e9df28c2 Limit type to tax identifier for party tax identifier of invoice
Closes #12356
2023-06-27 15:00:59 +02:00
Cédric Krier 1353212f31 Hide taxes deductible rate for invoice lines without the type line 2023-06-28 12:25:54 +02:00
Sergi Almacellas Abellana 614cff956d Allow modification of invoice references when report is not cached 2023-06-22 16:11:33 +00:00
Nicolas Évrard 91ed1cddc1 Use indexes and cache to make search on amounts faster
This optimization relies on the idea that few invoices should stay in the
states where the amount cache fields are empty. It splits the search query in
two parts: one on the cached fields, the other on the computation with the
invoice lines (and tax lines when it applies).

Closes #11919
2023-05-27 09:53:47 +02:00
Nicolas Évrard d894c1f442 Add cache on invoice's amounts
Having cache on the invoice's amounts will allow to make search more efficient
for #11919
2023-05-25 16:21:49 +02:00
Cédric Krier ccfb3bd8d5 Add more fields to payment lines of invoice
The same fields than for the receivable/payable line are used.
2023-05-26 18:07:04 +02:00
Cédric Krier c053327018 Show reconciliation lines of invoice also when cancelled
When the invoice is refund with a credit note, it is cancelled instead of paid
so the reconciliation lines from the credit note are not displayed as payment
lines.
So we should display them in this case.
2023-05-17 17:25:03 +02:00
Cédric Krier fc8e2016e7 Compute amount of invoice line tax when changing tax or base
Using on_change_with does not work correctly for editable field because the
value may be changed when the user does not expect it.

Closes #8618
2023-05-17 18:24:40 +02:00
Cédric Krier b0590200db Set invoice journal only when type is changed
Using on_change_with does not work correctly for editable field because the
value may be changed when the user does not expect it.
2023-04-29 12:57:57 +02:00
Cédric Krier f2838915d4 Set invoice account only when changing party or dates
Using on_change_with does not work correctly for editable field because the
value may be changed when the user does not expect it.

Closes #12239
2023-04-29 12:56:51 +02:00
Cédric Krier 5335a2022d Convert sum attribute into boolean 2023-05-06 14:25:22 +02:00
Cédric Krier 84d83120c5 Add receivable/payable to company 2023-04-07 18:24:09 +02:00
Adrià Tarroja Caubet 960c220329 Remove migrations previous to 5.0
Closes #11324
2023-01-19 11:25:25 +01:00
Cédric Krier 1a11e103bf Increase version number 2023-05-01 14:11:22 +02:00
Cédric Krier 1901135502 Prepare release 6.8.0 2023-05-01 13:19:11 +02:00
Cédric Krier 84a2b5e271 Update translations 2023-04-29 10:07:40 +02:00
Cédric Krier a84cb9f07c Do not change account nor journal of invoice no more draft
Closes #12146
2023-04-08 16:36:38 +02:00
Cédric Krier 51b7fe72f8 Support invoice payment with currency exchange
Closes #11500
2023-02-16 18:59:06 +01:00
Cédric Krier dc979ed50b Hide pay button on invoice if there is no payment method
Closes #12160
2023-03-24 13:21:42 +01:00
Cédric Krier b9c4b8230d Return instance in on_change_with methods 2023-03-26 09:49:00 +02:00
Cédric Krier c32affdc9a Use generic relate from party to invoice
Also for relate from party, it gives more information to the user to display
the number of pending and done.
2023-02-19 16:49:12 +01:00
Cédric Krier ba701d5a38 Remove invalid fields from default copy 2023-03-15 16:11:51 +01:00
Cédric Krier 4b8d1ccbab Reset next number of invoice sequences when renew fiscal year 2023-03-15 09:53:02 +01:00
Cédric Krier b049293df0 Do not search on party when searching invoice record name
The party is not part of the record name so for consistency it should not be
searched.
2023-02-16 09:58:20 +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
Cédric Krier 5cc5a8f672 Update tox.ini to set py311 and remove py37 2023-03-03 00:17:18 +01:00
Cédric Krier f429332d97 Use right boolean operator in composite domain of searcher
When the clause is negative, it must return an AND-ed domain instead of OR-ed.
2023-02-16 10:39:30 +01:00
Nicolas Évrard 039761e061 Remove support for Python 3.7 2023-01-29 20:36:51 +01:00
Nicolas Évrard 777ee10f27 Add support for Python 3.11 2023-01-27 11:02:47 +01:00
Maxime Richez 10466a9936 Prevent deletion of payment terms in use
Closes #12085
2023-02-21 12:55:12 +01:00
Cédric Krier 88aa08904c Replace same account check by domain between invoice, lines and taxes
Closes #7641
2023-02-10 16:06:23 +01:00
Cédric Krier e0182d9ecb Do not allow to create line or tax on invoice not in draft
Adding new line or tax should also be forbidden for validated state.
2023-01-26 15:01:10 +01:00
Sergi Almacellas Abellana 33aa8bad09 Limit tax kind of invoice tax based on invoice type 2023-01-27 11:55:05 +01:00
Nicolas Évrard 0d679effe2 Warn when cancelling a move related to an invoice
Closes #4981
2023-02-02 18:50:26 +01:00
Cédric Krier 68753ff402 Run action from button with proteus 2023-01-17 14:39:18 +01:00
Cédric Krier cad8cad4ef Do not convert into float search amount of invoice if it is None 2023-01-12 11:36:01 +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
Cédric Krier 2b786d8c44 Add coverage reports 2023-01-08 11:18:56 +01:00
Cédric Krier 62e8201d5a Add unit test reports 2023-01-08 01:55:20 +01:00