[trunk / 6.1] sale order line th_weight is not correct

Bug #996512 reported by Nicolas Bessi - Camptocamp
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Odoo Addons (MOVED TO GITHUB)
Fix Committed
Low
OpenERP R&D Addons Team 3

Bug Description

There is a little error in sale order line th_weight it is not computed correctly with qty > 1
It seems that a parenthesis is missing. But is also dot not take in account SoLine UOS but and use product coef.
The FixME should be Fixed

=== modified file 'sale/sale.py'
--- sale/sale.py 2012-02-16 16:52:53 +0000
+++ sale/sale.py 2012-05-08 11:53:37 +0000
@@ -1127,7 +1127,7 @@
         try:
             value.update({
                 'product_uom_qty': product_uos_qty / product.uos_coeff,
- 'th_weight': product_uos_qty / product.uos_coeff * product.weight
+ 'th_weight': (product_uos_qty / product.uos_coeff) * product.weight
             })
         except ZeroDivisionError:
             pass

Related branches

Revision history for this message
Nicolas Bessi - Camptocamp (nbessi-c2c-deactivatedaccount) wrote :

Seems bug is obsolete in last revision.

Regards

Nicolas

Changed in openobject-addons:
status: New → Invalid
status: Invalid → Confirmed
status: Confirmed → New
Revision history for this message
Nicolas Bessi - Camptocamp (nbessi-c2c-deactivatedaccount) wrote :

Got it in Sale layout use the on change ups_change but not the view in sale .py

We should remove this dead code.

Regards

Nicolas

Revision history for this message
Nicolas Bessi - Camptocamp (nbessi-c2c-deactivatedaccount) wrote :

in sale module sorry

Revision history for this message
Amit Bhavsar (Open ERP) (amb-openerp) wrote :

Hello Nicolas Bessi,

I have checked your Issue, But I am not able to understand your comment #2 and #3 properly. So would please more focus on this Issue and elaborate more .

Thanks and waiting for your reply!

Revision history for this message
Amit Bhavsar (Open ERP) (amb-openerp) wrote :

Hello Nicolas Bessi,

I am agree with you that, in sale order line th_weight it is not computed correctly with qty > 1.

So , It has been fixed onlp:~openerp-dev/openobject-addons/trunk-bug-996512-amb branch with following revision no and id.

rev no : 6797
rev id : 6797 <email address hidden>

Thanks for the reporting!

Changed in openobject-addons:
importance: Undecided → Low
status: New → Fix Committed
summary: - [6.1] sale order line th_weight is not correct
+ [trunk / 6.1] sale order line th_weight is not correct
Changed in openobject-addons:
assignee: nobody → OpenERP R&D Addons Team 3 (openerp-dev-addons3)
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

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