I'd like to add some features to TG's pagination and would like some
feedback.
The first is SQLAlchemy support. paginate.py uses SQLObject's
SelectResults to order the result set. SA has similar functionality in
an extension called SelectResults which can be used as a near drop in
replacement.
The second is session support. The URI's get long and complex, so if
sessions are in use, only the change information has to be passed in
the URI and everything else (like the data query params) can be stored
in a session. I've currently got it as an option in the decorator
params. @paginate(..., use_session=True). One thing I'm not sure
about yet is how to keep session data for the DataGrid widget from
overwriting another paginating DataGrid instance's session data. Right
now I'm using the id (id(func)) of the func passed into the decorator's
"decorated" function.
Third. All field sorting. Instead of only sorting by one field, each
sorting selection will build on the last.
My current implementation of these features does not change the default
behavior. The extra sorting capability is only present when using
sessions. Also it includes this bug fix:
http://trac.turbogears.org/turbogears/ticket/1044
which I submitted yesterday.
I'd like to hear opinions on these additions a well as requests for
other features.
Randall
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---