I'm not sure this is the correct mailing list, but I am trying to
create a sprox table outside of admin and I am getting a pylon error.
The table works OKAY in admin.  The pylon error seems to come up when
python trys to iteritems() menu_items which does not exist.  Any
suggestions??

class DepositTable(TableBase):
    __model__ = Deposit
deposit_table = DepositTable(DBSession)

class DepositTableFiller(TableFiller):
    __model__ = Deposit
deposit_table_filler = DepositTableFiller(DBSession)

in the rootcontroller
deposit = DepositController(DBSession,menu_items=None)


Pylons error.

Module ?:22 in <Expression u'iter(sorted
(tmpl_context.menu_items.iteritems()))'>          view
<<      <div style="float:left; padding-left:0px;">
               <ul id="menu_items" py:if="hasattr(tmpl_context,
'menu_items')">
                   <li py:for="lower, item in sorted
(tmpl_context.menu_items.iteritems())"><a href="../$lower">
$item.__name__</a></li>
               </ul>
           </div>
>>  <li py:for="lower, item in sorted(tmpl_context.menu_items.iteritems())"><a 
>> href="../$lower">$item.__name__</a></li>
Module genshi.template.eval:321 in lookup_attr         view
Module genshi.template.eval:405 in undefined         view
UndefinedError: '' has no member named "iteritems"
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"TurboGears" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/turbogears?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to