Fixed pagination for contracts page