217
217
def next_by_id(self, cr, uid, sequence_id, context=None):
218
218
""" Draw an interpolated string using the specified sequence."""
219
219
self.check_access_rights(cr, uid, 'read')
220
company_ids = self.pool.get('res.company').search(cr, uid, [], order='company_id', context=context) + [False]
220
company_ids = self.pool.get('res.company').search(cr, uid, [], context=context) + [False]
221
221
ids = self.search(cr, uid, ['&',('id','=', sequence_id),('company_id','in',company_ids)])
222
222
return self._next(cr, uid, ids, context)