Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0013132Openbravo ERP07. Sales managementpublic2010-04-26 19:592010-05-18 21:43
networkb 
harikrishnan 
highminoralways
closedfixed 
5
2.40MP12 
2.40MP13 
Core
No
0013132: m_get_offer error when using "create lines from" process
If m_get_offer function returns more than one row and you run "Create lines from" process, only first offer will be applied.
1. Master Data Management || Pricing || Price Adjustments || Adjustments: create 2 adjustments

a)name=adj1
start date=01/04/2010
end date=30/04/2010
discount%=10
bp category=not selected
product category=not selected
pricelist=all selected (choose Sales pricelist)
product=not selected
bp=all selected (choose mcgiver)

b)name=adj2
start date=01/04/2010
end date=30/04/2010
discount%=15
bp category=not selected
product category=not selected
pricelist=all selected (choose Purchase pricelist)
product=all selected (choose boots)
bp=not selected

2. Master Data Management || Product || Product >> Price : set 3 prices of Boots in pricelist_version "Sales 2006" to 42.

2. Sales Management || Transactions || Goods Shipment || Header : create shipment for
bp=mcgiver
org=Main
date=26/04/2010
product=boots
qty=1

3. Sales Management || Transactions || Sales Invoice || Header : create invoice for
bp=mcgiver
org=Main
date=26/04/2010
Create Lines From the previous shipment

4. Sales Management || Transactions || Sales Invoice || Header >> Lines >> Price Adjustments : navigate to Price Adjustment created for the invoice and realize that quantities are not correct.

If you refresh the product you can check that PriceAdjustment is recalculated correctly.
No tags attached.
depends on backport 00131332.40MP13 closed harikrishnan m_get_offer error when using "create lines from" process 
related to defect 00167403.0RC6 closed adrianromero Purchase Invoice - "Create lines From" feature does not take the unit price of the purchase order but the price list one 
Issue History
2010-04-26 19:59networkbNew Issue
2010-04-26 19:59networkbAssigned To => adrianromero
2010-04-26 20:00networkbNote Added: 0026709
2010-04-27 09:24adrianromeroStatusnew => scheduled
2010-04-27 09:24adrianromerofix_in_branch => pi
2010-04-27 09:25adrianromeroIssue cloned0013133
2010-04-27 09:25adrianromeroRelationship addeddepends on 0013133
2010-05-01 13:04harikrishnanAssigned Toadrianromero => harikrishnan
2010-05-01 13:41hgbotCheckin
2010-05-01 13:41hgbotNote Added: 0026835
2010-05-01 13:41hgbotStatusscheduled => resolved
2010-05-01 13:41hgbotResolutionopen => fixed
2010-05-01 13:41hgbotFixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/a106e43df4ade25f5d5aa2cc22ae8210fab8c1ba [^]
2010-05-01 13:42harikrishnanNote Added: 0026836
2010-05-03 16:45sureshbabuNote Added: 0026876
2010-05-17 11:50arunkumarNote Added: 0027360
2010-05-17 11:50arunkumarStatusresolved => closed
2010-05-18 00:01anonymoussf_bug_id0 => 3002959
2010-05-18 21:43hudsonbotCheckin
2010-05-18 21:43hudsonbotNote Added: 0027470
2011-04-11 17:01adrianromeroRelationship addedrelated to 0016740

Notes
(0026709)
networkb   
2010-04-26 20:00   
due date=06/07/2010
(0026835)
hgbot   
2010-05-01 13:41   
Repository: erp/devel/pi
Changeset: a106e43df4ade25f5d5aa2cc22ae8210fab8c1ba
Author: Harikrishnan Raja <harikrishnan.raja <at> openbravo.com>
Date: Sat May 01 17:10:36 2010 +0530
URL: http://code.openbravo.com/erp/devel/pi/rev/a106e43df4ade25f5d5aa2cc22ae8210fab8c1ba [^]

Fixes Issue 13132: m_get_offer error when using \"create lines from\" process.

---
M src/org/openbravo/erpCommon/ad_actionButton/CreateFrom.java
M src/org/openbravo/erpCommon/ad_actionButton/CreateFrom_Invoice_data.xsql
---
(0026836)
harikrishnan   
2010-05-01 13:42   
* Testing of the issue:
To test the issue, as Openbravo Admin, create a two price adjustments.If the invoice lines are created from "create lines from" then in price adjustments tab their should be two adjustments(Create price adjustments in such a way).
* Explanation of the changeset that fixes the issue:
In the CreateFrom class while copying the actual price offer price calculation is applied before.Now this calculation is applied.

* Other areas affected by the changeset:
The only areas affected by this change set are "Create Lines From " in sales invoice and purchase invoice.
(0026876)
sureshbabu   
2010-05-03 16:45   
I am not finding any problem in retesting the fix, but still i need little more clarification about your explanation

"If the invoice lines are created from "create lines from" then in price adjustments tab their should be two adjustments(Create price adjustments in such a way)."
(0027360)
arunkumar   
2010-05-17 11:50   
Tested working fine
(0027470)
hudsonbot   
2010-05-18 21:43   
A changeset related to this issue has been promoted to main after passing a series of tests and an OBX has been generated:

Changeset: http://code.openbravo.com/erp/devel/main/rev/a106e43df4ad [^]
Merge Changeset: http://code.openbravo.com/erp/devel/main/rev/aa11838d5f80 [^]
Tests: http://builds.openbravo.com/view/devel-int/ [^]
OBX: http://builds.openbravo.com/erp/core/obx/OpenbravoERP-2.50CI.17380.obx [^]