|View Issue Details|
|Type||Category||Severity||Reproducibility||Date Submitted||Last Update|
|backport||[Openbravo ERP] 02. Master data management||major||always||2016-09-27 17:30||2016-09-28 11:49|
|Priority||urgent||Resolution||fixed||Fixed in Version||3.0PR16Q3.2|
|Status||closed||Fix in branch||Fixed in SCM revision||4f62913933cd|
|OS Version||Database version||Ant version|
|Product Version||SCM revision|
|Review Assigned To||aferraz|
|Regression level||Production - QA Approved|
|Regression introduced in release||3.0PR16Q3|
|Regression introduced by commit||https://code.openbravo.com/erp/devel/pi/rev/168db990cb85 [^]|
|Triggers an Emergency Pack||No|
0034104: Incorrect prices are calculated in Purchase Orders/Invoices when exists discounts or promotions related to products.
|Description||When a Promotion or Discount is created for an specific product, and it is added to a purchase order/invoice prices for the product should not be recalculated as discounts and promotions not applies to Purchases, it applies only for the Sales flows. At moment of product selection, discounts are applied and when the purchase order/invoice is processed it is ignored. As it will be not applied, should be avoided recalculation of prices at product selection time.|
|Steps To Reproduce||As group admin role:|
1. Set the Price Precision of the Currency EUR to 2 if necessary
2. Create a new product
Search key/ Name: Test
3. Add two prices of 34.27 to it. For instance for Tarifa Bebidas Alegres and Tarifa de Ventas price lists versions.
4. Create a Price Adjustment for that product. Go to Discount and Promotions and add a new record:
Discount %: 64.3
Discount Amount: 0.00
Included Products: Only those defined
5. Add the new product in tab Products
6. Create a Purchase Order header for Bebidas Alegres, S.L bp.
7. Create a line to the purchase order:
Add the previously created product (Test) and check the Net Unit Price is updated to 12.34. IT IS NOT CORRECT
8. Set tax to Compras exentas, to not apply taxes.
9. Remove discounts from Basic Discounts if exists.
10. Book the order and check the following information is updated in header and line:
Purchase Order Line:
Net Unit Price is updated to 12.24
Purchase Order Header:
Total Gross Amount: 12.24
Total Net Amount: 12.24
IT IS NOT CORRECT because Discounts and Promotions only work for Sales flow and can not be applied.
In step 7, the price should not be updated because discounts are not applicable to purchases.
So, when the order is processed the correct values should be:
Purchase Order Line:
Net Unit Price is updated to 34.27
Purchase Order Header:
Total Gross Amount: 34.27
Total Net Amount: 34.27
Verify, this issue is also reproducible to Purchases Invoices.
|Tags||No tags attached.|
Author: Mark <markmm82 <at> gmail.com>
Date: Tue Sep 27 11:06:10 2016 -0400
URL: http://code.openbravo.com/erp/backports/3.0PR16Q3.2/rev/4f62913933cd5faf99fa2181231de93a657a5c13 [^]
Fixes issue 34104: No discounts are applied to product prices in Purchase flows
Price adjustments are not executed if is processing a Purchase Order/Invoice using a product with a promotion or discount, because this functionality should be only available for Sales flows.
|Code review + Testing OK|
|2016-09-27 17:31||markmm82||Type||defect => backport|
|2016-09-27 17:31||markmm82||Target Version||=> 3.0PR16Q3.3|
|2016-09-27 18:03||aferraz||Regression level||Production - Confirmed Stable => Production - QA Approved|
|2016-09-27 18:03||aferraz||Regression date||2016-06-17 => 2016-04-15|
|2016-09-27 18:03||aferraz||Regression introduced by commit||https://code.openbravo.com/erp/devel/main/rev/0dc7be081b1c [^] => https://code.openbravo.com/erp/devel/pi/rev/168db990cb85 [^]|
|2016-09-28 11:47||aferraz||Target Version||3.0PR16Q3.3 => 3.0PR16Q3.2|
|2016-09-28 11:47||hgbot||Note Added: 0090341|
|2016-09-28 11:47||hgbot||Status||scheduled => resolved|
|2016-09-28 11:47||hgbot||Resolution||open => fixed|
|2016-09-28 11:47||hgbot||Fixed in SCM revision||=> http://code.openbravo.com/erp/backports/3.0PR16Q3.2/rev/4f62913933cd5faf99fa2181231de93a657a5c13 [^]|
|2016-09-28 11:49||aferraz||Review Assigned To||=> aferraz|
|2016-09-28 11:49||aferraz||Note Added: 0090342|
|2016-09-28 11:49||aferraz||Status||resolved => closed|
|2016-09-28 11:49||aferraz||Fixed in Version||=> 3.0PR16Q3.2|
|Copyright © 2000 - 2009 MantisBT Group|