Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0031788Openbravo ERP03. Procurement managementpublic2015-12-28 19:132016-03-17 10:54
VictorVillar 
AtulOpenbravo 
urgentmajoralways
closedfixed 
5
pi 
 
vmromanos
Core
No
0031788: In a Purchase Order window the Price turns to 0 using a price list including taxes under some circumstancies
In a Purchase Order window the Price turns to 0 using a price list including taxes under some circumstancies
As group Admin role,
  Go to Price List window:
     to define Tarifa Bebidas Alegres as Price Includes Taxes
Go to Discounts and Promotions window
  create a new one.
  Organization: España - Región norte
  Discount Type: Price Adjustment
  Starting date: 12/01/2016
  Ending date: 12/01/2017
 All 'included ....' fields as: All excluding defined
 except 'Included Products' = Only those defined.
Discount %: 0
Discount Amount: 0.00
Fixed Unit price: 73
Min. Quantity: 10
Max. Quantity: blank
Prodcuts tab:
  Add Agua Sin gas.

Go to Purchase Order
   select Bebidas Alegres
   Check that the Price List is: Tarifa Bebidas Alegres
Click in Create Lines button.
   Add Cerveza Ale 0.5L, selecting the qty. Price = 19
Process the Purchase order.
Realise that the Price turns to 0.
No tags attached.
related to defect 0035428 closed aferraz Do not calculate Net Price and Net Amount outside triggers when creating new Order/Invoice with Price Including Taxes 
Issue History
2015-12-28 19:13VictorVillarNew Issue
2015-12-28 19:13VictorVillarAssigned To => Triage Finance
2015-12-28 19:13VictorVillarModules => Core
2015-12-28 19:13VictorVillarResolution time => 1451516400
2015-12-28 19:13VictorVillarRegression level => Pre packaging ( pi )
2015-12-28 19:13VictorVillarTriggers an Emergency Pack => No
2015-12-28 19:18VictorVillarIssue Monitored: networkb
2015-12-29 07:51AtulOpenbravoAssigned ToTriage Finance => AtulOpenbravo
2015-12-29 09:00AtulOpenbravoAssigned ToAtulOpenbravo => VictorVillar
2015-12-29 09:01AtulOpenbravoNote Added: 0083031
2015-12-29 09:01AtulOpenbravoStatusnew => feedback
2016-01-14 18:49VictorVillarResolution time1451516400 => 1454540400
2016-01-14 18:49VictorVillarRegression levelPre packaging ( pi ) =>
2016-01-14 18:49VictorVillarAssigned ToVictorVillar => AtulOpenbravo
2016-01-14 18:49VictorVillarPriorityimmediate => urgent
2016-01-14 18:49VictorVillarStatusfeedback => new
2016-01-14 18:49VictorVillarSteps to Reproduce Updatedbug_revision_view_page.php?rev_id=10636#r10636
2016-01-18 19:03AtulOpenbravoStatusnew => scheduled
2016-01-18 19:30AtulOpenbravoNote Added: 0083387
2016-01-19 12:32psanjuanNote Edited: 0083387bug_revision_view_page.php?bugnote_id=0083387#r10689
2016-01-19 12:32psanjuanNote Added: 0083396
2016-01-19 13:31psanjuanNote Edited: 0083387bug_revision_view_page.php?bugnote_id=0083387#r10690
2016-01-19 13:32psanjuanNote Edited: 0083387bug_revision_view_page.php?bugnote_id=0083387#r10691
2016-01-19 13:36psanjuanNote Edited: 0083387bug_revision_view_page.php?bugnote_id=0083387#r10692
2016-01-19 13:37psanjuanNote Edited: 0083396bug_revision_view_page.php?bugnote_id=0083396#r10694
2016-01-19 17:52hgbotCheckin
2016-01-19 17:52hgbotNote Added: 0083416
2016-01-19 17:52hgbotStatusscheduled => resolved
2016-01-19 17:52hgbotResolutionopen => fixed
2016-01-19 17:52hgbotFixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/31fa39bf2c6a862e933e31b50be93c8b092b5e2e [^]
2016-01-19 17:52vmromanosReview Assigned To => vmromanos
2016-01-19 17:52vmromanosNote Added: 0083417
2016-01-19 17:52vmromanosStatusresolved => closed
2016-03-17 10:54hudsonbotCheckin
2016-03-17 10:54hudsonbotNote Added: 0085056
2017-03-07 10:51aferrazRelationship addedrelated to 0035428

Notes
(0083031)
AtulOpenbravo   
2015-12-29 09:01   
Not able to reproduce with given steps. Need some more exact steps if any.
(0083387)
AtulOpenbravo   
2016-01-18 19:30   
(edited on: 2016-01-19 13:36)
Test Plan
- Login as Group Admin role.
- Go to Price List window:
  to define Tarifa Bebidas Alegres as Price Includes Taxes
- Go to Discounts and Promotions window
  create a new one.
  - Organization: España - Región norte
  - Discount Type: Price Adjustment
  - Starting date: 12/01/2016
  - Ending date: 12/01/2017
  - All 'included ....' fields as: All excluding defined
    except 'Included Products' = Only those defined.
  - Discount %: 0
  - Discount Amount: 0.00
  - Fixed Unit price: 73
  - Min. Quantity: 10
  - Max. Quantity: blank
- In Prodcuts tab:
  - Add Agua Sin gas.

- Go to Purchase Order. select Bebidas Alegres as business partner.
- Check that the Price List is: Tarifa Bebidas Alegres
- Click in Create Lines button.
  - Select Cerveza Ale 0.5L product, enter qty = 1, change the price to 19
- Check that the Price is 15.70 and not zero.
- Book the order.

Repeat same steps above with other products by changing or not the price. Check that the price is the correct one after deducting the corresponding taxes.

Check also that in the case of creating a purchase order for Agua sin Gas 1L product, if the ordered quantity is 20 (>10 units) net unit price changes to 60.33 (that is net unit price fixed to 73.00 deducing 21% VAT)

(0083396)
psanjuan   
2016-01-19 12:32   
(edited on: 2016-01-19 13:37)
Issue Verified.

Test Plan above verified. Issue can be code reviewed and close.

(0083416)
hgbot   
2016-01-19 17:52   
Repository: erp/devel/pi
Changeset: 31fa39bf2c6a862e933e31b50be93c8b092b5e2e
Author: Atul Gaware <atul.gaware <at> openbravo.com>
Date: Mon Jan 18 23:55:32 2016 +0530
URL: http://code.openbravo.com/erp/devel/pi/rev/31fa39bf2c6a862e933e31b50be93c8b092b5e2e [^]

Fixes Issue 31788:In a Purchase Order window the Price turns to 0 using a
price list including taxes under some circumstancies

In case of Tax included Price List, Create PO Lines action handler now sets
Gross Standard Price = Gross Base Unit Price with proper value so that
during m_promotion_calculate if there exists any price adjustments, price
needs to be re-calculated in the order line. Earlier as gross std price was
set to zero, Gross Unit Price, Line Gross Amount of the line was set to 0..

---
M src/org/openbravo/common/actionhandler/OrderCreatePOLines.java
---
(0083417)
vmromanos   
2016-01-19 17:52   
Code review + testing OK
(0085056)
hudsonbot   
2016-03-17 10:54   
A changeset related to this issue has been promoted main and to the
Central Repository, after passing a series of tests.

Promotion changeset: https://code.openbravo.com/erp/devel/main/rev/b22fb0500156 [^]
Maturity status: Test