fix filter, change pagination, refactoring controller