I have been trying to get a transition condition working in a workflow without 
success.  The condition looks like this:

&nbsp;<field name="condition">res_company.num_signers==2</field>

But it always produces a traceback:
Wed, 25 Jun 2008 21&#58;30&#58;58 ERROR&#58;web-services&#58;Exception in 
call&#58; Traceback &#40;most recent call last&#41;&#58;
&nbsp; File "/usr/lib/python2.5/site-packages/tinyerp-server/netsvc.py", line 
317, in run
&nbsp; &nbsp; r=m&#40;*msg&#91;2&#58;&#93;&#41;
&nbsp; File 
"/usr/lib/python2.5/site-packages/tinyerp-server/service/web_services.py", line 
360, in exec_workflow
&nbsp; &nbsp; res = service.exec_workflow&#40;db, uid, object, method, id&#41;
&nbsp; File "/usr/lib/python2.5/site-packages/tinyerp-server/osv/osv.py", line 
129, in exec_workflow
&nbsp; &nbsp; res = self.exec_workflow_cr&#40;cr, uid, obj, method, *args&#41;
&nbsp; File "/usr/lib/python2.5/site-packages/tinyerp-server/osv/osv.py", line 
122, in exec_workflow_cr
&nbsp; &nbsp; wf_service.trg_validate&#40;uid, obj, args&#91;0&#93;, method, 
cr&#41;
&nbsp; File 
"/usr/lib/python2.5/site-packages/tinyerp-server/workflow/wkf_service.py", line 
86, in trg_validate
&nbsp; &nbsp; instance.validate&#40;cr, id, ident, signal&#41;
&nbsp; File 
"/usr/lib/python2.5/site-packages/tinyerp-server/workflow/instance.py", line 
53, in validate
&nbsp; &nbsp; workitem.process&#40;cr, witem, ident, signal, force_running&#41;
&nbsp; File 
"/usr/lib/python2.5/site-packages/tinyerp-server/workflow/workitem.py", line 
64, in process
&nbsp; &nbsp; ok = _split_test&#40;cr, workitem, 
activity&#91;'split_mode'&#93;, ident, signal&#41;
&nbsp; File 
"/usr/lib/python2.5/site-packages/tinyerp-server/workflow/workitem.py", line 
143, in _split_test
&nbsp; &nbsp; if wkf_expr.check&#40;cr, workitem, ident, 
transition,signal&#41;&#58;
&nbsp; File 
"/usr/lib/python2.5/site-packages/tinyerp-server/workflow/wkf_expr.py", line 
99, in check
&nbsp; &nbsp; ok = ok and _eval_expr&#40;cr, ident, workitem, 
transition&#91;'condition'&#93;&#41;
&nbsp; File 
"/usr/lib/python2.5/site-packages/tinyerp-server/workflow/wkf_expr.py", line 
83, in _eval_expr
&nbsp; &nbsp; ret = eval&#40;line, env&#41;
&nbsp; File "<string>", line 1, in <module>
NameError&#58; name 'res_company' is not defined


How do I specify this condition for use on the Partner form?

Regards,
Gerry




_______________________________________________
Tinyerp-users mailing list
http://tiny.be/mailman/listinfo/tinyerp-users

Reply via email to