You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

13 lines
568 B

  1. # -*- encoding: utf-8 -*-
  2. ################################################################################
  3. # See __openerp__.py file for Copyright and Licence Informations.
  4. ################################################################################
  5. import openerp
  6. class WebEasySwitchCompanyController(openerp.addons.web.http.Controller):
  7. _cp_path = '/web_easy_switch_company/switch'
  8. @openerp.addons.web.http.jsonrequest
  9. def change_current_company(self, req, company_id):
  10. req.session.model('res.users').change_current_company(company_id)