cg_edit - added pagination