← Back to team overview

credativ team mailing list archive

[Bug 908189] Re: ir_sequence - code must be unique

 

Well - according to my experience this does not work reliably

Having 2 or more sequences with the same code - next_by code will take a random sequence - which can't be a desired behavior
this
        ids = self.search(cr, uid, ['&',('code','=', sequence_code),('company_id','in',company_ids)])
        return self._next(cr, uid, ids, context)

        return self.next_by_code(cr, uid, sequence_code_or_id, context)
will return multiple sequences which match the search  which IMHO is not handled

I just tried it with code of today.


** Changed in: openobject-addons
       Status: Invalid => New

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

Title:
  ir_sequence - code must be unique

Status in OpenERP Addons (modules):
  New

Bug description:
  IMHO the code must be unique (for lookup via code) or null (for lookup
  via id from journals)

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


References