[Zope] zClasses, newbie

Dave Walker lockjaw@cybernet2k.com
Sat, 2 Oct 1999 10:30:09 -0400


This is a multi-part message in MIME format.

------=_NextPart_000_000A_01BF0CC1.1A696740
Content-Type: text/plain;
	charset="Windows-1252"
Content-Transfer-Encoding: 7bit

After my question about how to store objects, I blundered across zclasses,
and got some help that pointed me in that direction through email, as well.
I've been learning a lot.

Unfortunately, I'm still having trouble. I've created a
QuoteProduct/QuoteClass combination with person and quotetext as the
properties in the property sheet. I've directed the view to direct toward my
property sheet. Then...

<dtml-var tarheel_header>
<dtml-if "AUTHENTICATED_USER.has_role('Manager',this())">
<dtml-let new_id=get_new_id>
<dtml-call "REQUEST.set('id',new_id)">
</dtml-let>
<dtml-call "REQUEST.set('person','Dave Walker')">
<dtml-call "REQUEST.set('quotetext', 'I have a fat one')">
<dtml-with "manage_addProduct['QuoteProduct']">
<dtml-call "QuoteClass_add(_.None, _, NoRedir=1)">
</dtml-with>
<dtml-else><P>You do not have the proper security to access this resource.
</dtml-if>
<dtml-var tarheel_footer>

This gives me an error:

Zope Error
Zope has encountered an error while publishing this resource.
Error Type: AttributeError
Error Value: _u

<!--
Traceback (innermost last):
File C:\Program Files\tarheel\lib\python\ZPublisher\Publish.py, line 214, in
publish_module
File C:\Program Files\tarheel\lib\python\ZPublisher\Publish.py, line 179, in
publish
File C:\Program Files\tarheel\lib\python\Zope\__init__.py, line 201, in
zpublisher_exception_hook
(Object: ElementWithAttributes)
File C:\Program Files\tarheel\lib\python\ZPublisher\Publish.py, line 165, in
publish
File C:\Program Files\tarheel\lib\python\ZPublisher\mapply.py, line 160, in
mapply
(Object: addquote)
File C:\Program Files\tarheel\lib\python\ZPublisher\Publish.py, line 102, in
call_object
(Object: addquote)
File C:\Program Files\tarheel\lib\python\OFS\DTMLMethod.py, line 145, in
__call__
(Object: addquote)
File C:\Program Files\tarheel\lib\python\DocumentTemplate\DT_String.py, line
502, in __call__
(Object: addquote)
File C:\Program Files\tarheel\lib\python\DocumentTemplate\DT_With.py, line
148, in render
(Object: PARENTS[-1])
File C:\Program Files\tarheel\lib\python\DocumentTemplate\DT_With.py, line
148, in render
(Object: quotes)
File C:\Program Files\tarheel\lib\python\DocumentTemplate\DT_With.py, line
148, in render
(Object: manage_addProduct['QuoteProduct'])
File C:\Program Files\tarheel\lib\python\DocumentTemplate\DT_Util.py, line
321, in eval
(Object: QuoteClass_add(_.None, _, NoRedir=1))
File <string>, line 0, in ?
File C:\Program Files\tarheel\lib\python\OFS\DTMLMethod.py, line 141, in
__call__
(Object: QuoteClass_add)
File C:\Program Files\tarheel\lib\python\DocumentTemplate\DT_String.py, line
502, in __call__
(Object: QuoteClass_add)
File C:\Program Files\tarheel\lib\python\App\FactoryDispatcher.py, line 126,
in DestinationURL
AttributeError: (see above)
-->

I played with this thing all night last night, and while I think I'm REALLY
grooving to get some zClasses stuff done, I can't figure out what problem I
have and why, in order to actually start doing.

I'm thinking the key is in the traceback "File <string>, line 0, in ?"
above.  Of course, I'm only guessing.

------=_NextPart_000_000A_01BF0CC1.1A696740
Content-Type: text/x-vcard;
	name="Dave Walker.vcf"
Content-Transfer-Encoding: quoted-printable
Content-Disposition: attachment;
	filename="Dave Walker.vcf"

BEGIN:VCARD
VERSION:2.1
N:Walker;Dave;;
FN:Dave Walker
ORG:Libertarian Party of North Carolina;
TITLE:Press Secretary
TEL;HOME;VOICE:(919) 498-1494
ADR;WORK:;;2815 Montclair Cir;Sanford;NC;27330;United States of America
LABEL;WORK;ENCODING=3DQUOTED-PRINTABLE:2815 Montclair =
Cir=3D0D=3D0ASanford, NC 27330=3D0D=3D0AUnited States of America
URL:
URL:http://www.alltel.net/~lockjaw
BDAY:19680505
EMAIL;PREF;INTERNET:lockjaw@alltel.net
REV:19981103T042854Z
END:VCARD

------=_NextPart_000_000A_01BF0CC1.1A696740--