cannot add an invoice line in a draft supplier invoice

Bug #753634 reported by Aline (OpenERP)
18
This bug affects 3 people
Affects Status Importance Assigned to Milestone
Odoo Addons (MOVED TO GITHUB)
Fix Released
High
OpenERP Publisher's Warranty Team
Odoo Web Client
Status tracked in 6.0
6.0
Invalid
Undecided
Unassigned

Bug Description

To test :

Install purchase ans invoicing :
-create a purchase order and convert it
- go to the invoice (supplier invoice)
- it is in draft so add a new invoice line by clicking "Create"

bug :

AVERTISSEMENT
 Traceback (most recent call last): File "/home/odoo/openerp/server/bin/netsvc.py", line 490, in dispatch result = ExportService.getService(service_name).dispatch(method, auth, params) File "/home/odoo/openerp/server/bin/addons/use_control/services.py", line 41, in dispatch return super(recording_objects_proxy, self).dispatch(func, auth, params) File "/home/odoo/openerp/server/bin/service/web_services.py", line 608, in dispatch res = fn(db, uid, *params) File "/home/odoo/openerp/server/bin/addons/audittrail/audittrail.py", line 511, in execute res = my_fct(db, uid, model, method, *args) File "/home/odoo/openerp/server/bin/addons/audittrail/audittrail.py", line 489, in my_fct return fct_src(db, uid, model, method, *args) File "/home/odoo/openerp/server/bin/osv/osv.py", line 122, in wrapper return f(self, dbname, *args, **kwargs) File "/home/odoo/openerp/server/bin/osv/osv.py", line 176, in execute res = self.execute_cr(cr, uid, obj, method, *args, **kw) File "/home/odoo/openerp/server/bin/osv/osv.py", line 167, in execute_cr return getattr(object, method)(cr, uid, *args, **kw) File "/home/odoo/openerp/server/bin/osv/orm.py", line 981, in default_get defaults[f] = self._defaults[f](self, cr, uid, context) File "/home/odoo/openerp/server/bin/addons/account/invoice.py", line 1262, in _price_unit_default for tax in tax_obj.compute_all(cr, uid, taxes, p,l[2].get('quantity'), context.get('address_invoice_id', False), l[2].get('product_id', False), context.get('partner_id', False))['taxes']: File "/home/odoo/openerp/server/bin/addons/account/account.py", line 1904, in compute_all if tax.price_include: AttributeError: 'NoneType' object has no attribute 'price_include'

Revision history for this message
DBR (OpenERP) (dbr-openerp) wrote :

Hello,

This problem occurred when we add tax in Sale Order.

Thanks.

Revision history for this message
DBR (OpenERP) (dbr-openerp) wrote :

Hello ,

Correcting last comment "This problem occurred when we add tax in Purchase Order".

Thanks for understanding.

Revision history for this message
DBR (OpenERP) (dbr-openerp) wrote :

Hello,

I have tested this problem with trunk but it is working fine for trunk .

Thanks.

Changed in openobject-client-web:
status: New → Invalid
Revision history for this message
Kevin Thompson (BPSO) (ketho) wrote :

Hi,

My customer is running on the version 6.0.2 and he gets the same problem.
Scenario to test:
- create a draft supplier invoice with 1 line relevant to taxe
- Save the draft the invoice
- Edit the invoice again and add a new line.

Then you get the traceback, as detailed above.

Thx, Kevin

Revision history for this message
Jay Vora (Serpent Consulting Services) (jayvora) wrote :

Hello Aline,Kevin,

This has been fixed into stable by revision http://bazaar.launchpad.net/~openerp/openobject-addons/6.0/revision/4537.
Fix will be available from Version 6.0.3.

Thank you.

Changed in openobject-addons:
status: New → Fix Released
importance: Undecided → High
milestone: none → 6.0.3
assignee: nobody → OpenERP Publisher's Warranty Team (openerp-opw)
Revision history for this message
Alexandre Gain (gain-nomendum) wrote :

Jay
I tried to apply the patch you provided on my 6.0.2 as I have the same problem.

Actually, It does not have any effect (positive or negative)

This is really critical (production)

Can anyone confirm this fixes the above described problem ?

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.