Přejít na obsah
Menu
You need to be registered to interact with the community.
This question has been flagged
1743 Zobrazení

Hello everyone,

I am using Odoo12 and need your help.
I need to write a python code that inherits base.import to control how the products import have to be done.

My problem is, every time I import the list of products to the system, all changes made on product name and other fields selected on import process are lost.

What I need to do is (during the import process):
- Keep product name intact if an existing product (I have to select this fields for system to create new records);
- Change only the "chosen" fields for existing products (in this case I just need to change the cost price, if the product already exist on system)
- Allow the import process create new product(s) if they do not exist on the system (normal import flow);

Basically I need (on import products process):
- Create new products that do not exist (with all required/selected fields);
- Leave existing products name intact (every product imported already have an external id, and this is created when the product is imported)
- On existing products, change only cost price (this is used for calculating sell price and I need to have this updated). On this case, perhaps change only some "chosen fields".

Can you please help me?

Thank you all in advance

Best regards

PM


Avatar
Zrušit
Related Posts Odpovědi Zobrazení Aktivita
3
zář 20
3589
3
čvc 25
2080
1
dub 25
3629
1
dub 25
1564
0
říj 24
1275