Comment 2 for bug 946144

Revision history for this message
Guewen Baconnier @ Camptocamp (gbaconnier-c2c) wrote :

Hi,
For each attribute there is a field (ir.model.fields) in product.template.
For attributes with options (m2o, m2m), a domain is declared on the field.

So let me explain with the visibility as exemple.
You have to edit the field x_magerp_visibility of product.template, you'll see that it is a m2o pointing to magerp.product.attributes.options (something like that) and it has a domain like [('attribute_id', '=', 10). Here, 10 is the id of the visibility attribute when it has been created the first time. You have to replace it by the new id of the visibility attribute and it should be restored.
Then repeat this for each relational attribute.

On my side, I do not understand why you would need to delete attributes on the OpenERP side?
If that's an user error so maybe we just have to forbid that?

Guewen