← Back to team overview

openerp-india team mailing list archive

[Bug 949516] Re: Workflow doesn't propagate context - needed for correct date generation

 

Dates generated by fields.date.context_today() and
fields.datetime.context_timestamp() should fallback to the user's TZ
when none can be detected in the context. This is similar to how the
translation system now falls back to the user's language when no context
language can be detected. This should be fixed soon.

The various tentative patches for passing context through workflows are
much more dangerous and incomplete solutions, and should probably be
abandoned. At some point the OpenERP API should also make the
transaction context implicit, deprecating this discussion.

** Changed in: openobject-server
   Importance: Low => Medium

** Changed in: openobject-server
       Status: Triaged => In Progress

** Changed in: openobject-server
    Milestone: None => 7.0

-- 
You received this bug notification because you are a member of OpenERP
Indian Team, which is subscribed to OpenERP Server.
https://bugs.launchpad.net/bugs/949516

Title:
  Workflow doesn't propagate context - needed for correct date
  generation

Status in OpenERP Server:
  In Progress

Bug description:
  The function in fields.date, context_today, uses the context variable
  'tz'.  Since context is not passed by workflow triggers, dates
  generated by workflow transitions are picking up UTC date, not the
  client's timezone date.

  For example, validating a customer invoice that has no invoice date.

  This is possibly related to bug:434266

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


References