[Erp5-dev] Changing workflow association and restoring document's workflow state

Łukasz Nowak lukasz.nowak at ventis.com.pl
Wed Oct 24 16:53:09 CEST 2007


Hello,

On 2007-10-24, 16:43:34
Jérome Perrin <jerome at nexedi.com> wrote:

(...)
> Look at workflow_history attribute on document, it's easy to
> understand how it's structured (with pprint).
> This http://svn.erp5.org/?view=rev&revision=17171 was to change the 
> state variable name, so it's not exactly the same. If only workflow
> ID changed, I think you can simply do:
> ob.workflow_history['new_workflow_id'] =\
>           ob.workflow_history.pop('old_workflow_id')

Hm. Well - yes. Only workflow_id will be changed (for now). So that
solution is great for me. You know, I've overwritten such workflows as
validation_workflow, order_workflow w/o creating mine workflows
(ventis_validation_workflow), etc - so such easy solution will save my
soul.

Regards,
Luke

-- 
Łukasz Nowak R&D Ventis http://www.ventis.com.pl/
tel: +48 32 768 16 85 fax: +48 32 392 10 61
``Use the Source, Luke...'' I am only craftsman.



More information about the Erp5-dev mailing list