[Zope-DB] Get value from selected item
Dieter Maurer
dieter@handshake.de
Wed, 29 Jan 2003 21:56:13 +0100
Kerstin Petersen wrote at 2003-1-29 12:51 +0100:
> ... complex situation using "ZSQL Method"s inside a "dtml-in" loop ...
I am not sure that I understood your problem.
Nevertheless, I think that parameters for your DTML objects and
Z SQL Methods are the solution.
DTML objects can uses all variables defined in the DTML namespace
as (implicit) parameters.
You can call Z SQL Methods with explicit keyword parameters (otherwise,
they use the REQUEST objects to find the parameter values).
You code will somehow look like
<dtml-in getMitarbeiter>
<a href="<dtml-var getEMailOrMitarbeiterNr>"> ...
with "getEMailOfMitarbeiterNr" somehow like:
<dtml-return "getEMailSQL(Mitarbeiter= MitarbeiterNr)[0].EMail">
By the way, I would not use DTML objects for gluing, but Python Scripts!
Dieter