Anonymous | Login
Project:
RSS
  
News | My View | View Issues | Roadmap | Summary

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0037211
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Retail Modules] StoreServermajorhave not tried2017-11-02 16:022017-11-29 10:39
ReporterAugustoMauchView Statuspublic 
Assigned ToAugustoMauch 
PrioritynormalResolutionfixedFixed in Version
StatusclosedFix in branchFixed in SCM revisionfa52b2def398
ProjectionnoneETAnoneTarget Version
OSAnyDatabaseAnyJava version
OS VersionDatabase versionAnt version
Product VersionSCM revision 
Review Assigned Tomigueldejuana
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo
Summary

0037211: OBRECP_ComplementaryProduct is not being exported/synchronized properly

DescriptionOBRECP_ComplementaryProduct is a child table of m_product, and it is used to associate a product with other products, so that when a product is buyed, other products are offered to buy as complementary products.

The records of that table are stored in the organization of the main product. But the router needs to also take into account the organization of the complementary products, to avoid synchronizing to a store a row where the complementary product does not exist.
Steps To ReproduceSuppose there are three products:
- One global product (defined in *)
- Two local products (defined in two different child organizations, say X and Y).

Suppose there is a store server defined for organiation X.

If the product defined in Y is added as a complementary for the global product, that record (defined in *) will be synchronized to the store that has access to X, even though it does not have access to the products defined in Y. This will lead to a synchronization error.
Proposed SolutionTake into account the organization of the complementary product when exporting/synchronizing records of OBRECP_ComplementaryProduct
TagsNo tags attached.
Attached Files

- Relationships Relation Graph ] Dependency Graph ]

-  Notes
(0100220)
hgbot (developer)
2017-11-02 16:07

Repository: erp/pmods/org.openbravo.retail.storeserver.synchronization.but
Changeset: d4c17cc6374137e0e2b2f41e9cb8a61b128a4291
Author: Augusto Mauch <augusto.mauch <at> openbravo.com>
Date: Thu Nov 02 16:04:43 2017 +0100
URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.storeserver.synchronization.but/rev/d4c17cc6374137e0e2b2f41e9cb8a61b128a4291 [^]

Fixes issue 37211: OBRECP_ComplementaryProduct is properly routed

Now when synchronizing/routing records of the OBRECP_ComplementaryProduct table, the organization of the complementary product is also taken into account.

This helps prevent synchronization errors when a local product is added to a global product.

---
M src-db/database/sourcedata/AD_DATASET_TABLE.xml
M src-db/database/sourcedata/STRSYNC_CUSTOM_ROUTER.xml
M src-db/database/sourcedata/STRSYNC_SYNCHRONIZEDTABLE.xml
A src/org/openbravo/retail/storeserver/synchronization/but/router/ComplementaryProductRouter.java
---
(0100614)
mtaal (manager)
2017-11-20 11:36

While reviewing and testing I found a bug (afaics) in the dataset store export query change. The query does 'm_product_id in'. While I think it should do 'm_product_complementary_id in'

I found this because the complementary product record was not exported if the comp-product has a different org than the parent product. It should be exported if both orgs are fine for the store being exported.
(0100711)
mtaal (manager)
2017-11-25 15:49

A change is needed in the dataset query, pushing the change and set back for reclosing by original author
(0100712)
hgbot (developer)
2017-11-25 15:51

Repository: erp/pmods/org.openbravo.retail.storeserver.synchronization.but
Changeset: fa52b2def398c610c280709c7f39187c94977a4d
Author: Martin Taal <martin.taal <at> openbravo.com>
Date: Sat Nov 25 15:50:57 2017 +0100
URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.storeserver.synchronization.but/rev/fa52b2def398c610c280709c7f39187c94977a4d [^]

Fixes issue 37211: OBRECP_ComplementaryProduct is not being exported/synchronized properly
Check for the child product, the complementary product if it is in the org of the store. The parent/main product is already checked in the query.

---
M src-db/database/sourcedata/AD_DATASET_TABLE.xml
---
(0100713)
mtaal (manager)
2017-11-25 15:52

Except for the additional change I propose, the rest of the changes look fine and work correctly
(0100805)
migueldejuana (developer)
2017-11-29 10:39

Reviewed

- Issue History
Date Modified Username Field Change
2017-11-02 16:02 AugustoMauch New Issue
2017-11-02 16:02 AugustoMauch Assigned To => AugustoMauch
2017-11-02 16:02 AugustoMauch Triggers an Emergency Pack => No
2017-11-02 16:07 hgbot Checkin
2017-11-02 16:07 hgbot Note Added: 0100220
2017-11-02 16:07 hgbot Status new => resolved
2017-11-02 16:07 hgbot Resolution open => fixed
2017-11-02 16:07 hgbot Fixed in SCM revision => http://code.openbravo.com/erp/pmods/org.openbravo.retail.storeserver.synchronization.but/rev/d4c17cc6374137e0e2b2f41e9cb8a61b128a4291 [^]
2017-11-07 22:30 mtaal Review Assigned To => mtaal
2017-11-20 11:36 mtaal Note Added: 0100614
2017-11-25 15:49 mtaal Note Added: 0100711
2017-11-25 15:49 mtaal Status resolved => new
2017-11-25 15:49 mtaal Resolution fixed => open
2017-11-25 15:51 mtaal Review Assigned To mtaal => AugustoMauch
2017-11-25 15:51 hgbot Checkin
2017-11-25 15:51 hgbot Note Added: 0100712
2017-11-25 15:51 hgbot Status new => resolved
2017-11-25 15:51 hgbot Resolution open => fixed
2017-11-25 15:51 hgbot Fixed in SCM revision http://code.openbravo.com/erp/pmods/org.openbravo.retail.storeserver.synchronization.but/rev/d4c17cc6374137e0e2b2f41e9cb8a61b128a4291 [^] => http://code.openbravo.com/erp/pmods/org.openbravo.retail.storeserver.synchronization.but/rev/fa52b2def398c610c280709c7f39187c94977a4d [^]
2017-11-25 15:52 mtaal Note Added: 0100713
2017-11-27 10:19 mtaal Review Assigned To AugustoMauch => migueldejuana
2017-11-29 10:39 migueldejuana Note Added: 0100805
2017-11-29 10:39 migueldejuana Status resolved => closed


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker