← Back to team overview

c2c-oerpscenario team mailing list archive

[Bug 799083] Re: sales line not invoiced after moving the delivery into another delivery order

 

Hi,
trying to use your fix gives me this error:

Environment Information : 
System : Windows-XP-5.1.2600-SP3
OS Name : nt
Operating System Release : XP
Operating System Version : 5.1.2600
Operating System Architecture : 32bit
Operating System Locale : ro_RO.cp1252
Python Version : 2.5.2
OpenERP-Client Version : 6.0.2
Last revision No. & ID :Bazaar Package not Found !Traceback (most recent call last):
  File "/usr/lib/openerp-server-6.0.1/netsvc.py", line 489, in dispatch
    result = ExportService.getService(service_name).dispatch(method, auth, params)
  File "/usr/lib/openerp-server-6.0.1/service/web_services.py", line 599, in dispatch
    res = fn(db, uid, *params)
  File "/usr/lib/openerp-server-6.0.1/osv/osv.py", line 122, in wrapper
    return f(self, dbname, *args, **kwargs)
  File "/usr/lib/openerp-server-6.0.1/osv/osv.py", line 176, in execute
    res = self.execute_cr(cr, uid, obj, method, *args, **kw)
  File "/usr/lib/openerp-server-6.0.1/osv/osv.py", line 167, in execute_cr
    return getattr(object, method)(cr, uid, *args, **kw)
  File "/usr/lib/openerp-server-6.0.1/osv/orm.py", line 2921, in read
    result = self._read_flat(cr, user, select, fields, context, load)
  File "/usr/lib/openerp-server-6.0.1/osv/orm.py", line 3041, in _read_flat
    res2 = self._columns[f].get(cr, self, ids, f, user, context=context, values=res)
  File "/usr/lib/openerp-server-6.0.1/osv/fields.py", line 793, in get
    res = self._fnct(obj, cr, user, ids, name, self._arg, context)
  File "/usr/lib/openerp-server-6.0.1/addons/sale/sale.py", line 128, in _invoiced_rate
    if sale.invoiced:
  File "/usr/lib/openerp-server-6.0.1/osv/orm.py", line 285, in __getattr__
    return self[name]
  File "/usr/lib/openerp-server-6.0.1/osv/orm.py", line 205, in __getitem__
    field_values = self._table.read(self._cr, self._uid, ids, field_names, context=self._context, load="_classic_write")
  File "/usr/lib/openerp-server-6.0.1/osv/orm.py", line 2921, in read
    result = self._read_flat(cr, user, select, fields, context, load)
  File "/usr/lib/openerp-server-6.0.1/osv/orm.py", line 3041, in _read_flat
    res2 = self._columns[f].get(cr, self, ids, f, user, context=context, values=res)
  File "/usr/lib/openerp-server-6.0.1/osv/fields.py", line 793, in get
    res = self._fnct(obj, cr, user, ids, name, self._arg, context)
  File "/usr/lib/openerp-server-6.0.1/addons/sale/sale.py", line 155, in _invoiced
    cursor.execute('SELECT invoice_id from sale_order_line_invoice_rel where order_line_id IN %s' ,(tuple(ids),))
  File "/usr/lib/openerp-server-6.0.1/sql_db.py", line 78, in wrapper
    return f(self, *args, **kwargs)
  File "/usr/lib/openerp-server-6.0.1/sql_db.py", line 131, in execute
    res = self._obj.execute(query, params)
ProgrammingError: syntax error at or near ")"
ZEILE 1: ...d from sale_order_line_invoice_rel where order_line_id IN ()

Thanks

-- 
You received this bug notification because you are a member of C2C
OERPScenario, which is subscribed to the OpenERP Project Group.
https://bugs.launchpad.net/bugs/799083

Title:
  sales line not invoiced after moving the delivery into another
  delivery order

Status in OpenERP Modules (addons):
  Fix Committed

Bug description:
  perhaps is connected  with https://bugs.launchpad.net/bugs/308803

  On a freshly installed db with demo data:
  profile manufacturing, invoice on delivery, with partial picking and direct delivery
  Create two sales orders (SO001 and SO002) for the same client with the same product. Quantities are not important.
  The system generates the delivery orders (OUT001 for SO001 and OUT002 for SO002)
  Go to Warehouse->Product moves-Deliver products and find the line that belongs to delivery order OUT001 and edit that line: in the Picking-Reference select the delivery order OUT002

  The result is that the delivery order OUT001 is now empty and OUT002
  has two lines.

  Process that order and create invoice.

  Problem:
  In the sales orders list the sale SO001 picked is 100% and invoiced is 0%;  SO002 picked is 100% and invoiced is 100%

  Expected result:
  In the sales orders list the sale SO001 picked is 100% and invoiced is 100%;  SO002 picked is 100% and invoiced is 100%

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


References