Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0007664Openbravo ERP07. Sales managementpublic2009-02-18 19:062009-04-22 00:00
walle 
rajagopal 
lowminoralways
closedfixed 
20rPath Linux
2.40 
2.50 
Core
No
0007664: Copy from Order in Sales Order - wrong ordering
The ordering of the importet lines from a other order or proposal is not like
the sequence ordering in the baseorder from where you copy the lines.
1) Create a new sales order
2) Go to sales order lines and add seq. 10 "product 1", seq 20 "product 2", seq 5 "product 3"
3) Create a new sales order and use Copy From Order button to copy this lines selecting the previous order

the sequence in the new order will be:
seq 10 "Product 1", seq 20 "product 2", seq 30 "product 3"
But in this case "product 3" must have the sequence 10 in the new order
Change ordering rule from field "c_orderline_id" to "line"
comsupchennai_sprint2
related to defect 0007653pi closed vmromanos Copy lines in the order should order result lines by product name 
Issue History
2009-02-18 19:06walleNew Issue
2009-02-18 19:06walleAssigned To => rafaroda
2009-02-24 13:30psarobeNote Added: 0014027
2009-02-24 13:30psarobeStatusnew => feedback
2009-03-03 09:34walleNote Added: 0014265
2009-03-06 08:30rafarodaAssigned Torafaroda => rajagopal
2009-03-06 08:30rafarodaPrioritynormal => low
2009-03-06 08:30rafarodaStatusfeedback => scheduled
2009-03-06 08:30rafarodaProposed Solution updated
2009-03-16 08:43hgbotCheckin
2009-03-16 08:43hgbotNote Added: 0014651
2009-03-16 08:43hgbotStatusscheduled => resolved
2009-03-16 08:43hgbotResolutionopen => fixed
2009-03-16 08:43hgbotFixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/e99661ebff202e70cedac841ba98a13913526890 [^]
2009-03-16 11:33rafarodaRelationship addedrelated to 0007653
2009-03-17 11:22rajagopalTag Attached: comsupchennai_sprint2
2009-04-21 10:53psarobeStatusresolved => closed
2009-04-22 00:00anonymoussf_bug_id0 => 2777900

Notes
(0014027)
psarobe   
2009-02-24 13:30   
please provide the steps to get to that button
(0014265)
walle   
2009-03-03 09:34   
Hi...
After a detailed investigation we know now that there is no orderrule for the positions, the involved xsql file is the CopyFromPOOrder_data.xsql. Please change here the the following select statement

SELECT C_ORDERLINE_ID as orderline, C_UOM_ID, M_PRODUCT_ID, QTYORDERED, QUANTITYORDER,
M_PRODUCT_UOM_ID, DESCRIPTION, C_CURRENCY_ID
FROM C_ORDERLINE
WHERE C_ORDER_ID = TO_NUMBER(?)

with

SELECT C_ORDERLINE_ID as orderline, C_UOM_ID, M_PRODUCT_ID, QTYORDERED, QUANTITYORDER,
M_PRODUCT_UOM_ID, DESCRIPTION, C_CURRENCY_ID
FROM C_ORDERLINE
WHERE C_ORDER_ID = TO_NUMBER(?)
ORDER BY LINE ASC

This will allow that on pressing the button "Copy from Order" the same sequence ordering as in the sourceorder is granted.

BR, Walter
(0014651)
hgbot   
2009-03-16 08:43   
Repository: erp/devel/pi
Changeset: e99661ebff202e70cedac841ba98a13913526890
Author: Rajagopal Baskaran <rajagopal.baskaran <at> openbravo.com>
Date: Mon Mar 16 12:55:33 2009 +0530
URL: http://code.openbravo.com/erp/devel/pi/rev/e99661ebff202e70cedac841ba98a13913526890 [^]

Fixes bug 7664 imported lines from a other order or proposal is not like the sequence ordering in the base order has been fixed.

---
M src/org/openbravo/erpCommon/ad_actionButton/CopyFromPOOrder_data.xsql
---