Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0036915Openbravo ERP02. Master data managementpublic2017-09-21 12:572017-10-17 23:37
shuehner 
nonofrancisco 
urgentmajorhave not tried
scheduledopen 
5
 
 
Core
No
0036915: UpdateVariantImage modulescript logic is functionally completely broken and causes lots of wrong data changes
This modulescript apparently (!) was to:
- for product which have a generic product associated
- Clone image associated to genric product
- assign cloned-image-id to specific product

However currently for any specific product
It clones its image and override the m_product image reference with the clone.

Which obviously does not make any sense and has 2 bad side-effects at least:
- changing ad_image_id causing useless diff in sampledata
- duplicating ad_image table size
Q3 install retail+ retail sampledata
export white valley (retail sampledata)
Review diff of m_product + ad_image notice changing id's + table growth
Understand + fix logic in modulescript
Check and maybe fix older data-corruption
No tags attached.
Issue History
2017-09-21 12:57shuehnerNew Issue
2017-09-21 12:57shuehnerAssigned To => Triage Finance
2017-09-21 12:57shuehnerModules => Core
2017-09-21 12:57shuehnerTriggers an Emergency Pack => No
2017-10-17 17:29nonofranciscoAssigned ToTriage Finance => nonofrancisco
2017-10-17 17:31nonofranciscoStatusnew => scheduled
2017-10-17 23:37nonofranciscoNote Added: 0099931
2017-10-17 23:39nonofranciscoNote Edited: 0099931bug_revision_view_page.php?bugnote_id=0099931#r16122

Notes
(0099931)
nonofrancisco   
2017-10-17 23:37   
(edited on: 2017-10-17 23:39)
Test Plan

Q3 install retail+ retail sampledata
Export white valley (retail sampledata)

Verify 4 new images have been created
Verify 16 products have been updated.

Currently, there are 5 products being used as generic products (referenced by other products in generic_product_id field), 1 of those products has no image. There are 20 products defined as generic (referencing one of 5 generic products), 4 of them referencing the generic product without image.
After running module script, 4 new images are created, and 16 product are updated, this info is logged to the console when module script is executed.