Adrien Widart d4eeb23397 [FIX] account: list all credit note methods
When adding a credit note, the user can only select the "Partial
Refund" credit method.

To reproduce the error:
1. Go to Invoicing
2. Create a new one
	- Add at least one invoice line
3. Save, Confirm
4. Click on "Add Credit Note"

=> You can not change the credit method.

The method field is editable only when the residual amount is different
from 0. Here is the issue: when clicking on "Add Credit Note", it
actually triggers some `onchange` methods. The latter uses a new record
to compute the values:
https://github.com/odoo/odoo/blob/45422d56bce413b8577f1784e10dd22ede93c751/odoo/models.py#L6147-L6148
Then, some `_compute` methods are also triggered. Among them, the amount
residual computation of the associated `account_move_line`. However,
`_compute_amount_residual` will skip the not-yet-created objects and set
the amount residual to 0. This is the reason why the residual amount of
the account move is zero and therefore, the user can't change the credit
method.

OPW-2418582

closes odoo/odoo#63780

X-original-commit: 13e33fdd9722a7022d56538ab69dda0200b3aaa2
Signed-off-by: Adrien Widart <adwid@users.noreply.github.com>
2020-12-24 13:47:21 +00:00
2020-12-21 10:24:18 +00:00
2020-04-20 11:41:39 +00:00
…
…
…
…
2019-11-08 11:24:04 +00:00
2020-09-28 14:07:25 +00:00

Build Status Tech Doc Help Nightly Builds

Odoo

Odoo is a suite of web based open source business apps.

The main Odoo Apps include an Open Source CRM, Website Builder, eCommerce, Warehouse Management, Project Management, Billing & Accounting, Point of Sale, Human Resources, Marketing, Manufacturing, ...

Odoo Apps can be used as stand-alone applications, but they also integrate seamlessly so you get a full-featured Open Source ERP when you install several Apps.

Getting started with Odoo

For a standard installation please follow the Setup instructions from the documentation.

To learn the software, we recommend the Odoo eLearning, or Scale-up, the business game. Developers can start with the developer tutorials

S
Description
No description provided
Readme LGPL-3.0
3.4 GiB
Languages
Python 49.6%
JavaScript 47.8%
SCSS 2%
CSS 0.3%
HTML 0.2%