~credativ/credativ-openerp/addons-7.0-purchase-arrival-auto-invoice

« back to all changes in this revision

Viewing changes to so_line_delivery_date/sale.py

  • Committer: Tom Pickering
  • Date: 2014-06-06 10:14:00 UTC
  • Revision ID: tom.pickering@credativ.co.uk-20140606101400-d4ghdb83tglc3jo2
[FIX] Fixed traceback when writing to single Sale Orders.

Show diffs side-by-side

added added

removed removed

Lines of Context:
44
44
        res = super(sale_order, self).write(cr, uid, ids, vals, context=context)
45
45
 
46
46
        id_list = isinstance(ids, list) and ids[:] or [ids]
47
 
        self_browses = self.browse(cr, uid, ids, context=context)
 
47
        self_browses = self.browse(cr, uid, id_list, context=context)
48
48
        for self_browse in self_browses:
49
49
            if self_browse.requested_delivery_date and not self_browse.delivery_date_per_line:
50
50
                line_pool = self.pool.get('sale.order.line')