Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0020068Openbravo ERPA. Platformpublic2012-03-20 18:482012-04-02 06:11
maite 
alostale 
immediatemajoralways
closedfixed 
5
pi 
3.0MP10 
Core
No
0020068: Products with different search key but same name are considered the same
Products with different search key but same name are considered the same
1. Create new product with search key =COM-FULLLEG-BLK-1 and name=CALF AND FORQUAD COMPRESS. Checked as Stocked.
2. Create new product with search key =COM-FULLLEG-BLK-1P and name=CALF AND FORQUAD COMPRESS. Checked as Stocked.
3. Create Goods Receipt from same organization and any BP. Add 2 lines: one per each product and any storage bin and with qty=1.

4.Go to the database and see that m_inoutline table records are correct(you can see that one line is for product COM-FULLLEG-BLK-1 and the other for product COM-FULLLEG-BLK-1P):

select io.m_product_id,p.value from m_inoutline io left join m_product p on io.m_product_id=p.m_product_id
 order by io.created desc limit 2

5.After that, in window "Goods Receipt" and inside the tab "Lines", change the view type from grid to form in both lines.

6.Go again to the database and execute again the previous query.You will see that one product id and search key has change and both are the same product. The only product is the product whose search key is 'COM-FULLLEG-BLK-1'
No tags attached.
related to defect 00199683.0MP10 closed alostale Products with different search key but same name are considered the same by Product Complete selector 
related to defect 0021553 closed AugustoMauch GenerateInvoice column is pointing to a wrong process named "Create Invoice". 
Issue History
2012-03-20 18:48maiteNew Issue
2012-03-20 18:48maiteAssigned To => jonalegriaesarte
2012-03-20 18:48maiteModules => Core
2012-03-20 18:49maiteIssue Monitored: networkb
2012-03-20 18:50jonalegriaesarteAssigned Tojonalegriaesarte => jecharri
2012-03-20 18:51jonalegriaesarteversion => pi
2012-03-20 18:51jonalegriaesarteTarget Version => 3.0MP10
2012-03-21 16:47alostaleRelationship addedrelated to 0019968
2012-03-21 16:47alostaleAssigned Tojecharri => alostale
2012-03-21 16:58jecharriAssigned Toalostale => jecharri
2012-03-21 16:58jecharriCategory04. Warehouse management => A. Platform
2012-03-21 16:58jecharriSummary"Create Inventory Count List" process is not correct when several products have same name => Products with different search key but same name are considered the same
2012-03-21 16:58jecharriDescription Updatedbug_revision_view_page.php?rev_id=3286#r3286
2012-03-21 16:58jecharriSteps to Reproduce Updatedbug_revision_view_page.php?rev_id=3288#r3288
2012-03-21 16:58jecharriAssigned Tojecharri => alostale
2012-03-21 16:59jecharriSteps to Reproduce Updatedbug_revision_view_page.php?rev_id=3289#r3289
2012-03-21 17:00jecharriSteps to Reproduce Updatedbug_revision_view_page.php?rev_id=3290#r3290
2012-03-23 11:51alostaleNote Added: 0046670
2012-03-23 11:58alostaleNote Added: 0046671
2012-03-23 11:59hgbotCheckin
2012-03-23 11:59hgbotNote Added: 0046673
2012-03-23 11:59hgbotStatusnew => resolved
2012-03-23 11:59hgbotResolutionopen => fixed
2012-03-23 11:59hgbotFixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/a0e58b778cf63bb2eebffdcb00c11c008719d74e [^]
2012-03-23 14:36maiteNote Added: 0046693
2012-03-23 14:36maiteStatusresolved => closed
2012-03-23 15:51marvintmNote Added: 0046699
2012-04-02 06:11hudsonbotCheckin
2012-04-02 06:11hudsonbotNote Added: 0047207
2012-09-06 18:14AugustoMauchRelationship addedrelated to 0021553

Notes
(0046670)
alostale   
2012-03-23 11:51   
This is the same case as 0019968: having 2 values that display the same info in the selector, being in form view for one of them, and opening form view for the other one, valueMap includes both making smartclient to fail to take the proper one.

The solution is to reimplement fix for 0019968 in a more generic way by cleaning up the valueMap for this case not only when the record is selected in the selector popup but whenever value is set.
(0046671)
alostale   
2012-03-23 11:58   
This fix reimplements fix for 0019968. 0019968 needs to be rechecked to ensure new implementation properly covers both cases. Apart of this, it doesn't add regression risk as it only affects the corner case of having multiple items in a selector with the same identifier but different ID.

Test plan:
 -Re-validate 0019968
 -In form create line for product 1
 -In form create line for product 2
 -Go to grid and select 1st line and open in form (note before the fix this was marked as modified)
 -Go back to grid (before the fix autosave was done setting to this line product 2)
 -Check in DB both lines still have different products.
(0046673)
hgbot   
2012-03-23 11:59   
Repository: erp/devel/pi
Changeset: a0e58b778cf63bb2eebffdcb00c11c008719d74e
Author: Asier Lostalé <asier.lostale <at> openbravo.com>
Date: Fri Mar 23 11:53:50 2012 +0100
URL: http://code.openbravo.com/erp/devel/pi/rev/a0e58b778cf63bb2eebffdcb00c11c008719d74e [^]

fixed bug 20068: Selector doesn't work when 2 items have same identifier

  Reimplemented fix for bug 19968 in a more generic way: do not only clean the valueMap
  when selecting an item in the selector pop up but whenever value is set.

---
M modules/org.openbravo.userinterface.selector/web/org.openbravo.userinterface.selector/js/ob-selector-item.js
---
(0046693)
maite   
2012-03-23 14:36   
verified
(0046699)
marvintm   
2012-03-23 15:51   
reviewed
(0047207)
hudsonbot   
2012-04-02 06:11   
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/7814864461ac [^]

Maturity status: Test