On May 17, 2008, at 8:37 AM, Chris Barham wrote:

Hi,

I've put together a new Appfuse project which demonstrates how to enhance the List screens. DisplayTag as provided has issues with large datasets, (it retrieves all the records every time), and sorting via column headings does not work for the entire dataset, only those on screen at the time.

I've built a project which addresses these issues, using Hibernate Criteria and extensions to DisplayTags PaginatedList interface which gets DisplayTag to hand off all requests for sorting and paging to the new implementation of PaginatedList.

The Google Code project is checked in to: http://code.google.com/p/pagingappfuse/ feel free to check out the code and comment. (instructions here: http://code.google.com/p/pagingappfuse/source/checkout )

There are instructions regarding the steps taken on the project wiki page here: http://code.google.com/p/pagingappfuse/wiki/PagingSorting

Cheers,
Chris

Chris,

Your tutorial was really excellent. I have two issues, that I was wondering if someone on the list would be able to help with:

1. I notice you're using DetachedCriteria in your Hibernate implementation. Does anyone know what the best method to would approach this would be with JPA? Is there any equivalent using the JPA API?

2. One other issue (that I'd be happy to help work on, since it benefits me), is with modular Appfuse-based applications - which I tend to use pretty much exclusively.

I'm not too strict of a purist when it comes to keeping the DAO/ Service/Web layers decoupled from each other (or at least as long as the layers only know about each other in one direction), but this solution does start to couple things together. This is particularly noticeable if you use the modular archetype. as you would end up having to have the DisplayTag as a dependency in your *-core module.

Parts of this problem would have a simple resolution, such as recreating a SortOrderEnum or passing a string for sort order to your DAO. However, pushing the classes in the helper package you created class down to the *-core module certainly would make DisplayTag a dependency.

Thanks,

Alex
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to