Odoo Help

Welcome!

This community is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.

0

AttributeError: 'product.product' object has no attribute '_ids' when confirming quotation

By
Oliver Stanton
on 12/16/15, 2:43 AM 535 views

Why do i get the error below each time i try to convert a sales quote to an order ?

Odoo

Odoo Server Error
Traceback (most recent call last):
  File "/opt/bitnami/apps/odoo/lib/odoo-9.0_20151109-py2.7.egg/openerp/http.py", line 599, in _handle_exception
    return super(JsonRequest, self)._handle_exception(exception)
  File "/opt/bitnami/apps/odoo/lib/odoo-9.0_20151109-py2.7.egg/openerp/http.py", line 636, in dispatch
    result = self._call_function(**self.params)
  File "/opt/bitnami/apps/odoo/lib/odoo-9.0_20151109-py2.7.egg/openerp/http.py", line 315, in _call_function
    return checked_call(self.db, *args, **kwargs)
  File "/opt/bitnami/apps/odoo/lib/odoo-9.0_20151109-py2.7.egg/openerp/service/model.py", line 118, in wrapper
    return f(dbname, *args, **kwargs)
  File "/opt/bitnami/apps/odoo/lib/odoo-9.0_20151109-py2.7.egg/openerp/http.py", line 308, in checked_call
    result = self.endpoint(*a, **kw)
  File "/opt/bitnami/apps/odoo/lib/odoo-9.0_20151109-py2.7.egg/openerp/http.py", line 887, in __call__
    return self.method(*args, **kw)
  File "/opt/bitnami/apps/odoo/lib/odoo-9.0_20151109-py2.7.egg/openerp/http.py", line 465, in response_wrap
    response = f(*args, **kw)
  File "/opt/bitnami/apps/odoo/lib/odoo-9.0_20151109-py2.7.egg/openerp/addons/web/controllers/main.py", line 975, in call_button
    action = self._call_kw(model, method, args, {})
  File "/opt/bitnami/apps/odoo/lib/odoo-9.0_20151109-py2.7.egg/openerp/addons/web/controllers/main.py", line 963, in _call_kw
    return getattr(request.registry.get(model), method)(request.cr, request.uid, *args, **kwargs)
  File "/opt/bitnami/apps/odoo/lib/odoo-9.0_20151109-py2.7.egg/openerp/api.py", line 232, in wrapper
    return old_api(self, *args, **kwargs)
  File "/opt/bitnami/apps/odoo/lib/odoo-9.0_20151109-py2.7.egg/openerp/api.py", line 354, in old_api
    result = method(recs, *args, **kwargs)
  File "/opt/bitnami/apps/odoo/lib/odoo-9.0_20151109-py2.7.egg/openerp/addons/delivery/models/sale_order.py", line 34, in action_confirm
    res = super(SaleOrder, self).action_confirm()
  File "/opt/bitnami/apps/odoo/lib/odoo-9.0_20151109-py2.7.egg/openerp/api.py", line 230, in wrapper
    return new_api(self, *args, **kwargs)
  File "/opt/bitnami/apps/odoo/lib/odoo-9.0_20151109-py2.7.egg/openerp/api.py", line 547, in new_api
    result = method(self._model, cr, uid, self.ids, *args, **kwargs)
  File "/opt/bitnami/apps/odoo/lib/odoo-9.0_20151109-py2.7.egg/openerp/addons/portal_sale/portal_sale.py", line 32, in action_confirm
    return super(sale_order, self).action_confirm(cr, uid, ids, context=context)
  File "/opt/bitnami/apps/odoo/lib/odoo-9.0_20151109-py2.7.egg/openerp/api.py", line 232, in wrapper
    return old_api(self, *args, **kwargs)
  File "/opt/bitnami/apps/odoo/lib/odoo-9.0_20151109-py2.7.egg/openerp/api.py", line 354, in old_api
    result = method(recs, *args, **kwargs)
  File "/opt/bitnami/apps/odoo/lib/odoo-9.0_20151109-py2.7.egg/openerp/addons/sale/sale.py", line 393, in action_confirm
    order.order_line._action_procurement_create()
  File "/opt/bitnami/apps/odoo/lib/odoo-9.0_20151109-py2.7.egg/openerp/api.py", line 230, in wrapper
    return new_api(self, *args, **kwargs)
  File "/opt/bitnami/apps/odoo/lib/odoo-9.0_20151109-py2.7.egg/openerp/addons/procurement_jit/sale.py", line 11, in _action_procurement_create
    res = super(SaleOrderLine, self)._action_procurement_create()
  File "/opt/bitnami/apps/odoo/lib/odoo-9.0_20151109-py2.7.egg/openerp/api.py", line 230, in wrapper
    return new_api(self, *args, **kwargs)
  File "/opt/bitnami/apps/odoo/lib/odoo-9.0_20151109-py2.7.egg/openerp/addons/sale/sale.py", line 560, in _action_procurement_create
    new_proc = self.env["procurement.order"].create(vals)
  File "/opt/bitnami/apps/odoo/lib/odoo-9.0_20151109-py2.7.egg/openerp/api.py", line 230, in wrapper
    return new_api(self, *args, **kwargs)
  File "/opt/bitnami/apps/odoo/lib/odoo-9.0_20151109-py2.7.egg/openerp/api.py", line 463, in new_api
    result = method(self._model, cr, uid, *args, **kwargs)
  File "/opt/bitnami/apps/odoo/lib/odoo-9.0_20151109-py2.7.egg/openerp/addons/procurement/procurement.py", line 146, in create
    self.run(cr, uid, [procurement_id], context=context)
  File "/opt/bitnami/apps/odoo/lib/odoo-9.0_20151109-py2.7.egg/openerp/api.py", line 232, in wrapper
    return old_api(self, *args, **kwargs)
  File "/opt/bitnami/apps/odoo/lib/odoo-9.0_20151109-py2.7.egg/openerp/addons/stock/procurement.py", line 334, in run
    self.pool.get('stock.move').action_confirm(cr, uid, move_to_confirm_ids, context=context)
  File "/opt/bitnami/apps/odoo/lib/odoo-9.0_20151109-py2.7.egg/openerp/api.py", line 232, in wrapper
    return old_api(self, *args, **kwargs)
  File "/opt/bitnami/apps/odoo/lib/odoo-9.0_20151109-py2.7.egg/openerp/api.py", line 354, in old_api
    result = method(recs, *args, **kwargs)
  File "/opt/bitnami/apps/odoo/lib/odoo-9.0_20151109-py2.7.egg/openerp/addons/delivery/models/stock_move.py", line 34, in action_confirm
    res = super(StockMove, self).action_confirm()
  File "/opt/bitnami/apps/odoo/lib/odoo-9.0_20151109-py2.7.egg/openerp/api.py", line 230, in wrapper
    return new_api(self, *args, **kwargs)
  File "/opt/bitnami/apps/odoo/lib/odoo-9.0_20151109-py2.7.egg/openerp/api.py", line 547, in new_api
    result = method(self._model, cr, uid, self.ids, *args, **kwargs)
  File "/opt/bitnami/apps/odoo/lib/odoo-9.0_20151109-py2.7.egg/openerp/addons/mrp/stock.py", line 112, in action_confirm
    move_ids.extend(self._action_explode(cr, uid, move, context=context))
  File "/opt/bitnami/apps/odoo/lib/odoo-9.0_20151109-py2.7.egg/openerp/api.py", line 232, in wrapper
    return old_api(self, *args, **kwargs)
  File "/opt/bitnami/apps/odoo/lib/odoo-9.0_20151109-py2.7.egg/openerp/api.py", line 327, in old_api
    result = method(recs, *args, **kwargs)
  File "/opt/bitnami/apps/odoo/lib/odoo-9.0_20151109-py2.7.egg/openerp/addons/sale_mrp/sale_mrp.py", line 86, in _action_explode
    return super(StockMove, self.with_context(property_ids=property_ids))._action_explode(move)
  File "/opt/bitnami/apps/odoo/lib/odoo-9.0_20151109-py2.7.egg/openerp/api.py", line 230, in wrapper
    return new_api(self, *args, **kwargs)
  File "/opt/bitnami/apps/odoo/lib/odoo-9.0_20151109-py2.7.egg/openerp/api.py", line 463, in new_api
    result = method(self._model, cr, uid, *args, **kwargs)
  File "/opt/bitnami/apps/odoo/lib/odoo-9.0_20151109-py2.7.egg/openerp/addons/mrp/stock.py", line 64, in _action_explode
    if prod_obj.type in ('consu','product'):
  File "/opt/bitnami/apps/odoo/lib/odoo-9.0_20151109-py2.7.egg/openerp/fields.py", line 797, in __get__
    record.ensure_one()
  File "/opt/bitnami/apps/odoo/lib/odoo-9.0_20151109-py2.7.egg/openerp/models.py", line 5367, in ensure_one
    if len(self) == 1:
  File "/opt/bitnami/apps/odoo/lib/odoo-9.0_20151109-py2.7.egg/openerp/models.py", line 5566, in __len__
    return len(self._ids)
AttributeError: 'product.product' object has no attribute '_ids'

Your Answer

Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!

About This Community

This community is for professionals and enthusiasts of our products and services. Read Guidelines

Question tools

1 follower(s)

Stats

Asked: 12/16/15, 2:43 AM
Seen: 535 times
Last updated: 12/16/15, 2:48 AM