refactor pagination using render

page 412
add admin attribute

page 417