pedrambiria ae28f02912 [FIX] point_of_sale: wrong fixed taxes sign for zero amount products
Before this commit: If a fixed tax is used for a product with the price
of zero, the tax line sign would be positive and lead to an unbalanced
move. The solution is to use its sign in its context for correct
calculation.
Also, in the PoS front-end, when you want to return a zero amount
product with a fixed tax, its sign would be positive, which is
incorrect.

Steps to reproduce the first issue:

	- Install 'Point of Sale' module
	- Create a new 'Tax' X with a fixed price (e.g.: 1 $)
	- Create a new 'Product' with zero Sales Price
	- Create a PoS session
	- Add the product to the order
	- Close the session

	It creates a line for the "Difference at closing PoS session," and
doesn't prevent closing. But the problem is that the tax capture as
debit is incorrect. The tax for the invoice must be credit.

Steps to reproduce the second issue:

	- Install 'Point of Sale' module
	- Create a new 'Tax' X with a fixed price (e.g.: 1 $)
	- Create a new 'Product' with zero Sales Price
	- Create a PoS session
	- Add the product to the order
	- Change the quantity to -1 (refund)

	The final amount is positive, while it should be negative.

Solution

	The sign must be sent in the context, and for the PoS front-end, it
should consider zero amount cases.

opw-2833590

closes odoo/odoo#95067

X-original-commit: c5fb4f778db95fb33845b9a5e0c2190d4d9037ee
Signed-off-by: Masereel Pierre <pim@odoo.com>
Signed-off-by: Joseph Caburnay (jcb) <jcb@odoo.com>
2022-07-01 17:48:08 +02:00
2022-06-30 18:52:28 +02:00
…
…
…
2022-01-14 15:44:52 +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%