[Zope] Calling dynamic zsql method from zpt?
Ed Leafe
ed at leafe.com
Thu Nov 27 13:44:27 EST 2003
On Nov 27, 2003, at 3:53 PM, Nick Bower wrote:
> I've searched everywhere for a seamingly obvious thing to have in the
> documentation - how to call a dynamic zsql method from a zope page
> template using arguments.
>
> What I need is something like this:
>
> <div tal:define="sqlRows
> nocall:here/ZSQLTerritoryList(parent_id=parent_id)">
> <select name="country_list">
> <option value="">ANY</option>
> <option tal:repeat="sqlRow sqlRows" ...
> etc...
>
> but obviously the first line of code doesn't work. How else are
> variables passed do zsql methods from page templates?
What happens if you change the call to:
<div tal:define="sqlRows
python:here.ZSQLTerritoryList(parent_id=parent_id)">
___/
/
__/
/
____/
Ed Leafe
Linux Love:
unzip;strip;touch;finger;mount;fsck;more;yes;umount;sleep
More information about the Zope
mailing list