← Back to team overview

openerp-india team mailing list archive

[Bug 973912] Re: base_sale_multichannels again broken

 

Hi,

No modification have been done here recently. 
If you have this error, it means that no invoice has been created for your order 

The line just before is : wf_service.trg_validate(uid, 'sale.order',
order.id, 'manual_invoice', cr)

This is supposed to create the invoice.

Do you have an idea why the invoice could not have been created ?

One possibility is to simply replace 
invoice_id = self.browse(cr, uid, order.id).invoice_ids[0].id
by 
invoice_ids = self.browse(cr, uid, order.id).invoice_ids
if invoice_ids:
    invoice_id = invoice_ids[0].id
and continue...

But I'm not sure that the good solution. I think we should first find
why the invoice is not created when we trigger the "manual_invoice".

Kyle, I will respond to your email as soon as possible.

Guewen

-- 
You received this bug notification because you are a member of OpenERP
Indian Team, which is subscribed to OpenERP Addons.
https://bugs.launchpad.net/bugs/973912

Title:
  base_sale_multichannels again broken

Status in OpenERP Addons (modules):
  New

Bug description:
  2012-04-05 02:46:30,651 22335 ERROR ? openerp.osv.osv: Uncaught exception
  Traceback (most recent call last):
    File "/usr/local/openerp/6.1/openerp-server/openerp/osv/osv.py", line 121, in wrapper
      return f(self, dbname, *args, **kwargs)
    File "/usr/local/openerp/6.1/openerp-server/openerp/osv/osv.py", line 176, in execute
      res = self.execute_cr(cr, uid, obj, method, *args, **kw)
    File "/usr/local/openerp/6.1/openerp-server/openerp/osv/osv.py", line 164, in execute_cr
      return getattr(object, method)(cr, uid, *args, **kw)
    File "/usr/local/openerp/6.1/addons/base_sale_multichannels/sale.py", line 326, in import_orders
      self.import_shop_orders(cr, uid, shop, defaults, context)
    File "/usr/local/openerp/6.1/addons/magentoerpconnect/sale.py", line 153, in import_shop_orders
      context=ctx)
    File "/usr/local/openerp/6.1/addons/magentoerpconnect/sale.py", line 715, in mage_import_base
      result = self.mage_import_one_by_one(cr, uid, conn, external_referential_id, mapping_id[0], order_ids_filtred, defaults, context)
    File "/usr/local/openerp/6.1/addons/magentoerpconnect/magerp_osv.py", line 279, in mage_import_one_by_one
      rec_result = self.ext_import(cr, uid, rec_data, external_referential_id, defaults, context)
    File "/usr/local/openerp/6.1/addons/magentoerpconnect/sale.py", line 662, in ext_import
      res = super(sale_order, self).ext_import(order_cr, uid, data, external_referential_id, defaults=defaults, context=context)
    File "/usr/local/openerp/6.1/addons/base_external_referentials/external_osv.py", line 514, in ext_import
      external_referential_id, context=context)
    File "/usr/local/openerp/6.1/addons/base_sale_multichannels/sale.py", line 606, in after_oe_create
      external_referential_id, context=context)
    File "/usr/local/openerp/6.1/addons/base_sale_multichannels/sale.py", line 591, in oe_status_and_paid
      self.oe_status(cr, uid, order_id, is_paid, context)
    File "/usr/local/openerp/6.1/addons/base_sale_multichannels/sale.py", line 765, in oe_status
      invoice_id = self.browse(cr, uid, order.id).invoice_ids[0].id
  IndexError: list index out of range

To manage notifications about this bug go to:
https://bugs.launchpad.net/openobject-addons/+bug/973912/+subscriptions


References