[Zope] Product Devel: How can I use a function for manage_addMyProductForm?
jkinsley
jkinsley@bticc.net
Fri, 8 Mar 2002 12:06:36 -0500 (EST)
Hi,
I am developing a product and I want to be able to conduct some tests
before presenting the add product form so that the results of the
test are available in the form.
I tried:
def manage_addMyProductForm(client, REQUEST. *args, **kw):
"""Perform tests and display add form."""
if test1: passed_test1=1
else: passed_test1=0
if not test2: passed_test2=1
else: passed_test2=0
form=PageTemplateFile('forms/manage_addMyProductForm.zpt',
globals(),
__name__='addMyProductFormPT')
return form(client, REQUEST, args=args,
pass_test1=pass_test1,
pass_test2=pass_test2)
The problem with this is the call to form() produces an
AttributeError on 'other in
Shared.DC.Scripts.Bindings._getTraverseSubpath() when
REQUEST.other.get('TraverseSubpath') is called.
I get the impression I am missing an argument in the call to form().
Thanks in advance
Regards,
Jarrod Kinsley
BTI Communications Co.