Granny's Programming Pearls
"inside of every large program is a small program struggling to get out"
JavaRanch.com/granny.jsp
The moose likes Spring and the fly likes Implementing Sorting with Pagination in Spring MVC Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Frameworks » Spring
Bookmark "Implementing Sorting with Pagination in Spring MVC" Watch "Implementing Sorting with Pagination in Spring MVC" New topic
Author

Implementing Sorting with Pagination in Spring MVC

shwetank sharma
Greenhorn

Joined: Jan 09, 2011
Posts: 10

Hi,

I want to implement paging and sorting on my Spring MVC application.

Paging I have easily achieved using PagedListHolder and working fine, now I need to implement sorting on each page and column.

Also the sorting need to be done on page not on complete list.

Restriction is that we cannot use Display Tag library.

~~Cheers~~
Shwetank
Bill Gorder
Bartender

Joined: Mar 07, 2010
Posts: 1648
    
    7

PagedListHolder takes a SortDefinition. Create a new MutableSortDefinition if the one registered for you with default values is not suitable.

Then you can call doSort on the pagedListHolder.


[How To Ask Questions][Read before you PM me]
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Implementing Sorting with Pagination in Spring MVC
 
Similar Threads
jgrid - Spring MVC CRUD operation with pagination and without page refresh
Paging and Sorting in JSF
How to do Paging
[Spring Web Flow 2] Can Spring Web Flow work with Spring Web MVC?
What is the difference between static vs dynamic in SQLJ