Grails

Improve 'paginate' tag to support BIG tables (limit number of pages displayed) in scaffolded views

Details

  • Type: Improvement Improvement
  • Status: Closed Closed
  • Priority: Major Major
  • Resolution: Fixed
  • Affects Version/s: 0.4
  • Fix Version/s: 0.5-RC1
  • Component/s: Scaffolding
  • Labels:
    None
  • Patch attached:
    Yes

Description

See http://www.nabble.com/Exercising-Grails-with-BIG-tables-tf2845407.html

Patch attached (i think the changes although correct, are not very... "elegant", maybe someone can improve them)

Also, the corner cases where somehow tested (not fully 100% ultra tested)

Activity

Hide
Marcel Overdijk added a comment -

Added maxsteps attribute to paginate tag to limit steps in case of big tables.

If not set maxsteps is automatically set to 10 page steps (just like the max attribute).
In case of big tables where more steps would be displayed then the maxsteps attribute, the number of steps are limited to maxsteps.
When the steps are limited, also a first and last step link is displayed next to the actual steps.

This looks like [Previous 1 .. 5 6 7 8 9 10 11 12 13 14 .. 22 Next]

The breadcrumd attribute is deprecated.

Also updated main.css to add some spacing between steps.

Show
Marcel Overdijk added a comment - Added maxsteps attribute to paginate tag to limit steps in case of big tables. If not set maxsteps is automatically set to 10 page steps (just like the max attribute). In case of big tables where more steps would be displayed then the maxsteps attribute, the number of steps are limited to maxsteps. When the steps are limited, also a first and last step link is displayed next to the actual steps. This looks like [Previous 1 .. 5 6 7 8 9 10 11 12 13 14 .. 22 Next] The breadcrumd attribute is deprecated. Also updated main.css to add some spacing between steps.

People

Vote (1)
Watch (0)

Dates

  • Created:
    Updated:
    Resolved: