OPSK-74 - fix to 500 error when trying filter for non existing item

e.g. studies/15/data_files, when study#15 doesnt exist, will now create a 404 error
some refactoring of index_pager code