Hello
# fields for Login history
active4_status_form=DataGrid(fields=[DataGrid.Column('visit_id','visit_id','VISIT_ID'),
DataGrid.Column('user_name','user_name','USER_NAME'),DataGrid.Column('created','created','CREATED')
,DataGrid.Column('expiry','expiry','EXPIRY')])
# query for login history for in tg identity
sq2='SELECT first 5
visit.id,tg_user.user_name,visit.created,visit.expiry FROM
tg_user,visit,visit_identity WHERE (((visit.visit_key) =
(visit_identity.visit_key)) AND ((visit_identity.user_id) =
(tg_user.id))) ORDER BY visit.created DESC'
myloginhistory=c.queryAll(sq2)
Question is here :
How to best send the query output to the datagrid ?
Is there any way to have the result of sqlbuilder queryAll translated
into a SelectResult type ?
return dict(data=???????,list_widget=active4_status_form)
#body of kid
<h2> Registered Users History - last 5 logins shown</h2> <h3> <span
py:content="get_time()">now</span> </h3>
${list_widget.display(data, show_actions=False,
show_add_link='',add_link_title='',delete_link_msg='')}
Thanks
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---