Partner Section price not working when using product templates

Bug #997898 reported by Jose Patricio Villarreal
20
This bug affects 3 people
Affects Status Importance Assigned to Milestone
Odoo Addons (MOVED TO GITHUB)
Fix Released
Low
OpenERP R&D Addons Team 2

Bug Description

Price List price_get_multi looks for product_id insted of tmpl_id for partener section.

1) Make a purchase order
2) Select a parnter
3)Select a price list that has on it's highest sequence the option Partner section of the product form.
3) select a product, make sure that the product has a supplier price (obvious the same as the parnter selected)

This will work, but if you are using product templates, the query on pricelist.py on the function price_get_multi looks for product_id insted of product templates, and on the product supplier info table is routed to product_template.

find my patch attached...

Related branches

Revision history for this message
Jose Patricio Villarreal (josepato-o) wrote :
Revision history for this message
Jose Patricio Villarreal (josepato-o) wrote :

Other option will be changing the supplier product field to product product instead of product template

Revision history for this message
Amit Parik (amit-parik) wrote :

Hello Jose,

I have checked your issue at my end as you said on bug report but I didn't face any problem.

I have also tried as you suggested that we have to use product template instead on product.product but same result I observed.

I have make a video and attached with this bug, So please check it and provide a precious steps to reproduce it.

Or may I missed something?

Thanks and waiting for your reply!

Revision history for this message
Amit Parik (amit-parik) wrote :
Changed in openobject-addons:
status: New → Incomplete
Revision history for this message
OpenBias (openbias) wrote :

Hi Amit, when you use all you products with a one to one relation with its variant there is no problem, because product_id = tmpl_id.

But if you install the module product_variant_multi that lets you see the product and the variant by separate and were you join the two or three products to the same template, thats where the problem starts.

Ex, I made a new product called IceCream and use the reference 2. Both IceCream 1 and 2 have the same template, for the product IceCream 1 there is not going to be a problem because (again) product_id = tmpl_id, but to IceCream 2 yes because product_id <> tmpl_id.

Find the video attached, I stated with the patch on, then I take it off and finally I put it back on...

Revision history for this message
Amit Parik (amit-parik) wrote :

Hello OpenBias,

Thanks for a good explanation and video.

I totally agree with, If product_id not same as a tmpl_id then this type of problem will raised (after product_variant_multi).

Thanks!

Changed in openobject-addons:
assignee: nobody → OpenERP R&D Addons Team 2 (openerp-dev-addons2)
importance: Undecided → Low
status: Incomplete → Confirmed
Revision history for this message
Amit Parik (amit-parik) wrote :

Hello,

Thanks for the reporting!

This issue has been fixed on lp:~openerp-dev/openobject-addons/trunk-bug-997898-amp branch with following rev no and rev ID.

Rev no : 6789

Rev Id : <email address hidden>

Thanks!

Changed in openobject-addons:
status: Confirmed → Fix Committed
Changed in openobject-addons:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.