• Jérome Perrin's avatar
    CMFActivity: Always set zope.globalrequest WIP · 40b795c7
    Jérome Perrin authored
    ERP5 uses a mix of context.REQUEST and Products.ERP5Type.Global.get_request(),
    which now uses zope.globalrequest.getRequest().
    CMFActivity reconstruct the original request before executing activity, so that
    the activity is executed with a request equivalent to the request at the time
    where the method was activated. For this, context.REQUEST was properly restored,
    but get_request()/globalrequest was only restored when the REQUEST had some
    ACCEPT_LANGUAGE header, so that it replays the language negociation for
    Localizer.
    With browser requests, I guess every browser pass an ACCEPT_LANGUAGE header,
    but within unit tests such header is not present.
    
    (TODO: finish this message)
    40b795c7
ActivityTool.py 71.6 KB