← Back to team overview

c2c-oerpscenario team mailing list archive

[Bug 764745] Re: user can't change company

 

The fix for this is in line 368 of base/res/res_user.py

Change:

if not (values['company_id'] in self.read(cr, uid, uid, ['company_ids'],
context=context)['company_ids']):

To be:

if not (values['company_id'] in self.read(cr, 1, uid, ['company_ids'],
context=context)['company_ids']):

Because it is doing the read in the context of the current company id of the user, whereas it needs to
see all of the companies of the user.

-- 
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/764745

Title:
  user can't change company

Status in OpenERP Modules (addons):
  New

Bug description:
  OpenERP v6.0.2

  As administrator, I put my user Miss Piggie into 5 different companies
  and set her company as Company1.

  When Miss Piggie logs in, she can open up her preferences and can select her company as Company2, but
  it never gets saved.

  Also note that when Miss Piggie goes into Administration / Users and looks at her account through there,
  she only sees Company1 in the list of Companies.  Administrator sees all 5 of the companies assigned to her.



References